Compare commits

..
81 Commits
Author SHA1 Message Date
Harvey Zack 6a602f4054 artplayer@4.5.4 2022-08-01 22:00:16 +08:00
Harvey 41c39284c5 add Artplayer.TOUCH_MOVE_RATIO 2022-07-28 17:49:24 +08:00
Harvey 62988f04e0 add option.id 2022-07-28 10:12:43 +08:00
Harvey ec09bcdc92 update types.test.ts 2022-07-19 14:16:38 +08:00
Harvey Zack bcd8010ade update docs 2022-07-18 21:42:18 +08:00
Harvey Zack e793fea93e Merge branch 'master' of https://github.com/zhw2590582/ArtPlayer 2022-07-18 21:33:12 +08:00
Harvey Zack e6b4669ae9 Update thumbnails.js 2022-07-18 21:33:08 +08:00
Harvey 6c8df95f56 update build 2022-07-18 09:23:07 +08:00
Harvey fab5afed28 add screenfull.js 2022-07-18 09:22:34 +08:00
Harvey 9f1971f7d6 Update CHANGELOG_CN.md 2022-07-14 10:34:47 +08:00
Harvey 856ab536fb update d.ts 2022-07-14 10:24:48 +08:00
Harvey 7e65d486bc add Artplayer.AUTO_PLAYBACK_MIN 2022-07-14 10:23:45 +08:00
Harvey 60b61dd7b1 Update package.json 2022-07-14 09:40:51 +08:00
Harvey d8b0477cdc remove some disable 2022-07-14 09:35:45 +08:00
Harvey 99bae1fab2 artplayer@4.5.3 2022-07-13 16:16:18 +08:00
Harvey 2294620436 update airplayMix 2022-07-13 16:10:39 +08:00
Harvey a39a2a19da update sw.js 2022-07-13 16:02:12 +08:00
Harvey 5758d4c93e update docs 2022-07-13 15:42:25 +08:00
Harvey fbd1d2170a add airplay 2022-07-13 15:35:04 +08:00
Harvey 55c7560ce2 update d.ts 2022-07-11 11:18:36 +08:00
Harvey bff84f9cb6 update urlMix 2022-06-27 10:37:13 +08:00
Harvey 19d9e5cea9 update screenfull 2022-06-27 09:53:01 +08:00
Harvey b6c274b2cf update dep 2022-06-27 09:44:00 +08:00
Harvey f665cf9b92 Update CHANGELOG_CN.md 2022-06-22 17:48:49 +08:00
Harvey ace7540b9c Update CHANGELOG_CN.md 2022-06-22 17:27:41 +08:00
Harvey 1d5ff8adf0 update playMix.js 2022-06-22 17:22:15 +08:00
Harvey c09713d50f artplayer@4.5.2 2022-06-22 16:58:46 +08:00
Harvey 0971aba7f9 Update CHANGELOG_CN.md 2022-06-22 16:51:13 +08:00
Harvey d29f821338 artplayer@4.5.1 2022-06-22 16:50:34 +08:00
Harvey 1db287fb24 update docs 2022-06-22 16:47:41 +08:00
Harvey eb9e42c8f5 update style 2022-06-22 14:35:03 +08:00
Harvey e48c50956d update autoPlayback 2022-06-22 14:27:42 +08:00
Harvey 691202ace4 artplayer-plugin-ads@1.0.4 2022-06-22 10:31:39 +08:00
Harvey 1d4b2d58ac artplayer-plugin-ads@1.0.3 2022-06-22 09:37:50 +08:00
Harvey d81f9d4f65 artplayer-plugin-ads@1.0.2 2022-06-21 14:55:27 +08:00
Harvey 7a2fb8302d Update test.png 2022-06-21 14:38:12 +08:00
Harvey dbac833a26 update mobile demo 2022-06-21 14:30:53 +08:00
Harvey d148e7d9e5 update mobile demo 2022-06-21 14:06:47 +08:00
Harvey 8d04f11048 update mobile demo 2022-06-21 13:57:14 +08:00
Harvey 829d3a4b42 update mobile demo 2022-06-21 13:49:45 +08:00
Harvey a831975f4f Fix test error 2022-06-21 11:13:40 +08:00
Harvey 25d2319287 artplayer-plugin-ads@1.0.0 2022-06-21 10:52:33 +08:00
Harvey d1ead6c543 Update sw.js 2022-06-21 10:46:03 +08:00
Harvey 0149a6e557 update docs 2022-06-21 10:45:20 +08:00
Harvey 35856b745f add ads loading 2022-06-21 10:32:31 +08:00
Harvey 667b7f16e1 Update CHANGELOG_CN.md 2022-06-21 10:09:41 +08:00
Harvey 910c020488 add artplayer-plugin-ads 2022-06-21 10:08:55 +08:00
Harvey 463e05fcc0 Update package.json 2022-06-21 10:02:57 +08:00
Harvey 9a2fd6d9fd update 2022-06-21 10:01:07 +08:00
Harvey Zack 0535b798b2 update 2022-06-20 22:10:24 +08:00
Harvey 199c15ff3f update 2022-06-20 18:17:50 +08:00
Harvey 830720790e update 2022-06-20 17:52:00 +08:00
Harvey 3dea070ade update 2022-06-20 17:23:05 +08:00
Harvey 9716f97a51 update 2022-06-20 16:27:06 +08:00
Harvey ff1f38aeb7 update 2022-06-20 15:12:59 +08:00
Harvey 640360abd7 update 2022-06-20 11:44:00 +08:00
Harvey 0c70663345 update ads demo 2022-06-20 11:13:07 +08:00
Harvey a4d7ff721b init artplayerPluginAds 2022-06-20 10:29:39 +08:00
Harvey 13ace1b8a8 update docs 2022-06-20 10:12:24 +08:00
Harvey 7bbe1ed0be remove ads 2022-06-20 10:09:20 +08:00
Harvey 92f751250e Update package.json 2022-06-17 15:51:29 +08:00
Harvey 422728844a update docs 2022-06-13 15:02:32 +08:00
Harvey 107d884274 add vue2 demo 2022-06-13 15:00:06 +08:00
Harvey 102037dd42 artplayer-plugin-danmuku@4.4.8 2022-06-13 13:28:03 +08:00
Harvey dce698a648 artplayer@4.4.7 2022-06-13 11:31:59 +08:00
Harvey Zack 7cbf28e134 增加弹幕库解析的兼容 2022-06-12 20:17:20 +08:00
Harvey Zack 1a638c490a Update package.json 2022-06-12 19:57:33 +08:00
Harvey Zack 47c2fab768 artplayer@4.4.6 2022-06-11 14:19:39 +08:00
dependabot[bot] 064841f555 Bump lerna from 4.0.0 to 5.1.1
Bumps [lerna](https://github.com/lerna/lerna/tree/HEAD/core/lerna) from 4.0.0 to 5.1.1.
- [Release notes](https://github.com/lerna/lerna/releases)
- [Changelog](https://github.com/lerna/lerna/blob/main/core/lerna/CHANGELOG.md)
- [Commits](https://github.com/lerna/lerna/commits/v5.1.1/core/lerna)

---
updated-dependencies:
- dependency-name: lerna
  dependency-type: direct:production
  update-type: version-update:semver-major
...

Signed-off-by: dependabot[bot] <support@github.com>
2022-06-10 10:55:44 +08:00
Harvey 530448c3b4 修改匹配 XML 弹幕的正则表达式 2022-06-08 16:22:27 +08:00
Genteure 19061122b2 修改匹配 XML 弹幕的正则表达式 2022-06-08 16:21:22 +08:00
Harvey edfc95e4c3 回滚到用正则解析弹幕xml 2022-06-08 10:15:16 +08:00
Harvey 8cedc12387 Update CHANGELOG_CN.md 2022-06-08 10:00:20 +08:00
Harvey e2558dafc0 使用DOMParser解析弹幕xml 2022-06-08 10:00:04 +08:00
Genteure d644d322c3 使用 DOMParser 解析弹幕 XML 文件
这样的实现更标准,主要有两个优点:
1. 能正确处理转义过的字符,如 `<d p="2,1,25,16777215,0,0,0,0">&lt;&lt;&lt;&lt;</d>`
2. 能支持其他“兼容”B站弹幕XML格式的弹幕文件
2022-06-08 09:59:11 +08:00
Harvey 3d4f8ce3aa 调整字幕字体大小参数 2022-06-06 14:58:42 +08:00
Harvey Zack a10a9f9507 Update artplayer-plugin-danmuku.d.ts 2022-06-04 11:51:53 +08:00
Harvey Zack b6254f41bc Update artplayer.d.ts 2022-06-04 11:49:01 +08:00
Harvey Zack 86d7b380d5 add danmuku d.ts 2022-06-04 11:32:18 +08:00
Harvey Zack d6b36b49fa artplayer@4.4.5 2022-06-02 21:39:45 +08:00
Harvey 49f4ac5ca9 Update CHANGELOG_CN.md 2022-05-26 13:39:21 +08:00
230 changed files with 4630 additions and 2941 deletions

No files matched your search

+83
View File
@@ -5,7 +5,90 @@ The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/),
## [Unreleased]
## [4.5.4] - 2022-8-1
### Added
- 新增 `Artplayer.AUTO_PLAYBACK_MIN` 用于控制最小可以记忆播放的进度值,默认为 `5` 秒
- 新增 `Artplayer.TOUCH_MOVE_RATIO` 用于控制移动端进度条拖放比例,默认为 `0.5`
- `option.thumbnails` 添加可选的 `width` 和 `height`
- 新增播放器编号选项 `option.id`,可用于记忆播放时的唯一标识
## [4.5.3] - 2022-7-13
### Added
- `url` 选项允许传空字符串,可用于异步设置 `art.url`
```js
const art = new Artplayer({
url: '',
container: '.artplayer-app',
});
setTimeout(() => {
art.url = '/assets/sample/video.mp4';
}, 1000);
```
- `art.play()` 方法统一返回 `Promise`, `play` 事件也改为异步触发
```js
const art = new Artplayer({
url: '/assets/sample/video.mp4',
container: '.artplayer-app',
});
art.on('ready', async () => {
try {
await art.play();
console.log('播放成功');
} catch (error) {
console.log('播放失败', error.message);
}
})
```
- 新增 `airplay` (隔空播放) 功能,当前只在 Safari 下可用
```js
const art = new Artplayer({
url: '/assets/sample/video.mp4',
container: '.artplayer-app',
airplay: true,
});
```
## [4.5.2] - 2022-6-22
### Added
- 优化自动回放功能,让用户自行选择
## [4.5.0] - 2022-6-21
### Added
- 移除内置广告功能
- 新增广告插件
## [4.4.7] - 2022-6-13
### Added
- 兼容弹幕库 d.ts
- 更新依赖库
## [4.4.6] - 2022-6-11
### Added
- 添加弹幕库 d.ts
- 调整字幕字体大小参数
- 优化正则解析xml弹幕
## [4.4.5] - 2022-6-2
### Added
- 修复迷你模式时,主题色缺失的bug
## [4.4.3] - 2022-05-26
### Added
- 修复弹幕库销毁时,自定义挂载输入框的残留
- 修复迷你模式的尺寸计算错误
+45
View File
@@ -0,0 +1,45 @@
var art = new Artplayer({
container: '.artplayer-app',
url: '/assets/sample/video.mp4',
autoSize: true,
fullscreen: true,
fullscreenWeb: true,
plugins: [
artplayerPluginAds({
// html广告,假如是视频广告则忽略该值
html: '<img src="/assets/sample/poster.jpg">',
// 视频广告的地址
video: '/assets/sample/test1.mp4',
// 广告跳转网址,为空则不跳转
url: 'http://artplayer.org',
// 必须观看的时长,期间不能被跳过,单位为秒
// 当该值大于或等于totalDuration时,不能提前关闭广告
// 当该值等于或小于0时,则随时都可以关闭广告
playDuration: 5,
// 广告总时长,单位为秒
totalDuration: 10,
// 多语言支持
i18n: {
close: '关闭广告',
countdown: '%s秒',
detail: '查看详情',
canBeClosed: '%s秒后可关闭广告',
},
}),
],
});
// 广告被点击
art.on('artplayerPluginAds:click', (ads) => {
console.info('广告被点击', ads);
});
// 广告被跳过
art.on('artplayerPluginAds:skip', (ads) => {
console.info('广告被跳过', ads);
});
+1
View File
@@ -24,6 +24,7 @@ var art = new Artplayer({
backdrop: true,
playsInline: true,
autoPlayback: true,
airplay: true,
theme: '#23ade5',
lang: navigator.language.toLowerCase(),
whitelist: ['*'],
+1
View File
@@ -0,0 +1 @@
<?xml version="1.0" encoding="UTF-8"?><i><chatserver>chat.bilibili.com</chatserver><chatid>580770634</chatid><mission>0</mission><maxlimit>1500</maxlimit><state>0</state><real_name>0</real_name><source>k-v</source><d p="481.89400,1,25,16777215,1653692078,0,70e36298,1062005140992593408,11">可以去太湖捞捞试试(狗头保命</d><d p="265.37800,1,25,16777215,1653616680,0,88afabc0,1061372654017566976,11">好了,今天就到这,我感觉生物钟启动了,我要睡了</d><d p="777.55400,1,25,16777215,1653575476,0,9bcc00a2,1061027009955725568,11">当然是sha256(sha256(pw)+salt)</d><d p="13.88600,1,25,16777215,1653570775,0,966e6348,1060987581535333376,11">Swift~~~</d><d p="454.63400,1,25,16777215,1652717912,0,6d2da793,1053833248746068480,11">搞个共享数据库,像挖矿一样每个人算好的都可以上传</d><d p="177.13900,1,25,16777215,1652453333,0,fb4f660b,1051613793517396736,11">有点懵,但感到很震撼</d><d p="22.57900,1,25,16777215,1652430212,0,bdb52a9e,1051419843691098880,11">哈希值</d><d p="58.06700,1,25,16777215,1652368788,0,e91e8413,1050904578150762496,11">有了粉碎机,家里就只剩下粉碎机了</d><d p="275.65900,5,25,16777215,1652354865,0,397b3aab,1050787785968982016,11">《我知道了》</d><d p="774.77900,1,25,16777215,1652256952,0,542886c4,1049966433997495040,11">奥卡姆剃刀</d><d p="352.26200,1,25,16777215,1652247365,0,139fd1a2,1049886011934382080,11">加盐只是通过不确定的盐来隐藏确定的原值,增加彩虹表的制作难度</d><d p="395.65900,1,25,16777215,1652169656,0,e2308d98,1049234139607279872,11">哈希冲突</d><d p="346.72900,1,25,16777215,1652112430,0,54ba448a,1048754095986328064,11">《彩虹表》</d><d p="653.60600,1,25,16777215,1652101305,0,5ec1b46c,1048660766959520768,11">哈哈,这个可以使git库瞬间挂掉</d><d p="461.75200,1,25,16777215,1652101091,0,5ec1b46c,1048658979179723264,11">做个超级字典,把最常用的组合记录下来就行了</d><d p="94.11200,1,25,16777215,1652100683,0,5ec1b46c,1048655552173002240,11">哈希根本不是加密,只是摘要算法</d><d p="386.19500,1,25,16777215,1652097650,0,c4cc4296,1048630114516051968,11">组合数学开始了</d><d p="414.69100,1,25,16777215,1652084321,0,fafcfbb0,1048518297794048256,11">设计者自己找不到(doge</d><d p="59.62300,5,25,16707842,1652052664,0,971041b8,1048252744781197824,11">我会!</d><d p="445.99300,1,25,16777215,1651998604,0,53d75164,1047799249896694016,11">哎嘿 很勇哦</d><d p="641.24300,1,25,16777215,1651991247,0,ed4717ed,1047737536325133312,11">但是加盐还是有用</d><d p="408.97200,1,25,16777215,1651977907,0,4bd9a2d7,1047625636933279232,11">可以存在一个笼子里一只鸽子也没有</d><d p="511.84900,1,25,16777215,1651972503,0,f0826639,1047580298436422144,11">哈希冲突</d><d p="520.96700,5,25,16777215,1651967260,0,27acb016,1047536317854342656,11">列巴的列(补充</d><d p="558.75200,1,25,16777215,1651940306,0,860de6bd,1047310216540149504,11">《模仿游戏》来了</d><d p="505.15000,1,25,16777215,1651940233,0,860de6bd,1047309599239544064,11">电影《模仿游戏》</d><d p="488.98600,1,25,16777215,1651927542,0,44f3ad45,1047203142191739648,11">俺姆昂鸽瑞!</d><d p="586.48600,1,25,16777215,1651849723,0,29026d4b,1046550345196703488,11">烫烫烫哈哈哈哈哈哈!</d><d p="102.05200,1,25,16777215,1651839216,0,1336ac64,1046462209011973120,11">王小云,指数级缩短了MD5的碰撞时间</d><d p="55.82000,1,25,16777215,1651825875,0,38443e73,1046350293337386752,11">一半我做的登录都会生成一个密码盐,存在本地</d><d p="681.33200,1,25,16777215,1651819803,0,fc3f2a25,1046299363606827264,11">加盐也对付不了碰撞 只能对付彩虹表</d><d p="18.26500,1,25,16777215,1651816441,0,cf2bea01,1046271154899279872,11">A(欸)P(劈)P(劈)</d><d p="567.29500,1,25,16777215,1651812016,0,5309839c,1046234041289880832,11">你错了,图灵对这个并不熟</d><d p="504.07300,1,25,16777215,1651806653,0,58c10bda,1046189050064611584,11">加盐</d><d p="350.22000,1,25,16777215,1651798844,0,d3cbe582,1046123548323639040,11">所以要加盐</d><d p="59.55900,1,25,16777215,1651793262,0,dc9b4d74,1046076722316952576,11">哈希有很小很小的概率把两个不一样的东西映射成一个</d><d p="468.25000,1,25,16777215,1651762009,0,1e90bb3e,1045814547245588736,11">量子计算:这个我熟</d><d p="565.29300,1,25,16777215,1651722446,0,1b70a4,1045482667682264064,11">图灵说:这个我熟</d><d p="652.84300,1,25,16777215,1651713497,0,9e19237c,1045407604815323904,11">图片隐写</d><d p="391.57200,1,25,16777215,1651622858,0,d78de8a,1044647266629422336,11">吾生而有崖</d><d p="273.57700,1,25,16777215,1651509100,0,c8ed82e9,1043692993388749056,11">《也可以100行以内》</d><d p="494.74000,1,25,16777215,1651405107,0,8262fe93,1042820639116808192,11">数据库!</d><d p="753.23500,1,25,16777215,1651385801,0,ea9eeeda,1042658687317412864,11">火速换RSA!</d><d p="747.76900,1,25,16777215Line truncated
Binary file not shown.

After

Width:  |  Height:  |  Size: 135 KiB

+95 -31
View File
@@ -172,9 +172,9 @@ type Component = {
add(option: ComponentOption): HTMLElement;
};
type PluginFunction = (art: Artplayer) => any;
type WhitelistFunction = (ua: string) => Boolean;
type PluginFunction = (art: Artplayer) => any | ((option: any) => (art: Artplayer) => any);
type CustomType = (video: HTMLVideoElement, url: string, art: Artplayer) => any;
type WhitelistFunction = (ua: string) => Boolean;
type EventCallback = (event: Event) => any;
type SubtitleOption = {
@@ -199,14 +199,12 @@ type SubtitleOption = {
encoding?: string;
};
type AdsOption = {
/**
* The ads video url
*/
url: string;
};
type Option = {
/**
* The player id
*/
id: string;
/**
* The container mounted by the player
*/
@@ -372,6 +370,11 @@ type Option = {
*/
autoOrientation?: boolean;
/**
* Whether use airplay
*/
airplay?: boolean;
/**
* Custom plugin list
*/
@@ -382,11 +385,6 @@ type Option = {
*/
whitelist?: (string | WhitelistFunction | RegExp)[];
/**
* Custom ads list
*/
ads?: AdsOption[];
/**
* Custom layer list
*/
@@ -460,6 +458,16 @@ type Option = {
* The thumbnail column size
*/
column?: number;
/**
* The thumbnail width
*/
width?: number;
/**
* The thumbnail height
*/
height?: number;
};
/**
@@ -507,6 +515,67 @@ type Option = {
type AspectRatio = 'default' | '4:3' | '16:9' | void;
type PlaybackRate = 0.5 | 0.75 | 1.0 | 1.25 | 1.5 | 1.75 | 2.0 | void;
type Flip = 'normal' | 'horizontal' | 'vertical' | void;
type Events =
| 'video:canplay'
| 'video:canplaythrough'
| 'video:complete'
| 'video:durationchange'
| 'video:emptied'
| 'video:ended'
| 'video:loadeddata'
| 'video:loadeddata'
| 'video:loadedmetadata'
| 'video:pause'
| 'video:play'
| 'video:playing'
| 'video:progress'
| 'video:ratechange'
| 'video:seeked'
| 'video:seeking'
| 'video:stalled'
| 'video:suspend'
| 'video:timeupdate'
| 'video:volumechange'
| 'video:waiting'
| 'hotkey'
| 'destroy'
| 'customType'
| 'url'
| 'subtitleUpdate'
| 'subtitleLoad'
| 'subtitleSwitch'
| 'focus'
| 'blur'
| 'dblclick'
| 'click'
| 'setBar'
| 'hover'
| 'mousemove'
| 'resize'
| 'view'
| 'aspectRatio'
| 'autoHeight'
| 'autoSize'
| 'ready'
| 'error'
| 'flip'
| 'fullscreen'
| 'fullscreenWeb'
| 'loop'
| 'mini'
| 'pause'
| 'pip'
| 'playbackRate'
| 'play'
| 'screenshot'
| 'seek'
| 'subtitleOffset'
| 'switch'
| 'restart'
| 'volume'
| 'lock'
| 'selector'
| string;
declare class Player {
get aspectRatio(): AspectRatio;
@@ -563,15 +632,16 @@ declare class Player {
set theme(theme: string);
get subtitleOffset(): number;
set subtitleOffset(time: number);
pause(): any;
play(): any;
toggle(): any;
pause(): void;
play(): Promise<void>;
toggle(): void;
attr(key: string, value: any): void;
switchUrl(url: string): Promise<string>;
switchQuality(url: string): Promise<string>;
getDataURL(): Promise<string>;
getBlobUrl(): Promise<string>;
screenshot(): Promise<string>;
airplay(): void;
}
declare class Artplayer extends Player {
@@ -624,6 +694,7 @@ declare class Artplayer extends Player {
static SCROLL_TIME: number;
static SCROLL_GAP: number;
static AUTO_PLAYBACK_MAX: number;
static AUTO_PLAYBACK_MIN: number;
static RECONNECT_TIME_MAX: number;
static RECONNECT_SLEEP_TIME: number;
static CONTROL_HIDE_TIME: number;
@@ -634,11 +705,13 @@ declare class Artplayer extends Player {
static INFO_LOOP_TIME: number;
static FAST_FORWARD_VALUE: number;
static FAST_FORWARD_TIME: number;
static TOUCH_MOVE_RATIO: number;
on(name: Events, fn: Function, ctx?: object): void;
once(name: Events, fn: Function, ctx?: object): void;
emit(name: Events): void;
off(name: Events, callback?: Function): void;
on(name: string, fn: Function, ctx?: object): void;
once(name: string, fn: Function, ctx?: object): void;
emit(name: string): void;
off(name: string, callback?: Function): void;
query(selector: string): HTMLElement;
proxy(
target: HTMLElement,
@@ -731,6 +804,7 @@ declare class Artplayer extends Player {
readonly plugins: {
readonly id: number;
add(plugin: PluginFunction): Artplayer['plugins'];
[pluginName: string]: any;
};
readonly i18n: {
@@ -756,16 +830,6 @@ declare class Artplayer extends Player {
switch(url: string, option?: SubtitleOption): Promise<string>;
};
readonly ads: {
index: number;
isEnd: boolean;
playing: boolean;
current: AdsOption;
prev: AdsOption;
next: AdsOption;
end(): void;
};
readonly mobile: object;
readonly player: Player;
+7
View File
@@ -0,0 +1,7 @@
/*!
* artplayer-plugin-ads.js v1.0.4
* Github: https://github.com/zhw2590582/ArtPlayer
* (c) 2017-2022 Harvey Zack
* Released under the MIT License.
*/
!function(e,n,l,t,i){var a="undefined"!=typeof globalThis?globalThis:"undefined"!=typeof self?self:"undefined"!=typeof window?window:"undefined"!=typeof global?global:{},r="function"==typeof a.parcelRequirea5da&&a.parcelRequirea5da,o=r.cache||{},d="undefined"!=typeof module&&"function"==typeof module.require&&module.require.bind(module);function p(n,l){if(!o[n]){if(!e[n]){var t="function"==typeof a.parcelRequirea5da&&a.parcelRequirea5da;if(!l&&t)return t(n,!0);if(r)return r(n,!0);if(d&&"string"==typeof n)return d(n);var i=new Error("Cannot find module '"+n+"'");throw i.code="MODULE_NOT_FOUND",i}u.resolve=function(l){var t=e[n][1][l];return null!=t?t:l},u.cache={};var s=o[n]=new p.Module(n);e[n][0].call(s.exports,u,s,s.exports,this)}return o[n].exports;function u(e){var n=u.resolve(e);return!1===n?{}:p(n)}}p.isParcelRequire=!0,p.Module=function(e){this.id=e,this.bundle=p,this.exports={}},p.modules=e,p.cache=o,p.parent=r,p.register=function(n,l){e[n]=[function(e,n){n.exports=l},{}]},Object.defineProperty(p,"root",{get:function(){return a.parcelRequirea5da}}),a.parcelRequirea5da=p;for(var s=0;s<n.length;s++)p(n[s]);var u=p(l);"object"==typeof exports&&"undefined"!=typeof module?module.exports=u:"function"==typeof define&&define.amd&&define((function(){return u}))}({E13ST:[function(e,n,l){var t=e("@parcel/transformer-js/src/esmodule-helpers.js");t.defineInteropFlag(l);var i=e("bundle-text:./style.less"),a=t.interopDefault(i);function r(e){return n=>{const{template:{$player:l},icons:{volume:t,volumeClose:i,fullscreenOn:a,fullscreenOff:r,loading:o},constructor:{validator:d,utils:{query:p,append:s,setStyle:u}}}=n;e=d({html:"",video:"",url:"",playDuration:5,totalDuration:10,i18n:{close:"关闭广告",countdown:"%s秒",detail:"查看详情",canBeClosed:"%s秒后可关闭广告"},...e},{html:"?string",video:"?string",url:"?string",playDuration:"number",totalDuration:"number",i18n:{close:"string",countdown:"string",detail:"string",canBeClosed:"string"}});let c=null,y=null,f=null,g=null,m=null,v=null,x=0,h=null,b=!1,w=!1,D=!1;function j(e,n){return n.replace("%s",e)}function k(){b=!0,n.play(),e.video&&c.pause(),u(n.template.$ads,"display","none"),n.emit("artplayerPluginAds:skip",e)}function O(){b||(h=setTimeout((()=>{x+=1;const n=e.playDuration-x;n>=1?f.innerHTML=j(n,e.i18n.canBeClosed):(f.innerHTML=e.i18n.close,D||(D=!0)),g.innerHTML=j(e.totalDuration-x,e.i18n.countdown),x>=e.totalDuration?k():O()}),1e3))}function $(){b||clearTimeout(h)}function P(){w||(w=!0,function(){n.template.$ads=s(l,'<div class="artplayer-plugin-ads"></div>'),c=s(n.template.$ads,e.video?`<video class="artplayer-plugin-ads-video" src="${e.video}" loop playsInline></video>`:`<div class="artplayer-plugin-ads-html">${e.html}</div>`),v=s(n.template.$ads,'<div class="artplayer-plugin-ads-loading"></div>'),s(v,o),y=s(n.template.$ads,`<div class="artplayer-plugin-ads-timer"><div class="artplayer-plugin-ads-close">${e.playDuration<=0?e.i18n.close:j(e.playDuration,e.i18n.canBeClosed)}</div><div class="artplayer-plugin-ads-countdown">${j(e.totalDuration,e.i18n.countdown)}</div></div>`),f=p(".artplayer-plugin-ads-close",y),g=p(".artplayer-plugin-ads-countdown",y),e.playDuration>=e.totalDuration&&u(f,"display","none"),n.proxy(f,"click",(()=>{D&&k()})),m=s(n.template.$ads,`<div class="artplayer-plugin-ads-control"><div class="artplayer-plugin-ads-detail">${e.i18n.detail}</div><div class="artplayer-plugin-ads-muted"></div><div class="artplayer-plugin-ads-fullscreen"></div></div>`);const d=p(".artplayer-plugin-ads-detail",m),x=p(".artplayer-plugin-ads-muted",m),h=p(".artplayer-plugin-ads-fullscreen",m);if(e.url?n.proxy(d,"click",(()=>{window.open(e.url),n.emit("artplayerPluginAds:click",e)})):u(d,"display","none"),e.video){const e=s(x,t),l=s(x,i);u(l,"display","none"),n.proxy(x,"click",(()=>{c.muted=!c.muted,c.muted?(u(e,"display","none"),u(l,"display","inline-flex")):(u(e,"display","inline-flex"),u(l,"display","none"))}))}else u(x,"display","none");const b=s(h,a),w=s(h,r);u(w,"display","none"),n.proxy(h,"click",(()=>{n.fullscreen=!n.fullscreen,n.fullscreen?(u(b,"display","inline-flex"),u(w,"display","none")):(u(b,"display","none"),u(w,"display","inline-flex"))})),n.proxy(c,"click",(()=>{e.url&&window.open(e.url),n.emit("artplayerPluginAds:click",e)}))}(),n.pause(),e.video?(n.proxy(c,"error",k),n.proxy(c,"loadedmetadata",(()=>{O(),c.play(),u(y,"display","flex"),u(m,"display","flex"),u(v,"display","none")}))):(O(),u(y,"display","flex"),u(m,"display","flex"),u(v,"display","none")),n.proxy(document,"visibilitychange",(()=>{document.hidden?$():O()})))}return n.on("ready",(()=>{n.once("play",P),n.once("video:playing",P)})),{name:"artplayerPluginAds",skip:k,pause:$,play:O}}}if(l.default=r,r.env="production",r.version="1.0.4",r.build="1656294187607","undefined"!=typeof document&&!document.getElementById("artplayer-plugin-ads")){const e=document.createElement("style");e.id="artplayer-plugin-ads",e.textContent=a.default,document.head.appendChild(e)}"undefined"!=typeof Line truncated
+2 -2
View File
@@ -1,7 +1,7 @@
/*!
* artplayer-plugin-danmuku.js v4.4.3
* artplayer-plugin-danmuku.js v4.4.8
* Github: https://github.com/zhw2590582/ArtPlayer
* (c) 2017-2022 Harvey Zack
* Released under the MIT License.
*/
!function(t,e,n,i,r){var a="undefined"!=typeof globalThis?globalThis:"undefined"!=typeof self?self:"undefined"!=typeof window?window:"undefined"!=typeof global?global:{},o="function"==typeof a.parcelRequire93cf&&a.parcelRequire93cf,s=o.cache||{},u="undefined"!=typeof module&&"function"==typeof module.require&&module.require.bind(module);function l(e,n){if(!s[e]){if(!t[e]){var i="function"==typeof a.parcelRequire93cf&&a.parcelRequire93cf;if(!n&&i)return i(e,!0);if(o)return o(e,!0);if(u&&"string"==typeof e)return u(e);var r=new Error("Cannot find module '"+e+"'");throw r.code="MODULE_NOT_FOUND",r}m.resolve=function(n){var i=t[e][1][n];return null!=i?i:n},m.cache={};var d=s[e]=new l.Module(e);t[e][0].call(d.exports,m,d,d.exports,this)}return s[e].exports;function m(t){var e=m.resolve(t);return!1===e?{}:l(e)}}l.isParcelRequire=!0,l.Module=function(t){this.id=t,this.bundle=l,this.exports={}},l.modules=t,l.cache=s,l.parent=o,l.register=function(e,n){t[e]=[function(t,e){e.exports=n},{}]},Object.defineProperty(l,"root",{get:function(){return a.parcelRequire93cf}}),a.parcelRequire93cf=l;for(var d=0;d<e.length;d++)l(e[d]);var m=l(n);"object"==typeof exports&&"undefined"!=typeof module?module.exports=m:"function"==typeof define&&define.amd&&define((function(){return m}))}({E13ST:[function(t,e,n){var i=t("@parcel/transformer-js/src/esmodule-helpers.js");i.defineInteropFlag(n);var r=t("./danmuku"),a=i.interopDefault(r),o=t("./setting"),s=i.interopDefault(o);function u(t){return e=>{!function(t){const{version:e,utils:{errorHandle:n}}=t.constructor,i=e.split(".").map(Number);n(i[0]+i[1]/100>=4.04,`Artplayer.js@${e} 不兼容该弹幕库,请更新到 4.4.x 版本以上`)}(e);const n=new a.default(e,t);return s.default(e,n),{name:"artplayerPluginDanmuku",emit:n.emit.bind(n),load:n.load.bind(n),config:n.config.bind(n),hide:n.hide.bind(n),show:n.show.bind(n),get isHide(){return n.isHide},get isStop(){return n.isStop}}}}n.default=u,u.env="production",u.version="4.4.3",u.build="1653543397013","undefined"!=typeof window&&(window.artplayerPluginDanmuku=u)},{"./danmuku":"8Gtnh","@parcel/transformer-js/src/esmodule-helpers.js":"9v6Cv","./setting":"jAkJm"}],"8Gtnh":[function(t,e,n){var i=t("@parcel/transformer-js/src/esmodule-helpers.js");i.defineInteropFlag(n);var r=t("./bilibili"),a=t("./getDanmuTop"),o=i.interopDefault(a);class s{constructor(e,n){const{constructor:i,template:r}=e;if(this.utils=i.utils,this.validator=i.validator,this.$danmuku=r.$danmuku,this.$player=r.$player,this.art=e,this.queue=[],this.option={},this.$refs=[],this.isStop=!1,this.isHide=!1,this.timer=null,this.config(n),this.option.useWorker)try{this.worker=new Worker(t("27c3930ee158179a"))}catch(t){}this.start=this.start.bind(this),this.stop=this.stop.bind(this),this.reset=this.reset.bind(this),this.destroy=this.destroy.bind(this),e.on("video:play",this.start),e.on("video:playing",this.start),e.on("video:pause",this.stop),e.on("video:waiting",this.stop),e.on("fullscreen",this.reset),e.on("fullscreenWeb",this.reset),e.on("destroy",this.destroy),this.load()}static get option(){return{danmuku:[],speed:5,margin:["2%","25%"],opacity:1,color:"#FFFFFF",mode:0,fontSize:25,filter:()=>!0,antiOverlap:!0,useWorker:!0,synchronousPlayback:!1,lockTime:5,maxLength:100,minWidth:200,maxWidth:400,mount:void 0,theme:"dark",beforeEmit:()=>!0}}static get scheme(){return{danmuku:"array|function|string",speed:"number",margin:"array",opacity:"number",color:"string",mode:"number",fontSize:"number|string",filter:"function",antiOverlap:"boolean",useWorker:"boolean",synchronousPlayback:"boolean",lockTime:"number",maxLength:"number",minWidth:"number",maxWidth:"number",mount:"undefined|htmldivelement",theme:"string",beforeEmit:"function"}}get isRotate(){return this.art.plugins.autoOrientation&&this.art.plugins.autoOrientation.state}get marginTop(){const{clamp:t}=this.utils,e=this.option.margin[0],{clientHeight:n}=this.$player;if("number"==typeof e)return t(e,0,n);if("string"==typeof e&&e.endsWith("%")){return t(n*(parseFloat(e)/100),0,n)}return s.option.margin[0]}get marginBottom(){const{clamp:t}=this.utils,e=this.option.margin[1],{clientHeight:n}=this.$player;if("number"==typeof e)return t(e,0,n);if("string"==typeof e&&e.endsWith("%")){return t(n*(parseFloat(e)/100),0,n)}return s.option.margin[1]}filter(t,e){return this.queue.filter((e=>e.$state===t)).map(e)}getLeft(t){const e=t.getBoundingClientRect();return this.isRotate?e.top:e.left}getRef(){const t=this.$refs.pop();if(t)return t;const e=document.createElement("div");return e.style.cssText='\n user-select: none;\n position: absolute;\n white-space: pre;\n pointer-events: none;\n perspective: 500px;\n display: inline-block;\n will-change: transform;\n font-weight: normal;\n line-height: 1.125;\n visibility: hidden;\n font-family: SimHei, "Microsoft JhengHei", Arial, Helvetica, sans-serif;\n text-shadow: rgLine truncated
!function(t,e,n,i,r){var a="undefined"!=typeof globalThis?globalThis:"undefined"!=typeof self?self:"undefined"!=typeof window?window:"undefined"!=typeof global?global:{},o="function"==typeof a.parcelRequire93cf&&a.parcelRequire93cf,s=o.cache||{},l="undefined"!=typeof module&&"function"==typeof module.require&&module.require.bind(module);function u(e,n){if(!s[e]){if(!t[e]){var i="function"==typeof a.parcelRequire93cf&&a.parcelRequire93cf;if(!n&&i)return i(e,!0);if(o)return o(e,!0);if(l&&"string"==typeof e)return l(e);var r=new Error("Cannot find module '"+e+"'");throw r.code="MODULE_NOT_FOUND",r}m.resolve=function(n){var i=t[e][1][n];return null!=i?i:n},m.cache={};var d=s[e]=new u.Module(e);t[e][0].call(d.exports,m,d,d.exports,this)}return s[e].exports;function m(t){var e=m.resolve(t);return!1===e?{}:u(e)}}u.isParcelRequire=!0,u.Module=function(t){this.id=t,this.bundle=u,this.exports={}},u.modules=t,u.cache=s,u.parent=o,u.register=function(e,n){t[e]=[function(t,e){e.exports=n},{}]},Object.defineProperty(u,"root",{get:function(){return a.parcelRequire93cf}}),a.parcelRequire93cf=u;for(var d=0;d<e.length;d++)u(e[d]);var m=u(n);"object"==typeof exports&&"undefined"!=typeof module?module.exports=m:"function"==typeof define&&define.amd&&define((function(){return m}))}({E13ST:[function(t,e,n){var i=t("@parcel/transformer-js/src/esmodule-helpers.js");i.defineInteropFlag(n);var r=t("./danmuku"),a=i.interopDefault(r),o=t("./setting"),s=i.interopDefault(o);function l(t){return e=>{!function(t){const{version:e,utils:{errorHandle:n}}=t.constructor,i=e.split(".").map(Number);n(i[0]+i[1]/100>=4.04,`Artplayer.js@${e} 不兼容该弹幕库,请更新到 4.4.x 版本以上`)}(e);const n=new(0,a.default)(e,t);return(0,s.default)(e,n),{name:"artplayerPluginDanmuku",emit:n.emit.bind(n),load:n.load.bind(n),config:n.config.bind(n),hide:n.hide.bind(n),show:n.show.bind(n),get isHide(){return n.isHide},get isStop(){return n.isStop}}}}n.default=l,l.env="production",l.version="4.4.8",l.build="1656294188506","undefined"!=typeof window&&(window.artplayerPluginDanmuku=l)},{"./danmuku":"8Gtnh","./setting":"jAkJm","@parcel/transformer-js/src/esmodule-helpers.js":"9v6Cv"}],"8Gtnh":[function(t,e,n){var i=t("@parcel/transformer-js/src/esmodule-helpers.js");i.defineInteropFlag(n);var r=t("./bilibili"),a=t("./getDanmuTop"),o=i.interopDefault(a);class s{constructor(e,n){const{constructor:i,template:r}=e;if(this.utils=i.utils,this.validator=i.validator,this.$danmuku=r.$danmuku,this.$player=r.$player,this.art=e,this.queue=[],this.option={},this.$refs=[],this.isStop=!1,this.isHide=!1,this.timer=null,this.config(n),this.option.useWorker)try{this.worker=new Worker(t("27c3930ee158179a"))}catch(t){}this.start=this.start.bind(this),this.stop=this.stop.bind(this),this.reset=this.reset.bind(this),this.destroy=this.destroy.bind(this),e.on("video:play",this.start),e.on("video:playing",this.start),e.on("video:pause",this.stop),e.on("video:waiting",this.stop),e.on("fullscreen",this.reset),e.on("fullscreenWeb",this.reset),e.on("destroy",this.destroy),this.load()}static get option(){return{danmuku:[],speed:5,margin:["2%","25%"],opacity:1,color:"#FFFFFF",mode:0,fontSize:25,filter:()=>!0,antiOverlap:!0,useWorker:!0,synchronousPlayback:!1,lockTime:5,maxLength:100,minWidth:200,maxWidth:400,mount:void 0,theme:"dark",beforeEmit:()=>!0}}static get scheme(){return{danmuku:"array|function|string",speed:"number",margin:"array",opacity:"number",color:"string",mode:"number",fontSize:"number|string",filter:"function",antiOverlap:"boolean",useWorker:"boolean",synchronousPlayback:"boolean",lockTime:"number",maxLength:"number",minWidth:"number",maxWidth:"number",mount:"undefined|htmldivelement",theme:"string",beforeEmit:"function"}}get isRotate(){return this.art.plugins.autoOrientation&&this.art.plugins.autoOrientation.state}get marginTop(){const{clamp:t}=this.utils,e=this.option.margin[0],{clientHeight:n}=this.$player;if("number"==typeof e)return t(e,0,n);if("string"==typeof e&&e.endsWith("%")){return t(n*(parseFloat(e)/100),0,n)}return s.option.margin[0]}get marginBottom(){const{clamp:t}=this.utils,e=this.option.margin[1],{clientHeight:n}=this.$player;if("number"==typeof e)return t(e,0,n);if("string"==typeof e&&e.endsWith("%")){return t(n*(parseFloat(e)/100),0,n)}return s.option.margin[1]}filter(t,e){return this.queue.filter((e=>e.$state===t)).map(e)}getLeft(t){const e=t.getBoundingClientRect();return this.isRotate?e.top:e.left}getRef(){const t=this.$refs.pop();if(t)return t;const e=document.createElement("div");return e.style.cssText='\n user-select: none;\n position: absolute;\n white-space: pre;\n pointer-events: none;\n perspective: 500px;\n display: inline-block;\n will-change: transform;\n font-weight: normal;\n line-height: 1.125;\n visibility: hidden;\n font-family: SimHei, "Microsoft JhengHei", Arial, Helvetica, sans-serif;\n text-shadLine truncated
+1 -1
View File
@@ -4,4 +4,4 @@
* (c) 2017-2022 Harvey Zack
* Released under the MIT License.
*/
!function(e,t,i,n,o){var r="undefined"!=typeof globalThis?globalThis:"undefined"!=typeof self?self:"undefined"!=typeof window?window:"undefined"!=typeof global?global:{},s="function"==typeof r.parcelRequire4dc0&&r.parcelRequire4dc0,l=s.cache||{},a="undefined"!=typeof module&&"function"==typeof module.require&&module.require.bind(module);function h(t,i){if(!l[t]){if(!e[t]){var n="function"==typeof r.parcelRequire4dc0&&r.parcelRequire4dc0;if(!i&&n)return n(t,!0);if(s)return s(t,!0);if(a&&"string"==typeof t)return a(t);var o=new Error("Cannot find module '"+t+"'");throw o.code="MODULE_NOT_FOUND",o}u.resolve=function(i){var n=e[t][1][i];return null!=n?n:i},u.cache={};var d=l[t]=new h.Module(t);e[t][0].call(d.exports,u,d,d.exports,this)}return l[t].exports;function u(e){var t=u.resolve(e);return!1===t?{}:h(t)}}h.isParcelRequire=!0,h.Module=function(e){this.id=e,this.bundle=h,this.exports={}},h.modules=e,h.cache=l,h.parent=s,h.register=function(t,i){e[t]=[function(e,t){t.exports=i},{}]},Object.defineProperty(h,"root",{get:function(){return r.parcelRequire4dc0}}),r.parcelRequire4dc0=h;for(var d=0;d<t.length;d++)h(t[d]);var u=h(i);"object"==typeof exports&&"undefined"!=typeof module?module.exports=u:"function"==typeof define&&define.amd&&define((function(){return u}))}({"8nq87":[function(e,t,i){var n=e("@parcel/transformer-js/src/esmodule-helpers.js");n.defineInteropFlag(i);var o=e("tiny-emitter"),r=n.interopDefault(o),s=e("./utils");class l extends r.default{constructor(e={}){super(),this.processing=!1,this.option={},this.setup(Object.assign({},l.DEFAULTS,e)),this.video=l.creatVideo(),this.duration=0,this.inputChange=this.inputChange.bind(this),this.ondrop=this.ondrop.bind(this),this.option.fileInput.addEventListener("change",this.inputChange),this.option.fileInput.addEventListener("dragover",l.ondragover),this.option.fileInput.addEventListener("drop",l.ondrop)}static get DEFAULTS(){return{number:60,width:160,height:90,column:10,begin:0,end:NaN}}static ondragover(e){e.preventDefault()}ondrop(e){e.preventDefault();const t=e.dataTransfer.files[0];this.loadVideo(t)}setup(e={}){this.option=Object.assign({},this.option,e);const{fileInput:t,number:i,width:n,column:o}=this.option;if(this.errorHandle(t instanceof Element,"The 'fileInput' is not a Element"),"INPUT"!==t.tagName||"file"!==t.type){t.style.position="relative";const e=document.createElement("input");e.type="file",e.style.position="absolute",e.style.width="100%",e.style.height="100%",e.style.left="0",e.style.top="0",e.style.right="0",e.style.bottom="0",e.style.opacity="0",t.appendChild(e),this.option.fileInput=e}return["number","width","column","begin","end"].forEach((e=>{this.errorHandle("number"==typeof this.option[e],`The '${e}' is not a number`)})),this.option.number=s.clamp(i,10,1e3),this.option.width=s.clamp(n,10,1e3),this.option.column=s.clamp(o,1,1e3),this}static creatVideo(){const e=document.createElement("video");return e.style.position="absolute",e.style.top="-9999px",e.style.left="-9999px",e.muted=!0,e.controls=!0,document.body.appendChild(e),e}inputChange(e){const t=this.option.fileInput.files[0];this.loadVideo(t),e.target.value=""}loadVideo(e){if(e){const t=this.video.canPlayType(e.type);this.errorHandle("maybe"===t||"probably"===t,`Playback of this file format is not supported: ${e.type}`);const i=URL.createObjectURL(e);this.videoUrl=i,this.file=e,this.emit("file",this.file),this.video.src=i,this.emit("video",this.video)}}start(){if(!this.video.duration)return s.sleep(1e3).then((()=>this.start()));const{width:e,number:t,begin:i,end:n}=this.option,o=this.video.videoHeight/this.video.videoWidth*e;this.option.height=o,this.option.begin=s.clamp(i,0,this.video.duration),this.option.end=s.clamp(n||this.video.duration,i,this.video.duration),this.errorHandle(this.option.end>this.option.begin,"End time must be greater than the start time"),this.duration=this.option.end-this.option.begin,this.density=t/this.duration,this.errorHandle(this.file&&this.video,"Please select the video file first"),this.errorHandle(!this.processing,"There is currently a task in progress, please wait a moment..."),this.errorHandle(this.density<=1,`The preview density cannot be greater than 1, but got ${this.density}`);const r=this.creatScreenshotDate(),l=this.creatCanvas(),a=l.getContext("2d");this.emit("canvas",l);const h=r.map(((i,n)=>()=>new Promise((r=>{this.video.oncanplay=()=>{a.drawImage(this.video,i.x,i.y,e,o),l.toBlob((e=>{this.thumbnailUrl&&URL.revokeObjectURL(this.thumbnailUrl),this.thumbnailUrl=URL.createObjectURL(e),this.emit("update",this.thumbnailUrl,(n+1)/t),this.video.oncanplay=null,r()}))},this.video.currentTime=i.time}))));return this.processing=!0,s.runPromisesInSeries(h).then((()=>{this.processing=!1,this.emit("done")})).catch((e=>{throw this.processing=!1,this.emit("error",e.message),e}))}creatScreenshotDate(){const{number:e,width:t,height:i,column:n,begin:o}=this.option,r=this.duration/e,s=[o+r];for(;s.length<e;){const e=s[s.length-1];s.push(e+r)}return s.maLine truncated
!function(e,t,i,n,o){var r="undefined"!=typeof globalThis?globalThis:"undefined"!=typeof self?self:"undefined"!=typeof window?window:"undefined"!=typeof global?global:{},s="function"==typeof r.parcelRequire7b4c&&r.parcelRequire7b4c,l=s.cache||{},a="undefined"!=typeof module&&"function"==typeof module.require&&module.require.bind(module);function h(t,i){if(!l[t]){if(!e[t]){var n="function"==typeof r.parcelRequire7b4c&&r.parcelRequire7b4c;if(!i&&n)return n(t,!0);if(s)return s(t,!0);if(a&&"string"==typeof t)return a(t);var o=new Error("Cannot find module '"+t+"'");throw o.code="MODULE_NOT_FOUND",o}d.resolve=function(i){var n=e[t][1][i];return null!=n?n:i},d.cache={};var u=l[t]=new h.Module(t);e[t][0].call(u.exports,d,u,u.exports,this)}return l[t].exports;function d(e){var t=d.resolve(e);return!1===t?{}:h(t)}}h.isParcelRequire=!0,h.Module=function(e){this.id=e,this.bundle=h,this.exports={}},h.modules=e,h.cache=l,h.parent=s,h.register=function(t,i){e[t]=[function(e,t){t.exports=i},{}]},Object.defineProperty(h,"root",{get:function(){return r.parcelRequire7b4c}}),r.parcelRequire7b4c=h;for(var u=0;u<t.length;u++)h(t[u]);var d=h(i);"object"==typeof exports&&"undefined"!=typeof module?module.exports=d:"function"==typeof define&&define.amd&&define((function(){return d}))}({E13ST:[function(e,t,i){var n=e("@parcel/transformer-js/src/esmodule-helpers.js");n.defineInteropFlag(i);var o=e("tiny-emitter"),r=n.interopDefault(o),s=e("./utils");class l extends r.default{constructor(e={}){super(),this.processing=!1,this.option={},this.setup(Object.assign({},l.DEFAULTS,e)),this.video=l.creatVideo(),this.duration=0,this.inputChange=this.inputChange.bind(this),this.ondrop=this.ondrop.bind(this),this.option.fileInput.addEventListener("change",this.inputChange),this.option.fileInput.addEventListener("dragover",l.ondragover),this.option.fileInput.addEventListener("drop",l.ondrop)}static get DEFAULTS(){return{number:60,width:160,height:90,column:10,begin:0,end:NaN}}static ondragover(e){e.preventDefault()}ondrop(e){e.preventDefault();const t=e.dataTransfer.files[0];this.loadVideo(t)}setup(e={}){this.option=Object.assign({},this.option,e);const{fileInput:t,number:i,width:n,column:o}=this.option;if(this.errorHandle(t instanceof Element,"The 'fileInput' is not a Element"),"INPUT"!==t.tagName||"file"!==t.type){t.style.position="relative";const e=document.createElement("input");e.type="file",e.style.position="absolute",e.style.width="100%",e.style.height="100%",e.style.left="0",e.style.top="0",e.style.right="0",e.style.bottom="0",e.style.opacity="0",t.appendChild(e),this.option.fileInput=e}return["number","width","column","begin","end"].forEach((e=>{this.errorHandle("number"==typeof this.option[e],`The '${e}' is not a number`)})),this.option.number=(0,s.clamp)(i,10,1e3),this.option.width=(0,s.clamp)(n,10,1e3),this.option.column=(0,s.clamp)(o,1,1e3),this}static creatVideo(){const e=document.createElement("video");return e.style.position="absolute",e.style.top="-9999px",e.style.left="-9999px",e.muted=!0,e.controls=!0,document.body.appendChild(e),e}inputChange(e){const t=this.option.fileInput.files[0];this.loadVideo(t),e.target.value=""}loadVideo(e){if(e){const t=this.video.canPlayType(e.type);this.errorHandle("maybe"===t||"probably"===t,`Playback of this file format is not supported: ${e.type}`);const i=URL.createObjectURL(e);this.videoUrl=i,this.file=e,this.emit("file",this.file),this.video.src=i,this.emit("video",this.video)}}start(){if(!this.video.duration)return(0,s.sleep)(1e3).then((()=>this.start()));const{width:e,number:t,begin:i,end:n}=this.option,o=this.video.videoHeight/this.video.videoWidth*e;this.option.height=o,this.option.begin=(0,s.clamp)(i,0,this.video.duration),this.option.end=(0,s.clamp)(n||this.video.duration,i,this.video.duration),this.errorHandle(this.option.end>this.option.begin,"End time must be greater than the start time"),this.duration=this.option.end-this.option.begin,this.density=t/this.duration,this.errorHandle(this.file&&this.video,"Please select the video file first"),this.errorHandle(!this.processing,"There is currently a task in progress, please wait a moment..."),this.errorHandle(this.density<=1,`The preview density cannot be greater than 1, but got ${this.density}`);const r=this.creatScreenshotDate(),l=this.creatCanvas(),a=l.getContext("2d");this.emit("canvas",l);const h=r.map(((i,n)=>()=>new Promise((r=>{this.video.oncanplay=()=>{a.drawImage(this.video,i.x,i.y,e,o),l.toBlob((e=>{this.thumbnailUrl&&URL.revokeObjectURL(this.thumbnailUrl),this.thumbnailUrl=URL.createObjectURL(e),this.emit("update",this.thumbnailUrl,(n+1)/t),this.video.oncanplay=null,r()}))},this.video.currentTime=i.time}))));return this.processing=!0,(0,s.runPromisesInSeries)(h).then((()=>{this.processing=!1,this.emit("done")})).catch((e=>{throw this.processing=!1,this.emit("error",e.message),e}))}creatScreenshotDate(){const{number:e,width:t,height:i,column:n,begin:o}=this.option,r=this.duration/e,s=[o+r];for(;s.length<e;){const e=s[s.length-1Line truncated
+2 -2
View File
@@ -1,7 +1,7 @@
/*!
* artplayer.js v4.4.3
* artplayer.js v4.5.4
* Github: https://github.com/zhw2590582/ArtPlayer
* (c) 2017-2022 Harvey Zack
* Released under the MIT License.
*/
!function(e,t,r,o,n){var i="undefined"!=typeof globalThis?globalThis:"undefined"!=typeof self?self:"undefined"!=typeof window?window:"undefined"!=typeof global?global:{},a="function"==typeof i.parcelRequire4dc0&&i.parcelRequire4dc0,s=a.cache||{},l="undefined"!=typeof module&&"function"==typeof module.require&&module.require.bind(module);function c(t,r){if(!s[t]){if(!e[t]){var o="function"==typeof i.parcelRequire4dc0&&i.parcelRequire4dc0;if(!r&&o)return o(t,!0);if(a)return a(t,!0);if(l&&"string"==typeof t)return l(t);var n=new Error("Cannot find module '"+t+"'");throw n.code="MODULE_NOT_FOUND",n}u.resolve=function(r){var o=e[t][1][r];return null!=o?o:r},u.cache={};var p=s[t]=new c.Module(t);e[t][0].call(p.exports,u,p,p.exports,this)}return s[t].exports;function u(e){var t=u.resolve(e);return!1===t?{}:c(t)}}c.isParcelRequire=!0,c.Module=function(e){this.id=e,this.bundle=c,this.exports={}},c.modules=e,c.cache=s,c.parent=a,c.register=function(t,r){e[t]=[function(e,t){t.exports=r},{}]},Object.defineProperty(c,"root",{get:function(){return i.parcelRequire4dc0}}),i.parcelRequire4dc0=c;for(var p=0;p<t.length;p++)c(t[p]);var u=c(r);"object"==typeof exports&&"undefined"!=typeof module?module.exports=u:"function"==typeof define&&define.amd&&define((function(){return u}))}({"6SN6P":[function(e,t,r){var o=e("@parcel/transformer-js/src/esmodule-helpers.js");o.defineInteropFlag(r);var n=e("bundle-text:./style/index.less"),i=o.interopDefault(n),a=e("option-validator"),s=o.interopDefault(a),l=e("./utils/emitter"),c=o.interopDefault(l),p=e("./utils"),u=e("./scheme"),d=o.interopDefault(u),f=e("./config"),h=o.interopDefault(f),m=e("./whitelist"),g=o.interopDefault(m),v=e("./template"),y=o.interopDefault(v),b=e("./i18n"),x=o.interopDefault(b),w=e("./player"),j=o.interopDefault(w),k=e("./control"),S=o.interopDefault(k),I=e("./contextmenu"),$=o.interopDefault(I),R=e("./info"),O=o.interopDefault(R),M=e("./subtitle"),T=o.interopDefault(M),E=e("./events"),F=o.interopDefault(E),C=e("./hotkey"),P=o.interopDefault(C),z=e("./layer"),D=o.interopDefault(z),A=e("./loading"),H=o.interopDefault(A),L=e("./notice"),Z=o.interopDefault(L),U=e("./mask"),N=o.interopDefault(U),V=e("./icons"),q=o.interopDefault(V),_=e("./setting"),W=o.interopDefault(_),B=e("./storage"),Y=o.interopDefault(B),G=e("./plugins"),X=o.interopDefault(G),Q=e("./ads"),J=o.interopDefault(Q),K=e("./mobile"),ee=o.interopDefault(K);let te=0;const re=[];class oe extends c.default{constructor(e,t){super(),this.id=++te;const r=p.mergeDeep(oe.option,e);this.option=s.default(r,d.default),this.isLock=!1,this.isReady=!1,this.isFocus=!1,this.isInput=!1,this.isDestroy=!1,this.whitelist=new g.default(this),this.template=new y.default(this),this.events=new F.default(this),this.whitelist.state?(this.storage=new Y.default(this),this.icons=new q.default(this),this.i18n=new x.default(this),this.notice=new Z.default(this),this.player=new j.default(this),this.layers=new D.default(this),this.controls=new S.default(this),this.contextmenu=new $.default(this),this.subtitle=new T.default(this),this.ads=new J.default(this),this.info=new O.default(this),this.loading=new H.default(this),this.hotkey=new P.default(this),this.mask=new N.default(this),this.setting=new W.default(this),this.plugins=new X.default(this)):this.mobile=new ee.default(this),"function"==typeof t&&this.on("ready",(()=>t.call(this))),re.push(this)}static get instances(){return re}static get version(){return"4.4.3"}static get env(){return"production"}static get build(){return"1653543392822"}static get config(){return h.default}static get utils(){return p}static get scheme(){return d.default}static get Emitter(){return c.default}static get validator(){return s.default}static get kindOf(){return s.default.kindOf}static get html(){return y.default.html}static get option(){return{container:"#artplayer",url:"",poster:"",title:"",type:"",theme:"#f00",volume:.7,isLive:!1,muted:!1,autoplay:!1,autoSize:!1,autoMini:!1,loop:!1,flip:!1,playbackRate:!1,aspectRatio:!1,screenshot:!1,setting:!1,hotkey:!0,pip:!1,mutex:!0,backdrop:!0,fullscreen:!1,fullscreenWeb:!1,subtitleOffset:!1,miniProgressBar:!1,useSSR:!1,playsInline:!0,lock:!1,fastForward:!1,autoPlayback:!1,autoOrientation:!1,ads:[],layers:[],contextmenu:[],controls:[],settings:[],quality:[],highlight:[],plugins:[],whitelist:[],thumbnails:{url:"",number:60,column:10},subtitle:{url:"",type:"",style:{},encoding:"utf-8"},moreVideoAttr:{controls:!1,preload:p.isSafari?"auto":"metadata"},icons:{},customType:{},lang:navigator.language.toLowerCase()}}get proxy(){return this.events.proxy}get query(){return this.template.query}destroy(e=!0){this.events.destroy(),this.template.destroy(e),re.splice(re.indexOf(this),1),this.isDestroy=!0,this.emit("destroy")}}if(r.default=oe,oe.NOTICE_TIME=2e3,oe.SETTING_WIDTH=250,oe.SETTING_ITEM_WIDTH=200,oe.SETTING_ITEM_HEIGHT=35,oe.INDICATOR_SIZE=14,oe.INDICATOR_SIZE_ICON=16,oe.INDICATOR_SIZE_MOBILE=18,oe.INDICATOR_SIZE_MOBILE_ICON=20,oe.VOLUME_PANEL_WIDTH=60,oe.VOLUME_HANDLLine truncated
!function(e,t,r,o,i){var n="undefined"!=typeof globalThis?globalThis:"undefined"!=typeof self?self:"undefined"!=typeof window?window:"undefined"!=typeof global?global:{},a="function"==typeof n.parcelRequireb749&&n.parcelRequireb749,s=a.cache||{},l="undefined"!=typeof module&&"function"==typeof module.require&&module.require.bind(module);function c(t,r){if(!s[t]){if(!e[t]){var o="function"==typeof n.parcelRequireb749&&n.parcelRequireb749;if(!r&&o)return o(t,!0);if(a)return a(t,!0);if(l&&"string"==typeof t)return l(t);var i=new Error("Cannot find module '"+t+"'");throw i.code="MODULE_NOT_FOUND",i}u.resolve=function(r){var o=e[t][1][r];return null!=o?o:r},u.cache={};var p=s[t]=new c.Module(t);e[t][0].call(p.exports,u,p,p.exports,this)}return s[t].exports;function u(e){var t=u.resolve(e);return!1===t?{}:c(t)}}c.isParcelRequire=!0,c.Module=function(e){this.id=e,this.bundle=c,this.exports={}},c.modules=e,c.cache=s,c.parent=a,c.register=function(t,r){e[t]=[function(e,t){t.exports=r},{}]},Object.defineProperty(c,"root",{get:function(){return n.parcelRequireb749}}),n.parcelRequireb749=c;for(var p=0;p<t.length;p++)c(t[p]);var u=c(r);"object"==typeof exports&&"undefined"!=typeof module?module.exports=u:"function"==typeof define&&define.amd&&define((function(){return u}))}({E13ST:[function(e,t,r){var o=e("@parcel/transformer-js/src/esmodule-helpers.js");o.defineInteropFlag(r);var i=e("bundle-text:./style/index.less"),n=o.interopDefault(i),a=e("option-validator"),s=o.interopDefault(a),l=e("./utils/emitter"),c=o.interopDefault(l),p=e("./utils"),u=e("./scheme"),d=o.interopDefault(u),f=e("./config"),h=o.interopDefault(f),m=e("./whitelist"),g=o.interopDefault(m),y=e("./template"),v=o.interopDefault(y),b=e("./i18n"),x=o.interopDefault(b),w=e("./player"),j=o.interopDefault(w),k=e("./control"),M=o.interopDefault(k),S=e("./contextmenu"),I=o.interopDefault(S),$=e("./info"),F=o.interopDefault($),T=e("./subtitle"),E=o.interopDefault(T),P=e("./events"),C=o.interopDefault(P),z=e("./hotkey"),Y=o.interopDefault(z),D=e("./layer"),A=o.interopDefault(D),R=e("./loading"),O=o.interopDefault(R),L=e("./notice"),H=o.interopDefault(L),N=e("./mask"),J=o.interopDefault(N),_=e("./icons"),V=o.interopDefault(_),q=e("./setting"),W=o.interopDefault(q),B=e("./storage"),U=o.interopDefault(B),Z=e("./plugins"),X=o.interopDefault(Z),G=e("./mobile"),K=o.interopDefault(G);let Q=0;const ee=[];class te extends c.default{constructor(e,t){super(),this.id=++Q;const r=p.mergeDeep(te.option,e);this.option=(0,s.default)(r,d.default),this.isLock=!1,this.isReady=!1,this.isFocus=!1,this.isInput=!1,this.isDestroy=!1,this.whitelist=new(0,g.default)(this),this.template=new(0,v.default)(this),this.events=new(0,C.default)(this),this.whitelist.state?(this.storage=new(0,U.default)(this),this.icons=new(0,V.default)(this),this.i18n=new(0,x.default)(this),this.notice=new(0,H.default)(this),this.player=new(0,j.default)(this),this.layers=new(0,A.default)(this),this.controls=new(0,M.default)(this),this.contextmenu=new(0,I.default)(this),this.subtitle=new(0,E.default)(this),this.info=new(0,F.default)(this),this.loading=new(0,O.default)(this),this.hotkey=new(0,Y.default)(this),this.mask=new(0,J.default)(this),this.setting=new(0,W.default)(this),this.plugins=new(0,X.default)(this)):this.mobile=new(0,K.default)(this),"function"==typeof t&&this.on("ready",(()=>t.call(this))),ee.push(this)}static get instances(){return ee}static get version(){return"4.5.4"}static get env(){return"production"}static get build(){return"1659362361789"}static get config(){return h.default}static get utils(){return p}static get scheme(){return d.default}static get Emitter(){return c.default}static get validator(){return s.default}static get kindOf(){return s.default.kindOf}static get html(){return v.default.html}static get option(){return{id:"",container:"#artplayer",url:"",poster:"",title:"",type:"",theme:"#f00",volume:.7,isLive:!1,muted:!1,autoplay:!1,autoSize:!1,autoMini:!1,loop:!1,flip:!1,playbackRate:!1,aspectRatio:!1,screenshot:!1,setting:!1,hotkey:!0,pip:!1,mutex:!0,backdrop:!0,fullscreen:!1,fullscreenWeb:!1,subtitleOffset:!1,miniProgressBar:!1,useSSR:!1,playsInline:!0,lock:!1,fastForward:!1,autoPlayback:!1,autoOrientation:!1,airplay:!1,layers:[],contextmenu:[],controls:[],settings:[],quality:[],highlight:[],plugins:[],whitelist:[],thumbnails:{url:"",number:60,column:10,width:0,height:0},subtitle:{url:"",type:"",style:{},encoding:"utf-8"},moreVideoAttr:{controls:!1,preload:p.isSafari?"auto":"metadata"},icons:{},customType:{},lang:navigator.language.toLowerCase()}}get proxy(){return this.events.proxy}get query(){return this.template.query}destroy(e=!0){this.events.destroy(),this.template.destroy(e),ee.splice(ee.indexOf(this),1),this.isDestroy=!0,this.emit("destroy")}}if(r.default=te,te.NOTICE_TIME=2e3,te.SETTING_WIDTH=250,te.SETTING_ITEM_WIDTH=200,te.SETTING_ITEM_HEIGHT=35,te.INDICATOR_SIZE=14,te.INDICATOR_SIZE_ICON=16,te.INDICATOR_SIZE_MOBILE=18,te.INDICATOR_SIZE_MOBILE_ICON=20,te.VOLUME_PANEL_WIDTH=Line truncated
+6 -6
View File
@@ -4,14 +4,14 @@
<meta charset="UTF-8">
<meta name="viewport" content="width=device-width,initial-scale=1">
<meta name="generator" content="Docusaurus v2.0.0-beta.20">
<title data-rh="true">Page Not Found | Artplayer.js</title><meta data-rh="true" name="twitter:card" content="summary_large_image"><meta data-rh="true" property="og:url" content="https://artplayer.org/document/404.html"><meta data-rh="true" name="docusaurus_locale" content="en"><meta data-rh="true" name="docusaurus_tag" content="default"><meta data-rh="true" name="docsearch:language" content="en"><meta data-rh="true" name="docsearch:docusaurus_tag" content="default"><meta data-rh="true" property="og:title" content="Page Not Found | Artplayer.js"><link data-rh="true" rel="icon" href="/document/img/favicon.ico"><link data-rh="true" rel="canonical" href="https://artplayer.org/document/404.html"><link data-rh="true" rel="alternate" href="https://artplayer.org/document/404.html" hreflang="en"><link data-rh="true" rel="alternate" href="https://artplayer.org/document/404.html" hreflang="x-default"><link rel="stylesheet" href="/document/assets/css/styles.eba261b7.css">
<link rel="preload" href="/document/assets/js/runtime~main.222c91cd.js" as="script">
<link rel="preload" href="/document/assets/js/main.9ce4b94b.js" as="script">
<title data-rh="true">Page Not Found | Artplayer.js</title><meta data-rh="true" name="twitter:card" content="summary_large_image"><meta data-rh="true" property="og:url" content="https://artplayer.org/document/404.html"><meta data-rh="true" name="docusaurus_locale" content="en"><meta data-rh="true" name="docusaurus_tag" content="default"><meta data-rh="true" name="docsearch:language" content="en"><meta data-rh="true" name="docsearch:docusaurus_tag" content="default"><meta data-rh="true" property="og:title" content="Page Not Found | Artplayer.js"><link data-rh="true" rel="icon" href="/document/img/favicon.ico"><link data-rh="true" rel="canonical" href="https://artplayer.org/document/404.html"><link data-rh="true" rel="alternate" href="https://artplayer.org/document/404.html" hreflang="en"><link data-rh="true" rel="alternate" href="https://artplayer.org/document/404.html" hreflang="x-default"><link rel="stylesheet" href="/document/assets/css/styles.7b2fc50a.css">
<link rel="preload" href="/document/assets/js/runtime~main.f9808e8d.js" as="script">
<link rel="preload" href="/document/assets/js/main.ac59e946.js" as="script">
</head>
<body class="navigation-with-keyboard">
<script>!function(){function t(t){document.documentElement.setAttribute("data-theme",t)}var e=function(){var t=null;try{t=localStorage.getItem("theme")}catch(t){}return t}();t(null!==e?e:"light")}()</script><div id="__docusaurus">
<div role="region"><a href="#" class="skipToContent_ZgBM">Skip to main content</a></div><nav class="navbar navbar--fixed-top"><div class="navbar__inner"><div class="navbar__items"><button aria-label="Navigation bar toggle" class="navbar__toggle clean-btn" type="button" tabindex="0"><svg width="30" height="30" viewBox="0 0 30 30" aria-hidden="true"><path stroke="currentColor" stroke-linecap="round" stroke-miterlimit="10" stroke-width="2" d="M4 7h22M4 15h22M4 23h22"></path></svg></button><a href="https://artplayer.org/document" target="_self" rel="noopener noreferrer" class="navbar__brand"><div class="navbar__logo"><img src="/document/img/logo.png" alt="Artplayer.js" class="themedImage_W2Cr themedImage--light_TfLj" height="28" width="28"><img src="/document/img/logo.png" alt="Artplayer.js" class="themedImage_W2Cr themedImage--dark_oUvU" height="28" width="28"></div><b class="navbar__title text--truncate">Artplayer.js</b></a><a href="https://artplayer.org" target="_blank" rel="noopener noreferrer" class="navbar__item navbar__link">Online Editor<svg width="13.5" height="13.5" aria-hidden="true" viewBox="0 0 24 24" class="iconExternalLink_I5OW"><path fill="currentColor" d="M21 13v10h-21v-19h12v2h-10v15h17v-8h2zm3-12h-10.988l4.035 4-6.977 7.07 2.828 2.828 6.977-7.07 4.125 4.172v-11z"></path></svg></a><a href="https://github.com/zhw2590582/ArtPlayer" target="_blank" rel="noopener noreferrer" class="navbar__item navbar__link">Github<svg width="13.5" height="13.5" aria-hidden="true" viewBox="0 0 24 24" class="iconExternalLink_I5OW"><path fill="currentColor" d="M21 13v10h-21v-19h12v2h-10v15h17v-8h2zm3-12h-10.988l4.035 4-6.977 7.07 2.828 2.828 6.977-7.07 4.125 4.172v-11z"></path></svg></a></div><div class="navbar__items navbar__items--right"><a href="#" class="navbar__item navbar__link">QQ群: 320881312</a><div class="navbar__item dropdown dropdown--hoverable dropdown--right"><a href="#" aria-haspopup="true" aria-expanded="false" role="button" class="navbar__link">English</a><ul class="dropdown__menu"><li><a class="dropdown__link" href="/document/">English</a></li><li><a class="dropdown__link" href="/document/zh-cn/">中文</a></li></ul></div><div class="toggle_S7eR colorModeToggle_vKtC"><button class="clean-btn toggleButton_rCf9 toggleButtonDisabled_Pu9x" type="button" disabled="" title="Switch between dark and light mode (currently light mode)" aria-label="Switch between dark and light mode (currently light mode)"><svg viewBox="0 0 24 24" width="24" height="24" class="lightToggleIcon_v35p"><path fill="currentColor" d="M12,9c1.65,0,3,1.35,3,3s-1.35,3-3,3s-3-1.35-3-3S10.35,9,12,9 M12,7c-2.76,0-5,2.24-5,5s2.24,5,5,5s5-2.24,5-5 S14.76,7,12,7L12,7z M2,13l2,0c0.55,0,1-0.45,1-1s-0.45-1-1-1l-2,0c-0.55,0-1,0.45-1,1S1.45,13,2,13z M20,13l2,0c0.55,0,1-0.45,1-1 s-0.45-1-1-1l-2,0c-0.55,0-1,0.45-1,1S19.45,13,20,13z M11,2v2c0,0.55,0.45,1,1,1s1-0.45,1-1V2c0-0.55-0.45-1-1-1S11,1.45,11,2z M11,20v2c0,0.55,0.45,1,1,1s1-0.45,1-1v-2c0-0.55-0.45-1-1-1C11.45,19,11,19.45,11,20z M5.99,4.58c-0.39-0.39-1.03-0.39-1.41,0 c-0.39,0.39-0.39,1.03,0,1.41l1.06,1.06c0.39,0.39,1.03,0.39,1.41,0s0.39-1.03,0-1.41L5.99,4.58z M18.36,16.95 c-0.39-0.39-1.03-0.39-1.41,0c-0.39,0.39-0.39,1.03,0,1.41l1.06,1.06c0.39,0.39,1.03,0.39,1.41,0c0.39-0.39,0.39-1.03,0-1.41 L18.36,16.95z M19.42,5.99c0.39-0.39,0.39-1.03,0-1.41c-0.39-0.39-1.03-0.39-1.41,0l-1.06,1.06c-0.39,0.39-0.39,1.03,0,1.41 s1.03,0.39,1.41,0L19.42,5.99z M7.05,18.36c0.39-0.39,0.39-1.03,0-1.41c-0.39-0.39-1.03-0.39-1.41,0l-1.06,1.06 c-0.39,0.39-0.39,1.03,0,1.41s1.03,0.39,1.41,0L7.05,18.36z"></path></svg><svg viewBox="0 0 24 24" width="24" height="24" class="darkToggleIcon_nQuB"><path fill="currentColor" d="M9.37,5.51C9.19,6.15,9.1,6.82,9.1,7.5c0,4.08,3.32,7.4,7.4,7.4c0.68,0,1.35-0.09,1.99-0.27C17.45,17.19,14.93,19,12,19 c-3.86,0-7-3.14-7-7C5,9.07,6.81,6.55,9.37,5.51z M12,3c-4.97,0-9,4.03-9,9s4.03,9,9,9s9-4.03,9-9c0-0.46-0.04-0.92-0.1-1.36 c-0.98,1.37-2.58,2.26-4.4,2.26c-2.98,0-5.4-2.42-5.4-5.4c0-1.81,0.89-3.42,2.26-4.4C12.92,3.04,12.46,3,12,3L12,3z"></path></svg></button></div><div class="searchBox_dLyj"><div class="navbar__search"><span aria-label="expand searchbar" role="button" class="search-icon" tabindex="0"></span><input type="search" id="search_input_react" placeholder="Search" aria-label="Search" class="navbar__search-input search-bar"></div></div></div></div><div role="presentation" class="navbar-sidebar__backdrop"></div></nav><div class="main-wrapper"><main class="container margin-vert--xl"><div class="row"><div class="col col--6 col--offset-3"><h1 class="hero__title">Page Not Found</h1><p>We could not find what you were looking for.</p><p>Please contact the owner of the site that linked you to the original URL and let them know their link is broken.</p></div></div></main></div><footer class="footer footer--dark"><div class="container container-fluid"><div class="footer__bottom text--center"><div class="footer__copyright">Copyright © 2022 Artplayer.js, Inc. Built with Docusaurus.</div></div></div></Line truncated
<script src="/document/assets/js/runtime~main.222c91cd.js"></script>
<script src="/document/assets/js/main.9ce4b94b.js"></script>
<div role="region"><a href="#" class="skipToContent_cbSD">Skip to main content</a></div><nav class="navbar navbar--fixed-top"><div class="navbar__inner"><div class="navbar__items"><button aria-label="Navigation bar toggle" class="navbar__toggle clean-btn" type="button" tabindex="0"><svg width="30" height="30" viewBox="0 0 30 30" aria-hidden="true"><path stroke="currentColor" stroke-linecap="round" stroke-miterlimit="10" stroke-width="2" d="M4 7h22M4 15h22M4 23h22"></path></svg></button><a href="https://artplayer.org/document" target="_self" rel="noopener noreferrer" class="navbar__brand"><div class="navbar__logo"><img src="/document/img/logo.png" alt="Artplayer.js" class="themedImage_WmJs themedImage--light_gXqO" height="28" width="28"><img src="/document/img/logo.png" alt="Artplayer.js" class="themedImage_WmJs themedImage--dark_X1Zc" height="28" width="28"></div><b class="navbar__title text--truncate">Artplayer.js</b></a><a href="https://artplayer.org" target="_blank" rel="noopener noreferrer" class="navbar__item navbar__link">Online Editor<svg width="13.5" height="13.5" aria-hidden="true" viewBox="0 0 24 24" class="iconExternalLink_cOdw"><path fill="currentColor" d="M21 13v10h-21v-19h12v2h-10v15h17v-8h2zm3-12h-10.988l4.035 4-6.977 7.07 2.828 2.828 6.977-7.07 4.125 4.172v-11z"></path></svg></a><a href="https://github.com/zhw2590582/ArtPlayer" target="_blank" rel="noopener noreferrer" class="navbar__item navbar__link">Github<svg width="13.5" height="13.5" aria-hidden="true" viewBox="0 0 24 24" class="iconExternalLink_cOdw"><path fill="currentColor" d="M21 13v10h-21v-19h12v2h-10v15h17v-8h2zm3-12h-10.988l4.035 4-6.977 7.07 2.828 2.828 6.977-7.07 4.125 4.172v-11z"></path></svg></a></div><div class="navbar__items navbar__items--right"><a href="#" class="navbar__item navbar__link">QQ群: 320881312</a><div class="navbar__item dropdown dropdown--hoverable dropdown--right"><a href="#" aria-haspopup="true" aria-expanded="false" role="button" class="navbar__link">English</a><ul class="dropdown__menu"><li><a class="dropdown__link" href="/document/">English</a></li><li><a class="dropdown__link" href="/document/zh-cn/">中文</a></li></ul></div><div class="toggle_F6nl colorModeToggle_ndsa"><button class="clean-btn toggleButton_Szei toggleButtonDisabled_qp8o" type="button" disabled="" title="Switch between dark and light mode (currently light mode)" aria-label="Switch between dark and light mode (currently light mode)"><svg viewBox="0 0 24 24" width="24" height="24" class="lightToggleIcon_y2PQ"><path fill="currentColor" d="M12,9c1.65,0,3,1.35,3,3s-1.35,3-3,3s-3-1.35-3-3S10.35,9,12,9 M12,7c-2.76,0-5,2.24-5,5s2.24,5,5,5s5-2.24,5-5 S14.76,7,12,7L12,7z M2,13l2,0c0.55,0,1-0.45,1-1s-0.45-1-1-1l-2,0c-0.55,0-1,0.45-1,1S1.45,13,2,13z M20,13l2,0c0.55,0,1-0.45,1-1 s-0.45-1-1-1l-2,0c-0.55,0-1,0.45-1,1S19.45,13,20,13z M11,2v2c0,0.55,0.45,1,1,1s1-0.45,1-1V2c0-0.55-0.45-1-1-1S11,1.45,11,2z M11,20v2c0,0.55,0.45,1,1,1s1-0.45,1-1v-2c0-0.55-0.45-1-1-1C11.45,19,11,19.45,11,20z M5.99,4.58c-0.39-0.39-1.03-0.39-1.41,0 c-0.39,0.39-0.39,1.03,0,1.41l1.06,1.06c0.39,0.39,1.03,0.39,1.41,0s0.39-1.03,0-1.41L5.99,4.58z M18.36,16.95 c-0.39-0.39-1.03-0.39-1.41,0c-0.39,0.39-0.39,1.03,0,1.41l1.06,1.06c0.39,0.39,1.03,0.39,1.41,0c0.39-0.39,0.39-1.03,0-1.41 L18.36,16.95z M19.42,5.99c0.39-0.39,0.39-1.03,0-1.41c-0.39-0.39-1.03-0.39-1.41,0l-1.06,1.06c-0.39,0.39-0.39,1.03,0,1.41 s1.03,0.39,1.41,0L19.42,5.99z M7.05,18.36c0.39-0.39,0.39-1.03,0-1.41c-0.39-0.39-1.03-0.39-1.41,0l-1.06,1.06 c-0.39,0.39-0.39,1.03,0,1.41s1.03,0.39,1.41,0L7.05,18.36z"></path></svg><svg viewBox="0 0 24 24" width="24" height="24" class="darkToggleIcon_sMpk"><path fill="currentColor" d="M9.37,5.51C9.19,6.15,9.1,6.82,9.1,7.5c0,4.08,3.32,7.4,7.4,7.4c0.68,0,1.35-0.09,1.99-0.27C17.45,17.19,14.93,19,12,19 c-3.86,0-7-3.14-7-7C5,9.07,6.81,6.55,9.37,5.51z M12,3c-4.97,0-9,4.03-9,9s4.03,9,9,9s9-4.03,9-9c0-0.46-0.04-0.92-0.1-1.36 c-0.98,1.37-2.58,2.26-4.4,2.26c-2.98,0-5.4-2.42-5.4-5.4c0-1.81,0.89-3.42,2.26-4.4C12.92,3.04,12.46,3,12,3L12,3z"></path></svg></button></div><div class="searchBox_xKlU"><div class="navbar__search"><span aria-label="expand searchbar" role="button" class="search-icon" tabindex="0"></span><input type="search" id="search_input_react" placeholder="Search" aria-label="Search" class="navbar__search-input search-bar"></div></div></div></div><div role="presentation" class="navbar-sidebar__backdrop"></div></nav><div class="main-wrapper"><main class="container margin-vert--xl"><div class="row"><div class="col col--6 col--offset-3"><h1 class="hero__title">Page Not Found</h1><p>We could not find what you were looking for.</p><p>Please contact the owner of the site that linked you to the original URL and let them know their link is broken.</p></div></div></main></div><footer class="footer footer--dark"><div class="container container-fluid"><div class="footer__bottom text--center"><div class="footer__copyright">Copyright © 2022 Artplayer.js, Inc. Built with Docusaurus.</div></div></div></Line truncated
<script src="/document/assets/js/runtime~main.f9808e8d.js"></script>
<script src="/document/assets/js/main.ac59e946.js"></script>
</body>
</html>
+6 -6
View File
@@ -4,14 +4,14 @@
<meta charset="UTF-8">
<meta name="viewport" content="width=device-width,initial-scale=1">
<meta name="generator" content="Docusaurus v2.0.0-beta.20">
<title data-rh="true">Advanced propertys | Artplayer.js</title><meta data-rh="true" name="twitter:card" content="summary_large_image"><meta data-rh="true" property="og:url" content="https://artplayer.org/document/advance"><meta data-rh="true" name="docusaurus_locale" content="en"><meta data-rh="true" name="docsearch:language" content="en"><meta data-rh="true" name="docusaurus_version" content="current"><meta data-rh="true" name="docusaurus_tag" content="docs-default-current"><meta data-rh="true" name="docsearch:version" content="current"><meta data-rh="true" name="docsearch:docusaurus_tag" content="docs-default-current"><meta data-rh="true" property="og:title" content="Advanced propertys | Artplayer.js"><meta data-rh="true" name="description" content="This page is some additional supplements to the commonly used properties, you need to read in depth to develop custom functions."><meta data-rh="true" property="og:description" content="This page is some additional supplements to the commonly used properties, you need to read in depth to develop custom functions."><link data-rh="true" rel="icon" href="/document/img/favicon.ico"><link data-rh="true" rel="canonical" href="https://artplayer.org/document/advance"><link data-rh="true" rel="alternate" href="https://artplayer.org/document/advance" hreflang="en"><link data-rh="true" rel="alternate" href="https://artplayer.org/document/advance" hreflang="x-default"><link rel="stylesheet" href="/document/assets/css/styles.eba261b7.css">
<link rel="preload" href="/document/assets/js/runtime~main.222c91cd.js" as="script">
<link rel="preload" href="/document/assets/js/main.9ce4b94b.js" as="script">
<title data-rh="true">Advanced propertys | Artplayer.js</title><meta data-rh="true" name="twitter:card" content="summary_large_image"><meta data-rh="true" property="og:url" content="https://artplayer.org/document/advance"><meta data-rh="true" name="docusaurus_locale" content="en"><meta data-rh="true" name="docsearch:language" content="en"><meta data-rh="true" name="docusaurus_version" content="current"><meta data-rh="true" name="docusaurus_tag" content="docs-default-current"><meta data-rh="true" name="docsearch:version" content="current"><meta data-rh="true" name="docsearch:docusaurus_tag" content="docs-default-current"><meta data-rh="true" property="og:title" content="Advanced propertys | Artplayer.js"><meta data-rh="true" name="description" content="This page is some additional supplements to the commonly used properties, you need to read in depth to develop custom functions."><meta data-rh="true" property="og:description" content="This page is some additional supplements to the commonly used properties, you need to read in depth to develop custom functions."><link data-rh="true" rel="icon" href="/document/img/favicon.ico"><link data-rh="true" rel="canonical" href="https://artplayer.org/document/advance"><link data-rh="true" rel="alternate" href="https://artplayer.org/document/advance" hreflang="en"><link data-rh="true" rel="alternate" href="https://artplayer.org/document/advance" hreflang="x-default"><link rel="stylesheet" href="/document/assets/css/styles.7b2fc50a.css">
<link rel="preload" href="/document/assets/js/runtime~main.f9808e8d.js" as="script">
<link rel="preload" href="/document/assets/js/main.ac59e946.js" as="script">
</head>
<body class="navigation-with-keyboard">
<script>!function(){function t(t){document.documentElement.setAttribute("data-theme",t)}var e=function(){var t=null;try{t=localStorage.getItem("theme")}catch(t){}return t}();t(null!==e?e:"light")}()</script><div id="__docusaurus">
<div role="region"><a href="#" class="skipToContent_ZgBM">Skip to main content</a></div><nav class="navbar navbar--fixed-top"><div class="navbar__inner"><div class="navbar__items"><button aria-label="Navigation bar toggle" class="navbar__toggle clean-btn" type="button" tabindex="0"><svg width="30" height="30" viewBox="0 0 30 30" aria-hidden="true"><path stroke="currentColor" stroke-linecap="round" stroke-miterlimit="10" stroke-width="2" d="M4 7h22M4 15h22M4 23h22"></path></svg></button><a href="https://artplayer.org/document" target="_self" rel="noopener noreferrer" class="navbar__brand"><div class="navbar__logo"><img src="/document/img/logo.png" alt="Artplayer.js" class="themedImage_W2Cr themedImage--light_TfLj" height="28" width="28"><img src="/document/img/logo.png" alt="Artplayer.js" class="themedImage_W2Cr themedImage--dark_oUvU" height="28" width="28"></div><b class="navbar__title text--truncate">Artplayer.js</b></a><a href="https://artplayer.org" target="_blank" rel="noopener noreferrer" class="navbar__item navbar__link">Online Editor<svg width="13.5" height="13.5" aria-hidden="true" viewBox="0 0 24 24" class="iconExternalLink_I5OW"><path fill="currentColor" d="M21 13v10h-21v-19h12v2h-10v15h17v-8h2zm3-12h-10.988l4.035 4-6.977 7.07 2.828 2.828 6.977-7.07 4.125 4.172v-11z"></path></svg></a><a href="https://github.com/zhw2590582/ArtPlayer" target="_blank" rel="noopener noreferrer" class="navbar__item navbar__link">Github<svg width="13.5" height="13.5" aria-hidden="true" viewBox="0 0 24 24" class="iconExternalLink_I5OW"><path fill="currentColor" d="M21 13v10h-21v-19h12v2h-10v15h17v-8h2zm3-12h-10.988l4.035 4-6.977 7.07 2.828 2.828 6.977-7.07 4.125 4.172v-11z"></path></svg></a></div><div class="navbar__items navbar__items--right"><a href="#" class="navbar__item navbar__link">QQ群: 320881312</a><div class="navbar__item dropdown dropdown--hoverable dropdown--right"><a href="#" aria-haspopup="true" aria-expanded="false" role="button" class="navbar__link">English</a><ul class="dropdown__menu"><li><a class="dropdown__link" href="/document/">English</a></li><li><a class="dropdown__link" href="/document/zh-cn/">中文</a></li></ul></div><div class="toggle_S7eR colorModeToggle_vKtC"><button class="clean-btn toggleButton_rCf9 toggleButtonDisabled_Pu9x" type="button" disabled="" title="Switch between dark and light mode (currently light mode)" aria-label="Switch between dark and light mode (currently light mode)"><svg viewBox="0 0 24 24" width="24" height="24" class="lightToggleIcon_v35p"><path fill="currentColor" d="M12,9c1.65,0,3,1.35,3,3s-1.35,3-3,3s-3-1.35-3-3S10.35,9,12,9 M12,7c-2.76,0-5,2.24-5,5s2.24,5,5,5s5-2.24,5-5 S14.76,7,12,7L12,7z M2,13l2,0c0.55,0,1-0.45,1-1s-0.45-1-1-1l-2,0c-0.55,0-1,0.45-1,1S1.45,13,2,13z M20,13l2,0c0.55,0,1-0.45,1-1 s-0.45-1-1-1l-2,0c-0.55,0-1,0.45-1,1S19.45,13,20,13z M11,2v2c0,0.55,0.45,1,1,1s1-0.45,1-1V2c0-0.55-0.45-1-1-1S11,1.45,11,2z M11,20v2c0,0.55,0.45,1,1,1s1-0.45,1-1v-2c0-0.55-0.45-1-1-1C11.45,19,11,19.45,11,20z M5.99,4.58c-0.39-0.39-1.03-0.39-1.41,0 c-0.39,0.39-0.39,1.03,0,1.41l1.06,1.06c0.39,0.39,1.03,0.39,1.41,0s0.39-1.03,0-1.41L5.99,4.58z M18.36,16.95 c-0.39-0.39-1.03-0.39-1.41,0c-0.39,0.39-0.39,1.03,0,1.41l1.06,1.06c0.39,0.39,1.03,0.39,1.41,0c0.39-0.39,0.39-1.03,0-1.41 L18.36,16.95z M19.42,5.99c0.39-0.39,0.39-1.03,0-1.41c-0.39-0.39-1.03-0.39-1.41,0l-1.06,1.06c-0.39,0.39-0.39,1.03,0,1.41 s1.03,0.39,1.41,0L19.42,5.99z M7.05,18.36c0.39-0.39,0.39-1.03,0-1.41c-0.39-0.39-1.03-0.39-1.41,0l-1.06,1.06 c-0.39,0.39-0.39,1.03,0,1.41s1.03,0.39,1.41,0L7.05,18.36z"></path></svg><svg viewBox="0 0 24 24" width="24" height="24" class="darkToggleIcon_nQuB"><path fill="currentColor" d="M9.37,5.51C9.19,6.15,9.1,6.82,9.1,7.5c0,4.08,3.32,7.4,7.4,7.4c0.68,0,1.35-0.09,1.99-0.27C17.45,17.19,14.93,19,12,19 c-3.86,0-7-3.14-7-7C5,9.07,6.81,6.55,9.37,5.51z M12,3c-4.97,0-9,4.03-9,9s4.03,9,9,9s9-4.03,9-9c0-0.46-0.04-0.92-0.1-1.36 c-0.98,1.37-2.58,2.26-4.4,2.26c-2.98,0-5.4-2.42-5.4-5.4c0-1.81,0.89-3.42,2.26-4.4C12.92,3.04,12.46,3,12,3L12,3z"></path></svg></button></div><div class="searchBox_dLyj"><div class="navbar__search"><span aria-label="expand searchbar" role="button" class="search-icon" tabindex="0"></span><input type="search" id="search_input_react" placeholder="Search" aria-label="Search" class="navbar__search-input search-bar"></div></div></div></div><div role="presentation" class="navbar-sidebar__backdrop"></div></nav><div class="main-wrapper docsWrapper_mKqt"><button aria-label="Scroll back to top" class="clean-btn theme-back-to-top-button backToTopButton_RiI4" type="button"></button><div class="docPage_ualW"><aside class="theme-doc-sidebar-container docSidebarContainer_UQUJ"><div class="sidebar_RiAD"><nav class="menu thin-scrollbar menu_izAj"><ul class="theme-doc-sidebar-menu menu__list"><li class="theme-doc-sidebar-item-link theme-doc-sidebar-item-link-level-1 menu__list-item"><a class="menu__link" href="/document/">Quick start</a></li><li class="theme-doc-sidebar-item-link theme-doc-sidebLine truncated
<script src="/document/assets/js/runtime~main.222c91cd.js"></script>
<script src="/document/assets/js/main.9ce4b94b.js"></script>
<div role="region"><a href="#" class="skipToContent_cbSD">Skip to main content</a></div><nav class="navbar navbar--fixed-top"><div class="navbar__inner"><div class="navbar__items"><button aria-label="Navigation bar toggle" class="navbar__toggle clean-btn" type="button" tabindex="0"><svg width="30" height="30" viewBox="0 0 30 30" aria-hidden="true"><path stroke="currentColor" stroke-linecap="round" stroke-miterlimit="10" stroke-width="2" d="M4 7h22M4 15h22M4 23h22"></path></svg></button><a href="https://artplayer.org/document" target="_self" rel="noopener noreferrer" class="navbar__brand"><div class="navbar__logo"><img src="/document/img/logo.png" alt="Artplayer.js" class="themedImage_WmJs themedImage--light_gXqO" height="28" width="28"><img src="/document/img/logo.png" alt="Artplayer.js" class="themedImage_WmJs themedImage--dark_X1Zc" height="28" width="28"></div><b class="navbar__title text--truncate">Artplayer.js</b></a><a href="https://artplayer.org" target="_blank" rel="noopener noreferrer" class="navbar__item navbar__link">Online Editor<svg width="13.5" height="13.5" aria-hidden="true" viewBox="0 0 24 24" class="iconExternalLink_cOdw"><path fill="currentColor" d="M21 13v10h-21v-19h12v2h-10v15h17v-8h2zm3-12h-10.988l4.035 4-6.977 7.07 2.828 2.828 6.977-7.07 4.125 4.172v-11z"></path></svg></a><a href="https://github.com/zhw2590582/ArtPlayer" target="_blank" rel="noopener noreferrer" class="navbar__item navbar__link">Github<svg width="13.5" height="13.5" aria-hidden="true" viewBox="0 0 24 24" class="iconExternalLink_cOdw"><path fill="currentColor" d="M21 13v10h-21v-19h12v2h-10v15h17v-8h2zm3-12h-10.988l4.035 4-6.977 7.07 2.828 2.828 6.977-7.07 4.125 4.172v-11z"></path></svg></a></div><div class="navbar__items navbar__items--right"><a href="#" class="navbar__item navbar__link">QQ群: 320881312</a><div class="navbar__item dropdown dropdown--hoverable dropdown--right"><a href="#" aria-haspopup="true" aria-expanded="false" role="button" class="navbar__link">English</a><ul class="dropdown__menu"><li><a class="dropdown__link" href="/document/">English</a></li><li><a class="dropdown__link" href="/document/zh-cn/">中文</a></li></ul></div><div class="toggle_F6nl colorModeToggle_ndsa"><button class="clean-btn toggleButton_Szei toggleButtonDisabled_qp8o" type="button" disabled="" title="Switch between dark and light mode (currently light mode)" aria-label="Switch between dark and light mode (currently light mode)"><svg viewBox="0 0 24 24" width="24" height="24" class="lightToggleIcon_y2PQ"><path fill="currentColor" d="M12,9c1.65,0,3,1.35,3,3s-1.35,3-3,3s-3-1.35-3-3S10.35,9,12,9 M12,7c-2.76,0-5,2.24-5,5s2.24,5,5,5s5-2.24,5-5 S14.76,7,12,7L12,7z M2,13l2,0c0.55,0,1-0.45,1-1s-0.45-1-1-1l-2,0c-0.55,0-1,0.45-1,1S1.45,13,2,13z M20,13l2,0c0.55,0,1-0.45,1-1 s-0.45-1-1-1l-2,0c-0.55,0-1,0.45-1,1S19.45,13,20,13z M11,2v2c0,0.55,0.45,1,1,1s1-0.45,1-1V2c0-0.55-0.45-1-1-1S11,1.45,11,2z M11,20v2c0,0.55,0.45,1,1,1s1-0.45,1-1v-2c0-0.55-0.45-1-1-1C11.45,19,11,19.45,11,20z M5.99,4.58c-0.39-0.39-1.03-0.39-1.41,0 c-0.39,0.39-0.39,1.03,0,1.41l1.06,1.06c0.39,0.39,1.03,0.39,1.41,0s0.39-1.03,0-1.41L5.99,4.58z M18.36,16.95 c-0.39-0.39-1.03-0.39-1.41,0c-0.39,0.39-0.39,1.03,0,1.41l1.06,1.06c0.39,0.39,1.03,0.39,1.41,0c0.39-0.39,0.39-1.03,0-1.41 L18.36,16.95z M19.42,5.99c0.39-0.39,0.39-1.03,0-1.41c-0.39-0.39-1.03-0.39-1.41,0l-1.06,1.06c-0.39,0.39-0.39,1.03,0,1.41 s1.03,0.39,1.41,0L19.42,5.99z M7.05,18.36c0.39-0.39,0.39-1.03,0-1.41c-0.39-0.39-1.03-0.39-1.41,0l-1.06,1.06 c-0.39,0.39-0.39,1.03,0,1.41s1.03,0.39,1.41,0L7.05,18.36z"></path></svg><svg viewBox="0 0 24 24" width="24" height="24" class="darkToggleIcon_sMpk"><path fill="currentColor" d="M9.37,5.51C9.19,6.15,9.1,6.82,9.1,7.5c0,4.08,3.32,7.4,7.4,7.4c0.68,0,1.35-0.09,1.99-0.27C17.45,17.19,14.93,19,12,19 c-3.86,0-7-3.14-7-7C5,9.07,6.81,6.55,9.37,5.51z M12,3c-4.97,0-9,4.03-9,9s4.03,9,9,9s9-4.03,9-9c0-0.46-0.04-0.92-0.1-1.36 c-0.98,1.37-2.58,2.26-4.4,2.26c-2.98,0-5.4-2.42-5.4-5.4c0-1.81,0.89-3.42,2.26-4.4C12.92,3.04,12.46,3,12,3L12,3z"></path></svg></button></div><div class="searchBox_xKlU"><div class="navbar__search"><span aria-label="expand searchbar" role="button" class="search-icon" tabindex="0"></span><input type="search" id="search_input_react" placeholder="Search" aria-label="Search" class="navbar__search-input search-bar"></div></div></div></div><div role="presentation" class="navbar-sidebar__backdrop"></div></nav><div class="main-wrapper docsWrapper_GpM1"><button aria-label="Scroll back to top" class="clean-btn theme-back-to-top-button backToTopButton_EOoS" type="button"></button><div class="docPage_vgSg"><aside class="theme-doc-sidebar-container docSidebarContainer_RUQH"><div class="sidebar_gEXq"><nav class="menu thin-scrollbar menu_squC"><ul class="theme-doc-sidebar-menu menu__list"><li class="theme-doc-sidebar-item-link theme-doc-sidebar-item-link-level-1 menu__list-item"><a class="menu__link" href="/document/">Quick start</a></li><li class="theme-doc-sidebar-item-link theme-doc-sidebLine truncated
<script src="/document/assets/js/runtime~main.f9808e8d.js"></script>
<script src="/document/assets/js/main.ac59e946.js"></script>
</body>
</html>
@@ -1 +1 @@
.col,.container{padding:0 var(--ifm-spacing-horizontal);width:100%}.markdown>h2,.markdown>h3,.markdown>h4,.markdown>h5,.markdown>h6{margin-bottom:calc(var(--ifm-heading-vertical-rhythm-bottom)*var(--ifm-leading))}body,ol ol,ol ul,ul ol,ul ul{margin:0}blockquote,pre{margin:0 0 var(--ifm-spacing-vertical)}.breadcrumbs__link,.button{transition-timing-function:var(--ifm-transition-timing-default)}.button,code{vertical-align:middle}.button--outline.button--active,.button--outline:active,.button--outline:hover,:root{--ifm-button-color:var(--ifm-font-color-base-inverse)}.menu__link:hover,a{transition:color var(--ifm-transition-fast) var(--ifm-transition-timing-default)}.navbar--dark,:root{--ifm-navbar-link-hover-color:var(--ifm-color-primary)}.menu,.navbar-sidebar{overflow-x:hidden}:root,html[data-theme=dark]{--ifm-color-emphasis-500:var(--ifm-color-gray-500)}.admonition-icon svg,.alert__icon svg{fill:var(--ifm-alert-foreground-color)}.toggleButton_rCf9,html{-webkit-tap-highlight-color:transparent}.button,.dropdown__link,.searchbox,.text--truncate{white-space:nowrap}.searchbox__reset:focus,.searchbox__submit:focus,body:not(.navigation-with-keyboard) :not(input):focus{outline:0}pre,table{overflow:auto}.markdown li,body{word-wrap:break-word}:root{--ifm-color-scheme:light;--ifm-dark-value:10%;--ifm-darker-value:15%;--ifm-darkest-value:30%;--ifm-light-value:15%;--ifm-lighter-value:30%;--ifm-lightest-value:50%;--ifm-contrast-background-value:90%;--ifm-contrast-foreground-value:70%;--ifm-contrast-background-dark-value:70%;--ifm-contrast-foreground-dark-value:90%;--ifm-color-primary:#3578e5;--ifm-color-secondary:#ebedf0;--ifm-color-success:#00a400;--ifm-color-info:#54c7ec;--ifm-color-warning:#ffba00;--ifm-color-danger:#fa383e;--ifm-color-primary-dark:#306cce;--ifm-color-primary-darker:#2d66c3;--ifm-color-primary-darkest:#2554a0;--ifm-color-primary-light:#538ce9;--ifm-color-primary-lighter:#72a1ed;--ifm-color-primary-lightest:#9abcf2;--ifm-color-primary-contrast-background:#ebf2fc;--ifm-color-primary-contrast-foreground:#102445;--ifm-color-secondary-dark:#d4d5d8;--ifm-color-secondary-darker:#c8c9cc;--ifm-color-secondary-darkest:#a4a6a8;--ifm-color-secondary-light:#eef0f2;--ifm-color-secondary-lighter:#f1f2f5;--ifm-color-secondary-lightest:#f5f6f8;--ifm-color-secondary-contrast-background:#fdfdfe;--ifm-color-secondary-contrast-foreground:#474748;--ifm-color-success-dark:#009400;--ifm-color-success-darker:#008b00;--ifm-color-success-darkest:#007300;--ifm-color-success-light:#26b226;--ifm-color-success-lighter:#4dbf4d;--ifm-color-success-lightest:#80d280;--ifm-color-success-contrast-background:#e6f6e6;--ifm-color-success-contrast-foreground:#003100;--ifm-color-info-dark:#4cb3d4;--ifm-color-info-darker:#47a9c9;--ifm-color-info-darkest:#3b8ba5;--ifm-color-info-light:#6ecfef;--ifm-color-info-lighter:#87d8f2;--ifm-color-info-lightest:#aae3f6;--ifm-color-info-contrast-background:#eef9fd;--ifm-color-info-contrast-foreground:#193c47;--ifm-color-warning-dark:#e6a700;--ifm-color-warning-darker:#d99e00;--ifm-color-warning-darkest:#b38200;--ifm-color-warning-light:#ffc426;--ifm-color-warning-lighter:#ffcf4d;--ifm-color-warning-lightest:#ffdd80;--ifm-color-warning-contrast-background:#fff8e6;--ifm-color-warning-contrast-foreground:#4d3800;--ifm-color-danger-dark:#e13238;--ifm-color-danger-darker:#d53035;--ifm-color-danger-darkest:#af272b;--ifm-color-danger-light:#fb565b;--ifm-color-danger-lighter:#fb7478;--ifm-color-danger-lightest:#fd9c9f;--ifm-color-danger-contrast-background:#ffebec;--ifm-color-danger-contrast-foreground:#4b1113;--ifm-color-white:#fff;--ifm-color-black:#000;--ifm-color-gray-0:var(--ifm-color-white);--ifm-color-gray-100:#f5f6f7;--ifm-color-gray-200:#ebedf0;--ifm-color-gray-300:#dadde1;--ifm-color-gray-400:#ccd0d5;--ifm-color-gray-500:#bec3c9;--ifm-color-gray-600:#8d949e;--ifm-color-gray-700:#606770;--ifm-color-gray-800:#444950;--ifm-color-gray-900:#1c1e21;--ifm-color-gray-1000:var(--ifm-color-black);--ifm-color-emphasis-0:var(--ifm-color-gray-0);--ifm-color-emphasis-100:var(--ifm-color-gray-100);--ifm-color-emphasis-200:var(--ifm-color-gray-200);--ifm-color-emphasis-300:var(--ifm-color-gray-300);--ifm-color-emphasis-400:var(--ifm-color-gray-400);--ifm-color-emphasis-600:var(--ifm-color-gray-600);--ifm-color-emphasis-700:var(--ifm-color-gray-700);--ifm-color-emphasis-800:var(--ifm-color-gray-800);--ifm-color-emphasis-900:var(--ifm-color-gray-900);--ifm-color-emphasis-1000:var(--ifm-color-gray-1000);--ifm-color-content:var(--ifm-color-emphasis-900);--ifm-color-content-inverse:var(--ifm-color-emphasis-0);--ifm-color-content-secondary:#525860;--ifm-background-color:transparent;--ifm-background-surface-color:var(--ifm-color-content-inverse);--ifm-global-border-width:1px;--ifm-global-radius:0.4rem;--ifm-hover-overlay:rgba(0,0,0,.05);--ifm-font-color-base:var(--ifm-color-content);--ifm-font-color-base-inverse:var(--ifm-color-content-inverse);--ifm-font-color-secondary:var(--ifm-color-content-secondary);--ifm-font-family-basLine truncated
.col,.container{padding:0 var(--ifm-spacing-horizontal);width:100%}.markdown>h2,.markdown>h3,.markdown>h4,.markdown>h5,.markdown>h6{margin-bottom:calc(var(--ifm-heading-vertical-rhythm-bottom)*var(--ifm-leading))}body,ol ol,ol ul,ul ol,ul ul{margin:0}blockquote,pre{margin:0 0 var(--ifm-spacing-vertical)}.breadcrumbs__link,.button{transition-timing-function:var(--ifm-transition-timing-default)}.button,code{vertical-align:middle}.button--outline.button--active,.button--outline:active,.button--outline:hover,:root{--ifm-button-color:var(--ifm-font-color-base-inverse)}.menu__link:hover,a{transition:color var(--ifm-transition-fast) var(--ifm-transition-timing-default)}.navbar--dark,:root{--ifm-navbar-link-hover-color:var(--ifm-color-primary)}.menu,.navbar-sidebar{overflow-x:hidden}:root,html[data-theme=dark]{--ifm-color-emphasis-500:var(--ifm-color-gray-500)}.admonition-icon svg,.alert__icon svg{fill:var(--ifm-alert-foreground-color)}.toggleButton_Szei,html{-webkit-tap-highlight-color:transparent}.button,.dropdown__link,.searchbox,.text--truncate{white-space:nowrap}.searchbox__reset:focus,.searchbox__submit:focus,body:not(.navigation-with-keyboard) :not(input):focus{outline:0}pre,table{overflow:auto}.markdown li,body{word-wrap:break-word}:root{--ifm-color-scheme:light;--ifm-dark-value:10%;--ifm-darker-value:15%;--ifm-darkest-value:30%;--ifm-light-value:15%;--ifm-lighter-value:30%;--ifm-lightest-value:50%;--ifm-contrast-background-value:90%;--ifm-contrast-foreground-value:70%;--ifm-contrast-background-dark-value:70%;--ifm-contrast-foreground-dark-value:90%;--ifm-color-primary:#3578e5;--ifm-color-secondary:#ebedf0;--ifm-color-success:#00a400;--ifm-color-info:#54c7ec;--ifm-color-warning:#ffba00;--ifm-color-danger:#fa383e;--ifm-color-primary-dark:#306cce;--ifm-color-primary-darker:#2d66c3;--ifm-color-primary-darkest:#2554a0;--ifm-color-primary-light:#538ce9;--ifm-color-primary-lighter:#72a1ed;--ifm-color-primary-lightest:#9abcf2;--ifm-color-primary-contrast-background:#ebf2fc;--ifm-color-primary-contrast-foreground:#102445;--ifm-color-secondary-dark:#d4d5d8;--ifm-color-secondary-darker:#c8c9cc;--ifm-color-secondary-darkest:#a4a6a8;--ifm-color-secondary-light:#eef0f2;--ifm-color-secondary-lighter:#f1f2f5;--ifm-color-secondary-lightest:#f5f6f8;--ifm-color-secondary-contrast-background:#fdfdfe;--ifm-color-secondary-contrast-foreground:#474748;--ifm-color-success-dark:#009400;--ifm-color-success-darker:#008b00;--ifm-color-success-darkest:#007300;--ifm-color-success-light:#26b226;--ifm-color-success-lighter:#4dbf4d;--ifm-color-success-lightest:#80d280;--ifm-color-success-contrast-background:#e6f6e6;--ifm-color-success-contrast-foreground:#003100;--ifm-color-info-dark:#4cb3d4;--ifm-color-info-darker:#47a9c9;--ifm-color-info-darkest:#3b8ba5;--ifm-color-info-light:#6ecfef;--ifm-color-info-lighter:#87d8f2;--ifm-color-info-lightest:#aae3f6;--ifm-color-info-contrast-background:#eef9fd;--ifm-color-info-contrast-foreground:#193c47;--ifm-color-warning-dark:#e6a700;--ifm-color-warning-darker:#d99e00;--ifm-color-warning-darkest:#b38200;--ifm-color-warning-light:#ffc426;--ifm-color-warning-lighter:#ffcf4d;--ifm-color-warning-lightest:#ffdd80;--ifm-color-warning-contrast-background:#fff8e6;--ifm-color-warning-contrast-foreground:#4d3800;--ifm-color-danger-dark:#e13238;--ifm-color-danger-darker:#d53035;--ifm-color-danger-darkest:#af272b;--ifm-color-danger-light:#fb565b;--ifm-color-danger-lighter:#fb7478;--ifm-color-danger-lightest:#fd9c9f;--ifm-color-danger-contrast-background:#ffebec;--ifm-color-danger-contrast-foreground:#4b1113;--ifm-color-white:#fff;--ifm-color-black:#000;--ifm-color-gray-0:var(--ifm-color-white);--ifm-color-gray-100:#f5f6f7;--ifm-color-gray-200:#ebedf0;--ifm-color-gray-300:#dadde1;--ifm-color-gray-400:#ccd0d5;--ifm-color-gray-500:#bec3c9;--ifm-color-gray-600:#8d949e;--ifm-color-gray-700:#606770;--ifm-color-gray-800:#444950;--ifm-color-gray-900:#1c1e21;--ifm-color-gray-1000:var(--ifm-color-black);--ifm-color-emphasis-0:var(--ifm-color-gray-0);--ifm-color-emphasis-100:var(--ifm-color-gray-100);--ifm-color-emphasis-200:var(--ifm-color-gray-200);--ifm-color-emphasis-300:var(--ifm-color-gray-300);--ifm-color-emphasis-400:var(--ifm-color-gray-400);--ifm-color-emphasis-600:var(--ifm-color-gray-600);--ifm-color-emphasis-700:var(--ifm-color-gray-700);--ifm-color-emphasis-800:var(--ifm-color-gray-800);--ifm-color-emphasis-900:var(--ifm-color-gray-900);--ifm-color-emphasis-1000:var(--ifm-color-gray-1000);--ifm-color-content:var(--ifm-color-emphasis-900);--ifm-color-content-inverse:var(--ifm-color-emphasis-0);--ifm-color-content-secondary:#525860;--ifm-background-color:transparent;--ifm-background-surface-color:var(--ifm-color-content-inverse);--ifm-global-border-width:1px;--ifm-global-radius:0.4rem;--ifm-hover-overlay:rgba(0,0,0,.05);--ifm-font-color-base:var(--ifm-color-content);--ifm-font-color-base-inverse:var(--ifm-color-content-inverse);--ifm-font-color-secondary:var(--ifm-color-content-secondary);--ifm-font-family-basLine truncated
@@ -1 +0,0 @@
"use strict";(self.webpackChunkartplayer_document=self.webpackChunkartplayer_document||[]).push([[898],{3905:function(e,n,t){t.d(n,{Zo:function(){return l},kt:function(){return f}});var r=t(7294);function o(e,n,t){return n in e?Object.defineProperty(e,n,{value:t,enumerable:!0,configurable:!0,writable:!0}):e[n]=t,e}function a(e,n){var t=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);n&&(r=r.filter((function(n){return Object.getOwnPropertyDescriptor(e,n).enumerable}))),t.push.apply(t,r)}return t}function i(e){for(var n=1;n<arguments.length;n++){var t=null!=arguments[n]?arguments[n]:{};n%2?a(Object(t),!0).forEach((function(n){o(e,n,t[n])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(t)):a(Object(t)).forEach((function(n){Object.defineProperty(e,n,Object.getOwnPropertyDescriptor(t,n))}))}return e}function s(e,n){if(null==e)return{};var t,r,o=function(e,n){if(null==e)return{};var t,r,o={},a=Object.keys(e);for(r=0;r<a.length;r++)t=a[r],n.indexOf(t)>=0||(o[t]=e[t]);return o}(e,n);if(Object.getOwnPropertySymbols){var a=Object.getOwnPropertySymbols(e);for(r=0;r<a.length;r++)t=a[r],n.indexOf(t)>=0||Object.prototype.propertyIsEnumerable.call(e,t)&&(o[t]=e[t])}return o}var d=r.createContext({}),c=function(e){var n=r.useContext(d),t=n;return e&&(t="function"==typeof e?e(n):i(i({},n),e)),t},l=function(e){var n=c(e.components);return r.createElement(d.Provider,{value:n},e.children)},p={inlineCode:"code",wrapper:function(e){var n=e.children;return r.createElement(r.Fragment,{},n)}},u=r.forwardRef((function(e,n){var t=e.components,o=e.mdxType,a=e.originalType,d=e.parentName,l=s(e,["components","mdxType","originalType","parentName"]),u=c(t),f=o,m=u["".concat(d,".").concat(f)]||u[f]||p[f]||a;return t?r.createElement(m,i(i({ref:n},l),{},{components:t})):r.createElement(m,i({ref:n},l))}));function f(e,n){var t=arguments,o=n&&n.mdxType;if("string"==typeof e||o){var a=t.length,i=new Array(a);i[0]=u;var s={};for(var d in n)hasOwnProperty.call(n,d)&&(s[d]=n[d]);s.originalType=e,s.mdxType="string"==typeof e?e:o,i[1]=s;for(var c=2;c<a;c++)i[c]=t[c];return r.createElement.apply(null,i)}return r.createElement.apply(null,t)}u.displayName="MDXCreateElement"},8089:function(e,n,t){t.r(n),t.d(n,{assets:function(){return l},contentTitle:function(){return d},default:function(){return f},frontMatter:function(){return s},metadata:function(){return c},toc:function(){return p}});var r=t(7462),o=t(3366),a=(t(7294),t(3905)),i=["components"],s={title:"How to add video ads",sidebar_position:5},d=void 0,c={unversionedId:"en/Questions/How_to_add_video_ads",id:"en/Questions/How_to_add_video_ads",title:"How to add video ads",description:"Video ads play before main video playback, support multiple video ads",source:"@site/docs/en/Questions/How_to_add_video_ads.mdx",sourceDirName:"en/Questions",slug:"/en/Questions/How_to_add_video_ads",permalink:"/document/en/Questions/How_to_add_video_ads",draft:!1,tags:[],version:"current",sidebarPosition:5,frontMatter:{title:"How to add video ads",sidebar_position:5},sidebar:"en",previous:{title:"How to import types",permalink:"/document/en/Questions/How_to_import_types"},next:{title:"How to add setting panel",permalink:"/document/en/Questions/How_to_add_setting_panel"}},l={},p=[],u={toc:p};function f(e){var n=e.components,t=(0,o.Z)(e,i);return(0,a.kt)("wrapper",(0,r.Z)({},u,t,{components:n,mdxType:"MDXLayout"}),(0,a.kt)("p",null,"Video ads play before main video playback, support multiple video ads"),(0,a.kt)("div",{className:"run-code"},"\u25b6 Run Code"),(0,a.kt)("pre",null,(0,a.kt)("code",{parentName:"pre",className:"language-js"},"var art = new Artplayer({\n container: '.artplayer-app',\n url: 'https://artplayer.org/assets/sample/video.mp4',\n muted: true,\n autoSize: true,\n autoplay: true,\n ads: [\n {\n url: '/assets/sample/test1.mp4'\n },\n {\n url: '/assets/sample/test2.webm'\n },\n ],\n controls: [\n {\n position: 'right',\n html: 'Skip The Ads',\n click: function () {\n // Skip The Ads\n art.ads.end();\n },\n },\n ],\n layers: [\n {\n html: 'Skip The Ads',\n style: {\n position: 'absolute',\n top: '20px',\n right: '20px',\n },\n click: function () {\n // Skip The Ads\n art.ads.end();\n },\n },\n ],\n});\n\nart.on('ready', function () {\n // Triggers when each video advertisement is played\n art.on('ads:start', (item) => {\n console.info('Ads is playing: ' + item.url);\n });\n\n // Triggers when all video advertisements are end\n art.on('ads:end', () => {\n console.info('Ads is end');\n });\n\n // Current advertising index\n console.info(art.ads.index);\n\n // Whether all t Line truncated
@@ -1 +0,0 @@
(self.webpackChunkartplayer_document=self.webpackChunkartplayer_document||[]).push([[918],{3905:function(e,t,n){"use strict";n.d(t,{Zo:function(){return u},kt:function(){return p}});var a=n(7294);function r(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function l(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var a=Object.getOwnPropertySymbols(e);t&&(a=a.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,a)}return n}function o(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?l(Object(n),!0).forEach((function(t){r(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):l(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}function c(e,t){if(null==e)return{};var n,a,r=function(e,t){if(null==e)return{};var n,a,r={},l=Object.keys(e);for(a=0;a<l.length;a++)n=l[a],t.indexOf(n)>=0||(r[n]=e[n]);return r}(e,t);if(Object.getOwnPropertySymbols){var l=Object.getOwnPropertySymbols(e);for(a=0;a<l.length;a++)n=l[a],t.indexOf(n)>=0||Object.prototype.propertyIsEnumerable.call(e,n)&&(r[n]=e[n])}return r}var i=a.createContext({}),s=function(e){var t=a.useContext(i),n=t;return e&&(n="function"==typeof e?e(t):o(o({},t),e)),n},u=function(e){var t=s(e.components);return a.createElement(i.Provider,{value:t},e.children)},m={inlineCode:"code",wrapper:function(e){var t=e.children;return a.createElement(a.Fragment,{},t)}},d=a.forwardRef((function(e,t){var n=e.components,r=e.mdxType,l=e.originalType,i=e.parentName,u=c(e,["components","mdxType","originalType","parentName"]),d=s(n),p=r,v=d["".concat(i,".").concat(p)]||d[p]||m[p]||l;return n?a.createElement(v,o(o({ref:t},u),{},{components:n})):a.createElement(v,o({ref:t},u))}));function p(e,t){var n=arguments,r=t&&t.mdxType;if("string"==typeof e||r){var l=n.length,o=new Array(l);o[0]=d;var c={};for(var i in t)hasOwnProperty.call(t,i)&&(c[i]=t[i]);c.originalType=e,c.mdxType="string"==typeof e?e:r,o[1]=c;for(var s=2;s<l;s++)o[s]=n[s];return a.createElement.apply(null,o)}return a.createElement.apply(null,n)}d.displayName="MDXCreateElement"},7209:function(e,t,n){"use strict";n.r(t),n.d(t,{default:function(){return Ot}});var a=n(7294),r=n(6010),l=n(7462),o=n(5999),c=n(9960);function i(e){var t=e.permalink,n=e.title,l=e.subLabel,o=e.isNext;return a.createElement(c.Z,{className:(0,r.Z)("pagination-nav__link",o?"pagination-nav__link--next":"pagination-nav__link--prev"),to:t},l&&a.createElement("div",{className:"pagination-nav__sublabel"},l),a.createElement("div",{className:"pagination-nav__label"},n))}function s(e){var t=e.previous,n=e.next;return a.createElement("nav",{className:"pagination-nav docusaurus-mt-lg","aria-label":(0,o.I)({id:"theme.docs.paginator.navAriaLabel",message:"Docs pages navigation",description:"The ARIA label for the docs pagination"})},t&&a.createElement(i,(0,l.Z)({},t,{subLabel:a.createElement(o.Z,{id:"theme.docs.paginator.previous",description:"The label used to navigate to the previous doc"},"Previous")})),n&&a.createElement(i,(0,l.Z)({},n,{subLabel:a.createElement(o.Z,{id:"theme.docs.paginator.next",description:"The label used to navigate to the next doc"},"Next"),isNext:!0})))}var u=n(2263),m=n(5551),d=n(373),p=n(5281),v=n(4477);var f={unreleased:function(e){var t=e.siteTitle,n=e.versionMetadata;return a.createElement(o.Z,{id:"theme.docs.versions.unreleasedVersionLabel",description:"The label used to tell the user that he's browsing an unreleased doc version",values:{siteTitle:t,versionLabel:a.createElement("b",null,n.label)}},"This is unreleased documentation for {siteTitle} {versionLabel} version.")},unmaintained:function(e){var t=e.siteTitle,n=e.versionMetadata;return a.createElement(o.Z,{id:"theme.docs.versions.unmaintainedVersionLabel",description:"The label used to tell the user that he's browsing an unmaintained doc version",values:{siteTitle:t,versionLabel:a.createElement("b",null,n.label)}},"This is documentation for {siteTitle} {versionLabel}, which is no longer actively maintained.")}};function g(e){var t=f[e.versionMetadata.banner];return a.createElement(t,e)}function h(e){var t=e.versionLabel,n=e.to,r=e.onClick;return a.createElement(o.Z,{id:"theme.docs.versions.latestVersionSuggestionLabel",description:"The label used to tell the user to check the latest version",values:{versionLabel:t,latestVersionLink:a.createElement("b",null,a.createElement(c.Z,{to:n,onClick:r},a.createElement(o.Z,{id:"theme.docs.versions.latestVersionLinkLabel",description:"The label used for the latest version suggestion link label"},"latest version")))}},"For up-to-date documentation, see the {latestVersionLink} ({versionLabel}).")}function b(e){var t,n=e.className,l=e.versionMetadata,o=(0,u.Z)().siteConfig.title,c=(0,m.gA)({failfast:!0}).pluginId,i=(0,d.J)(c).savePreferredVersionName,s=(0,m.Jo)(c),v=s.latestDocSuggestion,fLine truncated
@@ -0,0 +1 @@
(self.webpackChunkartplayer_document=self.webpackChunkartplayer_document||[]).push([[918],{876:function(e,t,n){"use strict";n.d(t,{Zo:function(){return u},kt:function(){return p}});var a=n(2784);function r(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function l(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var a=Object.getOwnPropertySymbols(e);t&&(a=a.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,a)}return n}function o(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?l(Object(n),!0).forEach((function(t){r(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):l(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}function c(e,t){if(null==e)return{};var n,a,r=function(e,t){if(null==e)return{};var n,a,r={},l=Object.keys(e);for(a=0;a<l.length;a++)n=l[a],t.indexOf(n)>=0||(r[n]=e[n]);return r}(e,t);if(Object.getOwnPropertySymbols){var l=Object.getOwnPropertySymbols(e);for(a=0;a<l.length;a++)n=l[a],t.indexOf(n)>=0||Object.prototype.propertyIsEnumerable.call(e,n)&&(r[n]=e[n])}return r}var i=a.createContext({}),s=function(e){var t=a.useContext(i),n=t;return e&&(n="function"==typeof e?e(t):o(o({},t),e)),n},u=function(e){var t=s(e.components);return a.createElement(i.Provider,{value:t},e.children)},m={inlineCode:"code",wrapper:function(e){var t=e.children;return a.createElement(a.Fragment,{},t)}},d=a.forwardRef((function(e,t){var n=e.components,r=e.mdxType,l=e.originalType,i=e.parentName,u=c(e,["components","mdxType","originalType","parentName"]),d=s(n),p=r,v=d["".concat(i,".").concat(p)]||d[p]||m[p]||l;return n?a.createElement(v,o(o({ref:t},u),{},{components:n})):a.createElement(v,o({ref:t},u))}));function p(e,t){var n=arguments,r=t&&t.mdxType;if("string"==typeof e||r){var l=n.length,o=new Array(l);o[0]=d;var c={};for(var i in t)hasOwnProperty.call(t,i)&&(c[i]=t[i]);c.originalType=e,c.mdxType="string"==typeof e?e:r,o[1]=c;for(var s=2;s<l;s++)o[s]=n[s];return a.createElement.apply(null,o)}return a.createElement.apply(null,n)}d.displayName="MDXCreateElement"},1258:function(e,t,n){"use strict";n.r(t),n.d(t,{default:function(){return Ot}});var a=n(2784),r=n(6277),l=n(7896),o=n(1077),c=n(9817);function i(e){var t=e.permalink,n=e.title,l=e.subLabel,o=e.isNext;return a.createElement(c.Z,{className:(0,r.Z)("pagination-nav__link",o?"pagination-nav__link--next":"pagination-nav__link--prev"),to:t},l&&a.createElement("div",{className:"pagination-nav__sublabel"},l),a.createElement("div",{className:"pagination-nav__label"},n))}function s(e){var t=e.previous,n=e.next;return a.createElement("nav",{className:"pagination-nav docusaurus-mt-lg","aria-label":(0,o.I)({id:"theme.docs.paginator.navAriaLabel",message:"Docs pages navigation",description:"The ARIA label for the docs pagination"})},t&&a.createElement(i,(0,l.Z)({},t,{subLabel:a.createElement(o.Z,{id:"theme.docs.paginator.previous",description:"The label used to navigate to the previous doc"},"Previous")})),n&&a.createElement(i,(0,l.Z)({},n,{subLabel:a.createElement(o.Z,{id:"theme.docs.paginator.next",description:"The label used to navigate to the next doc"},"Next"),isNext:!0})))}var u=n(7614),m=n(7486),d=n(7949),p=n(211),v=n(5663);var f={unreleased:function(e){var t=e.siteTitle,n=e.versionMetadata;return a.createElement(o.Z,{id:"theme.docs.versions.unreleasedVersionLabel",description:"The label used to tell the user that he's browsing an unreleased doc version",values:{siteTitle:t,versionLabel:a.createElement("b",null,n.label)}},"This is unreleased documentation for {siteTitle} {versionLabel} version.")},unmaintained:function(e){var t=e.siteTitle,n=e.versionMetadata;return a.createElement(o.Z,{id:"theme.docs.versions.unmaintainedVersionLabel",description:"The label used to tell the user that he's browsing an unmaintained doc version",values:{siteTitle:t,versionLabel:a.createElement("b",null,n.label)}},"This is documentation for {siteTitle} {versionLabel}, which is no longer actively maintained.")}};function g(e){var t=f[e.versionMetadata.banner];return a.createElement(t,e)}function h(e){var t=e.versionLabel,n=e.to,r=e.onClick;return a.createElement(o.Z,{id:"theme.docs.versions.latestVersionSuggestionLabel",description:"The label used to tell the user to check the latest version",values:{versionLabel:t,latestVersionLink:a.createElement("b",null,a.createElement(c.Z,{to:n,onClick:r},a.createElement(o.Z,{id:"theme.docs.versions.latestVersionLinkLabel",description:"The label used for the latest version suggestion link label"},"latest version")))}},"For up-to-date documentation, see the {latestVersionLink} ({versionLabel}).")}function b(e){var t,n=e.className,l=e.versionMetadata,o=(0,u.Z)().siteConfig.title,c=(0,m.gA)({failfast:!0}).pluginId,i=(0,d.J)(c).savePreferredVersionName,s=(0,m.Jo)(c),v=s.latestDocSuggestion,f=Line truncated
@@ -0,0 +1 @@
"use strict";(self.webpackChunkartplayer_document=self.webpackChunkartplayer_document||[]).push([[514,489],{1635:function(e,t,n){n.r(t),n.d(t,{default:function(){return xe}});var a=n(2784),r=n(2489),l=n(8828),i=n(6277),o=n(1077),c=n(4126),s=n(2105);var d=n(211),u="backToTopButton_EOoS",m="backToTopButtonShow_Iijp";function b(){var e=function(e){var t=e.threshold,n=(0,a.useState)(!1),r=n[0],l=n[1],i=(0,a.useRef)(!1),o=(0,c.Ct)(),d=o.startScroll,u=o.cancelScroll;return(0,c.RF)((function(e,n){var a=e.scrollY,r=null==n?void 0:n.scrollY;r&&(i.current?i.current=!1:a>=r?(u(),l(!1)):a<t?l(!1):a+window.innerHeight<document.documentElement.scrollHeight&&l(!0))})),(0,s.S)((function(e){e.location.hash&&(i.current=!0,l(!1))})),{shown:r,scrollToTop:function(){return d(0)}}}({threshold:300}),t=e.shown,n=e.scrollToTop;return a.createElement("button",{"aria-label":(0,o.I)({id:"theme.BackToTopButton.buttonAriaLabel",message:"Scroll back to top",description:"The ARIA label for the back to top button"}),className:(0,i.Z)("clean-btn",d.k.common.backToTopButton,u,t&&m),type:"button",onClick:n})}var p=n(7963),v=n(7683),h=n(3578),f=n(7896);function E(e){return a.createElement("svg",(0,f.Z)({width:"20",height:"20","aria-hidden":"true"},e),a.createElement("g",{fill:"#7a7a7a"},a.createElement("path",{d:"M9.992 10.023c0 .2-.062.399-.172.547l-4.996 7.492a.982.982 0 01-.828.454H1c-.55 0-1-.453-1-1 0-.2.059-.403.168-.551l4.629-6.942L.168 3.078A.939.939 0 010 2.528c0-.548.45-.997 1-.997h2.996c.352 0 .649.18.828.45L9.82 9.472c.11.148.172.347.172.55zm0 0"}),a.createElement("path",{d:"M19.98 10.023c0 .2-.058.399-.168.547l-4.996 7.492a.987.987 0 01-.828.454h-3c-.547 0-.996-.453-.996-1 0-.2.059-.403.168-.551l4.625-6.942-4.625-6.945a.939.939 0 01-.168-.55 1 1 0 01.996-.997h3c.348 0 .649.18.828.45l4.996 7.492c.11.148.168.347.168.55zm0 0"})))}var g="collapseSidebarButton_YeeX",k="collapseSidebarButtonIcon_Ifa6";function _(e){var t=e.onClick;return a.createElement("button",{type:"button",title:(0,o.I)({id:"theme.docs.sidebar.collapseButtonTitle",message:"Collapse sidebar",description:"The title attribute for collapse button of doc sidebar"}),"aria-label":(0,o.I)({id:"theme.docs.sidebar.collapseButtonAriaLabel",message:"Collapse sidebar",description:"The title attribute for collapse button of doc sidebar"}),className:(0,i.Z)("button button--secondary button--outline",g),onClick:t},a.createElement(E,{className:k}))}var C=n(3717),I=n(1461),S=n(3364),N=n(2293),Z=n(7661),x=n(8698),y=Symbol("EmptyContext"),T=a.createContext(y);function L(e){var t=e.children,n=(0,a.useState)(null),r=n[0],l=n[1],i=(0,a.useMemo)((function(){return{expandedItem:r,setExpandedItem:l}}),[r]);return a.createElement(T.Provider,{value:i},t)}var w=n(9817),M=n(9741),P=["item","onItemClick","activePath","level","index"];function A(e){var t=e.categoryLabel,n=e.onClick;return a.createElement("button",{"aria-label":(0,o.I)({id:"theme.DocSidebarItem.toggleCollapsedCategoryAriaLabel",message:"Toggle the collapsible sidebar category '{label}'",description:"The ARIA label to toggle the collapsible sidebar category"},{label:t}),type:"button",className:"clean-btn menu__caret",onClick:n})}function F(e){var t=e.item,n=e.onItemClick,r=e.activePath,l=e.level,o=e.index,c=(0,I.Z)(e,P),s=t.items,u=t.label,m=t.collapsible,b=t.className,p=t.href,h=function(e){var t=(0,M.Z)();return(0,a.useMemo)((function(){return e.href?e.href:!t&&e.collapsible?(0,N.Wl)(e):void 0}),[e,t])}(t),E=(0,N._F)(t,r),g=(0,Z.Mg)(p,r),k=(0,x.u)({initialState:function(){return!!m&&(!E&&t.collapsed)}}),_=k.collapsed,C=k.setCollapsed;!function(e){var t=e.isActive,n=e.collapsed,r=e.setCollapsed,l=(0,S.D9)(t);(0,a.useEffect)((function(){t&&!l&&n&&r(!1)}),[t,l,n,r])}({isActive:E,collapsed:_,setCollapsed:C});var L=function(){var e=(0,a.useContext)(T);if(e===y)throw new S.i6("DocSidebarItemsExpandedStateProvider");return e}(),F=L.expandedItem,B=L.setExpandedItem;function H(e){void 0===e&&(e=!_),B(e?null:o),C(e)}var D=(0,v.L)().docs.sidebar.autoCollapseCategories;return(0,a.useEffect)((function(){m&&F&&F!==o&&D&&C(!0)}),[m,F,o,C,D]),a.createElement("li",{className:(0,i.Z)(d.k.docs.docSidebarItemCategory,d.k.docs.docSidebarItemCategoryLevel(l),"menu__list-item",{"menu__list-item--collapsed":_},b)},a.createElement("div",{className:(0,i.Z)("menu__list-item-collapsible",{"menu__list-item-collapsible--active":g})},a.createElement(w.Z,(0,f.Z)({className:(0,i.Z)("menu__link",{"menu__link--sublist":m,"menu__link--sublist-caret":!p&&m,"menu__link--active":E}),onClick:m?function(e){null==n||n(t),p?H(!1):(e.preventDefault(),H())}:function(){null==n||n(t)},"aria-current":g?"page":void 0,"aria-expanded":m?!_:void 0,href:m?null!=h?h:"#":h},c),u),p&&m&&a.createElement(A,{categoryLabel:u,onClick:function(e){e.preventDefault(),H()}})),a.createElement(x.z,{lazy:!0,as:"ul",className:"menu__list",collapsed:_},a.createElement(Q,{items:s,tabIndex:_?-1:0,onItemClick:n,activePath:r,level:l+1})))}var B=n(1344),H=n(1090),D="menuExternalLink_g0f0",W=["item","onILine truncated
@@ -1 +0,0 @@
"use strict";(self.webpackChunkartplayer_document=self.webpackChunkartplayer_document||[]).push([[514,608],{9068:function(e,t,n){n.r(t),n.d(t,{default:function(){return ye}});var a=n(7294),r=n(4608),l=n(3460),i=n(6010),o=n(5999),c=n(2466),s=n(5936);var d=n(5281),u="backToTopButton_RiI4",m="backToTopButtonShow_ssHd";function b(){var e=function(e){var t=e.threshold,n=(0,a.useState)(!1),r=n[0],l=n[1],i=(0,a.useRef)(!1),o=(0,c.Ct)(),d=o.startScroll,u=o.cancelScroll;return(0,c.RF)((function(e,n){var a=e.scrollY,r=null==n?void 0:n.scrollY;r&&(i.current?i.current=!1:a>=r?(u(),l(!1)):a<t?l(!1):a+window.innerHeight<document.documentElement.scrollHeight&&l(!0))})),(0,s.S)((function(e){e.location.hash&&(i.current=!0,l(!1))})),{shown:r,scrollToTop:function(){return d(0)}}}({threshold:300}),t=e.shown,n=e.scrollToTop;return a.createElement("button",{"aria-label":(0,o.I)({id:"theme.BackToTopButton.buttonAriaLabel",message:"Scroll back to top",description:"The ARIA label for the back to top button"}),className:(0,i.Z)("clean-btn",d.k.common.backToTopButton,u,t&&m),type:"button",onClick:n})}var p=n(7524),v=n(6668),h=n(5537),f=n(7462);function E(e){return a.createElement("svg",(0,f.Z)({width:"20",height:"20","aria-hidden":"true"},e),a.createElement("g",{fill:"#7a7a7a"},a.createElement("path",{d:"M9.992 10.023c0 .2-.062.399-.172.547l-4.996 7.492a.982.982 0 01-.828.454H1c-.55 0-1-.453-1-1 0-.2.059-.403.168-.551l4.629-6.942L.168 3.078A.939.939 0 010 2.528c0-.548.45-.997 1-.997h2.996c.352 0 .649.18.828.45L9.82 9.472c.11.148.172.347.172.55zm0 0"}),a.createElement("path",{d:"M19.98 10.023c0 .2-.058.399-.168.547l-4.996 7.492a.987.987 0 01-.828.454h-3c-.547 0-.996-.453-.996-1 0-.2.059-.403.168-.551l4.625-6.942-4.625-6.945a.939.939 0 01-.168-.55 1 1 0 01.996-.997h3c.348 0 .649.18.828.45l4.996 7.492c.11.148.168.347.168.55zm0 0"})))}var g="collapseSidebarButton_FykI",_="collapseSidebarButtonIcon_DTRl";function k(e){var t=e.onClick;return a.createElement("button",{type:"button",title:(0,o.I)({id:"theme.docs.sidebar.collapseButtonTitle",message:"Collapse sidebar",description:"The title attribute for collapse button of doc sidebar"}),"aria-label":(0,o.I)({id:"theme.docs.sidebar.collapseButtonAriaLabel",message:"Collapse sidebar",description:"The title attribute for collapse button of doc sidebar"}),className:(0,i.Z)("button button--secondary button--outline",g),onClick:t},a.createElement(E,{className:_}))}var C=n(9689),I=n(3366),N=n(9688),S=n(3791),Z=n(8596),y=n(6043),x=Symbol("EmptyContext"),T=a.createContext(x);function L(e){var t=e.children,n=(0,a.useState)(null),r=n[0],l=n[1],i=(0,a.useMemo)((function(){return{expandedItem:r,setExpandedItem:l}}),[r]);return a.createElement(T.Provider,{value:i},t)}var w=n(9960),A=n(2389),F=["item","onItemClick","activePath","level","index"];function P(e){var t=e.categoryLabel,n=e.onClick;return a.createElement("button",{"aria-label":(0,o.I)({id:"theme.DocSidebarItem.toggleCollapsedCategoryAriaLabel",message:"Toggle the collapsible sidebar category '{label}'",description:"The ARIA label to toggle the collapsible sidebar category"},{label:t}),type:"button",className:"clean-btn menu__caret",onClick:n})}function M(e){var t=e.item,n=e.onItemClick,r=e.activePath,l=e.level,o=e.index,c=(0,I.Z)(e,F),s=t.items,u=t.label,m=t.collapsible,b=t.className,p=t.href,h=function(e){var t=(0,A.Z)();return(0,a.useMemo)((function(){return e.href?e.href:!t&&e.collapsible?(0,S.Wl)(e):void 0}),[e,t])}(t),E=(0,S._F)(t,r),g=(0,Z.Mg)(p,r),_=(0,y.u)({initialState:function(){return!!m&&(!E&&t.collapsed)}}),k=_.collapsed,C=_.setCollapsed;!function(e){var t=e.isActive,n=e.collapsed,r=e.setCollapsed,l=(0,N.D9)(t);(0,a.useEffect)((function(){t&&!l&&n&&r(!1)}),[t,l,n,r])}({isActive:E,collapsed:k,setCollapsed:C});var L=function(){var e=(0,a.useContext)(T);if(e===x)throw new N.i6("DocSidebarItemsExpandedStateProvider");return e}(),M=L.expandedItem,H=L.setExpandedItem;function B(e){void 0===e&&(e=!k),H(e?null:o),C(e)}var D=(0,v.L)().docs.sidebar.autoCollapseCategories;return(0,a.useEffect)((function(){m&&M&&M!==o&&D&&C(!0)}),[m,M,o,C,D]),a.createElement("li",{className:(0,i.Z)(d.k.docs.docSidebarItemCategory,d.k.docs.docSidebarItemCategoryLevel(l),"menu__list-item",{"menu__list-item--collapsed":k},b)},a.createElement("div",{className:(0,i.Z)("menu__list-item-collapsible",{"menu__list-item-collapsible--active":g})},a.createElement(w.Z,(0,f.Z)({className:(0,i.Z)("menu__link",{"menu__link--sublist":m,"menu__link--sublist-caret":!p&&m,"menu__link--active":E}),onClick:m?function(e){null==n||n(t),p?B(!1):(e.preventDefault(),B())}:function(){null==n||n(t)},"aria-current":g?"page":void 0,"aria-expanded":m?!k:void 0,href:m?null!=h?h:"#":h},c),u),p&&m&&a.createElement(P,{categoryLabel:u,onClick:function(e){e.preventDefault(),B()}})),a.createElement(y.z,{lazy:!0,as:"ul",className:"menu__list",collapsed:k},a.createElement(Q,{items:s,tabIndex:k?-1:0,onItemClick:n,activePath:r,level:l+1})))}var H=n(3919),B=n(541),D="menuExternalLink_KU1_",R=["item","onILine truncated
@@ -1 +0,0 @@
"use strict";(self.webpackChunkartplayer_document=self.webpackChunkartplayer_document||[]).push([[784],{3905:function(e,n,t){t.d(n,{Zo:function(){return m},kt:function(){return d}});var o=t(7294);function r(e,n,t){return n in e?Object.defineProperty(e,n,{value:t,enumerable:!0,configurable:!0,writable:!0}):e[n]=t,e}function a(e,n){var t=Object.keys(e);if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);n&&(o=o.filter((function(n){return Object.getOwnPropertyDescriptor(e,n).enumerable}))),t.push.apply(t,o)}return t}function i(e){for(var n=1;n<arguments.length;n++){var t=null!=arguments[n]?arguments[n]:{};n%2?a(Object(t),!0).forEach((function(n){r(e,n,t[n])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(t)):a(Object(t)).forEach((function(n){Object.defineProperty(e,n,Object.getOwnPropertyDescriptor(t,n))}))}return e}function c(e,n){if(null==e)return{};var t,o,r=function(e,n){if(null==e)return{};var t,o,r={},a=Object.keys(e);for(o=0;o<a.length;o++)t=a[o],n.indexOf(t)>=0||(r[t]=e[t]);return r}(e,n);if(Object.getOwnPropertySymbols){var a=Object.getOwnPropertySymbols(e);for(o=0;o<a.length;o++)t=a[o],n.indexOf(t)>=0||Object.prototype.propertyIsEnumerable.call(e,t)&&(r[t]=e[t])}return r}var l=o.createContext({}),s=function(e){var n=o.useContext(l),t=n;return e&&(t="function"==typeof e?e(n):i(i({},n),e)),t},m=function(e){var n=s(e.components);return o.createElement(l.Provider,{value:n},e.children)},u={inlineCode:"code",wrapper:function(e){var n=e.children;return o.createElement(o.Fragment,{},n)}},p=o.forwardRef((function(e,n){var t=e.components,r=e.mdxType,a=e.originalType,l=e.parentName,m=c(e,["components","mdxType","originalType","parentName"]),p=s(t),d=r,y=p["".concat(l,".").concat(d)]||p[d]||u[d]||a;return t?o.createElement(y,i(i({ref:n},m),{},{components:t})):o.createElement(y,i({ref:n},m))}));function d(e,n){var t=arguments,r=n&&n.mdxType;if("string"==typeof e||r){var a=t.length,i=new Array(a);i[0]=p;var c={};for(var l in n)hasOwnProperty.call(n,l)&&(c[l]=n[l]);c.originalType=e,c.mdxType="string"==typeof e?e:r,i[1]=c;for(var s=2;s<a;s++)i[s]=t[s];return o.createElement.apply(null,i)}return o.createElement.apply(null,t)}p.displayName="MDXCreateElement"},8414:function(e,n,t){t.r(n),t.d(n,{assets:function(){return m},contentTitle:function(){return l},default:function(){return d},frontMatter:function(){return c},metadata:function(){return s},toc:function(){return u}});var o=t(7462),r=t(3366),a=(t(7294),t(3905)),i=["components"],c={title:"Handle a single component",sidebar_position:3},l=void 0,s={unversionedId:"en/Questions/Handle_single_component",id:"en/Questions/Handle_single_component",title:"Handle a single component",description:"When we add custom components in layers, contextmenu, controls, It is best to add a name property that is used to position the DOM element of the component.",source:"@site/docs/en/Questions/Handle_single_component.mdx",sourceDirName:"en/Questions",slug:"/en/Questions/Handle_single_component",permalink:"/document/en/Questions/Handle_single_component",draft:!1,tags:[],version:"current",sidebarPosition:3,frontMatter:{title:"Handle a single component",sidebar_position:3},sidebar:"en",previous:{title:"Add button to the controls",permalink:"/document/en/Questions/Create_button_in_the_controls"},next:{title:"How to import types",permalink:"/document/en/Questions/How_to_import_types"}},m={},u=[],p={toc:u};function d(e){var n=e.components,t=(0,r.Z)(e,i);return(0,a.kt)("wrapper",(0,o.Z)({},p,t,{components:n,mdxType:"MDXLayout"}),(0,a.kt)("p",null,"When we add custom components in ",(0,a.kt)("inlineCode",{parentName:"p"},"layers"),", ",(0,a.kt)("inlineCode",{parentName:"p"},"contextmenu"),", ",(0,a.kt)("inlineCode",{parentName:"p"},"controls"),", It is best to add a ",(0,a.kt)("inlineCode",{parentName:"p"},"name")," property that is used to position the DOM element of the component."),(0,a.kt)("p",null,"Here are three ways to get the DOM element of the component: component method ",(0,a.kt)("inlineCode",{parentName:"p"},"mounted"),", instance method ",(0,a.kt)("inlineCode",{parentName:"p"},"query"),", recommended through ",(0,a.kt)("inlineCode",{parentName:"p"},"name")," direct acquisition."),(0,a.kt)("div",{className:"run-code"},"\u25b6 Run Code"),(0,a.kt)("pre",null,(0,a.kt)("code",{parentName:"pre",className:"language-js"},"var art = new Artplayer({\n container: '.artplayer-app',\n url: '/assets/sample/video.mp4',\n setting: true,\n});\n\nart.on('ready', () => {\n art.layers.add({\n name: 'layer1',\n html: 'your-layer',\n mounted: function($layer1) {\n //\n }\n });\n\n art.contextmenu.add({\n name: 'contextmenu1',\n html: 'your-contextmenu',\n mounted: function($contextmenu1) {\n //\n }\n });\n\n art.controls.add({\n name: 'control1',\n html: 'your-control',\n position: 'right',\n mounted: function( Line truncated
@@ -0,0 +1 @@
"use strict";(self.webpackChunkartplayer_document=self.webpackChunkartplayer_document||[]).push([[784],{876:function(e,n,t){t.d(n,{Zo:function(){return m},kt:function(){return d}});var o=t(2784);function r(e,n,t){return n in e?Object.defineProperty(e,n,{value:t,enumerable:!0,configurable:!0,writable:!0}):e[n]=t,e}function a(e,n){var t=Object.keys(e);if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);n&&(o=o.filter((function(n){return Object.getOwnPropertyDescriptor(e,n).enumerable}))),t.push.apply(t,o)}return t}function i(e){for(var n=1;n<arguments.length;n++){var t=null!=arguments[n]?arguments[n]:{};n%2?a(Object(t),!0).forEach((function(n){r(e,n,t[n])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(t)):a(Object(t)).forEach((function(n){Object.defineProperty(e,n,Object.getOwnPropertyDescriptor(t,n))}))}return e}function c(e,n){if(null==e)return{};var t,o,r=function(e,n){if(null==e)return{};var t,o,r={},a=Object.keys(e);for(o=0;o<a.length;o++)t=a[o],n.indexOf(t)>=0||(r[t]=e[t]);return r}(e,n);if(Object.getOwnPropertySymbols){var a=Object.getOwnPropertySymbols(e);for(o=0;o<a.length;o++)t=a[o],n.indexOf(t)>=0||Object.prototype.propertyIsEnumerable.call(e,t)&&(r[t]=e[t])}return r}var l=o.createContext({}),s=function(e){var n=o.useContext(l),t=n;return e&&(t="function"==typeof e?e(n):i(i({},n),e)),t},m=function(e){var n=s(e.components);return o.createElement(l.Provider,{value:n},e.children)},u={inlineCode:"code",wrapper:function(e){var n=e.children;return o.createElement(o.Fragment,{},n)}},p=o.forwardRef((function(e,n){var t=e.components,r=e.mdxType,a=e.originalType,l=e.parentName,m=c(e,["components","mdxType","originalType","parentName"]),p=s(t),d=r,y=p["".concat(l,".").concat(d)]||p[d]||u[d]||a;return t?o.createElement(y,i(i({ref:n},m),{},{components:t})):o.createElement(y,i({ref:n},m))}));function d(e,n){var t=arguments,r=n&&n.mdxType;if("string"==typeof e||r){var a=t.length,i=new Array(a);i[0]=p;var c={};for(var l in n)hasOwnProperty.call(n,l)&&(c[l]=n[l]);c.originalType=e,c.mdxType="string"==typeof e?e:r,i[1]=c;for(var s=2;s<a;s++)i[s]=t[s];return o.createElement.apply(null,i)}return o.createElement.apply(null,t)}p.displayName="MDXCreateElement"},5332:function(e,n,t){t.r(n),t.d(n,{assets:function(){return m},contentTitle:function(){return l},default:function(){return d},frontMatter:function(){return c},metadata:function(){return s},toc:function(){return u}});var o=t(7896),r=t(1461),a=(t(2784),t(876)),i=["components"],c={title:"Handle a single component",sidebar_position:3},l=void 0,s={unversionedId:"en/Questions/Handle_single_component",id:"en/Questions/Handle_single_component",title:"Handle a single component",description:"When we add custom components in layers, contextmenu, controls, It is best to add a name property that is used to position the DOM element of the component.",source:"@site/docs/en/Questions/Handle_single_component.mdx",sourceDirName:"en/Questions",slug:"/en/Questions/Handle_single_component",permalink:"/document/en/Questions/Handle_single_component",draft:!1,tags:[],version:"current",sidebarPosition:3,frontMatter:{title:"Handle a single component",sidebar_position:3},sidebar:"en",previous:{title:"Add button to the controls",permalink:"/document/en/Questions/Create_button_in_the_controls"},next:{title:"How to import types",permalink:"/document/en/Questions/How_to_import_types"}},m={},u=[],p={toc:u};function d(e){var n=e.components,t=(0,r.Z)(e,i);return(0,a.kt)("wrapper",(0,o.Z)({},p,t,{components:n,mdxType:"MDXLayout"}),(0,a.kt)("p",null,"When we add custom components in ",(0,a.kt)("inlineCode",{parentName:"p"},"layers"),", ",(0,a.kt)("inlineCode",{parentName:"p"},"contextmenu"),", ",(0,a.kt)("inlineCode",{parentName:"p"},"controls"),", It is best to add a ",(0,a.kt)("inlineCode",{parentName:"p"},"name")," property that is used to position the DOM element of the component."),(0,a.kt)("p",null,"Here are three ways to get the DOM element of the component: component method ",(0,a.kt)("inlineCode",{parentName:"p"},"mounted"),", instance method ",(0,a.kt)("inlineCode",{parentName:"p"},"query"),", recommended through ",(0,a.kt)("inlineCode",{parentName:"p"},"name")," direct acquisition."),(0,a.kt)("div",{className:"run-code"},"\u25b6 Run Code"),(0,a.kt)("pre",null,(0,a.kt)("code",{parentName:"pre",className:"language-js"},"var art = new Artplayer({\n container: '.artplayer-app',\n url: '/assets/sample/video.mp4',\n setting: true,\n});\n\nart.on('ready', () => {\n art.layers.add({\n name: 'layer1',\n html: 'your-layer',\n mounted: function($layer1) {\n //\n }\n });\n\n art.contextmenu.add({\n name: 'contextmenu1',\n html: 'your-contextmenu',\n mounted: function($contextmenu1) {\n //\n }\n });\n\n art.controls.add({\n name: 'control1',\n html: 'your-control',\n position: 'right',\n mounted: function($c Line truncated
@@ -0,0 +1 @@
"use strict";(self.webpackChunkartplayer_document=self.webpackChunkartplayer_document||[]).push([[615],{876:function(e,t,n){n.d(t,{Zo:function(){return p},kt:function(){return f}});var r=n(2784);function o(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function a(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,r)}return n}function c(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?a(Object(n),!0).forEach((function(t){o(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):a(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}function i(e,t){if(null==e)return{};var n,r,o=function(e,t){if(null==e)return{};var n,r,o={},a=Object.keys(e);for(r=0;r<a.length;r++)n=a[r],t.indexOf(n)>=0||(o[n]=e[n]);return o}(e,t);if(Object.getOwnPropertySymbols){var a=Object.getOwnPropertySymbols(e);for(r=0;r<a.length;r++)n=a[r],t.indexOf(n)>=0||Object.prototype.propertyIsEnumerable.call(e,n)&&(o[n]=e[n])}return o}var l=r.createContext({}),s=function(e){var t=r.useContext(l),n=t;return e&&(n="function"==typeof e?e(t):c(c({},t),e)),n},p=function(e){var t=s(e.components);return r.createElement(l.Provider,{value:t},e.children)},u={inlineCode:"code",wrapper:function(e){var t=e.children;return r.createElement(r.Fragment,{},t)}},m=r.forwardRef((function(e,t){var n=e.components,o=e.mdxType,a=e.originalType,l=e.parentName,p=i(e,["components","mdxType","originalType","parentName"]),m=s(n),f=o,d=m["".concat(l,".").concat(f)]||m[f]||u[f]||a;return n?r.createElement(d,c(c({ref:t},p),{},{components:n})):r.createElement(d,c({ref:t},p))}));function f(e,t){var n=arguments,o=t&&t.mdxType;if("string"==typeof e||o){var a=n.length,c=new Array(a);c[0]=m;var i={};for(var l in t)hasOwnProperty.call(t,l)&&(i[l]=t[l]);i.originalType=e,i.mdxType="string"==typeof e?e:o,c[1]=i;for(var s=2;s<a;s++)c[s]=n[s];return r.createElement.apply(null,c)}return r.createElement.apply(null,n)}m.displayName="MDXCreateElement"},9411:function(e,t,n){n.r(t),n.d(t,{assets:function(){return p},contentTitle:function(){return l},default:function(){return f},frontMatter:function(){return i},metadata:function(){return s},toc:function(){return u}});var r=n(7896),o=n(1461),a=(n(2784),n(876)),c=["components"],i={title:"\u4e0e React Portal \u4f7f\u7528",sidebar_position:6},l=void 0,s={unversionedId:"zh-cn/Questions/Use_with_react_portal",id:"zh-cn/Questions/Use_with_react_portal",title:"\u4e0e React Portal \u4f7f\u7528",description:"\u5728 layers\u3001contextmenu\u3001controls \u91cc\u4f7f\u7528 react \u7ec4\u4ef6\u4e5f\u662f\u975e\u5e38\u5bb9\u6613\u7684\u4e8b\uff0c\u901a\u8fc7 createPortal \u5904\u7406\u66f4\u590d\u6742\u7684\u4e1a\u52a1\u903b\u8f91",source:"@site/docs/zh-cn/Questions/Use_with_react_portal.mdx",sourceDirName:"zh-cn/Questions",slug:"/zh-cn/Questions/Use_with_react_portal",permalink:"/document/zh-cn/Questions/Use_with_react_portal",draft:!1,tags:[],version:"current",sidebarPosition:6,frontMatter:{title:"\u4e0e React Portal \u4f7f\u7528",sidebar_position:6},sidebar:"zh-cn",previous:{title:"\u600e\u4e48\u6dfb\u52a0\u8bbe\u7f6e\u9762\u677f",permalink:"/document/zh-cn/Questions/How_to_add_setting_panel"}},p={},u=[],m={toc:u};function f(e){var t=e.components,n=(0,o.Z)(e,c);return(0,a.kt)("wrapper",(0,r.Z)({},m,n,{components:t,mdxType:"MDXLayout"}),(0,a.kt)("p",null,"\u5728 layers\u3001contextmenu\u3001controls \u91cc\u4f7f\u7528 react \u7ec4\u4ef6\u4e5f\u662f\u975e\u5e38\u5bb9\u6613\u7684\u4e8b\uff0c\u901a\u8fc7 createPortal \u5904\u7406\u66f4\u590d\u6742\u7684\u4e1a\u52a1\u903b\u8f91"),(0,a.kt)("p",null,"\ud83d\udc49 ",(0,a.kt)("a",{parentName:"p",href:"https://codesandbox.io/s/artplayer-react-portal-5z32h"},"\u70b9\u51fb\u6253\u5f00\u5728\u7ebf\u6f14\u793a")),(0,a.kt)("pre",null,(0,a.kt)("code",{parentName:"pre",className:"language-jsx"},'import React, { useState, useEffect } from "react";\nimport ReactDOM, { createPortal } from "react-dom";\nimport Artplayer from "artplayer/examples/react/Artplayer";\n\nfunction Timer({ time }) {\n return <div>{time}</div>;\n}\n\nfunction App() {\n const [art, setArt] = useState(null);\n const [time, setTime] = useState(0);\n\n useEffect(() => {\n const update = () => setTime((time) => time + 1);\n setInterval(update, 1000);\n }, []);\n\n return (\n <div>\n <Artplayer\n option={{\n url: "https://artplayer.org/assets/sample/video.mp4",\n layers: [\n {\n html: "",\n name: "portal"\n }\n ],\n controls: [\n {\n position: "right",\n name: "portal",\n html: ""\n }\n ]\n }}\n style={{\n widthLine truncated
@@ -1 +0,0 @@
"use strict";(self.webpackChunkartplayer_document=self.webpackChunkartplayer_document||[]).push([[615],{3905:function(e,t,n){n.d(t,{Zo:function(){return p},kt:function(){return f}});var r=n(7294);function o(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function a(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,r)}return n}function c(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?a(Object(n),!0).forEach((function(t){o(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):a(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}function i(e,t){if(null==e)return{};var n,r,o=function(e,t){if(null==e)return{};var n,r,o={},a=Object.keys(e);for(r=0;r<a.length;r++)n=a[r],t.indexOf(n)>=0||(o[n]=e[n]);return o}(e,t);if(Object.getOwnPropertySymbols){var a=Object.getOwnPropertySymbols(e);for(r=0;r<a.length;r++)n=a[r],t.indexOf(n)>=0||Object.prototype.propertyIsEnumerable.call(e,n)&&(o[n]=e[n])}return o}var l=r.createContext({}),s=function(e){var t=r.useContext(l),n=t;return e&&(n="function"==typeof e?e(t):c(c({},t),e)),n},p=function(e){var t=s(e.components);return r.createElement(l.Provider,{value:t},e.children)},u={inlineCode:"code",wrapper:function(e){var t=e.children;return r.createElement(r.Fragment,{},t)}},m=r.forwardRef((function(e,t){var n=e.components,o=e.mdxType,a=e.originalType,l=e.parentName,p=i(e,["components","mdxType","originalType","parentName"]),m=s(n),f=o,d=m["".concat(l,".").concat(f)]||m[f]||u[f]||a;return n?r.createElement(d,c(c({ref:t},p),{},{components:n})):r.createElement(d,c({ref:t},p))}));function f(e,t){var n=arguments,o=t&&t.mdxType;if("string"==typeof e||o){var a=n.length,c=new Array(a);c[0]=m;var i={};for(var l in t)hasOwnProperty.call(t,l)&&(i[l]=t[l]);i.originalType=e,i.mdxType="string"==typeof e?e:o,c[1]=i;for(var s=2;s<a;s++)c[s]=n[s];return r.createElement.apply(null,c)}return r.createElement.apply(null,n)}m.displayName="MDXCreateElement"},6707:function(e,t,n){n.r(t),n.d(t,{assets:function(){return p},contentTitle:function(){return l},default:function(){return f},frontMatter:function(){return i},metadata:function(){return s},toc:function(){return u}});var r=n(7462),o=n(3366),a=(n(7294),n(3905)),c=["components"],i={title:"\u4e0e React Portal \u4f7f\u7528",sidebar_position:6},l=void 0,s={unversionedId:"zh-cn/Questions/Use_with_react_portal",id:"zh-cn/Questions/Use_with_react_portal",title:"\u4e0e React Portal \u4f7f\u7528",description:"\u5728 layers\u3001contextmenu\u3001controls \u91cc\u4f7f\u7528 react \u7ec4\u4ef6\u4e5f\u662f\u975e\u5e38\u5bb9\u6613\u7684\u4e8b\uff0c\u901a\u8fc7 createPortal \u5904\u7406\u66f4\u590d\u6742\u7684\u4e1a\u52a1\u903b\u8f91",source:"@site/docs/zh-cn/Questions/Use_with_react_portal.mdx",sourceDirName:"zh-cn/Questions",slug:"/zh-cn/Questions/Use_with_react_portal",permalink:"/document/zh-cn/Questions/Use_with_react_portal",draft:!1,tags:[],version:"current",sidebarPosition:6,frontMatter:{title:"\u4e0e React Portal \u4f7f\u7528",sidebar_position:6},sidebar:"zh-cn",previous:{title:"\u600e\u4e48\u6dfb\u52a0\u8bbe\u7f6e\u9762\u677f",permalink:"/document/zh-cn/Questions/How_to_add_setting_panel"}},p={},u=[],m={toc:u};function f(e){var t=e.components,n=(0,o.Z)(e,c);return(0,a.kt)("wrapper",(0,r.Z)({},m,n,{components:t,mdxType:"MDXLayout"}),(0,a.kt)("p",null,"\u5728 layers\u3001contextmenu\u3001controls \u91cc\u4f7f\u7528 react \u7ec4\u4ef6\u4e5f\u662f\u975e\u5e38\u5bb9\u6613\u7684\u4e8b\uff0c\u901a\u8fc7 createPortal \u5904\u7406\u66f4\u590d\u6742\u7684\u4e1a\u52a1\u903b\u8f91"),(0,a.kt)("p",null,"\ud83d\udc49 ",(0,a.kt)("a",{parentName:"p",href:"https://codesandbox.io/s/artplayer-react-portal-5z32h"},"\u70b9\u51fb\u6253\u5f00\u5728\u7ebf\u6f14\u793a")),(0,a.kt)("pre",null,(0,a.kt)("code",{parentName:"pre",className:"language-jsx"},'import React, { useState, useEffect } from "react";\nimport ReactDOM, { createPortal } from "react-dom";\nimport Artplayer from "artplayer/examples/react/Artplayer";\n\nfunction Timer({ time }) {\n return <div>{time}</div>;\n}\n\nfunction App() {\n const [art, setArt] = useState(null);\n const [time, setTime] = useState(0);\n\n useEffect(() => {\n const update = () => setTime((time) => time + 1);\n setInterval(update, 1000);\n }, []);\n\n return (\n <div>\n <Artplayer\n option={{\n url: "https://artplayer.org/assets/sample/video.mp4",\n layers: [\n {\n html: "",\n name: "portal"\n }\n ],\n controls: [\n {\n position: "right",\n name: "portal",\n html: ""\n }\n ]\n }}\n style={{\n widLine truncated
-1
View File
@@ -1 +0,0 @@
(self.webpackChunkartplayer_document=self.webpackChunkartplayer_document||[]).push([[245],{4130:function(e,t,n){"use strict";n.r(t),n.d(t,{default:function(){return v}});var i=n(5485),a=n.n(i),s=n(1336);s.tokenizer.separator=/[\s\-/]+/;var r=function(){function e(e,t){this.searchDocs=e,this.lunrIndex=s.Index.load(t)}var t=e.prototype;return t.getLunrResult=function(e){return this.lunrIndex.query((function(t){var n=s.tokenizer(e);t.term(n,{boost:10}),t.term(n,{wildcard:s.Query.wildcard.TRAILING})}))},t.getHit=function(e,t,n){return{hierarchy:{lvl0:e.pageTitle||e.title,lvl1:0===e.type?null:e.title},url:e.url,_snippetResult:n?{content:{value:n,matchLevel:"full"}}:null,_highlightResult:{hierarchy:{lvl0:{value:0===e.type?t||e.title:e.pageTitle},lvl1:0===e.type?null:{value:t||e.title}}}}},t.getTitleHit=function(e,t,n){var i=t[0],a=t[0]+n,s=e.title.substring(0,i)+'<span class="algolia-docsearch-suggestion--highlight">'+e.title.substring(i,a)+"</span>"+e.title.substring(a,e.title.length);return this.getHit(e,s)},t.getKeywordHit=function(e,t,n){var i=t[0],a=t[0]+n,s=e.title+"<br /><i>Keywords: "+e.keywords.substring(0,i)+'<span class="algolia-docsearch-suggestion--highlight">'+e.keywords.substring(i,a)+"</span>"+e.keywords.substring(a,e.keywords.length)+"</i>";return this.getHit(e,s)},t.getContentHit=function(e,t){for(var n=t[0],i=t[0]+t[1],a=n,s=i,r=!0,l=!0,o=0;o<3;o++){var u=e.content.lastIndexOf(" ",a-2),c=e.content.lastIndexOf(".",a-2);if(c>0&&c>u){a=c+1,r=!1;break}if(u<0){a=0,r=!1;break}a=u+1}for(var h=0;h<10;h++){var g=e.content.indexOf(" ",s+1),d=e.content.indexOf(".",s+1);if(d>0&&d<g){s=d,l=!1;break}if(g<0){s=e.content.length,l=!1;break}s=g}var p=e.content.substring(a,n);return r&&(p="... "+p),p+='<span class="algolia-docsearch-suggestion--highlight">'+e.content.substring(n,i)+"</span>",p+=e.content.substring(i,s),l&&(p+=" ..."),this.getHit(e,null,p)},t.search=function(e){var t=this;return new Promise((function(n,i){var a=t.getLunrResult(e),s=[];a.length>5&&(a.length=5),t.titleHitsRes=[],t.contentHitsRes=[],a.forEach((function(n){var i=t.searchDocs[n.ref],a=n.matchData.metadata;for(var r in a)if(a[r].title){if(!t.titleHitsRes.includes(n.ref)){var l=a[r].title.position[0];s.push(t.getTitleHit(i,l,e.length)),t.titleHitsRes.push(n.ref)}}else if(a[r].content){var o=a[r].content.position[0];s.push(t.getContentHit(i,o))}else if(a[r].keywords){var u=a[r].keywords.position[0];s.push(t.getKeywordHit(i,u,e.length)),t.titleHitsRes.push(n.ref)}})),s.length>5&&(s.length=5),n(s)}))},e}(),l=n(1639),o=n.n(l),u="algolia-docsearch",c=u+"-suggestion",h={suggestion:'\n <a class="'+c+"\n {{#isCategoryHeader}}"+c+"__main{{/isCategoryHeader}}\n {{#isSubCategoryHeader}}"+c+'__secondary{{/isSubCategoryHeader}}\n "\n aria-label="Link to the result"\n href="{{{url}}}"\n >\n <div class="'+c+'--category-header">\n <span class="'+c+'--category-header-lvl0">{{{category}}}</span>\n </div>\n <div class="'+c+'--wrapper">\n <div class="'+c+'--subcategory-column">\n <span class="'+c+'--subcategory-column-text">{{{subcategory}}}</span>\n </div>\n {{#isTextOrSubcategoryNonEmpty}}\n <div class="'+c+'--content">\n <div class="'+c+'--subcategory-inline">{{{subcategory}}}</div>\n <div class="'+c+'--title">{{{title}}}</div>\n {{#text}}<div class="'+c+'--text">{{{text}}}</div>{{/text}}\n </div>\n {{/isTextOrSubcategoryNonEmpty}}\n </div>\n </a>\n ',suggestionSimple:'\n <div class="'+c+"\n {{#isCategoryHeader}}"+c+"__main{{/isCategoryHeader}}\n {{#isSubCategoryHeader}}"+c+'__secondary{{/isSubCategoryHeader}}\n suggestion-layout-simple\n ">\n <div class="'+c+'--category-header">\n {{^isLvl0}}\n <span class="'+c+"--category-header-lvl0 "+c+'--category-header-item">{{{category}}}</span>\n {{^isLvl1}}\n {{^isLvl1EmptyOrDuplicate}}\n <span class="'+c+"--category-header-lvl1 "+c+'--category-header-item">\n {{{subcategory}}}\n </span>\n {{/isLvl1EmptyOrDuplicate}}\n {{/isLvl1}}\n {{/isLvl0}}\n <div class="'+c+"--title "+c+'--category-header-item">\n {{#isLvl2}}\n {{{title}}}\n {{/isLvl2}}\n {{#isLvl1}}\n {{{subcategory}}}\n {{/isLvl1}}\n {{#isLvl0}}\n {{{category}}}\n {{/isLvl0}}\n </div>\n </div>\n <div class="'+c+'--wrapper">\n {{#text}}\n <div class="'+c+'--content">\n <div class="'+c+'--text">{{{text}}}</div>\n </div>\n {{/text}}\n </div>\n </div>\n ',footer:'\n <div class="algolia-docsearch-footer">\n </div>\n ',empty:'\n <div class="'+c+'">\n <div class="'+c+'--wrapper">\n <div class="'+c+"--content "+c+'--no-results">\n <div class="'+c+'--title">\n <div class="'+c+'--text">\n No results found for query <b>"{{query}}"</b>\n Line truncated
@@ -0,0 +1 @@
"use strict";(self.webpackChunkartplayer_document=self.webpackChunkartplayer_document||[]).push([[201],{876:function(n,e,t){t.d(e,{Zo:function(){return u},kt:function(){return p}});var r=t(2784);function l(n,e,t){return e in n?Object.defineProperty(n,e,{value:t,enumerable:!0,configurable:!0,writable:!0}):n[e]=t,n}function s(n,e){var t=Object.keys(n);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(n);e&&(r=r.filter((function(e){return Object.getOwnPropertyDescriptor(n,e).enumerable}))),t.push.apply(t,r)}return t}function a(n){for(var e=1;e<arguments.length;e++){var t=null!=arguments[e]?arguments[e]:{};e%2?s(Object(t),!0).forEach((function(e){l(n,e,t[e])})):Object.getOwnPropertyDescriptors?Object.defineProperties(n,Object.getOwnPropertyDescriptors(t)):s(Object(t)).forEach((function(e){Object.defineProperty(n,e,Object.getOwnPropertyDescriptor(t,e))}))}return n}function i(n,e){if(null==n)return{};var t,r,l=function(n,e){if(null==n)return{};var t,r,l={},s=Object.keys(n);for(r=0;r<s.length;r++)t=s[r],e.indexOf(t)>=0||(l[t]=n[t]);return l}(n,e);if(Object.getOwnPropertySymbols){var s=Object.getOwnPropertySymbols(n);for(r=0;r<s.length;r++)t=s[r],e.indexOf(t)>=0||Object.prototype.propertyIsEnumerable.call(n,t)&&(l[t]=n[t])}return l}var o=r.createContext({}),c=function(n){var e=r.useContext(o),t=e;return n&&(t="function"==typeof n?n(e):a(a({},e),n)),t},u=function(n){var e=c(n.components);return r.createElement(o.Provider,{value:e},n.children)},m={inlineCode:"code",wrapper:function(n){var e=n.children;return r.createElement(r.Fragment,{},e)}},f=r.forwardRef((function(n,e){var t=n.components,l=n.mdxType,s=n.originalType,o=n.parentName,u=i(n,["components","mdxType","originalType","parentName"]),f=c(t),p=l,h=f["".concat(o,".").concat(p)]||f[p]||m[p]||s;return t?r.createElement(h,a(a({ref:e},u),{},{components:t})):r.createElement(h,a({ref:e},u))}));function p(n,e){var t=arguments,l=e&&e.mdxType;if("string"==typeof n||l){var s=t.length,a=new Array(s);a[0]=f;var i={};for(var o in e)hasOwnProperty.call(e,o)&&(i[o]=e[o]);i.originalType=n,i.mdxType="string"==typeof n?n:l,a[1]=i;for(var c=2;c<s;c++)a[c]=t[c];return r.createElement.apply(null,a)}return r.createElement.apply(null,t)}f.displayName="MDXCreateElement"},588:function(n,e,t){t.r(e),t.d(e,{assets:function(){return u},contentTitle:function(){return o},default:function(){return p},frontMatter:function(){return i},metadata:function(){return c},toc:function(){return m}});var r=t(7896),l=t(1461),s=(t(2784),t(876)),a=["components"],i={title:"Add select in the controls",sidebar_position:1},o=void 0,c={unversionedId:"en/Questions/Create_selector_in_the_controls",id:"en/Questions/Create_selector_in_the_controls",title:"Add select in the controls",description:"Sometimes you need to add a list in the controls, then you can use the selector and onSelect attribute when adding controls",source:"@site/docs/en/Questions/Create_selector_in_the_controls.mdx",sourceDirName:"en/Questions",slug:"/en/Questions/Create_selector_in_the_controls",permalink:"/document/en/Questions/Create_selector_in_the_controls",draft:!1,tags:[],version:"current",sidebarPosition:1,frontMatter:{title:"Add select in the controls",sidebar_position:1},sidebar:"en",previous:{title:"Ads Plugin",permalink:"/document/en/Plugins/ads"},next:{title:"Add button to the controls",permalink:"/document/en/Questions/Create_button_in_the_controls"}},u={},m=[{value:"Switch Subtitle",id:"switch-subtitle",level:3},{value:"Switch filter",id:"switch-filter",level:3}],f={toc:m};function p(n){var e=n.components,t=(0,l.Z)(n,a);return(0,s.kt)("wrapper",(0,r.Z)({},f,t,{components:e,mdxType:"MDXLayout"}),(0,s.kt)("p",null,"Sometimes you need to add a list in the controls, then you can use the ",(0,s.kt)("inlineCode",{parentName:"p"},"selector")," and ",(0,s.kt)("inlineCode",{parentName:"p"},"onSelect")," attribute when adding controls"),(0,s.kt)("h3",{id:"switch-subtitle"},"Switch Subtitle"),(0,s.kt)("div",{className:"run-code"},"\u25b6 Run Code"),(0,s.kt)("pre",null,(0,s.kt)("code",{parentName:"pre",className:"language-js"},"var art = new Artplayer({\n container: '.artplayer-app',\n url: '/assets/sample/video.mp4',\n controls: [\n {\n position: 'right',\n html: 'Subtitle 01',\n selector: [\n {\n default: true,\n html: '<span style=\"color:red\">Subtitle 01</span>',\n url: '/assets/sample/subtitle.srt?id=1',\n },\n {\n html: '<span style=\"color:yellow\">Subtitle 02</span>',\n url: '/assets/sample/subtitle.srt?id=2',\n },\n ],\n onSelect: function (item, $dom) {\n console.info(item, $dom);\n\n art.subtitle.url = item.url;\n \n return 'You click ' + item.html;\n },\n },\n ],\n});\n")),(0,s.kt)("h3",{id:"switch-filter"},"Line truncated
@@ -1 +0,0 @@
"use strict";(self.webpackChunkartplayer_document=self.webpackChunkartplayer_document||[]).push([[201],{3905:function(n,e,t){t.d(e,{Zo:function(){return u},kt:function(){return p}});var r=t(7294);function l(n,e,t){return e in n?Object.defineProperty(n,e,{value:t,enumerable:!0,configurable:!0,writable:!0}):n[e]=t,n}function s(n,e){var t=Object.keys(n);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(n);e&&(r=r.filter((function(e){return Object.getOwnPropertyDescriptor(n,e).enumerable}))),t.push.apply(t,r)}return t}function a(n){for(var e=1;e<arguments.length;e++){var t=null!=arguments[e]?arguments[e]:{};e%2?s(Object(t),!0).forEach((function(e){l(n,e,t[e])})):Object.getOwnPropertyDescriptors?Object.defineProperties(n,Object.getOwnPropertyDescriptors(t)):s(Object(t)).forEach((function(e){Object.defineProperty(n,e,Object.getOwnPropertyDescriptor(t,e))}))}return n}function i(n,e){if(null==n)return{};var t,r,l=function(n,e){if(null==n)return{};var t,r,l={},s=Object.keys(n);for(r=0;r<s.length;r++)t=s[r],e.indexOf(t)>=0||(l[t]=n[t]);return l}(n,e);if(Object.getOwnPropertySymbols){var s=Object.getOwnPropertySymbols(n);for(r=0;r<s.length;r++)t=s[r],e.indexOf(t)>=0||Object.prototype.propertyIsEnumerable.call(n,t)&&(l[t]=n[t])}return l}var o=r.createContext({}),c=function(n){var e=r.useContext(o),t=e;return n&&(t="function"==typeof n?n(e):a(a({},e),n)),t},u=function(n){var e=c(n.components);return r.createElement(o.Provider,{value:e},n.children)},m={inlineCode:"code",wrapper:function(n){var e=n.children;return r.createElement(r.Fragment,{},e)}},f=r.forwardRef((function(n,e){var t=n.components,l=n.mdxType,s=n.originalType,o=n.parentName,u=i(n,["components","mdxType","originalType","parentName"]),f=c(t),p=l,h=f["".concat(o,".").concat(p)]||f[p]||m[p]||s;return t?r.createElement(h,a(a({ref:e},u),{},{components:t})):r.createElement(h,a({ref:e},u))}));function p(n,e){var t=arguments,l=e&&e.mdxType;if("string"==typeof n||l){var s=t.length,a=new Array(s);a[0]=f;var i={};for(var o in e)hasOwnProperty.call(e,o)&&(i[o]=e[o]);i.originalType=n,i.mdxType="string"==typeof n?n:l,a[1]=i;for(var c=2;c<s;c++)a[c]=t[c];return r.createElement.apply(null,a)}return r.createElement.apply(null,t)}f.displayName="MDXCreateElement"},8582:function(n,e,t){t.r(e),t.d(e,{assets:function(){return u},contentTitle:function(){return o},default:function(){return p},frontMatter:function(){return i},metadata:function(){return c},toc:function(){return m}});var r=t(7462),l=t(3366),s=(t(7294),t(3905)),a=["components"],i={title:"Add select in the controls",sidebar_position:1},o=void 0,c={unversionedId:"en/Questions/Create_selector_in_the_controls",id:"en/Questions/Create_selector_in_the_controls",title:"Add select in the controls",description:"Sometimes you need to add a list in the controls, then you can use the selector and onSelect attribute when adding controls",source:"@site/docs/en/Questions/Create_selector_in_the_controls.mdx",sourceDirName:"en/Questions",slug:"/en/Questions/Create_selector_in_the_controls",permalink:"/document/en/Questions/Create_selector_in_the_controls",draft:!1,tags:[],version:"current",sidebarPosition:1,frontMatter:{title:"Add select in the controls",sidebar_position:1},sidebar:"en",previous:{title:"Danmuku plugin",permalink:"/document/en/Plugins/danmuku"},next:{title:"Add button to the controls",permalink:"/document/en/Questions/Create_button_in_the_controls"}},u={},m=[{value:"Switch Subtitle",id:"switch-subtitle",level:3},{value:"Switch filter",id:"switch-filter",level:3}],f={toc:m};function p(n){var e=n.components,t=(0,l.Z)(n,a);return(0,s.kt)("wrapper",(0,r.Z)({},f,t,{components:e,mdxType:"MDXLayout"}),(0,s.kt)("p",null,"Sometimes you need to add a list in the controls, then you can use the ",(0,s.kt)("inlineCode",{parentName:"p"},"selector")," and ",(0,s.kt)("inlineCode",{parentName:"p"},"onSelect")," attribute when adding controls"),(0,s.kt)("h3",{id:"switch-subtitle"},"Switch Subtitle"),(0,s.kt)("div",{className:"run-code"},"\u25b6 Run Code"),(0,s.kt)("pre",null,(0,s.kt)("code",{parentName:"pre",className:"language-js"},"var art = new Artplayer({\n container: '.artplayer-app',\n url: '/assets/sample/video.mp4',\n controls: [\n {\n position: 'right',\n html: 'Subtitle 01',\n selector: [\n {\n default: true,\n html: '<span style=\"color:red\">Subtitle 01</span>',\n url: '/assets/sample/subtitle.srt?id=1',\n },\n {\n html: '<span style=\"color:yellow\">Subtitle 02</span>',\n url: '/assets/sample/subtitle.srt?id=2',\n },\n ],\n onSelect: function (item, $dom) {\n console.info(item, $dom);\n\n art.subtitle.url = item.url;\n \n return 'You click ' + item.html;\n },\n },\n ],\n});\n")),(0,s.kt)("h3",{id:"switchLine truncated
@@ -0,0 +1 @@
"use strict";(self.webpackChunkartplayer_document=self.webpackChunkartplayer_document||[]).push([[280],{876:function(t,e,n){n.d(e,{Zo:function(){return m},kt:function(){return c}});var a=n(2784);function r(t,e,n){return e in t?Object.defineProperty(t,e,{value:n,enumerable:!0,configurable:!0,writable:!0}):t[e]=n,t}function l(t,e){var n=Object.keys(t);if(Object.getOwnPropertySymbols){var a=Object.getOwnPropertySymbols(t);e&&(a=a.filter((function(e){return Object.getOwnPropertyDescriptor(t,e).enumerable}))),n.push.apply(n,a)}return n}function i(t){for(var e=1;e<arguments.length;e++){var n=null!=arguments[e]?arguments[e]:{};e%2?l(Object(n),!0).forEach((function(e){r(t,e,n[e])})):Object.getOwnPropertyDescriptors?Object.defineProperties(t,Object.getOwnPropertyDescriptors(n)):l(Object(n)).forEach((function(e){Object.defineProperty(t,e,Object.getOwnPropertyDescriptor(n,e))}))}return t}function o(t,e){if(null==t)return{};var n,a,r=function(t,e){if(null==t)return{};var n,a,r={},l=Object.keys(t);for(a=0;a<l.length;a++)n=l[a],e.indexOf(n)>=0||(r[n]=t[n]);return r}(t,e);if(Object.getOwnPropertySymbols){var l=Object.getOwnPropertySymbols(t);for(a=0;a<l.length;a++)n=l[a],e.indexOf(n)>=0||Object.prototype.propertyIsEnumerable.call(t,n)&&(r[n]=t[n])}return r}var d=a.createContext({}),p=function(t){var e=a.useContext(d),n=e;return t&&(n="function"==typeof t?t(e):i(i({},e),t)),n},m=function(t){var e=p(t.components);return a.createElement(d.Provider,{value:e},t.children)},s={inlineCode:"code",wrapper:function(t){var e=t.children;return a.createElement(a.Fragment,{},e)}},u=a.forwardRef((function(t,e){var n=t.components,r=t.mdxType,l=t.originalType,d=t.parentName,m=o(t,["components","mdxType","originalType","parentName"]),u=p(n),c=r,g=u["".concat(d,".").concat(c)]||u[c]||s[c]||l;return n?a.createElement(g,i(i({ref:e},m),{},{components:n})):a.createElement(g,i({ref:e},m))}));function c(t,e){var n=arguments,r=e&&e.mdxType;if("string"==typeof t||r){var l=n.length,i=new Array(l);i[0]=u;var o={};for(var d in e)hasOwnProperty.call(e,d)&&(o[d]=e[d]);o.originalType=t,o.mdxType="string"==typeof t?t:r,i[1]=o;for(var p=2;p<l;p++)i[p]=n[p];return a.createElement.apply(null,i)}return a.createElement.apply(null,n)}u.displayName="MDXCreateElement"},337:function(t,e,n){n.r(e),n.d(e,{assets:function(){return m},contentTitle:function(){return d},default:function(){return c},frontMatter:function(){return o},metadata:function(){return p},toc:function(){return s}});var a=n(7896),r=n(1461),l=(n(2784),n(876)),i=["components"],o={title:"How to add setting panel",sidebar_position:6},d=void 0,p={unversionedId:"en/Questions/How_to_add_setting_panel",id:"en/Questions/How_to_add_setting_panel",title:"How to add setting panel",description:"Add selector list",source:"@site/docs/en/Questions/How_to_add_setting_panel.mdx",sourceDirName:"en/Questions",slug:"/en/Questions/How_to_add_setting_panel",permalink:"/document/en/Questions/How_to_add_setting_panel",draft:!1,tags:[],version:"current",sidebarPosition:6,frontMatter:{title:"How to add setting panel",sidebar_position:6},sidebar:"en",previous:{title:"How to import types",permalink:"/document/en/Questions/How_to_import_types"},next:{title:"Use with React Portal",permalink:"/document/en/Questions/Use_with_react_portal"}},m={},s=[{value:"Add selector list",id:"add-selector-list",level:2},{value:"Add switch button",id:"add-switch-button",level:2},{value:"Add range slider",id:"add-range-slider",level:2}],u={toc:s};function c(t){var e=t.components,n=(0,r.Z)(t,i);return(0,l.kt)("wrapper",(0,a.Z)({},u,n,{components:e,mdxType:"MDXLayout"}),(0,l.kt)("h2",{id:"add-selector-list"},"Add selector list"),(0,l.kt)("p",null,"Settings panels are similar to a collection of list selections, and support multi-layer nested"),(0,l.kt)("table",null,(0,l.kt)("thead",{parentName:"table"},(0,l.kt)("tr",{parentName:"thead"},(0,l.kt)("th",{parentName:"tr",align:null},"Property"),(0,l.kt)("th",{parentName:"tr",align:null},"Type"),(0,l.kt)("th",{parentName:"tr",align:null},"Description"))),(0,l.kt)("tbody",{parentName:"table"},(0,l.kt)("tr",{parentName:"tbody"},(0,l.kt)("td",{parentName:"tr",align:null},(0,l.kt)("inlineCode",{parentName:"td"},"html")),(0,l.kt)("td",{parentName:"tr",align:null},(0,l.kt)("inlineCode",{parentName:"td"},"String"),"\u3001",(0,l.kt)("inlineCode",{parentName:"td"},"Element")),(0,l.kt)("td",{parentName:"tr",align:null},"DOM elements of selector")),(0,l.kt)("tr",{parentName:"tbody"},(0,l.kt)("td",{parentName:"tr",align:null},(0,l.kt)("inlineCode",{parentName:"td"},"icon")),(0,l.kt)("td",{parentName:"tr",align:null},(0,l.kt)("inlineCode",{parentName:"td"},"String"),"\u3001",(0,l.kt)("inlineCode",{parentName:"td"},"Element")),(0,l.kt)("td",{parentName:"tr",align:null},"Icon of selector")),(0,l.kt)("tr",{parentName:"tbody"},(0,l.kt)("td",{parentName:"tr",align:null},(0,l.kt)("inlineCode",{parentName:"td"},"selector")),(0,l.kt)("td",{parentName:"tr",align:null},(0,l.kt)("inlineCode",{parentName:"td"},"Array")),(0,l.kt)(Line truncated
@@ -1 +0,0 @@
"use strict";(self.webpackChunkartplayer_document=self.webpackChunkartplayer_document||[]).push([[280],{3905:function(t,e,n){n.d(e,{Zo:function(){return m},kt:function(){return c}});var a=n(7294);function r(t,e,n){return e in t?Object.defineProperty(t,e,{value:n,enumerable:!0,configurable:!0,writable:!0}):t[e]=n,t}function l(t,e){var n=Object.keys(t);if(Object.getOwnPropertySymbols){var a=Object.getOwnPropertySymbols(t);e&&(a=a.filter((function(e){return Object.getOwnPropertyDescriptor(t,e).enumerable}))),n.push.apply(n,a)}return n}function i(t){for(var e=1;e<arguments.length;e++){var n=null!=arguments[e]?arguments[e]:{};e%2?l(Object(n),!0).forEach((function(e){r(t,e,n[e])})):Object.getOwnPropertyDescriptors?Object.defineProperties(t,Object.getOwnPropertyDescriptors(n)):l(Object(n)).forEach((function(e){Object.defineProperty(t,e,Object.getOwnPropertyDescriptor(n,e))}))}return t}function o(t,e){if(null==t)return{};var n,a,r=function(t,e){if(null==t)return{};var n,a,r={},l=Object.keys(t);for(a=0;a<l.length;a++)n=l[a],e.indexOf(n)>=0||(r[n]=t[n]);return r}(t,e);if(Object.getOwnPropertySymbols){var l=Object.getOwnPropertySymbols(t);for(a=0;a<l.length;a++)n=l[a],e.indexOf(n)>=0||Object.prototype.propertyIsEnumerable.call(t,n)&&(r[n]=t[n])}return r}var d=a.createContext({}),p=function(t){var e=a.useContext(d),n=e;return t&&(n="function"==typeof t?t(e):i(i({},e),t)),n},m=function(t){var e=p(t.components);return a.createElement(d.Provider,{value:e},t.children)},s={inlineCode:"code",wrapper:function(t){var e=t.children;return a.createElement(a.Fragment,{},e)}},u=a.forwardRef((function(t,e){var n=t.components,r=t.mdxType,l=t.originalType,d=t.parentName,m=o(t,["components","mdxType","originalType","parentName"]),u=p(n),c=r,g=u["".concat(d,".").concat(c)]||u[c]||s[c]||l;return n?a.createElement(g,i(i({ref:e},m),{},{components:n})):a.createElement(g,i({ref:e},m))}));function c(t,e){var n=arguments,r=e&&e.mdxType;if("string"==typeof t||r){var l=n.length,i=new Array(l);i[0]=u;var o={};for(var d in e)hasOwnProperty.call(e,d)&&(o[d]=e[d]);o.originalType=t,o.mdxType="string"==typeof t?t:r,i[1]=o;for(var p=2;p<l;p++)i[p]=n[p];return a.createElement.apply(null,i)}return a.createElement.apply(null,n)}u.displayName="MDXCreateElement"},3797:function(t,e,n){n.r(e),n.d(e,{assets:function(){return m},contentTitle:function(){return d},default:function(){return c},frontMatter:function(){return o},metadata:function(){return p},toc:function(){return s}});var a=n(7462),r=n(3366),l=(n(7294),n(3905)),i=["components"],o={title:"How to add setting panel",sidebar_position:6},d=void 0,p={unversionedId:"en/Questions/How_to_add_setting_panel",id:"en/Questions/How_to_add_setting_panel",title:"How to add setting panel",description:"Add selector list",source:"@site/docs/en/Questions/How_to_add_setting_panel.mdx",sourceDirName:"en/Questions",slug:"/en/Questions/How_to_add_setting_panel",permalink:"/document/en/Questions/How_to_add_setting_panel",draft:!1,tags:[],version:"current",sidebarPosition:6,frontMatter:{title:"How to add setting panel",sidebar_position:6},sidebar:"en",previous:{title:"How to add video ads",permalink:"/document/en/Questions/How_to_add_video_ads"},next:{title:"Use with React Portal",permalink:"/document/en/Questions/Use_with_react_portal"}},m={},s=[{value:"Add selector list",id:"add-selector-list",level:2},{value:"Add switch button",id:"add-switch-button",level:2},{value:"Add range slider",id:"add-range-slider",level:2}],u={toc:s};function c(t){var e=t.components,n=(0,r.Z)(t,i);return(0,l.kt)("wrapper",(0,a.Z)({},u,n,{components:e,mdxType:"MDXLayout"}),(0,l.kt)("h2",{id:"add-selector-list"},"Add selector list"),(0,l.kt)("p",null,"Settings panels are similar to a collection of list selections, and support multi-layer nested"),(0,l.kt)("table",null,(0,l.kt)("thead",{parentName:"table"},(0,l.kt)("tr",{parentName:"thead"},(0,l.kt)("th",{parentName:"tr",align:null},"Property"),(0,l.kt)("th",{parentName:"tr",align:null},"Type"),(0,l.kt)("th",{parentName:"tr",align:null},"Description"))),(0,l.kt)("tbody",{parentName:"table"},(0,l.kt)("tr",{parentName:"tbody"},(0,l.kt)("td",{parentName:"tr",align:null},(0,l.kt)("inlineCode",{parentName:"td"},"html")),(0,l.kt)("td",{parentName:"tr",align:null},(0,l.kt)("inlineCode",{parentName:"td"},"String"),"\u3001",(0,l.kt)("inlineCode",{parentName:"td"},"Element")),(0,l.kt)("td",{parentName:"tr",align:null},"DOM elements of selector")),(0,l.kt)("tr",{parentName:"tbody"},(0,l.kt)("td",{parentName:"tr",align:null},(0,l.kt)("inlineCode",{parentName:"td"},"icon")),(0,l.kt)("td",{parentName:"tr",align:null},(0,l.kt)("inlineCode",{parentName:"td"},"String"),"\u3001",(0,l.kt)("inlineCode",{parentName:"td"},"Element")),(0,l.kt)("td",{parentName:"tr",align:null},"Icon of selector")),(0,l.kt)("tr",{parentName:"tbody"},(0,l.kt)("td",{parentName:"tr",align:null},(0,l.kt)("inlineCode",{parentName:"td"},"selector")),(0,l.kt)("td",{parentName:"tr",align:null},(0,l.kt)("inlineCode",{parentName:"td"},"Array")),(0,lLine truncated
@@ -1 +0,0 @@
"use strict";(self.webpackChunkartplayer_document=self.webpackChunkartplayer_document||[]).push([[250],{3905:function(e,t,n){n.d(t,{Zo:function(){return u},kt:function(){return s}});var a=n(7294);function l(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function r(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var a=Object.getOwnPropertySymbols(e);t&&(a=a.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,a)}return n}function i(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?r(Object(n),!0).forEach((function(t){l(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):r(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}function p(e,t){if(null==e)return{};var n,a,l=function(e,t){if(null==e)return{};var n,a,l={},r=Object.keys(e);for(a=0;a<r.length;a++)n=r[a],t.indexOf(n)>=0||(l[n]=e[n]);return l}(e,t);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);for(a=0;a<r.length;a++)n=r[a],t.indexOf(n)>=0||Object.prototype.propertyIsEnumerable.call(e,n)&&(l[n]=e[n])}return l}var o=a.createContext({}),d=function(e){var t=a.useContext(o),n=t;return e&&(n="function"==typeof e?e(t):i(i({},t),e)),n},u=function(e){var t=d(e.components);return a.createElement(o.Provider,{value:t},e.children)},m={inlineCode:"code",wrapper:function(e){var t=e.children;return a.createElement(a.Fragment,{},t)}},k=a.forwardRef((function(e,t){var n=e.components,l=e.mdxType,r=e.originalType,o=e.parentName,u=p(e,["components","mdxType","originalType","parentName"]),k=d(n),s=l,N=k["".concat(o,".").concat(s)]||k[s]||m[s]||r;return n?a.createElement(N,i(i({ref:t},u),{},{components:n})):a.createElement(N,i({ref:t},u))}));function s(e,t){var n=arguments,l=t&&t.mdxType;if("string"==typeof e||l){var r=n.length,i=new Array(r);i[0]=k;var p={};for(var o in t)hasOwnProperty.call(t,o)&&(p[o]=t[o]);p.originalType=e,p.mdxType="string"==typeof e?e:l,i[1]=p;for(var d=2;d<r;d++)i[d]=n[d];return a.createElement.apply(null,i)}return a.createElement.apply(null,n)}k.displayName="MDXCreateElement"},4863:function(e,t,n){n.r(t),n.d(t,{assets:function(){return u},contentTitle:function(){return o},default:function(){return s},frontMatter:function(){return p},metadata:function(){return d},toc:function(){return m}});var a=n(7462),l=n(3366),r=(n(7294),n(3905)),i=["components"],p={title:"\u9ad8\u7ea7\u5c5e\u6027",sidebar_position:4,slug:"/zh-cn/advance"},o=void 0,d={unversionedId:"zh-cn/Advance",id:"zh-cn/Advance",title:"\u9ad8\u7ea7\u5c5e\u6027",description:"\u8fd9\u9875\u9762\u662f\u5bf9\u5e38\u7528\u5c5e\u6027\u7684\u4e00\u4e9b\u989d\u5916\u8865\u5145\uff0c\u9700\u8981\u6df1\u5165\u5f00\u53d1\u81ea\u5b9a\u4e49\u529f\u80fd\u65f6\u624d\u9700\u8981\u9605\u8bfb",source:"@site/docs/zh-cn/Advance.mdx",sourceDirName:"zh-cn",slug:"/zh-cn/advance",permalink:"/document/zh-cn/advance",draft:!1,tags:[],version:"current",sidebarPosition:4,frontMatter:{title:"\u9ad8\u7ea7\u5c5e\u6027",sidebar_position:4,slug:"/zh-cn/advance"},sidebar:"zh-cn",previous:{title:"\u5e38\u7528\u5c5e\u6027",permalink:"/document/zh-cn/propertie"},next:{title:"\u9759\u6001\u5c5e\u6027",permalink:"/document/zh-cn/class"}},u={},m=[{value:"id",id:"id",level:2},{value:"option",id:"option",level:2},{value:"isFocus",id:"isfocus",level:2},{value:"isInput",id:"isinput",level:2},{value:"isLock",id:"islock",level:2},{value:"isDestroy",id:"isdestroy",level:2},{value:"whitelist",id:"whitelist",level:2},{value:"template",id:"template",level:2},{value:"query",id:"query",level:3},{value:"query",id:"query-1",level:2},{value:"events",id:"events",level:2},{value:"proxy",id:"proxy",level:2},{value:"storage",id:"storage",level:2},{value:"icons",id:"icons",level:2},{value:"i18n",id:"i18n",level:2},{value:"get",id:"get",level:3},{value:"update",id:"update",level:3},{value:"player",id:"player",level:2},{value:"subtitle",id:"subtitle",level:2},{value:"show",id:"show",level:3},{value:"style",id:"style",level:3},{value:"url",id:"url",level:3},{value:"switch",id:"switch",level:3},{value:"info",id:"info",level:2},{value:"layers",id:"layers",level:2},{value:"show",id:"show-1",level:3},{value:"add",id:"add",level:3},{value:"notice",id:"notice",level:2},{value:"show",id:"show-2",level:3},{value:"controls",id:"controls",level:2},{value:"show",id:"show-3",level:3},{value:"add",id:"add-1",level:3},{value:"contextmenu",id:"contextmenu",level:2},{value:"show",id:"show-4",level:3},{value:"add",id:"add-2",level:3},{value:"loading",id:"loading",level:2},{value:"show",id:"show-5",level:3},{value:"mask",id:"mask",level:2},{value:"show",id:"show-6",level:3},{value:"hotkey",id:"hotkey",level:2},{value:"add",id:"add-3",level:3},{value:"setting",id:"setting",level:2},{value:"show",id:"show-7",level:3},{value:"plugins",id:"plugins",level:2},{value:"add",id:"add-4",level:3}],k={tocLine truncated
@@ -0,0 +1 @@
"use strict";(self.webpackChunkartplayer_document=self.webpackChunkartplayer_document||[]).push([[250],{876:function(e,t,n){n.d(t,{Zo:function(){return u},kt:function(){return s}});var a=n(2784);function l(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function r(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var a=Object.getOwnPropertySymbols(e);t&&(a=a.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,a)}return n}function i(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?r(Object(n),!0).forEach((function(t){l(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):r(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}function p(e,t){if(null==e)return{};var n,a,l=function(e,t){if(null==e)return{};var n,a,l={},r=Object.keys(e);for(a=0;a<r.length;a++)n=r[a],t.indexOf(n)>=0||(l[n]=e[n]);return l}(e,t);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);for(a=0;a<r.length;a++)n=r[a],t.indexOf(n)>=0||Object.prototype.propertyIsEnumerable.call(e,n)&&(l[n]=e[n])}return l}var o=a.createContext({}),d=function(e){var t=a.useContext(o),n=t;return e&&(n="function"==typeof e?e(t):i(i({},t),e)),n},u=function(e){var t=d(e.components);return a.createElement(o.Provider,{value:t},e.children)},m={inlineCode:"code",wrapper:function(e){var t=e.children;return a.createElement(a.Fragment,{},t)}},k=a.forwardRef((function(e,t){var n=e.components,l=e.mdxType,r=e.originalType,o=e.parentName,u=p(e,["components","mdxType","originalType","parentName"]),k=d(n),s=l,N=k["".concat(o,".").concat(s)]||k[s]||m[s]||r;return n?a.createElement(N,i(i({ref:t},u),{},{components:n})):a.createElement(N,i({ref:t},u))}));function s(e,t){var n=arguments,l=t&&t.mdxType;if("string"==typeof e||l){var r=n.length,i=new Array(r);i[0]=k;var p={};for(var o in t)hasOwnProperty.call(t,o)&&(p[o]=t[o]);p.originalType=e,p.mdxType="string"==typeof e?e:l,i[1]=p;for(var d=2;d<r;d++)i[d]=n[d];return a.createElement.apply(null,i)}return a.createElement.apply(null,n)}k.displayName="MDXCreateElement"},1431:function(e,t,n){n.r(t),n.d(t,{assets:function(){return u},contentTitle:function(){return o},default:function(){return s},frontMatter:function(){return p},metadata:function(){return d},toc:function(){return m}});var a=n(7896),l=n(1461),r=(n(2784),n(876)),i=["components"],p={title:"\u9ad8\u7ea7\u5c5e\u6027",sidebar_position:4,slug:"/zh-cn/advance"},o=void 0,d={unversionedId:"zh-cn/Advance",id:"zh-cn/Advance",title:"\u9ad8\u7ea7\u5c5e\u6027",description:"\u8fd9\u9875\u9762\u662f\u5bf9\u5e38\u7528\u5c5e\u6027\u7684\u4e00\u4e9b\u989d\u5916\u8865\u5145\uff0c\u9700\u8981\u6df1\u5165\u5f00\u53d1\u81ea\u5b9a\u4e49\u529f\u80fd\u65f6\u624d\u9700\u8981\u9605\u8bfb",source:"@site/docs/zh-cn/Advance.mdx",sourceDirName:"zh-cn",slug:"/zh-cn/advance",permalink:"/document/zh-cn/advance",draft:!1,tags:[],version:"current",sidebarPosition:4,frontMatter:{title:"\u9ad8\u7ea7\u5c5e\u6027",sidebar_position:4,slug:"/zh-cn/advance"},sidebar:"zh-cn",previous:{title:"\u5e38\u7528\u5c5e\u6027",permalink:"/document/zh-cn/propertie"},next:{title:"\u9759\u6001\u5c5e\u6027",permalink:"/document/zh-cn/class"}},u={},m=[{value:"id",id:"id",level:2},{value:"option",id:"option",level:2},{value:"isFocus",id:"isfocus",level:2},{value:"isInput",id:"isinput",level:2},{value:"isLock",id:"islock",level:2},{value:"isDestroy",id:"isdestroy",level:2},{value:"whitelist",id:"whitelist",level:2},{value:"template",id:"template",level:2},{value:"query",id:"query",level:3},{value:"query",id:"query-1",level:2},{value:"events",id:"events",level:2},{value:"proxy",id:"proxy",level:2},{value:"storage",id:"storage",level:2},{value:"icons",id:"icons",level:2},{value:"i18n",id:"i18n",level:2},{value:"get",id:"get",level:3},{value:"update",id:"update",level:3},{value:"player",id:"player",level:2},{value:"subtitle",id:"subtitle",level:2},{value:"show",id:"show",level:3},{value:"style",id:"style",level:3},{value:"url",id:"url",level:3},{value:"switch",id:"switch",level:3},{value:"info",id:"info",level:2},{value:"layers",id:"layers",level:2},{value:"show",id:"show-1",level:3},{value:"add",id:"add",level:3},{value:"notice",id:"notice",level:2},{value:"show",id:"show-2",level:3},{value:"controls",id:"controls",level:2},{value:"show",id:"show-3",level:3},{value:"add",id:"add-1",level:3},{value:"contextmenu",id:"contextmenu",level:2},{value:"show",id:"show-4",level:3},{value:"add",id:"add-2",level:3},{value:"loading",id:"loading",level:2},{value:"show",id:"show-5",level:3},{value:"mask",id:"mask",level:2},{value:"show",id:"show-6",level:3},{value:"hotkey",id:"hotkey",level:2},{value:"add",id:"add-3",level:3},{value:"setting",id:"setting",level:2},{value:"show",id:"show-7",level:3},{value:"plugins",id:"plugins",level:2},{value:"add",id:"add-4",level:3}],k={toc:mLine truncated
-1
View File
@@ -1 +0,0 @@
"use strict";(self.webpackChunkartplayer_document=self.webpackChunkartplayer_document||[]).push([[343],{3343:function(e,t,u){u.r(t)}}]);
@@ -1 +0,0 @@
"use strict";(self.webpackChunkartplayer_document=self.webpackChunkartplayer_document||[]).push([[78],{3905:function(n,e,t){t.d(e,{Zo:function(){return s},kt:function(){return c}});var a=t(7294);function r(n,e,t){return e in n?Object.defineProperty(n,e,{value:t,enumerable:!0,configurable:!0,writable:!0}):n[e]=t,n}function l(n,e){var t=Object.keys(n);if(Object.getOwnPropertySymbols){var a=Object.getOwnPropertySymbols(n);e&&(a=a.filter((function(e){return Object.getOwnPropertyDescriptor(n,e).enumerable}))),t.push.apply(t,a)}return t}function u(n){for(var e=1;e<arguments.length;e++){var t=null!=arguments[e]?arguments[e]:{};e%2?l(Object(t),!0).forEach((function(e){r(n,e,t[e])})):Object.getOwnPropertyDescriptors?Object.defineProperties(n,Object.getOwnPropertyDescriptors(t)):l(Object(t)).forEach((function(e){Object.defineProperty(n,e,Object.getOwnPropertyDescriptor(t,e))}))}return n}function i(n,e){if(null==n)return{};var t,a,r=function(n,e){if(null==n)return{};var t,a,r={},l=Object.keys(n);for(a=0;a<l.length;a++)t=l[a],e.indexOf(t)>=0||(r[t]=n[t]);return r}(n,e);if(Object.getOwnPropertySymbols){var l=Object.getOwnPropertySymbols(n);for(a=0;a<l.length;a++)t=l[a],e.indexOf(t)>=0||Object.prototype.propertyIsEnumerable.call(n,t)&&(r[t]=n[t])}return r}var o=a.createContext({}),p=function(n){var e=a.useContext(o),t=e;return n&&(t="function"==typeof n?n(e):u(u({},e),n)),t},s=function(n){var e=p(n.components);return a.createElement(o.Provider,{value:e},n.children)},m={inlineCode:"code",wrapper:function(n){var e=n.children;return a.createElement(a.Fragment,{},e)}},d=a.forwardRef((function(n,e){var t=n.components,r=n.mdxType,l=n.originalType,o=n.parentName,s=i(n,["components","mdxType","originalType","parentName"]),d=p(t),c=r,k=d["".concat(o,".").concat(c)]||d[c]||m[c]||l;return t?a.createElement(k,u(u({ref:e},s),{},{components:t})):a.createElement(k,u({ref:e},s))}));function c(n,e){var t=arguments,r=e&&e.mdxType;if("string"==typeof n||r){var l=t.length,u=new Array(l);u[0]=d;var i={};for(var o in e)hasOwnProperty.call(e,o)&&(i[o]=e[o]);i.originalType=n,i.mdxType="string"==typeof n?n:r,u[1]=i;for(var p=2;p<l;p++)u[p]=t[p];return a.createElement.apply(null,u)}return a.createElement.apply(null,t)}d.displayName="MDXCreateElement"},9489:function(n,e,t){t.r(e),t.d(e,{assets:function(){return s},contentTitle:function(){return o},default:function(){return c},frontMatter:function(){return i},metadata:function(){return p},toc:function(){return m}});var a=t(7462),r=t(3366),l=(t(7294),t(3905)),u=["components"],i={title:"\u5f39\u5e55\u5e93\u63d2\u4ef6",sidebar_position:1},o=void 0,p={unversionedId:"zh-cn/Plugins/danmuku",id:"zh-cn/Plugins/danmuku",title:"\u5f39\u5e55\u5e93\u63d2\u4ef6",description:"\u6f14\u793a",source:"@site/docs/zh-cn/Plugins/danmuku.mdx",sourceDirName:"zh-cn/Plugins",slug:"/zh-cn/Plugins/danmuku",permalink:"/document/zh-cn/Plugins/danmuku",draft:!1,tags:[],version:"current",sidebarPosition:1,frontMatter:{title:"\u5f39\u5e55\u5e93\u63d2\u4ef6",sidebar_position:1},sidebar:"zh-cn",previous:{title:"\u7b2c\u4e09\u65b9\u5e93",permalink:"/document/zh-cn/libraries"},next:{title:"\u5728\u63a7\u5236\u680f\u6dfb\u52a0\u5217\u8868",permalink:"/document/zh-cn/Questions/Create_selector_in_the_controls"}},s={},m=[{value:"\u6f14\u793a",id:"\u6f14\u793a",level:2},{value:"\u5b89\u88c5",id:"\u5b89\u88c5",level:2},{value:"\u901a\u8fc7 <code>npm</code> \u5b89\u88c5\uff1a",id:"\u901a\u8fc7-npm-\u5b89\u88c5",level:3},{value:"\u901a\u8fc7 <code>yarn</code> \u5b89\u88c5\uff1a",id:"\u901a\u8fc7-yarn-\u5b89\u88c5",level:3},{value:"\u901a\u8fc7 <code>script</code> \u5b89\u88c5\uff1a",id:"\u901a\u8fc7-script-\u5b89\u88c5",level:3},{value:"\u4f7f\u7528",id:"\u4f7f\u7528",level:2},{value:"\u4f7f\u7528\u5f39\u5e55\u6570\u7ec4",id:"\u4f7f\u7528\u5f39\u5e55\u6570\u7ec4",level:3},{value:"\u4f7f\u7528\u5f39\u5e55 XML",id:"\u4f7f\u7528\u5f39\u5e55-xml",level:3},{value:"\u4f7f\u7528\u5f02\u6b65\u8c03\u7528",id:"\u4f7f\u7528\u5f02\u6b65\u8c03\u7528",level:3},{value:"\u63a5\u53e3",id:"\u63a5\u53e3",level:2},{value:"hide/show",id:"hideshow",level:3},{value:"isHide",id:"ishide",level:3},{value:"emit",id:"emit",level:3},{value:"config",id:"config",level:3},{value:"load",id:"load",level:3},{value:"\u4e8b\u4ef6",id:"\u4e8b\u4ef6",level:2}],d={toc:m};function c(n){var e=n.components,t=(0,r.Z)(n,u);return(0,l.kt)("wrapper",(0,a.Z)({},d,t,{components:e,mdxType:"MDXLayout"}),(0,l.kt)("h2",{id:"\u6f14\u793a"},"\u6f14\u793a"),(0,l.kt)("p",null,"\ud83d\udc49 ",(0,l.kt)("a",{parentName:"p",href:"https://artplayer.org/?libs=./uncompiled/artplayer-plugin-danmuku/index.js&example=danmuku"},"\u67e5\u770b\u5b8c\u6574\u6f14\u793a")),(0,l.kt)("h2",{id:"\u5b89\u88c5"},"\u5b89\u88c5"),(0,l.kt)("h3",{id:"\u901a\u8fc7-npm-\u5b89\u88c5"},"\u901a\u8fc7 ",(0,l.kt)("inlineCode",{parentName:"h3"},"npm")," \u5b89\u88c5\uff1a"),(0,l.kt)("pre",null,(0,l.kt)("code",{parentName:"pre",className:"language-bash"},"$ npm install artplayer-plugin-danmuku\n")),(0,l.kt)("h3",{id:"\u901a\u8fc7-Line truncated
@@ -0,0 +1 @@
"use strict";(self.webpackChunkartplayer_document=self.webpackChunkartplayer_document||[]).push([[78],{876:function(n,e,t){t.d(e,{Zo:function(){return s},kt:function(){return c}});var a=t(2784);function r(n,e,t){return e in n?Object.defineProperty(n,e,{value:t,enumerable:!0,configurable:!0,writable:!0}):n[e]=t,n}function l(n,e){var t=Object.keys(n);if(Object.getOwnPropertySymbols){var a=Object.getOwnPropertySymbols(n);e&&(a=a.filter((function(e){return Object.getOwnPropertyDescriptor(n,e).enumerable}))),t.push.apply(t,a)}return t}function u(n){for(var e=1;e<arguments.length;e++){var t=null!=arguments[e]?arguments[e]:{};e%2?l(Object(t),!0).forEach((function(e){r(n,e,t[e])})):Object.getOwnPropertyDescriptors?Object.defineProperties(n,Object.getOwnPropertyDescriptors(t)):l(Object(t)).forEach((function(e){Object.defineProperty(n,e,Object.getOwnPropertyDescriptor(t,e))}))}return n}function i(n,e){if(null==n)return{};var t,a,r=function(n,e){if(null==n)return{};var t,a,r={},l=Object.keys(n);for(a=0;a<l.length;a++)t=l[a],e.indexOf(t)>=0||(r[t]=n[t]);return r}(n,e);if(Object.getOwnPropertySymbols){var l=Object.getOwnPropertySymbols(n);for(a=0;a<l.length;a++)t=l[a],e.indexOf(t)>=0||Object.prototype.propertyIsEnumerable.call(n,t)&&(r[t]=n[t])}return r}var o=a.createContext({}),p=function(n){var e=a.useContext(o),t=e;return n&&(t="function"==typeof n?n(e):u(u({},e),n)),t},s=function(n){var e=p(n.components);return a.createElement(o.Provider,{value:e},n.children)},m={inlineCode:"code",wrapper:function(n){var e=n.children;return a.createElement(a.Fragment,{},e)}},d=a.forwardRef((function(n,e){var t=n.components,r=n.mdxType,l=n.originalType,o=n.parentName,s=i(n,["components","mdxType","originalType","parentName"]),d=p(t),c=r,k=d["".concat(o,".").concat(c)]||d[c]||m[c]||l;return t?a.createElement(k,u(u({ref:e},s),{},{components:t})):a.createElement(k,u({ref:e},s))}));function c(n,e){var t=arguments,r=e&&e.mdxType;if("string"==typeof n||r){var l=t.length,u=new Array(l);u[0]=d;var i={};for(var o in e)hasOwnProperty.call(e,o)&&(i[o]=e[o]);i.originalType=n,i.mdxType="string"==typeof n?n:r,u[1]=i;for(var p=2;p<l;p++)u[p]=t[p];return a.createElement.apply(null,u)}return a.createElement.apply(null,t)}d.displayName="MDXCreateElement"},9942:function(n,e,t){t.r(e),t.d(e,{assets:function(){return s},contentTitle:function(){return o},default:function(){return c},frontMatter:function(){return i},metadata:function(){return p},toc:function(){return m}});var a=t(7896),r=t(1461),l=(t(2784),t(876)),u=["components"],i={title:"\u5f39\u5e55\u5e93\u63d2\u4ef6",sidebar_position:1},o=void 0,p={unversionedId:"zh-cn/Plugins/danmuku",id:"zh-cn/Plugins/danmuku",title:"\u5f39\u5e55\u5e93\u63d2\u4ef6",description:"\u6f14\u793a",source:"@site/docs/zh-cn/Plugins/danmuku.mdx",sourceDirName:"zh-cn/Plugins",slug:"/zh-cn/Plugins/danmuku",permalink:"/document/zh-cn/Plugins/danmuku",draft:!1,tags:[],version:"current",sidebarPosition:1,frontMatter:{title:"\u5f39\u5e55\u5e93\u63d2\u4ef6",sidebar_position:1},sidebar:"zh-cn",previous:{title:"\u7b2c\u4e09\u65b9\u5e93",permalink:"/document/zh-cn/libraries"},next:{title:"\u5e7f\u544a\u63d2\u4ef6",permalink:"/document/zh-cn/Plugins/ads"}},s={},m=[{value:"\u6f14\u793a",id:"\u6f14\u793a",level:2},{value:"\u5b89\u88c5",id:"\u5b89\u88c5",level:2},{value:"\u901a\u8fc7 <code>npm</code> \u5b89\u88c5\uff1a",id:"\u901a\u8fc7-npm-\u5b89\u88c5",level:3},{value:"\u901a\u8fc7 <code>yarn</code> \u5b89\u88c5\uff1a",id:"\u901a\u8fc7-yarn-\u5b89\u88c5",level:3},{value:"\u901a\u8fc7 <code>script</code> \u5b89\u88c5\uff1a",id:"\u901a\u8fc7-script-\u5b89\u88c5",level:3},{value:"\u4f7f\u7528",id:"\u4f7f\u7528",level:2},{value:"\u4f7f\u7528\u5f39\u5e55\u6570\u7ec4",id:"\u4f7f\u7528\u5f39\u5e55\u6570\u7ec4",level:3},{value:"\u4f7f\u7528\u5f39\u5e55 XML",id:"\u4f7f\u7528\u5f39\u5e55-xml",level:3},{value:"\u4f7f\u7528\u5f02\u6b65\u8c03\u7528",id:"\u4f7f\u7528\u5f02\u6b65\u8c03\u7528",level:3},{value:"\u63a5\u53e3",id:"\u63a5\u53e3",level:2},{value:"hide/show",id:"hideshow",level:3},{value:"isHide",id:"ishide",level:3},{value:"emit",id:"emit",level:3},{value:"config",id:"config",level:3},{value:"load",id:"load",level:3},{value:"\u4e8b\u4ef6",id:"\u4e8b\u4ef6",level:2}],d={toc:m};function c(n){var e=n.components,t=(0,r.Z)(n,u);return(0,l.kt)("wrapper",(0,a.Z)({},d,t,{components:e,mdxType:"MDXLayout"}),(0,l.kt)("h2",{id:"\u6f14\u793a"},"\u6f14\u793a"),(0,l.kt)("p",null,"\ud83d\udc49 ",(0,l.kt)("a",{parentName:"p",href:"https://artplayer.org/?libs=./uncompiled/artplayer-plugin-danmuku/index.js&example=danmuku"},"\u67e5\u770b\u5b8c\u6574\u6f14\u793a")),(0,l.kt)("h2",{id:"\u5b89\u88c5"},"\u5b89\u88c5"),(0,l.kt)("h3",{id:"\u901a\u8fc7-npm-\u5b89\u88c5"},"\u901a\u8fc7 ",(0,l.kt)("inlineCode",{parentName:"h3"},"npm")," \u5b89\u88c5\uff1a"),(0,l.kt)("pre",null,(0,l.kt)("code",{parentName:"pre",className:"language-bash"},"$ npm install artplayer-plugin-danmuku\n")),(0,l.kt)("h3",{id:"\u901a\u8fc7-yarn-\u5b89\u88c5"},"\u901a\u8fc7 ",(0,l.kt)("inlineCodeLine truncated
@@ -1 +0,0 @@
"use strict";(self.webpackChunkartplayer_document=self.webpackChunkartplayer_document||[]).push([[610],{3905:function(e,t,n){n.d(t,{Zo:function(){return u},kt:function(){return d}});var r=n(7294);function a(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function l(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,r)}return n}function s(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?l(Object(n),!0).forEach((function(t){a(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):l(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}function i(e,t){if(null==e)return{};var n,r,a=function(e,t){if(null==e)return{};var n,r,a={},l=Object.keys(e);for(r=0;r<l.length;r++)n=l[r],t.indexOf(n)>=0||(a[n]=e[n]);return a}(e,t);if(Object.getOwnPropertySymbols){var l=Object.getOwnPropertySymbols(e);for(r=0;r<l.length;r++)n=l[r],t.indexOf(n)>=0||Object.prototype.propertyIsEnumerable.call(e,n)&&(a[n]=e[n])}return a}var o=r.createContext({}),p=function(e){var t=r.useContext(o),n=t;return e&&(n="function"==typeof e?e(t):s(s({},t),e)),n},u=function(e){var t=p(e.components);return r.createElement(o.Provider,{value:t},e.children)},c={inlineCode:"code",wrapper:function(e){var t=e.children;return r.createElement(r.Fragment,{},t)}},m=r.forwardRef((function(e,t){var n=e.components,a=e.mdxType,l=e.originalType,o=e.parentName,u=i(e,["components","mdxType","originalType","parentName"]),m=p(n),d=a,h=m["".concat(o,".").concat(d)]||m[d]||c[d]||l;return n?r.createElement(h,s(s({ref:t},u),{},{components:n})):r.createElement(h,s({ref:t},u))}));function d(e,t){var n=arguments,a=t&&t.mdxType;if("string"==typeof e||a){var l=n.length,s=new Array(l);s[0]=m;var i={};for(var o in t)hasOwnProperty.call(t,o)&&(i[o]=t[o]);i.originalType=e,i.mdxType="string"==typeof e?e:a,s[1]=i;for(var p=2;p<l;p++)s[p]=n[p];return r.createElement.apply(null,s)}return r.createElement.apply(null,n)}m.displayName="MDXCreateElement"},2360:function(e,t,n){n.d(t,{Z:function(){return s}});var r=n(7294),a=n(6010),l="tabItem_OmH5";function s(e){var t=e.children,n=e.hidden,s=e.className;return r.createElement("div",{role:"tabpanel",className:(0,a.Z)(l,s),hidden:n},t)}},9877:function(e,t,n){n.d(t,{Z:function(){return d}});var r=n(7462),a=n(7294),l=n(2389),s=n(7392),i=n(7094),o=n(2466),p=n(6010),u="tabList_uSqn",c="tabItem_LplD";function m(e){var t,n,l,m=e.lazy,d=e.block,h=e.defaultValue,v=e.values,y=e.groupId,f=e.className,b=a.Children.map(e.children,(function(e){if((0,a.isValidElement)(e)&&void 0!==e.props.value)return e;throw new Error("Docusaurus error: Bad <Tabs> child <"+("string"==typeof e.type?e.type:e.type.name)+'>: all children of the <Tabs> component should be <TabItem>, and every <TabItem> should have a unique "value" prop.')})),g=null!=v?v:b.map((function(e){var t=e.props;return{value:t.value,label:t.label,attributes:t.attributes}})),k=(0,s.l)(g,(function(e,t){return e.value===t.value}));if(k.length>0)throw new Error('Docusaurus error: Duplicate values "'+k.map((function(e){return e.value})).join(", ")+'" found in <Tabs>. Every value needs to be unique.');var N=null===h?h:null!=(t=null!=h?h:null==(n=b.find((function(e){return e.props.default})))?void 0:n.props.value)?t:null==(l=b[0])?void 0:l.props.value;if(null!==N&&!g.some((function(e){return e.value===N})))throw new Error('Docusaurus error: The <Tabs> has a defaultValue "'+N+'" but none of its children has the corresponding value. Available values are: '+g.map((function(e){return e.value})).join(", ")+". If you intend to show no default tab, use defaultValue={null} instead.");var x=(0,i.U)(),j=x.tabGroupChoices,w=x.setTabGroupChoices,T=(0,a.useState)(N),A=T[0],O=T[1],Z=[],E=(0,o.o5)().blockElementScrollPositionUntilNextRender;if(null!=y){var I=j[y];null!=I&&I!==A&&g.some((function(e){return e.value===I}))&&O(I)}var P=function(e){var t=e.currentTarget,n=Z.indexOf(t),r=g[n].value;r!==A&&(E(t),O(r),null!=y&&w(y,r))},L=function(e){var t,n=null;switch(e.key){case"ArrowRight":var r=Z.indexOf(e.currentTarget)+1;n=Z[r]||Z[0];break;case"ArrowLeft":var a=Z.indexOf(e.currentTarget)-1;n=Z[a]||Z[Z.length-1]}null==(t=n)||t.focus()};return a.createElement("div",{className:(0,p.Z)("tabs-container",u)},a.createElement("ul",{role:"tablist","aria-orientation":"horizontal",className:(0,p.Z)("tabs",{"tabs--block":d},f)},g.map((function(e){var t=e.value,n=e.label,l=e.attributes;return a.createElement("li",(0,r.Z)({role:"tab",tabIndex:A===t?0:-1,"aria-selected":A===t,key:t,ref:function(e){return Z.push(e)},onKeyDown:L,onFocus:P,onClick:P},l,{className:(0,p.Z)("tabs__item",c,null==l?void 0:l.className,{"tabs__item--active":A===t})}),null!=n?n:t)}))),m?(0,a.cloneElement)(b.filter((function(e){Line truncated
@@ -0,0 +1 @@
"use strict";(self.webpackChunkartplayer_document=self.webpackChunkartplayer_document||[]).push([[610],{876:function(e,t,n){n.d(t,{Zo:function(){return u},kt:function(){return d}});var r=n(2784);function a(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function l(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,r)}return n}function s(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?l(Object(n),!0).forEach((function(t){a(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):l(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}function i(e,t){if(null==e)return{};var n,r,a=function(e,t){if(null==e)return{};var n,r,a={},l=Object.keys(e);for(r=0;r<l.length;r++)n=l[r],t.indexOf(n)>=0||(a[n]=e[n]);return a}(e,t);if(Object.getOwnPropertySymbols){var l=Object.getOwnPropertySymbols(e);for(r=0;r<l.length;r++)n=l[r],t.indexOf(n)>=0||Object.prototype.propertyIsEnumerable.call(e,n)&&(a[n]=e[n])}return a}var o=r.createContext({}),p=function(e){var t=r.useContext(o),n=t;return e&&(n="function"==typeof e?e(t):s(s({},t),e)),n},u=function(e){var t=p(e.components);return r.createElement(o.Provider,{value:t},e.children)},c={inlineCode:"code",wrapper:function(e){var t=e.children;return r.createElement(r.Fragment,{},t)}},m=r.forwardRef((function(e,t){var n=e.components,a=e.mdxType,l=e.originalType,o=e.parentName,u=i(e,["components","mdxType","originalType","parentName"]),m=p(n),d=a,v=m["".concat(o,".").concat(d)]||m[d]||c[d]||l;return n?r.createElement(v,s(s({ref:t},u),{},{components:n})):r.createElement(v,s({ref:t},u))}));function d(e,t){var n=arguments,a=t&&t.mdxType;if("string"==typeof e||a){var l=n.length,s=new Array(l);s[0]=m;var i={};for(var o in t)hasOwnProperty.call(t,o)&&(i[o]=t[o]);i.originalType=e,i.mdxType="string"==typeof e?e:a,s[1]=i;for(var p=2;p<l;p++)s[p]=n[p];return r.createElement.apply(null,s)}return r.createElement.apply(null,n)}m.displayName="MDXCreateElement"},8294:function(e,t,n){n.d(t,{Z:function(){return s}});var r=n(2784),a=n(6277),l="tabItem_zQZC";function s(e){var t=e.children,n=e.hidden,s=e.className;return r.createElement("div",{role:"tabpanel",className:(0,a.Z)(l,s),hidden:n},t)}},7370:function(e,t,n){n.d(t,{Z:function(){return d}});var r=n(7896),a=n(2784),l=n(9741),s=n(2244),i=n(8963),o=n(4126),p=n(6277),u="tabList_vG2x",c="tabItem_yrY8";function m(e){var t,n,l,m=e.lazy,d=e.block,v=e.defaultValue,y=e.values,h=e.groupId,f=e.className,b=a.Children.map(e.children,(function(e){if((0,a.isValidElement)(e)&&void 0!==e.props.value)return e;throw new Error("Docusaurus error: Bad <Tabs> child <"+("string"==typeof e.type?e.type:e.type.name)+'>: all children of the <Tabs> component should be <TabItem>, and every <TabItem> should have a unique "value" prop.')})),g=null!=y?y:b.map((function(e){var t=e.props;return{value:t.value,label:t.label,attributes:t.attributes}})),k=(0,s.l)(g,(function(e,t){return e.value===t.value}));if(k.length>0)throw new Error('Docusaurus error: Duplicate values "'+k.map((function(e){return e.value})).join(", ")+'" found in <Tabs>. Every value needs to be unique.');var N=null===v?v:null!=(t=null!=v?v:null==(n=b.find((function(e){return e.props.default})))?void 0:n.props.value)?t:null==(l=b[0])?void 0:l.props.value;if(null!==N&&!g.some((function(e){return e.value===N})))throw new Error('Docusaurus error: The <Tabs> has a defaultValue "'+N+'" but none of its children has the corresponding value. Available values are: '+g.map((function(e){return e.value})).join(", ")+". If you intend to show no default tab, use defaultValue={null} instead.");var x=(0,i.U)(),j=x.tabGroupChoices,w=x.setTabGroupChoices,T=(0,a.useState)(N),A=T[0],O=T[1],Z=[],E=(0,o.o5)().blockElementScrollPositionUntilNextRender;if(null!=h){var I=j[h];null!=I&&I!==A&&g.some((function(e){return e.value===I}))&&O(I)}var P=function(e){var t=e.currentTarget,n=Z.indexOf(t),r=g[n].value;r!==A&&(E(t),O(r),null!=h&&w(h,r))},C=function(e){var t,n=null;switch(e.key){case"ArrowRight":var r=Z.indexOf(e.currentTarget)+1;n=Z[r]||Z[0];break;case"ArrowLeft":var a=Z.indexOf(e.currentTarget)-1;n=Z[a]||Z[Z.length-1]}null==(t=n)||t.focus()};return a.createElement("div",{className:(0,p.Z)("tabs-container",u)},a.createElement("ul",{role:"tablist","aria-orientation":"horizontal",className:(0,p.Z)("tabs",{"tabs--block":d},f)},g.map((function(e){var t=e.value,n=e.label,l=e.attributes;return a.createElement("li",(0,r.Z)({role:"tab",tabIndex:A===t?0:-1,"aria-selected":A===t,key:t,ref:function(e){return Z.push(e)},onKeyDown:C,onFocus:P,onClick:P},l,{className:(0,p.Z)("tabs__item",c,null==l?void 0:l.className,{"tabs__item--active":A===t})}),null!=n?n:t)}))),m?(0,a.cloneElement)(b.filter((function(e){rLine truncated
+1
View File
@@ -0,0 +1 @@
(self.webpackChunkartplayer_document=self.webpackChunkartplayer_document||[]).push([[4],{6553:function(e,t,n){"use strict";n.r(t),n.d(t,{default:function(){return v}});var i=n(5485),a=n.n(i),s=n(1336);s.tokenizer.separator=/[\s\-/]+/;var r=function(){function e(e,t){this.searchDocs=e,this.lunrIndex=s.Index.load(t)}var t=e.prototype;return t.getLunrResult=function(e){return this.lunrIndex.query((function(t){var n=s.tokenizer(e);t.term(n,{boost:10}),t.term(n,{wildcard:s.Query.wildcard.TRAILING})}))},t.getHit=function(e,t,n){return{hierarchy:{lvl0:e.pageTitle||e.title,lvl1:0===e.type?null:e.title},url:e.url,_snippetResult:n?{content:{value:n,matchLevel:"full"}}:null,_highlightResult:{hierarchy:{lvl0:{value:0===e.type?t||e.title:e.pageTitle},lvl1:0===e.type?null:{value:t||e.title}}}}},t.getTitleHit=function(e,t,n){var i=t[0],a=t[0]+n,s=e.title.substring(0,i)+'<span class="algolia-docsearch-suggestion--highlight">'+e.title.substring(i,a)+"</span>"+e.title.substring(a,e.title.length);return this.getHit(e,s)},t.getKeywordHit=function(e,t,n){var i=t[0],a=t[0]+n,s=e.title+"<br /><i>Keywords: "+e.keywords.substring(0,i)+'<span class="algolia-docsearch-suggestion--highlight">'+e.keywords.substring(i,a)+"</span>"+e.keywords.substring(a,e.keywords.length)+"</i>";return this.getHit(e,s)},t.getContentHit=function(e,t){for(var n=t[0],i=t[0]+t[1],a=n,s=i,r=!0,l=!0,o=0;o<3;o++){var u=e.content.lastIndexOf(" ",a-2),c=e.content.lastIndexOf(".",a-2);if(c>0&&c>u){a=c+1,r=!1;break}if(u<0){a=0,r=!1;break}a=u+1}for(var h=0;h<10;h++){var g=e.content.indexOf(" ",s+1),d=e.content.indexOf(".",s+1);if(d>0&&d<g){s=d,l=!1;break}if(g<0){s=e.content.length,l=!1;break}s=g}var p=e.content.substring(a,n);return r&&(p="... "+p),p+='<span class="algolia-docsearch-suggestion--highlight">'+e.content.substring(n,i)+"</span>",p+=e.content.substring(i,s),l&&(p+=" ..."),this.getHit(e,null,p)},t.search=function(e){var t=this;return new Promise((function(n,i){var a=t.getLunrResult(e),s=[];a.length>5&&(a.length=5),t.titleHitsRes=[],t.contentHitsRes=[],a.forEach((function(n){var i=t.searchDocs[n.ref],a=n.matchData.metadata;for(var r in a)if(a[r].title){if(!t.titleHitsRes.includes(n.ref)){var l=a[r].title.position[0];s.push(t.getTitleHit(i,l,e.length)),t.titleHitsRes.push(n.ref)}}else if(a[r].content){var o=a[r].content.position[0];s.push(t.getContentHit(i,o))}else if(a[r].keywords){var u=a[r].keywords.position[0];s.push(t.getKeywordHit(i,u,e.length)),t.titleHitsRes.push(n.ref)}})),s.length>5&&(s.length=5),n(s)}))},e}(),l=n(1639),o=n.n(l),u="algolia-docsearch",c=u+"-suggestion",h={suggestion:'\n <a class="'+c+"\n {{#isCategoryHeader}}"+c+"__main{{/isCategoryHeader}}\n {{#isSubCategoryHeader}}"+c+'__secondary{{/isSubCategoryHeader}}\n "\n aria-label="Link to the result"\n href="{{{url}}}"\n >\n <div class="'+c+'--category-header">\n <span class="'+c+'--category-header-lvl0">{{{category}}}</span>\n </div>\n <div class="'+c+'--wrapper">\n <div class="'+c+'--subcategory-column">\n <span class="'+c+'--subcategory-column-text">{{{subcategory}}}</span>\n </div>\n {{#isTextOrSubcategoryNonEmpty}}\n <div class="'+c+'--content">\n <div class="'+c+'--subcategory-inline">{{{subcategory}}}</div>\n <div class="'+c+'--title">{{{title}}}</div>\n {{#text}}<div class="'+c+'--text">{{{text}}}</div>{{/text}}\n </div>\n {{/isTextOrSubcategoryNonEmpty}}\n </div>\n </a>\n ',suggestionSimple:'\n <div class="'+c+"\n {{#isCategoryHeader}}"+c+"__main{{/isCategoryHeader}}\n {{#isSubCategoryHeader}}"+c+'__secondary{{/isSubCategoryHeader}}\n suggestion-layout-simple\n ">\n <div class="'+c+'--category-header">\n {{^isLvl0}}\n <span class="'+c+"--category-header-lvl0 "+c+'--category-header-item">{{{category}}}</span>\n {{^isLvl1}}\n {{^isLvl1EmptyOrDuplicate}}\n <span class="'+c+"--category-header-lvl1 "+c+'--category-header-item">\n {{{subcategory}}}\n </span>\n {{/isLvl1EmptyOrDuplicate}}\n {{/isLvl1}}\n {{/isLvl0}}\n <div class="'+c+"--title "+c+'--category-header-item">\n {{#isLvl2}}\n {{{title}}}\n {{/isLvl2}}\n {{#isLvl1}}\n {{{subcategory}}}\n {{/isLvl1}}\n {{#isLvl0}}\n {{{category}}}\n {{/isLvl0}}\n </div>\n </div>\n <div class="'+c+'--wrapper">\n {{#text}}\n <div class="'+c+'--content">\n <div class="'+c+'--text">{{{text}}}</div>\n </div>\n {{/text}}\n </div>\n </div>\n ',footer:'\n <div class="algolia-docsearch-footer">\n </div>\n ',empty:'\n <div class="'+c+'">\n <div class="'+c+'--wrapper">\n <div class="'+c+"--content "+c+'--no-results">\n <div class="'+c+'--title">\n <div class="'+c+'--text">\n No results found for query <b>"{{query}}"</b>\n Line truncated
@@ -0,0 +1 @@
"use strict";(self.webpackChunkartplayer_document=self.webpackChunkartplayer_document||[]).push([[778],{876:function(e,n,t){t.d(n,{Zo:function(){return c},kt:function(){return m}});var r=t(2784);function a(e,n,t){return n in e?Object.defineProperty(e,n,{value:t,enumerable:!0,configurable:!0,writable:!0}):e[n]=t,e}function l(e,n){var t=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);n&&(r=r.filter((function(n){return Object.getOwnPropertyDescriptor(e,n).enumerable}))),t.push.apply(t,r)}return t}function i(e){for(var n=1;n<arguments.length;n++){var t=null!=arguments[n]?arguments[n]:{};n%2?l(Object(t),!0).forEach((function(n){a(e,n,t[n])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(t)):l(Object(t)).forEach((function(n){Object.defineProperty(e,n,Object.getOwnPropertyDescriptor(t,n))}))}return e}function o(e,n){if(null==e)return{};var t,r,a=function(e,n){if(null==e)return{};var t,r,a={},l=Object.keys(e);for(r=0;r<l.length;r++)t=l[r],n.indexOf(t)>=0||(a[t]=e[t]);return a}(e,n);if(Object.getOwnPropertySymbols){var l=Object.getOwnPropertySymbols(e);for(r=0;r<l.length;r++)t=l[r],n.indexOf(t)>=0||Object.prototype.propertyIsEnumerable.call(e,t)&&(a[t]=e[t])}return a}var s=r.createContext({}),p=function(e){var n=r.useContext(s),t=n;return e&&(t="function"==typeof e?e(n):i(i({},n),e)),t},c=function(e){var n=p(e.components);return r.createElement(s.Provider,{value:n},e.children)},u={inlineCode:"code",wrapper:function(e){var n=e.children;return r.createElement(r.Fragment,{},n)}},d=r.forwardRef((function(e,n){var t=e.components,a=e.mdxType,l=e.originalType,s=e.parentName,c=o(e,["components","mdxType","originalType","parentName"]),d=p(t),m=a,f=d["".concat(s,".").concat(m)]||d[m]||u[m]||l;return t?r.createElement(f,i(i({ref:n},c),{},{components:t})):r.createElement(f,i({ref:n},c))}));function m(e,n){var t=arguments,a=n&&n.mdxType;if("string"==typeof e||a){var l=t.length,i=new Array(l);i[0]=d;var o={};for(var s in n)hasOwnProperty.call(n,s)&&(o[s]=n[s]);o.originalType=e,o.mdxType="string"==typeof e?e:a,i[1]=o;for(var p=2;p<l;p++)i[p]=t[p];return r.createElement.apply(null,i)}return r.createElement.apply(null,t)}d.displayName="MDXCreateElement"},9494:function(e,n,t){t.r(n),t.d(n,{assets:function(){return c},contentTitle:function(){return s},default:function(){return m},frontMatter:function(){return o},metadata:function(){return p},toc:function(){return u}});var r=t(7896),a=t(1461),l=(t(2784),t(876)),i=["components"],o={title:"\u5e7f\u544a\u63d2\u4ef6",sidebar_position:2},s=void 0,p={unversionedId:"zh-cn/Plugins/ads",id:"zh-cn/Plugins/ads",title:"\u5e7f\u544a\u63d2\u4ef6",description:"\u6f14\u793a",source:"@site/docs/zh-cn/Plugins/ads.mdx",sourceDirName:"zh-cn/Plugins",slug:"/zh-cn/Plugins/ads",permalink:"/document/zh-cn/Plugins/ads",draft:!1,tags:[],version:"current",sidebarPosition:2,frontMatter:{title:"\u5e7f\u544a\u63d2\u4ef6",sidebar_position:2},sidebar:"zh-cn",previous:{title:"\u5f39\u5e55\u5e93\u63d2\u4ef6",permalink:"/document/zh-cn/Plugins/danmuku"},next:{title:"\u5728\u63a7\u5236\u680f\u6dfb\u52a0\u5217\u8868",permalink:"/document/zh-cn/Questions/Create_selector_in_the_controls"}},c={},u=[{value:"\u6f14\u793a",id:"\u6f14\u793a",level:2},{value:"\u5b89\u88c5",id:"\u5b89\u88c5",level:2},{value:"\u901a\u8fc7 <code>npm</code> \u5b89\u88c5\uff1a",id:"\u901a\u8fc7-npm-\u5b89\u88c5",level:3},{value:"\u901a\u8fc7 <code>yarn</code> \u5b89\u88c5\uff1a",id:"\u901a\u8fc7-yarn-\u5b89\u88c5",level:3},{value:"\u901a\u8fc7 <code>script</code> \u5b89\u88c5\uff1a",id:"\u901a\u8fc7-script-\u5b89\u88c5",level:3},{value:"\u4f7f\u7528",id:"\u4f7f\u7528",level:2}],d={toc:u};function m(e){var n=e.components,t=(0,a.Z)(e,i);return(0,l.kt)("wrapper",(0,r.Z)({},d,t,{components:n,mdxType:"MDXLayout"}),(0,l.kt)("h2",{id:"\u6f14\u793a"},"\u6f14\u793a"),(0,l.kt)("p",null,"\ud83d\udc49 ",(0,l.kt)("a",{parentName:"p",href:"https://artplayer.org/?libs=./uncompiled/artplayer-plugin-ads/index.js&example=ads"},"\u67e5\u770b\u5b8c\u6574\u6f14\u793a")),(0,l.kt)("h2",{id:"\u5b89\u88c5"},"\u5b89\u88c5"),(0,l.kt)("h3",{id:"\u901a\u8fc7-npm-\u5b89\u88c5"},"\u901a\u8fc7 ",(0,l.kt)("inlineCode",{parentName:"h3"},"npm")," \u5b89\u88c5\uff1a"),(0,l.kt)("pre",null,(0,l.kt)("code",{parentName:"pre",className:"language-bash"},"$ npm install artplayer-plugin-ads\n")),(0,l.kt)("h3",{id:"\u901a\u8fc7-yarn-\u5b89\u88c5"},"\u901a\u8fc7 ",(0,l.kt)("inlineCode",{parentName:"h3"},"yarn")," \u5b89\u88c5\uff1a"),(0,l.kt)("pre",null,(0,l.kt)("code",{parentName:"pre",className:"language-bash"},"$ yarn add artplayer-plugin-ads\n")),(0,l.kt)("h3",{id:"\u901a\u8fc7-script-\u5b89\u88c5"},"\u901a\u8fc7 ",(0,l.kt)("inlineCode",{parentName:"h3"},"script")," \u5b89\u88c5\uff1a"),(0,l.kt)("pre",null,(0,l.kt)("code",{parentName:"pre",className:"language-html"},'\x3c!-- \u672c\u5730 --\x3e\n<script src="path/to/artplayer-plugin-ads.js"><\/script>\n\n\x3c!-- jsdelivr --\x3e\n<script src="https://cdn.jsde Line truncated
@@ -1 +0,0 @@
"use strict";(self.webpackChunkartplayer_document=self.webpackChunkartplayer_document||[]).push([[558],{3905:function(e,t,n){n.d(t,{Zo:function(){return m},kt:function(){return k}});var a=n(7294);function l(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function r(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var a=Object.getOwnPropertySymbols(e);t&&(a=a.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,a)}return n}function i(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?r(Object(n),!0).forEach((function(t){l(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):r(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}function p(e,t){if(null==e)return{};var n,a,l=function(e,t){if(null==e)return{};var n,a,l={},r=Object.keys(e);for(a=0;a<r.length;a++)n=r[a],t.indexOf(n)>=0||(l[n]=e[n]);return l}(e,t);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);for(a=0;a<r.length;a++)n=r[a],t.indexOf(n)>=0||Object.prototype.propertyIsEnumerable.call(e,n)&&(l[n]=e[n])}return l}var o=a.createContext({}),u=function(e){var t=a.useContext(o),n=t;return e&&(n="function"==typeof e?e(t):i(i({},t),e)),n},m=function(e){var t=u(e.components);return a.createElement(o.Provider,{value:t},e.children)},s={inlineCode:"code",wrapper:function(e){var t=e.children;return a.createElement(a.Fragment,{},t)}},d=a.forwardRef((function(e,t){var n=e.components,l=e.mdxType,r=e.originalType,o=e.parentName,m=p(e,["components","mdxType","originalType","parentName"]),d=u(n),k=l,c=d["".concat(o,".").concat(k)]||d[k]||s[k]||r;return n?a.createElement(c,i(i({ref:t},m),{},{components:n})):a.createElement(c,i({ref:t},m))}));function k(e,t){var n=arguments,l=t&&t.mdxType;if("string"==typeof e||l){var r=n.length,i=new Array(r);i[0]=d;var p={};for(var o in t)hasOwnProperty.call(t,o)&&(p[o]=t[o]);p.originalType=e,p.mdxType="string"==typeof e?e:l,i[1]=p;for(var u=2;u<r;u++)i[u]=n[u];return a.createElement.apply(null,i)}return a.createElement.apply(null,n)}d.displayName="MDXCreateElement"},3397:function(e,t,n){n.r(t),n.d(t,{assets:function(){return m},contentTitle:function(){return o},default:function(){return k},frontMatter:function(){return p},metadata:function(){return u},toc:function(){return s}});var a=n(7462),l=n(3366),r=(n(7294),n(3905)),i=["components"],p={title:"Basic options",sidebar_position:2,slug:"/options"},o=void 0,u={unversionedId:"en/Options",id:"en/Options",title:"Basic options",description:"container",source:"@site/docs/en/Options.mdx",sourceDirName:"en",slug:"/options",permalink:"/document/options",draft:!1,tags:[],version:"current",sidebarPosition:2,frontMatter:{title:"Basic options",sidebar_position:2,slug:"/options"},sidebar:"en",previous:{title:"Quick start",permalink:"/document/"},next:{title:"Common properties",permalink:"/document/propertie"}},m={},s=[{value:"container",id:"container",level:2},{value:"url",id:"url",level:2},{value:"Ready Callback",id:"ready-callback",level:2},{value:"poster",id:"poster",level:2},{value:"title",id:"title",level:2},{value:"theme",id:"theme",level:2},{value:"volume",id:"volume",level:2},{value:"isLive",id:"islive",level:2},{value:"muted",id:"muted",level:2},{value:"autoplay",id:"autoplay",level:2},{value:"autoSize",id:"autosize",level:2},{value:"autoMini",id:"automini",level:2},{value:"loop",id:"loop",level:2},{value:"flip",id:"flip",level:2},{value:"playbackRate",id:"playbackrate",level:2},{value:"aspectRatio",id:"aspectratio",level:2},{value:"screenshot",id:"screenshot",level:2},{value:"setting",id:"setting",level:2},{value:"hotkey",id:"hotkey",level:2},{value:"pip",id:"pip",level:2},{value:"mutex",id:"mutex",level:2},{value:"fullscreen",id:"fullscreen",level:2},{value:"fullscreenWeb",id:"fullscreenweb",level:2},{value:"subtitleOffset",id:"subtitleoffset",level:2},{value:"miniProgressBar",id:"miniprogressbar",level:2},{value:"useSSR",id:"usessr",level:2},{value:"playsInline",id:"playsinline",level:2},{value:"layers",id:"layers",level:2},{value:"settings",id:"settings",level:2},{value:"contextmenu",id:"contextmenu",level:2},{value:"controls",id:"controls",level:2},{value:"quality",id:"quality",level:2},{value:"highlight",id:"highlight",level:2},{value:"plugins",id:"plugins",level:2},{value:"whitelist",id:"whitelist",level:2},{value:"thumbnails",id:"thumbnails",level:2},{value:"subtitle",id:"subtitle",level:2},{value:"moreVideoAttr",id:"morevideoattr",level:2},{value:"icons",id:"icons",level:2},{value:"type",id:"type",level:2},{value:"customType",id:"customtype",level:2},{value:"lang",id:"lang",level:2},{value:"lock",id:"lock",level:2},{value:"fastForward",id:"fastforward",level:2},{value:"autoPlayback",id:"autoplayback",level:2},{value:"autoOrientation",id:"autoorientation",level:2}],d={toc:s};function k(e){var t=e.componentLine truncated
@@ -0,0 +1 @@
"use strict";(self.webpackChunkartplayer_document=self.webpackChunkartplayer_document||[]).push([[558],{876:function(e,t,n){n.d(t,{Zo:function(){return m},kt:function(){return k}});var a=n(2784);function l(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function r(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var a=Object.getOwnPropertySymbols(e);t&&(a=a.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,a)}return n}function i(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?r(Object(n),!0).forEach((function(t){l(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):r(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}function p(e,t){if(null==e)return{};var n,a,l=function(e,t){if(null==e)return{};var n,a,l={},r=Object.keys(e);for(a=0;a<r.length;a++)n=r[a],t.indexOf(n)>=0||(l[n]=e[n]);return l}(e,t);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);for(a=0;a<r.length;a++)n=r[a],t.indexOf(n)>=0||Object.prototype.propertyIsEnumerable.call(e,n)&&(l[n]=e[n])}return l}var o=a.createContext({}),u=function(e){var t=a.useContext(o),n=t;return e&&(n="function"==typeof e?e(t):i(i({},t),e)),n},m=function(e){var t=u(e.components);return a.createElement(o.Provider,{value:t},e.children)},d={inlineCode:"code",wrapper:function(e){var t=e.children;return a.createElement(a.Fragment,{},t)}},s=a.forwardRef((function(e,t){var n=e.components,l=e.mdxType,r=e.originalType,o=e.parentName,m=p(e,["components","mdxType","originalType","parentName"]),s=u(n),k=l,c=s["".concat(o,".").concat(k)]||s[k]||d[k]||r;return n?a.createElement(c,i(i({ref:t},m),{},{components:n})):a.createElement(c,i({ref:t},m))}));function k(e,t){var n=arguments,l=t&&t.mdxType;if("string"==typeof e||l){var r=n.length,i=new Array(r);i[0]=s;var p={};for(var o in t)hasOwnProperty.call(t,o)&&(p[o]=t[o]);p.originalType=e,p.mdxType="string"==typeof e?e:l,i[1]=p;for(var u=2;u<r;u++)i[u]=n[u];return a.createElement.apply(null,i)}return a.createElement.apply(null,n)}s.displayName="MDXCreateElement"},8857:function(e,t,n){n.r(t),n.d(t,{assets:function(){return m},contentTitle:function(){return o},default:function(){return k},frontMatter:function(){return p},metadata:function(){return u},toc:function(){return d}});var a=n(7896),l=n(1461),r=(n(2784),n(876)),i=["components"],p={title:"Basic options",sidebar_position:2,slug:"/options"},o=void 0,u={unversionedId:"en/Options",id:"en/Options",title:"Basic options",description:"container",source:"@site/docs/en/Options.mdx",sourceDirName:"en",slug:"/options",permalink:"/document/options",draft:!1,tags:[],version:"current",sidebarPosition:2,frontMatter:{title:"Basic options",sidebar_position:2,slug:"/options"},sidebar:"en",previous:{title:"Quick start",permalink:"/document/"},next:{title:"Common properties",permalink:"/document/propertie"}},m={},d=[{value:"container",id:"container",level:2},{value:"url",id:"url",level:2},{value:"Ready Callback",id:"ready-callback",level:2},{value:"poster",id:"poster",level:2},{value:"title",id:"title",level:2},{value:"theme",id:"theme",level:2},{value:"volume",id:"volume",level:2},{value:"isLive",id:"islive",level:2},{value:"muted",id:"muted",level:2},{value:"autoplay",id:"autoplay",level:2},{value:"autoSize",id:"autosize",level:2},{value:"autoMini",id:"automini",level:2},{value:"loop",id:"loop",level:2},{value:"flip",id:"flip",level:2},{value:"playbackRate",id:"playbackrate",level:2},{value:"aspectRatio",id:"aspectratio",level:2},{value:"screenshot",id:"screenshot",level:2},{value:"setting",id:"setting",level:2},{value:"hotkey",id:"hotkey",level:2},{value:"pip",id:"pip",level:2},{value:"mutex",id:"mutex",level:2},{value:"fullscreen",id:"fullscreen",level:2},{value:"fullscreenWeb",id:"fullscreenweb",level:2},{value:"subtitleOffset",id:"subtitleoffset",level:2},{value:"miniProgressBar",id:"miniprogressbar",level:2},{value:"useSSR",id:"usessr",level:2},{value:"playsInline",id:"playsinline",level:2},{value:"layers",id:"layers",level:2},{value:"settings",id:"settings",level:2},{value:"contextmenu",id:"contextmenu",level:2},{value:"controls",id:"controls",level:2},{value:"quality",id:"quality",level:2},{value:"highlight",id:"highlight",level:2},{value:"plugins",id:"plugins",level:2},{value:"whitelist",id:"whitelist",level:2},{value:"thumbnails",id:"thumbnails",level:2},{value:"subtitle",id:"subtitle",level:2},{value:"moreVideoAttr",id:"morevideoattr",level:2},{value:"icons",id:"icons",level:2},{value:"type",id:"type",level:2},{value:"customType",id:"customtype",level:2},{value:"lang",id:"lang",level:2},{value:"lock",id:"lock",level:2},{value:"fastForward",id:"fastforward",level:2},{value:"autoPlayback",id:"autoplayback",level:2},{value:"autoOrientation",id:"autoorientation",level:2},{value:"airplay",id:"airplay",level:2}],s={tLine truncated
+1
View File
@@ -0,0 +1 @@
"use strict";(self.webpackChunkartplayer_document=self.webpackChunkartplayer_document||[]).push([[489],{2489:function(e,t,n){n.r(t),n.d(t,{default:function(){return c}});var a=n(2784),l=n(8828),o=n(1077),r=n(328);function c(){return a.createElement(a.Fragment,null,a.createElement(r.d,{title:(0,o.I)({id:"theme.NotFound.title",message:"Page Not Found"})}),a.createElement(l.Z,null,a.createElement("main",{className:"container margin-vert--xl"},a.createElement("div",{className:"row"},a.createElement("div",{className:"col col--6 col--offset-3"},a.createElement("h1",{className:"hero__title"},a.createElement(o.Z,{id:"theme.NotFound.title",description:"The title of the 404 page"},"Page Not Found")),a.createElement("p",null,a.createElement(o.Z,{id:"theme.NotFound.p1",description:"The first paragraph of the 404 page"},"We could not find what you were looking for.")),a.createElement("p",null,a.createElement(o.Z,{id:"theme.NotFound.p2",description:"The 2nd paragraph of the 404 page"},"Please contact the owner of the site that linked you to the original URL and let them know their link is broken.")))))))}}}]);
@@ -1 +0,0 @@
"use strict";(self.webpackChunkartplayer_document=self.webpackChunkartplayer_document||[]).push([[619],{3905:function(e,n,t){t.d(n,{Zo:function(){return s},kt:function(){return d}});var r=t(7294);function o(e,n,t){return n in e?Object.defineProperty(e,n,{value:t,enumerable:!0,configurable:!0,writable:!0}):e[n]=t,e}function a(e,n){var t=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);n&&(r=r.filter((function(n){return Object.getOwnPropertyDescriptor(e,n).enumerable}))),t.push.apply(t,r)}return t}function i(e){for(var n=1;n<arguments.length;n++){var t=null!=arguments[n]?arguments[n]:{};n%2?a(Object(t),!0).forEach((function(n){o(e,n,t[n])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(t)):a(Object(t)).forEach((function(n){Object.defineProperty(e,n,Object.getOwnPropertyDescriptor(t,n))}))}return e}function c(e,n){if(null==e)return{};var t,r,o=function(e,n){if(null==e)return{};var t,r,o={},a=Object.keys(e);for(r=0;r<a.length;r++)t=a[r],n.indexOf(t)>=0||(o[t]=e[t]);return o}(e,n);if(Object.getOwnPropertySymbols){var a=Object.getOwnPropertySymbols(e);for(r=0;r<a.length;r++)t=a[r],n.indexOf(t)>=0||Object.prototype.propertyIsEnumerable.call(e,t)&&(o[t]=e[t])}return o}var l=r.createContext({}),u=function(e){var n=r.useContext(l),t=n;return e&&(t="function"==typeof e?e(n):i(i({},n),e)),t},s=function(e){var n=u(e.components);return r.createElement(l.Provider,{value:n},e.children)},p={inlineCode:"code",wrapper:function(e){var n=e.children;return r.createElement(r.Fragment,{},n)}},m=r.forwardRef((function(e,n){var t=e.components,o=e.mdxType,a=e.originalType,l=e.parentName,s=c(e,["components","mdxType","originalType","parentName"]),m=u(t),d=o,y=m["".concat(l,".").concat(d)]||m[d]||p[d]||a;return t?r.createElement(y,i(i({ref:n},s),{},{components:t})):r.createElement(y,i({ref:n},s))}));function d(e,n){var t=arguments,o=n&&n.mdxType;if("string"==typeof e||o){var a=t.length,i=new Array(a);i[0]=m;var c={};for(var l in n)hasOwnProperty.call(n,l)&&(c[l]=n[l]);c.originalType=e,c.mdxType="string"==typeof e?e:o,i[1]=c;for(var u=2;u<a;u++)i[u]=t[u];return r.createElement.apply(null,i)}return r.createElement.apply(null,t)}m.displayName="MDXCreateElement"},4418:function(e,n,t){t.r(n),t.d(n,{assets:function(){return s},contentTitle:function(){return l},default:function(){return d},frontMatter:function(){return c},metadata:function(){return u},toc:function(){return p}});var r=t(7462),o=t(3366),a=(t(7294),t(3905)),i=["components"],c={title:"\u5904\u7406\u5355\u4e2a\u7ec4\u4ef6",sidebar_position:3},l=void 0,u={unversionedId:"zh-cn/Questions/Handle_single_component",id:"zh-cn/Questions/Handle_single_component",title:"\u5904\u7406\u5355\u4e2a\u7ec4\u4ef6",description:"\u5f53\u6211\u4eec\u5728layers\u3001contextmenu\u3001controls\u91cc\u6dfb\u52a0\u81ea\u5b9a\u4e49\u7ec4\u4ef6\u65f6\uff0c\u6700\u597d\u5e26\u4e0a\u4e00\u4e2a\u552f\u4e00\u7684 name \u5c5e\u6027\uff0c\u8be5\u5c5e\u6027\u4e0d\u4f46\u4f1a\u4f5c\u4e3a\u7c7b\u540d\u6dfb\u52a0\u5230 dom \u5143\u7d20\u91cc\uff0c\u8fd8\u53ef\u4ee5\u7528\u4e8e\u5feb\u901f\u5b9a\u4f4d\u5230\u7ec4\u4ef6\u3002",source:"@site/docs/zh-cn/Questions/Handle_single_component.mdx",sourceDirName:"zh-cn/Questions",slug:"/zh-cn/Questions/Handle_single_component",permalink:"/document/zh-cn/Questions/Handle_single_component",draft:!1,tags:[],version:"current",sidebarPosition:3,frontMatter:{title:"\u5904\u7406\u5355\u4e2a\u7ec4\u4ef6",sidebar_position:3},sidebar:"zh-cn",previous:{title:"\u5728\u63a7\u5236\u680f\u6dfb\u52a0\u6309\u94ae",permalink:"/document/zh-cn/Questions/Create_button_in_the_controls"},next:{title:"\u5982\u4f55\u5bfc\u5165\u7c7b\u578b",permalink:"/document/zh-cn/Questions/How_to_import_types"}},s={},p=[],m={toc:p};function d(e){var n=e.components,t=(0,o.Z)(e,i);return(0,a.kt)("wrapper",(0,r.Z)({},m,t,{components:n,mdxType:"MDXLayout"}),(0,a.kt)("p",null,"\u5f53\u6211\u4eec\u5728",(0,a.kt)("inlineCode",{parentName:"p"},"layers"),"\u3001",(0,a.kt)("inlineCode",{parentName:"p"},"contextmenu"),"\u3001",(0,a.kt)("inlineCode",{parentName:"p"},"controls"),"\u91cc\u6dfb\u52a0\u81ea\u5b9a\u4e49\u7ec4\u4ef6\u65f6\uff0c\u6700\u597d\u5e26\u4e0a\u4e00\u4e2a\u552f\u4e00\u7684 ",(0,a.kt)("inlineCode",{parentName:"p"},"name")," \u5c5e\u6027\uff0c\u8be5\u5c5e\u6027\u4e0d\u4f46\u4f1a\u4f5c\u4e3a\u7c7b\u540d\u6dfb\u52a0\u5230 dom \u5143\u7d20\u91cc\uff0c\u8fd8\u53ef\u4ee5\u7528\u4e8e\u5feb\u901f\u5b9a\u4f4d\u5230\u7ec4\u4ef6\u3002"),(0,a.kt)("p",null,"\u8fd9\u91cc\u6709\u4e09\u79cd\u65b9\u6cd5\u83b7\u53d6\u7ec4\u4ef6\u7684dom\u5143\u7d20\uff1a\u7ec4\u4ef6\u65b9\u6cd5 ",(0,a.kt)("inlineCode",{parentName:"p"},"mounted"),"\u3001\u5b9e\u4f8b\u65b9\u6cd5 ",(0,a.kt)("inlineCode",{parentName:"p"},"query"),"\u3001\u63a8\u8350\u901a\u8fc7 ",(0,a.kt)("inlineCode",{parentName:"p"},"name")," \u76f4\u63a5\u83b7\u53d6"),(0,a.kt)("div",{className:"run-code"},"\u25b6 Run Code"),(0,a.kt)("pre",null,(0,a.kt)("code",{parentName:"pre",className:"languagLine truncated
@@ -0,0 +1 @@
"use strict";(self.webpackChunkartplayer_document=self.webpackChunkartplayer_document||[]).push([[619],{876:function(e,n,t){t.d(n,{Zo:function(){return s},kt:function(){return d}});var r=t(2784);function o(e,n,t){return n in e?Object.defineProperty(e,n,{value:t,enumerable:!0,configurable:!0,writable:!0}):e[n]=t,e}function a(e,n){var t=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);n&&(r=r.filter((function(n){return Object.getOwnPropertyDescriptor(e,n).enumerable}))),t.push.apply(t,r)}return t}function i(e){for(var n=1;n<arguments.length;n++){var t=null!=arguments[n]?arguments[n]:{};n%2?a(Object(t),!0).forEach((function(n){o(e,n,t[n])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(t)):a(Object(t)).forEach((function(n){Object.defineProperty(e,n,Object.getOwnPropertyDescriptor(t,n))}))}return e}function c(e,n){if(null==e)return{};var t,r,o=function(e,n){if(null==e)return{};var t,r,o={},a=Object.keys(e);for(r=0;r<a.length;r++)t=a[r],n.indexOf(t)>=0||(o[t]=e[t]);return o}(e,n);if(Object.getOwnPropertySymbols){var a=Object.getOwnPropertySymbols(e);for(r=0;r<a.length;r++)t=a[r],n.indexOf(t)>=0||Object.prototype.propertyIsEnumerable.call(e,t)&&(o[t]=e[t])}return o}var l=r.createContext({}),u=function(e){var n=r.useContext(l),t=n;return e&&(t="function"==typeof e?e(n):i(i({},n),e)),t},s=function(e){var n=u(e.components);return r.createElement(l.Provider,{value:n},e.children)},p={inlineCode:"code",wrapper:function(e){var n=e.children;return r.createElement(r.Fragment,{},n)}},m=r.forwardRef((function(e,n){var t=e.components,o=e.mdxType,a=e.originalType,l=e.parentName,s=c(e,["components","mdxType","originalType","parentName"]),m=u(t),d=o,y=m["".concat(l,".").concat(d)]||m[d]||p[d]||a;return t?r.createElement(y,i(i({ref:n},s),{},{components:t})):r.createElement(y,i({ref:n},s))}));function d(e,n){var t=arguments,o=n&&n.mdxType;if("string"==typeof e||o){var a=t.length,i=new Array(a);i[0]=m;var c={};for(var l in n)hasOwnProperty.call(n,l)&&(c[l]=n[l]);c.originalType=e,c.mdxType="string"==typeof e?e:o,i[1]=c;for(var u=2;u<a;u++)i[u]=t[u];return r.createElement.apply(null,i)}return r.createElement.apply(null,t)}m.displayName="MDXCreateElement"},9700:function(e,n,t){t.r(n),t.d(n,{assets:function(){return s},contentTitle:function(){return l},default:function(){return d},frontMatter:function(){return c},metadata:function(){return u},toc:function(){return p}});var r=t(7896),o=t(1461),a=(t(2784),t(876)),i=["components"],c={title:"\u5904\u7406\u5355\u4e2a\u7ec4\u4ef6",sidebar_position:3},l=void 0,u={unversionedId:"zh-cn/Questions/Handle_single_component",id:"zh-cn/Questions/Handle_single_component",title:"\u5904\u7406\u5355\u4e2a\u7ec4\u4ef6",description:"\u5f53\u6211\u4eec\u5728layers\u3001contextmenu\u3001controls\u91cc\u6dfb\u52a0\u81ea\u5b9a\u4e49\u7ec4\u4ef6\u65f6\uff0c\u6700\u597d\u5e26\u4e0a\u4e00\u4e2a\u552f\u4e00\u7684 name \u5c5e\u6027\uff0c\u8be5\u5c5e\u6027\u4e0d\u4f46\u4f1a\u4f5c\u4e3a\u7c7b\u540d\u6dfb\u52a0\u5230 dom \u5143\u7d20\u91cc\uff0c\u8fd8\u53ef\u4ee5\u7528\u4e8e\u5feb\u901f\u5b9a\u4f4d\u5230\u7ec4\u4ef6\u3002",source:"@site/docs/zh-cn/Questions/Handle_single_component.mdx",sourceDirName:"zh-cn/Questions",slug:"/zh-cn/Questions/Handle_single_component",permalink:"/document/zh-cn/Questions/Handle_single_component",draft:!1,tags:[],version:"current",sidebarPosition:3,frontMatter:{title:"\u5904\u7406\u5355\u4e2a\u7ec4\u4ef6",sidebar_position:3},sidebar:"zh-cn",previous:{title:"\u5728\u63a7\u5236\u680f\u6dfb\u52a0\u6309\u94ae",permalink:"/document/zh-cn/Questions/Create_button_in_the_controls"},next:{title:"\u5982\u4f55\u5bfc\u5165\u7c7b\u578b",permalink:"/document/zh-cn/Questions/How_to_import_types"}},s={},p=[],m={toc:p};function d(e){var n=e.components,t=(0,o.Z)(e,i);return(0,a.kt)("wrapper",(0,r.Z)({},m,t,{components:n,mdxType:"MDXLayout"}),(0,a.kt)("p",null,"\u5f53\u6211\u4eec\u5728",(0,a.kt)("inlineCode",{parentName:"p"},"layers"),"\u3001",(0,a.kt)("inlineCode",{parentName:"p"},"contextmenu"),"\u3001",(0,a.kt)("inlineCode",{parentName:"p"},"controls"),"\u91cc\u6dfb\u52a0\u81ea\u5b9a\u4e49\u7ec4\u4ef6\u65f6\uff0c\u6700\u597d\u5e26\u4e0a\u4e00\u4e2a\u552f\u4e00\u7684 ",(0,a.kt)("inlineCode",{parentName:"p"},"name")," \u5c5e\u6027\uff0c\u8be5\u5c5e\u6027\u4e0d\u4f46\u4f1a\u4f5c\u4e3a\u7c7b\u540d\u6dfb\u52a0\u5230 dom \u5143\u7d20\u91cc\uff0c\u8fd8\u53ef\u4ee5\u7528\u4e8e\u5feb\u901f\u5b9a\u4f4d\u5230\u7ec4\u4ef6\u3002"),(0,a.kt)("p",null,"\u8fd9\u91cc\u6709\u4e09\u79cd\u65b9\u6cd5\u83b7\u53d6\u7ec4\u4ef6\u7684dom\u5143\u7d20\uff1a\u7ec4\u4ef6\u65b9\u6cd5 ",(0,a.kt)("inlineCode",{parentName:"p"},"mounted"),"\u3001\u5b9e\u4f8b\u65b9\u6cd5 ",(0,a.kt)("inlineCode",{parentName:"p"},"query"),"\u3001\u63a8\u8350\u901a\u8fc7 ",(0,a.kt)("inlineCode",{parentName:"p"},"name")," \u76f4\u63a5\u83b7\u53d6"),(0,a.kt)("div",{className:"run-code"},"\u25b6 Run Code"),(0,a.kt)("pre",null,(0,a.kt)("code",{parentName:"pre",className:"language-Line truncated
@@ -1 +0,0 @@
"use strict";(self.webpackChunkartplayer_document=self.webpackChunkartplayer_document||[]).push([[645],{3905:function(e,t,n){n.d(t,{Zo:function(){return p},kt:function(){return f}});var r=n(7294);function o(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function a(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,r)}return n}function i(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?a(Object(n),!0).forEach((function(t){o(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):a(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}function c(e,t){if(null==e)return{};var n,r,o=function(e,t){if(null==e)return{};var n,r,o={},a=Object.keys(e);for(r=0;r<a.length;r++)n=a[r],t.indexOf(n)>=0||(o[n]=e[n]);return o}(e,t);if(Object.getOwnPropertySymbols){var a=Object.getOwnPropertySymbols(e);for(r=0;r<a.length;r++)n=a[r],t.indexOf(n)>=0||Object.prototype.propertyIsEnumerable.call(e,n)&&(o[n]=e[n])}return o}var l=r.createContext({}),s=function(e){var t=r.useContext(l),n=t;return e&&(n="function"==typeof e?e(t):i(i({},t),e)),n},p=function(e){var t=s(e.components);return r.createElement(l.Provider,{value:t},e.children)},u={inlineCode:"code",wrapper:function(e){var t=e.children;return r.createElement(r.Fragment,{},t)}},m=r.forwardRef((function(e,t){var n=e.components,o=e.mdxType,a=e.originalType,l=e.parentName,p=c(e,["components","mdxType","originalType","parentName"]),m=s(n),f=o,d=m["".concat(l,".").concat(f)]||m[f]||u[f]||a;return n?r.createElement(d,i(i({ref:t},p),{},{components:n})):r.createElement(d,i({ref:t},p))}));function f(e,t){var n=arguments,o=t&&t.mdxType;if("string"==typeof e||o){var a=n.length,i=new Array(a);i[0]=m;var c={};for(var l in t)hasOwnProperty.call(t,l)&&(c[l]=t[l]);c.originalType=e,c.mdxType="string"==typeof e?e:o,i[1]=c;for(var s=2;s<a;s++)i[s]=n[s];return r.createElement.apply(null,i)}return r.createElement.apply(null,n)}m.displayName="MDXCreateElement"},8999:function(e,t,n){n.r(t),n.d(t,{assets:function(){return p},contentTitle:function(){return l},default:function(){return f},frontMatter:function(){return c},metadata:function(){return s},toc:function(){return u}});var r=n(7462),o=n(3366),a=(n(7294),n(3905)),i=["components"],c={title:"Use with React Portal",sidebar_position:6},l=void 0,s={unversionedId:"en/Questions/Use_with_react_portal",id:"en/Questions/Use_with_react_portal",title:"Use with React Portal",description:"It is also very easy to use React Components in layers, contextmenu, controls. Handle more complex logic through ReactDOM.createPortal.",source:"@site/docs/en/Questions/Use_with_react_portal.mdx",sourceDirName:"en/Questions",slug:"/en/Questions/Use_with_react_portal",permalink:"/document/en/Questions/Use_with_react_portal",draft:!1,tags:[],version:"current",sidebarPosition:6,frontMatter:{title:"Use with React Portal",sidebar_position:6},sidebar:"en",previous:{title:"How to add setting panel",permalink:"/document/en/Questions/How_to_add_setting_panel"}},p={},u=[],m={toc:u};function f(e){var t=e.components,n=(0,o.Z)(e,i);return(0,a.kt)("wrapper",(0,r.Z)({},m,n,{components:t,mdxType:"MDXLayout"}),(0,a.kt)("p",null,"It is also very easy to use ",(0,a.kt)("inlineCode",{parentName:"p"},"React Components")," in ",(0,a.kt)("inlineCode",{parentName:"p"},"layers"),", ",(0,a.kt)("inlineCode",{parentName:"p"},"contextmenu"),", ",(0,a.kt)("inlineCode",{parentName:"p"},"controls"),". Handle more complex logic through ",(0,a.kt)("inlineCode",{parentName:"p"},"ReactDOM.createPortal"),"."),(0,a.kt)("p",null,"\ud83d\udc49 ",(0,a.kt)("a",{parentName:"p",href:"https://codesandbox.io/s/artplayer-react-portal-5z32h"},"Click to open an online demo")),(0,a.kt)("pre",null,(0,a.kt)("code",{parentName:"pre",className:"language-jsx"},'import React, { useState, useEffect } from "react";\nimport ReactDOM, { createPortal } from "react-dom";\nimport Artplayer from "artplayer/examples/react/Artplayer";\n\nfunction Timer({ time }) {\n return <div>{time}</div>;\n}\n\nfunction App() {\n const [art, setArt] = useState(null);\n const [time, setTime] = useState(0);\n\n useEffect(() => {\n const update = () => setTime((time) => time + 1);\n setInterval(update, 1000);\n }, []);\n\n return (\n <div>\n <Artplayer\n option={{\n url: "https://artplayer.org/assets/sample/video.mp4",\n layers: [\n {\n html: "",\n name: "portal"\n }\n ],\n controls: [\n {\n position: "right",\n name: "portal",\n html: ""\n }\n ]\n }}\n style={{\n width: "600px",\n height: "400px",\n Line truncated
@@ -0,0 +1 @@
"use strict";(self.webpackChunkartplayer_document=self.webpackChunkartplayer_document||[]).push([[645],{876:function(e,t,n){n.d(t,{Zo:function(){return p},kt:function(){return f}});var r=n(2784);function o(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function a(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,r)}return n}function i(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?a(Object(n),!0).forEach((function(t){o(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):a(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}function c(e,t){if(null==e)return{};var n,r,o=function(e,t){if(null==e)return{};var n,r,o={},a=Object.keys(e);for(r=0;r<a.length;r++)n=a[r],t.indexOf(n)>=0||(o[n]=e[n]);return o}(e,t);if(Object.getOwnPropertySymbols){var a=Object.getOwnPropertySymbols(e);for(r=0;r<a.length;r++)n=a[r],t.indexOf(n)>=0||Object.prototype.propertyIsEnumerable.call(e,n)&&(o[n]=e[n])}return o}var l=r.createContext({}),s=function(e){var t=r.useContext(l),n=t;return e&&(n="function"==typeof e?e(t):i(i({},t),e)),n},p=function(e){var t=s(e.components);return r.createElement(l.Provider,{value:t},e.children)},u={inlineCode:"code",wrapper:function(e){var t=e.children;return r.createElement(r.Fragment,{},t)}},m=r.forwardRef((function(e,t){var n=e.components,o=e.mdxType,a=e.originalType,l=e.parentName,p=c(e,["components","mdxType","originalType","parentName"]),m=s(n),f=o,d=m["".concat(l,".").concat(f)]||m[f]||u[f]||a;return n?r.createElement(d,i(i({ref:t},p),{},{components:n})):r.createElement(d,i({ref:t},p))}));function f(e,t){var n=arguments,o=t&&t.mdxType;if("string"==typeof e||o){var a=n.length,i=new Array(a);i[0]=m;var c={};for(var l in t)hasOwnProperty.call(t,l)&&(c[l]=t[l]);c.originalType=e,c.mdxType="string"==typeof e?e:o,i[1]=c;for(var s=2;s<a;s++)i[s]=n[s];return r.createElement.apply(null,i)}return r.createElement.apply(null,n)}m.displayName="MDXCreateElement"},2361:function(e,t,n){n.r(t),n.d(t,{assets:function(){return p},contentTitle:function(){return l},default:function(){return f},frontMatter:function(){return c},metadata:function(){return s},toc:function(){return u}});var r=n(7896),o=n(1461),a=(n(2784),n(876)),i=["components"],c={title:"Use with React Portal",sidebar_position:6},l=void 0,s={unversionedId:"en/Questions/Use_with_react_portal",id:"en/Questions/Use_with_react_portal",title:"Use with React Portal",description:"It is also very easy to use React Components in layers, contextmenu, controls. Handle more complex logic through ReactDOM.createPortal.",source:"@site/docs/en/Questions/Use_with_react_portal.mdx",sourceDirName:"en/Questions",slug:"/en/Questions/Use_with_react_portal",permalink:"/document/en/Questions/Use_with_react_portal",draft:!1,tags:[],version:"current",sidebarPosition:6,frontMatter:{title:"Use with React Portal",sidebar_position:6},sidebar:"en",previous:{title:"How to add setting panel",permalink:"/document/en/Questions/How_to_add_setting_panel"}},p={},u=[],m={toc:u};function f(e){var t=e.components,n=(0,o.Z)(e,i);return(0,a.kt)("wrapper",(0,r.Z)({},m,n,{components:t,mdxType:"MDXLayout"}),(0,a.kt)("p",null,"It is also very easy to use ",(0,a.kt)("inlineCode",{parentName:"p"},"React Components")," in ",(0,a.kt)("inlineCode",{parentName:"p"},"layers"),", ",(0,a.kt)("inlineCode",{parentName:"p"},"contextmenu"),", ",(0,a.kt)("inlineCode",{parentName:"p"},"controls"),". Handle more complex logic through ",(0,a.kt)("inlineCode",{parentName:"p"},"ReactDOM.createPortal"),"."),(0,a.kt)("p",null,"\ud83d\udc49 ",(0,a.kt)("a",{parentName:"p",href:"https://codesandbox.io/s/artplayer-react-portal-5z32h"},"Click to open an online demo")),(0,a.kt)("pre",null,(0,a.kt)("code",{parentName:"pre",className:"language-jsx"},'import React, { useState, useEffect } from "react";\nimport ReactDOM, { createPortal } from "react-dom";\nimport Artplayer from "artplayer/examples/react/Artplayer";\n\nfunction Timer({ time }) {\n return <div>{time}</div>;\n}\n\nfunction App() {\n const [art, setArt] = useState(null);\n const [time, setTime] = useState(0);\n\n useEffect(() => {\n const update = () => setTime((time) => time + 1);\n setInterval(update, 1000);\n }, []);\n\n return (\n <div>\n <Artplayer\n option={{\n url: "https://artplayer.org/assets/sample/video.mp4",\n layers: [\n {\n html: "",\n name: "portal"\n }\n ],\n controls: [\n {\n position: "right",\n name: "portal",\n html: ""\n }\n ]\n }}\n style={{\n width: "600px",\n height: "400px",\n Line truncated
@@ -1 +0,0 @@
"use strict";(self.webpackChunkartplayer_document=self.webpackChunkartplayer_document||[]).push([[28],{3905:function(n,e,t){t.d(e,{Zo:function(){return m},kt:function(){return f}});var r=t(7294);function l(n,e,t){return e in n?Object.defineProperty(n,e,{value:t,enumerable:!0,configurable:!0,writable:!0}):n[e]=t,n}function s(n,e){var t=Object.keys(n);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(n);e&&(r=r.filter((function(e){return Object.getOwnPropertyDescriptor(n,e).enumerable}))),t.push.apply(t,r)}return t}function a(n){for(var e=1;e<arguments.length;e++){var t=null!=arguments[e]?arguments[e]:{};e%2?s(Object(t),!0).forEach((function(e){l(n,e,t[e])})):Object.getOwnPropertyDescriptors?Object.defineProperties(n,Object.getOwnPropertyDescriptors(t)):s(Object(t)).forEach((function(e){Object.defineProperty(n,e,Object.getOwnPropertyDescriptor(t,e))}))}return n}function i(n,e){if(null==n)return{};var t,r,l=function(n,e){if(null==n)return{};var t,r,l={},s=Object.keys(n);for(r=0;r<s.length;r++)t=s[r],e.indexOf(t)>=0||(l[t]=n[t]);return l}(n,e);if(Object.getOwnPropertySymbols){var s=Object.getOwnPropertySymbols(n);for(r=0;r<s.length;r++)t=s[r],e.indexOf(t)>=0||Object.prototype.propertyIsEnumerable.call(n,t)&&(l[t]=n[t])}return l}var o=r.createContext({}),c=function(n){var e=r.useContext(o),t=e;return n&&(t="function"==typeof n?n(e):a(a({},e),n)),t},m=function(n){var e=c(n.components);return r.createElement(o.Provider,{value:e},n.children)},u={inlineCode:"code",wrapper:function(n){var e=n.children;return r.createElement(r.Fragment,{},e)}},p=r.forwardRef((function(n,e){var t=n.components,l=n.mdxType,s=n.originalType,o=n.parentName,m=i(n,["components","mdxType","originalType","parentName"]),p=c(t),f=l,h=p["".concat(o,".").concat(f)]||p[f]||u[f]||s;return t?r.createElement(h,a(a({ref:e},m),{},{components:t})):r.createElement(h,a({ref:e},m))}));function f(n,e){var t=arguments,l=e&&e.mdxType;if("string"==typeof n||l){var s=t.length,a=new Array(s);a[0]=p;var i={};for(var o in e)hasOwnProperty.call(e,o)&&(i[o]=e[o]);i.originalType=n,i.mdxType="string"==typeof n?n:l,a[1]=i;for(var c=2;c<s;c++)a[c]=t[c];return r.createElement.apply(null,a)}return r.createElement.apply(null,t)}p.displayName="MDXCreateElement"},9450:function(n,e,t){t.r(e),t.d(e,{assets:function(){return m},contentTitle:function(){return o},default:function(){return f},frontMatter:function(){return i},metadata:function(){return c},toc:function(){return u}});var r=t(7462),l=t(3366),s=(t(7294),t(3905)),a=["components"],i={title:"\u5728\u63a7\u5236\u680f\u6dfb\u52a0\u5217\u8868",sidebar_position:1},o=void 0,c={unversionedId:"zh-cn/Questions/Create_selector_in_the_controls",id:"zh-cn/Questions/Create_selector_in_the_controls",title:"\u5728\u63a7\u5236\u680f\u6dfb\u52a0\u5217\u8868",description:"\u6709\u65f6\u4f60\u9700\u8981\u5728\u63a7\u5236\u680f\u6dfb\u52a0\u5217\u8868\uff0c\u90a3\u4e48\u4f60\u53ef\u4ee5\u5728\u6dfb\u52a0\u63a7\u4ef6\u7684\u65f6\u5019\u4f7f\u7528 selector \u548c onSelect \u5c5e\u6027",source:"@site/docs/zh-cn/Questions/Create_selector_in_the_controls.mdx",sourceDirName:"zh-cn/Questions",slug:"/zh-cn/Questions/Create_selector_in_the_controls",permalink:"/document/zh-cn/Questions/Create_selector_in_the_controls",draft:!1,tags:[],version:"current",sidebarPosition:1,frontMatter:{title:"\u5728\u63a7\u5236\u680f\u6dfb\u52a0\u5217\u8868",sidebar_position:1},sidebar:"zh-cn",previous:{title:"\u5f39\u5e55\u5e93\u63d2\u4ef6",permalink:"/document/zh-cn/Plugins/danmuku"},next:{title:"\u5728\u63a7\u5236\u680f\u6dfb\u52a0\u6309\u94ae",permalink:"/document/zh-cn/Questions/Create_button_in_the_controls"}},m={},u=[{value:"\u5207\u6362\u5b57\u5e55",id:"\u5207\u6362\u5b57\u5e55",level:3},{value:"\u5207\u6362\u6ee4\u955c",id:"\u5207\u6362\u6ee4\u955c",level:3}],p={toc:u};function f(n){var e=n.components,t=(0,l.Z)(n,a);return(0,s.kt)("wrapper",(0,r.Z)({},p,t,{components:e,mdxType:"MDXLayout"}),(0,s.kt)("p",null,"\u6709\u65f6\u4f60\u9700\u8981\u5728\u63a7\u5236\u680f\u6dfb\u52a0\u5217\u8868\uff0c\u90a3\u4e48\u4f60\u53ef\u4ee5\u5728\u6dfb\u52a0\u63a7\u4ef6\u7684\u65f6\u5019\u4f7f\u7528 ",(0,s.kt)("inlineCode",{parentName:"p"},"selector")," \u548c ",(0,s.kt)("inlineCode",{parentName:"p"},"onSelect")," \u5c5e\u6027"),(0,s.kt)("h3",{id:"\u5207\u6362\u5b57\u5e55"},"\u5207\u6362\u5b57\u5e55"),(0,s.kt)("div",{className:"run-code"},"\u25b6 Run Code"),(0,s.kt)("pre",null,(0,s.kt)("code",{parentName:"pre",className:"language-js"},"var art = new Artplayer({\n container: '.artplayer-app',\n url: '/assets/sample/video.mp4',\n controls: [\n {\n position: 'right',\n html: 'Subtitle 01',\n selector: [\n {\n default: true,\n html: '<span style=\"color:red\">Subtitle 01</span>',\n url: '/assets/sample/subtitle.srt?id=1',\n },\n {\n html: '<span style=\"color:yellow\">Subtitle 02</span>',\n Line truncated
@@ -0,0 +1 @@
"use strict";(self.webpackChunkartplayer_document=self.webpackChunkartplayer_document||[]).push([[28],{876:function(n,e,t){t.d(e,{Zo:function(){return m},kt:function(){return f}});var r=t(2784);function l(n,e,t){return e in n?Object.defineProperty(n,e,{value:t,enumerable:!0,configurable:!0,writable:!0}):n[e]=t,n}function s(n,e){var t=Object.keys(n);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(n);e&&(r=r.filter((function(e){return Object.getOwnPropertyDescriptor(n,e).enumerable}))),t.push.apply(t,r)}return t}function a(n){for(var e=1;e<arguments.length;e++){var t=null!=arguments[e]?arguments[e]:{};e%2?s(Object(t),!0).forEach((function(e){l(n,e,t[e])})):Object.getOwnPropertyDescriptors?Object.defineProperties(n,Object.getOwnPropertyDescriptors(t)):s(Object(t)).forEach((function(e){Object.defineProperty(n,e,Object.getOwnPropertyDescriptor(t,e))}))}return n}function i(n,e){if(null==n)return{};var t,r,l=function(n,e){if(null==n)return{};var t,r,l={},s=Object.keys(n);for(r=0;r<s.length;r++)t=s[r],e.indexOf(t)>=0||(l[t]=n[t]);return l}(n,e);if(Object.getOwnPropertySymbols){var s=Object.getOwnPropertySymbols(n);for(r=0;r<s.length;r++)t=s[r],e.indexOf(t)>=0||Object.prototype.propertyIsEnumerable.call(n,t)&&(l[t]=n[t])}return l}var o=r.createContext({}),c=function(n){var e=r.useContext(o),t=e;return n&&(t="function"==typeof n?n(e):a(a({},e),n)),t},m=function(n){var e=c(n.components);return r.createElement(o.Provider,{value:e},n.children)},u={inlineCode:"code",wrapper:function(n){var e=n.children;return r.createElement(r.Fragment,{},e)}},p=r.forwardRef((function(n,e){var t=n.components,l=n.mdxType,s=n.originalType,o=n.parentName,m=i(n,["components","mdxType","originalType","parentName"]),p=c(t),f=l,h=p["".concat(o,".").concat(f)]||p[f]||u[f]||s;return t?r.createElement(h,a(a({ref:e},m),{},{components:t})):r.createElement(h,a({ref:e},m))}));function f(n,e){var t=arguments,l=e&&e.mdxType;if("string"==typeof n||l){var s=t.length,a=new Array(s);a[0]=p;var i={};for(var o in e)hasOwnProperty.call(e,o)&&(i[o]=e[o]);i.originalType=n,i.mdxType="string"==typeof n?n:l,a[1]=i;for(var c=2;c<s;c++)a[c]=t[c];return r.createElement.apply(null,a)}return r.createElement.apply(null,t)}p.displayName="MDXCreateElement"},3385:function(n,e,t){t.r(e),t.d(e,{assets:function(){return m},contentTitle:function(){return o},default:function(){return f},frontMatter:function(){return i},metadata:function(){return c},toc:function(){return u}});var r=t(7896),l=t(1461),s=(t(2784),t(876)),a=["components"],i={title:"\u5728\u63a7\u5236\u680f\u6dfb\u52a0\u5217\u8868",sidebar_position:1},o=void 0,c={unversionedId:"zh-cn/Questions/Create_selector_in_the_controls",id:"zh-cn/Questions/Create_selector_in_the_controls",title:"\u5728\u63a7\u5236\u680f\u6dfb\u52a0\u5217\u8868",description:"\u6709\u65f6\u4f60\u9700\u8981\u5728\u63a7\u5236\u680f\u6dfb\u52a0\u5217\u8868\uff0c\u90a3\u4e48\u4f60\u53ef\u4ee5\u5728\u6dfb\u52a0\u63a7\u4ef6\u7684\u65f6\u5019\u4f7f\u7528 selector \u548c onSelect \u5c5e\u6027",source:"@site/docs/zh-cn/Questions/Create_selector_in_the_controls.mdx",sourceDirName:"zh-cn/Questions",slug:"/zh-cn/Questions/Create_selector_in_the_controls",permalink:"/document/zh-cn/Questions/Create_selector_in_the_controls",draft:!1,tags:[],version:"current",sidebarPosition:1,frontMatter:{title:"\u5728\u63a7\u5236\u680f\u6dfb\u52a0\u5217\u8868",sidebar_position:1},sidebar:"zh-cn",previous:{title:"\u5e7f\u544a\u63d2\u4ef6",permalink:"/document/zh-cn/Plugins/ads"},next:{title:"\u5728\u63a7\u5236\u680f\u6dfb\u52a0\u6309\u94ae",permalink:"/document/zh-cn/Questions/Create_button_in_the_controls"}},m={},u=[{value:"\u5207\u6362\u5b57\u5e55",id:"\u5207\u6362\u5b57\u5e55",level:3},{value:"\u5207\u6362\u6ee4\u955c",id:"\u5207\u6362\u6ee4\u955c",level:3}],p={toc:u};function f(n){var e=n.components,t=(0,l.Z)(n,a);return(0,s.kt)("wrapper",(0,r.Z)({},p,t,{components:e,mdxType:"MDXLayout"}),(0,s.kt)("p",null,"\u6709\u65f6\u4f60\u9700\u8981\u5728\u63a7\u5236\u680f\u6dfb\u52a0\u5217\u8868\uff0c\u90a3\u4e48\u4f60\u53ef\u4ee5\u5728\u6dfb\u52a0\u63a7\u4ef6\u7684\u65f6\u5019\u4f7f\u7528 ",(0,s.kt)("inlineCode",{parentName:"p"},"selector")," \u548c ",(0,s.kt)("inlineCode",{parentName:"p"},"onSelect")," \u5c5e\u6027"),(0,s.kt)("h3",{id:"\u5207\u6362\u5b57\u5e55"},"\u5207\u6362\u5b57\u5e55"),(0,s.kt)("div",{className:"run-code"},"\u25b6 Run Code"),(0,s.kt)("pre",null,(0,s.kt)("code",{parentName:"pre",className:"language-js"},"var art = new Artplayer({\n container: '.artplayer-app',\n url: '/assets/sample/video.mp4',\n controls: [\n {\n position: 'right',\n html: 'Subtitle 01',\n selector: [\n {\n default: true,\n html: '<span style=\"color:red\">Subtitle 01</span>',\n url: '/assets/sample/subtitle.srt?id=1',\n },\n {\n html: '<span style=\"color:yellow\">Subtitle 02</span>',\n Line truncated
@@ -1 +0,0 @@
"use strict";(self.webpackChunkartplayer_document=self.webpackChunkartplayer_document||[]).push([[220],{3905:function(e,t,n){n.d(t,{Zo:function(){return p},kt:function(){return c}});var a=n(7294);function r(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function l(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var a=Object.getOwnPropertySymbols(e);t&&(a=a.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,a)}return n}function o(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?l(Object(n),!0).forEach((function(t){r(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):l(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}function i(e,t){if(null==e)return{};var n,a,r=function(e,t){if(null==e)return{};var n,a,r={},l=Object.keys(e);for(a=0;a<l.length;a++)n=l[a],t.indexOf(n)>=0||(r[n]=e[n]);return r}(e,t);if(Object.getOwnPropertySymbols){var l=Object.getOwnPropertySymbols(e);for(a=0;a<l.length;a++)n=l[a],t.indexOf(n)>=0||Object.prototype.propertyIsEnumerable.call(e,n)&&(r[n]=e[n])}return r}var d=a.createContext({}),s=function(e){var t=a.useContext(d),n=t;return e&&(n="function"==typeof e?e(t):o(o({},t),e)),n},p=function(e){var t=s(e.components);return a.createElement(d.Provider,{value:t},e.children)},u={inlineCode:"code",wrapper:function(e){var t=e.children;return a.createElement(a.Fragment,{},t)}},m=a.forwardRef((function(e,t){var n=e.components,r=e.mdxType,l=e.originalType,d=e.parentName,p=i(e,["components","mdxType","originalType","parentName"]),m=s(n),c=r,k=m["".concat(d,".").concat(c)]||m[c]||u[c]||l;return n?a.createElement(k,o(o({ref:t},p),{},{components:n})):a.createElement(k,o({ref:t},p))}));function c(e,t){var n=arguments,r=t&&t.mdxType;if("string"==typeof e||r){var l=n.length,o=new Array(l);o[0]=m;var i={};for(var d in t)hasOwnProperty.call(t,d)&&(i[d]=t[d]);i.originalType=e,i.mdxType="string"==typeof e?e:r,o[1]=i;for(var s=2;s<l;s++)o[s]=n[s];return a.createElement.apply(null,o)}return a.createElement.apply(null,n)}m.displayName="MDXCreateElement"},6641:function(e,t,n){n.r(t),n.d(t,{assets:function(){return p},contentTitle:function(){return d},default:function(){return c},frontMatter:function(){return i},metadata:function(){return s},toc:function(){return u}});var a=n(7462),r=n(3366),l=(n(7294),n(3905)),o=["components"],i={title:"\u5b9e\u4f8b\u4e8b\u4ef6",sidebar_position:6,slug:"/zh-cn/events"},d=void 0,s={unversionedId:"zh-cn/Events",id:"zh-cn/Events",title:"\u5b9e\u4f8b\u4e8b\u4ef6",description:"\u64ad\u653e\u5668\u7684\u4e8b\u4ef6\u5206\u4e3a\u4e24\u79cd\uff0c\u4e00\u79cd\u89c6\u9891\u7684\u539f\u751f\u4e8b\u4ef6\uff0c\u53e6\u5916\u4e00\u79cd\u662f\u81ea\u5b9a\u4e49\u7684\u4e8b\u4ef6\u3002\u539f\u751f\u4e8b\u4ef6\u6765\u81ea video \u5143\u7d20\uff0c\u662f\u76f4\u63a5\u76d1\u542cvideo\u5143\u7d20\u7684\u539f\u59cb\u4e8b\u4ef6\uff0c\u4e3a\u4e86\u8ba9\u5b83\u548c\u81ea\u5b9a\u4e49\u4e8b\u4ef6\u533a\u5206\uff0c\u539f\u751f\u4e8b\u4ef6\u6dfb\u52a0\u4e86\u524d\u7f00 video:",source:"@site/docs/zh-cn/Events.mdx",sourceDirName:"zh-cn",slug:"/zh-cn/events",permalink:"/document/zh-cn/events",draft:!1,tags:[],version:"current",sidebarPosition:6,frontMatter:{title:"\u5b9e\u4f8b\u4e8b\u4ef6",sidebar_position:6,slug:"/zh-cn/events"},sidebar:"zh-cn",previous:{title:"\u9759\u6001\u5c5e\u6027",permalink:"/document/zh-cn/class"},next:{title:"\u7b2c\u4e09\u65b9\u5e93",permalink:"/document/zh-cn/libraries"}},p={},u=[{value:"\u539f\u751f\u4e8b\u4ef6",id:"\u539f\u751f\u4e8b\u4ef6",level:2},{value:"\u81ea\u5b9a\u4e49\u4e8b\u4ef6",id:"\u81ea\u5b9a\u4e49\u4e8b\u4ef6",level:2},{value:"ready",id:"ready",level:3},{value:"play",id:"play",level:3},{value:"pause",id:"pause",level:3},{value:"seek",id:"seek",level:3},{value:"volume",id:"volume",level:3},{value:"destroy",id:"destroy",level:3},{value:"focus",id:"focus",level:3},{value:"blur",id:"blur",level:3},{value:"hover",id:"hover",level:3},{value:"resize",id:"resize",level:3},{value:"mousemove",id:"mousemove",level:3},{value:"url",id:"url",level:3},{value:"fullscreen",id:"fullscreen",level:3},{value:"fullscreenWeb",id:"fullscreenweb",level:3},{value:"hotkey",id:"hotkey",level:3}],m={toc:u};function c(e){var t=e.components,n=(0,r.Z)(e,o);return(0,l.kt)("wrapper",(0,a.Z)({},m,n,{components:t,mdxType:"MDXLayout"}),(0,l.kt)("p",null,"\u64ad\u653e\u5668\u7684\u4e8b\u4ef6\u5206\u4e3a\u4e24\u79cd\uff0c\u4e00\u79cd\u89c6\u9891\u7684\u539f\u751f\u4e8b\u4ef6\uff0c\u53e6\u5916\u4e00\u79cd\u662f\u81ea\u5b9a\u4e49\u7684\u4e8b\u4ef6\u3002\u539f\u751f\u4e8b\u4ef6\u6765\u81ea ",(0,l.kt)("inlineCode",{parentName:"p"},"video")," \u5143\u7d20\uff0c\u662f\u76f4\u63a5\u76d1\u542c",(0,l.kt)("inlineCode",{parentName:"p"},"video"),"\u5143\u7d20\u7684\u539f\u59cb\u4e8b\u4ef6\uff0c\u4e3a\u4e86\u8ba9\u5b83\u548c\u81ea\u5b9a\u4e49\u4e8b\u4ef6\u5Line truncated
@@ -0,0 +1 @@
"use strict";(self.webpackChunkartplayer_document=self.webpackChunkartplayer_document||[]).push([[220],{876:function(e,t,n){n.d(t,{Zo:function(){return p},kt:function(){return c}});var a=n(2784);function r(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function l(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var a=Object.getOwnPropertySymbols(e);t&&(a=a.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,a)}return n}function o(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?l(Object(n),!0).forEach((function(t){r(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):l(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}function i(e,t){if(null==e)return{};var n,a,r=function(e,t){if(null==e)return{};var n,a,r={},l=Object.keys(e);for(a=0;a<l.length;a++)n=l[a],t.indexOf(n)>=0||(r[n]=e[n]);return r}(e,t);if(Object.getOwnPropertySymbols){var l=Object.getOwnPropertySymbols(e);for(a=0;a<l.length;a++)n=l[a],t.indexOf(n)>=0||Object.prototype.propertyIsEnumerable.call(e,n)&&(r[n]=e[n])}return r}var d=a.createContext({}),s=function(e){var t=a.useContext(d),n=t;return e&&(n="function"==typeof e?e(t):o(o({},t),e)),n},p=function(e){var t=s(e.components);return a.createElement(d.Provider,{value:t},e.children)},u={inlineCode:"code",wrapper:function(e){var t=e.children;return a.createElement(a.Fragment,{},t)}},m=a.forwardRef((function(e,t){var n=e.components,r=e.mdxType,l=e.originalType,d=e.parentName,p=i(e,["components","mdxType","originalType","parentName"]),m=s(n),c=r,k=m["".concat(d,".").concat(c)]||m[c]||u[c]||l;return n?a.createElement(k,o(o({ref:t},p),{},{components:n})):a.createElement(k,o({ref:t},p))}));function c(e,t){var n=arguments,r=t&&t.mdxType;if("string"==typeof e||r){var l=n.length,o=new Array(l);o[0]=m;var i={};for(var d in t)hasOwnProperty.call(t,d)&&(i[d]=t[d]);i.originalType=e,i.mdxType="string"==typeof e?e:r,o[1]=i;for(var s=2;s<l;s++)o[s]=n[s];return a.createElement.apply(null,o)}return a.createElement.apply(null,n)}m.displayName="MDXCreateElement"},9991:function(e,t,n){n.r(t),n.d(t,{assets:function(){return p},contentTitle:function(){return d},default:function(){return c},frontMatter:function(){return i},metadata:function(){return s},toc:function(){return u}});var a=n(7896),r=n(1461),l=(n(2784),n(876)),o=["components"],i={title:"\u5b9e\u4f8b\u4e8b\u4ef6",sidebar_position:6,slug:"/zh-cn/events"},d=void 0,s={unversionedId:"zh-cn/Events",id:"zh-cn/Events",title:"\u5b9e\u4f8b\u4e8b\u4ef6",description:"\u64ad\u653e\u5668\u7684\u4e8b\u4ef6\u5206\u4e3a\u4e24\u79cd\uff0c\u4e00\u79cd\u89c6\u9891\u7684\u539f\u751f\u4e8b\u4ef6\uff0c\u53e6\u5916\u4e00\u79cd\u662f\u81ea\u5b9a\u4e49\u7684\u4e8b\u4ef6\u3002\u539f\u751f\u4e8b\u4ef6\u6765\u81ea video \u5143\u7d20\uff0c\u662f\u76f4\u63a5\u76d1\u542cvideo\u5143\u7d20\u7684\u539f\u59cb\u4e8b\u4ef6\uff0c\u4e3a\u4e86\u8ba9\u5b83\u548c\u81ea\u5b9a\u4e49\u4e8b\u4ef6\u533a\u5206\uff0c\u539f\u751f\u4e8b\u4ef6\u6dfb\u52a0\u4e86\u524d\u7f00 video:",source:"@site/docs/zh-cn/Events.mdx",sourceDirName:"zh-cn",slug:"/zh-cn/events",permalink:"/document/zh-cn/events",draft:!1,tags:[],version:"current",sidebarPosition:6,frontMatter:{title:"\u5b9e\u4f8b\u4e8b\u4ef6",sidebar_position:6,slug:"/zh-cn/events"},sidebar:"zh-cn",previous:{title:"\u9759\u6001\u5c5e\u6027",permalink:"/document/zh-cn/class"},next:{title:"\u7b2c\u4e09\u65b9\u5e93",permalink:"/document/zh-cn/libraries"}},p={},u=[{value:"\u539f\u751f\u4e8b\u4ef6",id:"\u539f\u751f\u4e8b\u4ef6",level:2},{value:"\u81ea\u5b9a\u4e49\u4e8b\u4ef6",id:"\u81ea\u5b9a\u4e49\u4e8b\u4ef6",level:2},{value:"ready",id:"ready",level:3},{value:"play",id:"play",level:3},{value:"pause",id:"pause",level:3},{value:"seek",id:"seek",level:3},{value:"volume",id:"volume",level:3},{value:"destroy",id:"destroy",level:3},{value:"focus",id:"focus",level:3},{value:"blur",id:"blur",level:3},{value:"hover",id:"hover",level:3},{value:"resize",id:"resize",level:3},{value:"mousemove",id:"mousemove",level:3},{value:"url",id:"url",level:3},{value:"fullscreen",id:"fullscreen",level:3},{value:"fullscreenWeb",id:"fullscreenweb",level:3},{value:"hotkey",id:"hotkey",level:3}],m={toc:u};function c(e){var t=e.components,n=(0,r.Z)(e,o);return(0,l.kt)("wrapper",(0,a.Z)({},m,n,{components:t,mdxType:"MDXLayout"}),(0,l.kt)("p",null,"\u64ad\u653e\u5668\u7684\u4e8b\u4ef6\u5206\u4e3a\u4e24\u79cd\uff0c\u4e00\u79cd\u89c6\u9891\u7684\u539f\u751f\u4e8b\u4ef6\uff0c\u53e6\u5916\u4e00\u79cd\u662f\u81ea\u5b9a\u4e49\u7684\u4e8b\u4ef6\u3002\u539f\u751f\u4e8b\u4ef6\u6765\u81ea ",(0,l.kt)("inlineCode",{parentName:"p"},"video")," \u5143\u7d20\uff0c\u662f\u76f4\u63a5\u76d1\u542c",(0,l.kt)("inlineCode",{parentName:"p"},"video"),"\u5143\u7d20\u7684\u539f\u59cb\u4e8b\u4ef6\uff0c\u4e3a\u4e86\u8ba9\u5b83\u548c\u81ea\u5b9a\u4e49\u4e8b\u4ef6\u533Line truncated
+1
View File
@@ -0,0 +1 @@
"use strict";(self.webpackChunkartplayer_document=self.webpackChunkartplayer_document||[]).push([[605],{6605:function(e,t,u){u.r(t)}}]);
-1
View File
@@ -1 +0,0 @@
"use strict";(self.webpackChunkartplayer_document=self.webpackChunkartplayer_document||[]).push([[608],{4608:function(e,t,n){n.r(t),n.d(t,{default:function(){return c}});var a=n(7294),l=n(3460),o=n(5999),r=n(1944);function c(){return a.createElement(a.Fragment,null,a.createElement(r.d,{title:(0,o.I)({id:"theme.NotFound.title",message:"Page Not Found"})}),a.createElement(l.Z,null,a.createElement("main",{className:"container margin-vert--xl"},a.createElement("div",{className:"row"},a.createElement("div",{className:"col col--6 col--offset-3"},a.createElement("h1",{className:"hero__title"},a.createElement(o.Z,{id:"theme.NotFound.title",description:"The title of the 404 page"},"Page Not Found")),a.createElement("p",null,a.createElement(o.Z,{id:"theme.NotFound.p1",description:"The first paragraph of the 404 page"},"We could not find what you were looking for.")),a.createElement("p",null,a.createElement(o.Z,{id:"theme.NotFound.p2",description:"The 2nd paragraph of the 404 page"},"Please contact the owner of the site that linked you to the original URL and let them know their link is broken.")))))))}}}]);
@@ -0,0 +1 @@
"use strict";(self.webpackChunkartplayer_document=self.webpackChunkartplayer_document||[]).push([[48],{876:function(e,n,t){t.d(n,{Zo:function(){return u},kt:function(){return c}});var a=t(2784);function l(e,n,t){return n in e?Object.defineProperty(e,n,{value:t,enumerable:!0,configurable:!0,writable:!0}):e[n]=t,e}function r(e,n){var t=Object.keys(e);if(Object.getOwnPropertySymbols){var a=Object.getOwnPropertySymbols(e);n&&(a=a.filter((function(n){return Object.getOwnPropertyDescriptor(e,n).enumerable}))),t.push.apply(t,a)}return t}function i(e){for(var n=1;n<arguments.length;n++){var t=null!=arguments[n]?arguments[n]:{};n%2?r(Object(t),!0).forEach((function(n){l(e,n,t[n])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(t)):r(Object(t)).forEach((function(n){Object.defineProperty(e,n,Object.getOwnPropertyDescriptor(t,n))}))}return e}function p(e,n){if(null==e)return{};var t,a,l=function(e,n){if(null==e)return{};var t,a,l={},r=Object.keys(e);for(a=0;a<r.length;a++)t=r[a],n.indexOf(t)>=0||(l[t]=e[t]);return l}(e,n);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);for(a=0;a<r.length;a++)t=r[a],n.indexOf(t)>=0||Object.prototype.propertyIsEnumerable.call(e,t)&&(l[t]=e[t])}return l}var o=a.createContext({}),s=function(e){var n=a.useContext(o),t=n;return e&&(t="function"==typeof e?e(n):i(i({},n),e)),t},u=function(e){var n=s(e.components);return a.createElement(o.Provider,{value:n},e.children)},d={inlineCode:"code",wrapper:function(e){var n=e.children;return a.createElement(a.Fragment,{},n)}},m=a.forwardRef((function(e,n){var t=e.components,l=e.mdxType,r=e.originalType,o=e.parentName,u=p(e,["components","mdxType","originalType","parentName"]),m=s(t),c=l,k=m["".concat(o,".").concat(c)]||m[c]||d[c]||r;return t?a.createElement(k,i(i({ref:n},u),{},{components:t})):a.createElement(k,i({ref:n},u))}));function c(e,n){var t=arguments,l=n&&n.mdxType;if("string"==typeof e||l){var r=t.length,i=new Array(r);i[0]=m;var p={};for(var o in n)hasOwnProperty.call(n,o)&&(p[o]=n[o]);p.originalType=e,p.mdxType="string"==typeof e?e:l,i[1]=p;for(var s=2;s<r;s++)i[s]=t[s];return a.createElement.apply(null,i)}return a.createElement.apply(null,t)}m.displayName="MDXCreateElement"},1314:function(e,n,t){t.r(n),t.d(n,{assets:function(){return u},contentTitle:function(){return o},default:function(){return c},frontMatter:function(){return p},metadata:function(){return s},toc:function(){return d}});var a=t(7896),l=t(1461),r=(t(2784),t(876)),i=["components"],p={title:"\u5e38\u7528\u5c5e\u6027",sidebar_position:3,slug:"/zh-cn/propertie"},o=void 0,s={unversionedId:"zh-cn/Properties",id:"zh-cn/Properties",title:"\u5e38\u7528\u5c5e\u6027",description:"play",source:"@site/docs/zh-cn/Properties.mdx",sourceDirName:"zh-cn",slug:"/zh-cn/propertie",permalink:"/document/zh-cn/propertie",draft:!1,tags:[],version:"current",sidebarPosition:3,frontMatter:{title:"\u5e38\u7528\u5c5e\u6027",sidebar_position:3,slug:"/zh-cn/propertie"},sidebar:"zh-cn",previous:{title:"\u57fa\u7840\u53c2\u6570",permalink:"/document/zh-cn/options"},next:{title:"\u9ad8\u7ea7\u5c5e\u6027",permalink:"/document/zh-cn/advance"}},u={},d=[{value:"play",id:"play",level:2},{value:"pause",id:"pause",level:2},{value:"toggle",id:"toggle",level:2},{value:"seek",id:"seek",level:2},{value:"forward",id:"forward",level:2},{value:"backward",id:"backward",level:2},{value:"volume",id:"volume",level:2},{value:"url",id:"url",level:2},{value:"switchUrl",id:"switchurl",level:2},{value:"switchQuality",id:"switchquality",level:2},{value:"muted",id:"muted",level:2},{value:"currentTime",id:"currenttime",level:2},{value:"duration",id:"duration",level:2},{value:"screenshot",id:"screenshot",level:2},{value:"getDataURL",id:"getdataurl",level:2},{value:"getBlobUrl",id:"getbloburl",level:2},{value:"fullscreen",id:"fullscreen",level:2},{value:"fullscreenWeb",id:"fullscreenweb",level:2},{value:"pip",id:"pip",level:2},{value:"poster",id:"poster",level:2},{value:"mini",id:"mini",level:2},{value:"playing",id:"playing",level:2},{value:"autoSize",id:"autosize",level:2},{value:"rect",id:"rect",level:2},{value:"flip",id:"flip",level:2},{value:"playbackRate",id:"playbackrate",level:2},{value:"aspectRatio",id:"aspectratio",level:2},{value:"loop",id:"loop",level:2},{value:"autoHeight",id:"autoheight",level:2},{value:"attr",id:"attr",level:2},{value:"title",id:"title",level:2},{value:"theme",id:"theme",level:2},{value:"airplay",id:"airplay",level:2},{value:"destroy",id:"destroy",level:2}],m={toc:d};function c(e){var n=e.components,t=(0,l.Z)(e,i);return(0,r.kt)("wrapper",(0,a.Z)({},m,t,{components:n,mdxType:"MDXLayout"}),(0,r.kt)("h2",{id:"play"},"play"),(0,r.kt)("ul",null,(0,r.kt)("li",{parentName:"ul"},"\u7c7b\u578b: ",(0,r.kt)("inlineCode",{parentName:"li"},"Function"))),(0,r.kt)("p",null,"\u64ad\u653e\u89c6\u9891"),(0,r.kt)("div",{className:"run-code"},"\u25b6 Run Code"),(0,r.kt)("pre",null,(0,r.kt)("code",{parentName:"pre",className:"language-js"},"var art = new Line truncated
@@ -1 +0,0 @@
"use strict";(self.webpackChunkartplayer_document=self.webpackChunkartplayer_document||[]).push([[48],{3905:function(e,n,t){t.d(n,{Zo:function(){return u},kt:function(){return c}});var a=t(7294);function l(e,n,t){return n in e?Object.defineProperty(e,n,{value:t,enumerable:!0,configurable:!0,writable:!0}):e[n]=t,e}function r(e,n){var t=Object.keys(e);if(Object.getOwnPropertySymbols){var a=Object.getOwnPropertySymbols(e);n&&(a=a.filter((function(n){return Object.getOwnPropertyDescriptor(e,n).enumerable}))),t.push.apply(t,a)}return t}function i(e){for(var n=1;n<arguments.length;n++){var t=null!=arguments[n]?arguments[n]:{};n%2?r(Object(t),!0).forEach((function(n){l(e,n,t[n])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(t)):r(Object(t)).forEach((function(n){Object.defineProperty(e,n,Object.getOwnPropertyDescriptor(t,n))}))}return e}function p(e,n){if(null==e)return{};var t,a,l=function(e,n){if(null==e)return{};var t,a,l={},r=Object.keys(e);for(a=0;a<r.length;a++)t=r[a],n.indexOf(t)>=0||(l[t]=e[t]);return l}(e,n);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);for(a=0;a<r.length;a++)t=r[a],n.indexOf(t)>=0||Object.prototype.propertyIsEnumerable.call(e,t)&&(l[t]=e[t])}return l}var o=a.createContext({}),s=function(e){var n=a.useContext(o),t=n;return e&&(t="function"==typeof e?e(n):i(i({},n),e)),t},u=function(e){var n=s(e.components);return a.createElement(o.Provider,{value:n},e.children)},d={inlineCode:"code",wrapper:function(e){var n=e.children;return a.createElement(a.Fragment,{},n)}},m=a.forwardRef((function(e,n){var t=e.components,l=e.mdxType,r=e.originalType,o=e.parentName,u=p(e,["components","mdxType","originalType","parentName"]),m=s(t),c=l,k=m["".concat(o,".").concat(c)]||m[c]||d[c]||r;return t?a.createElement(k,i(i({ref:n},u),{},{components:t})):a.createElement(k,i({ref:n},u))}));function c(e,n){var t=arguments,l=n&&n.mdxType;if("string"==typeof e||l){var r=t.length,i=new Array(r);i[0]=m;var p={};for(var o in n)hasOwnProperty.call(n,o)&&(p[o]=n[o]);p.originalType=e,p.mdxType="string"==typeof e?e:l,i[1]=p;for(var s=2;s<r;s++)i[s]=t[s];return a.createElement.apply(null,i)}return a.createElement.apply(null,t)}m.displayName="MDXCreateElement"},4387:function(e,n,t){t.r(n),t.d(n,{assets:function(){return u},contentTitle:function(){return o},default:function(){return c},frontMatter:function(){return p},metadata:function(){return s},toc:function(){return d}});var a=t(7462),l=t(3366),r=(t(7294),t(3905)),i=["components"],p={title:"\u5e38\u7528\u5c5e\u6027",sidebar_position:3,slug:"/zh-cn/propertie"},o=void 0,s={unversionedId:"zh-cn/Properties",id:"zh-cn/Properties",title:"\u5e38\u7528\u5c5e\u6027",description:"play",source:"@site/docs/zh-cn/Properties.mdx",sourceDirName:"zh-cn",slug:"/zh-cn/propertie",permalink:"/document/zh-cn/propertie",draft:!1,tags:[],version:"current",sidebarPosition:3,frontMatter:{title:"\u5e38\u7528\u5c5e\u6027",sidebar_position:3,slug:"/zh-cn/propertie"},sidebar:"zh-cn",previous:{title:"\u57fa\u7840\u53c2\u6570",permalink:"/document/zh-cn/options"},next:{title:"\u9ad8\u7ea7\u5c5e\u6027",permalink:"/document/zh-cn/advance"}},u={},d=[{value:"play",id:"play",level:2},{value:"pause",id:"pause",level:2},{value:"toggle",id:"toggle",level:2},{value:"seek",id:"seek",level:2},{value:"forward",id:"forward",level:2},{value:"backward",id:"backward",level:2},{value:"volume",id:"volume",level:2},{value:"url",id:"url",level:2},{value:"switchUrl",id:"switchurl",level:2},{value:"switchQuality",id:"switchquality",level:2},{value:"muted",id:"muted",level:2},{value:"currentTime",id:"currenttime",level:2},{value:"duration",id:"duration",level:2},{value:"screenshot",id:"screenshot",level:2},{value:"getDataURL",id:"getdataurl",level:2},{value:"getBlobUrl",id:"getbloburl",level:2},{value:"fullscreen",id:"fullscreen",level:2},{value:"fullscreenWeb",id:"fullscreenweb",level:2},{value:"pip",id:"pip",level:2},{value:"poster",id:"poster",level:2},{value:"mini",id:"mini",level:2},{value:"playing",id:"playing",level:2},{value:"autoSize",id:"autosize",level:2},{value:"rect",id:"rect",level:2},{value:"flip",id:"flip",level:2},{value:"playbackRate",id:"playbackrate",level:2},{value:"aspectRatio",id:"aspectratio",level:2},{value:"loop",id:"loop",level:2},{value:"autoHeight",id:"autoheight",level:2},{value:"attr",id:"attr",level:2},{value:"title",id:"title",level:2},{value:"theme",id:"theme",level:2},{value:"destroy",id:"destroy",level:2}],m={toc:d};function c(e){var n=e.components,t=(0,l.Z)(e,i);return(0,r.kt)("wrapper",(0,a.Z)({},m,t,{components:n,mdxType:"MDXLayout"}),(0,r.kt)("h2",{id:"play"},"play"),(0,r.kt)("ul",null,(0,r.kt)("li",{parentName:"ul"},"\u7c7b\u578b: ",(0,r.kt)("inlineCode",{parentName:"li"},"Function"))),(0,r.kt)("p",null,"\u64ad\u653e\u89c6\u9891"),(0,r.kt)("div",{className:"run-code"},"\u25b6 Run Code"),(0,r.kt)("pre",null,(0,r.kt)("code",{parentName:"pre",className:"language-js"},"var art = new Artplayer({\n container: '.artplayLine truncated
@@ -1 +0,0 @@
"use strict";(self.webpackChunkartplayer_document=self.webpackChunkartplayer_document||[]).push([[359],{3905:function(e,t,n){n.d(t,{Zo:function(){return u},kt:function(){return c}});var a=n(7294);function r(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function l(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var a=Object.getOwnPropertySymbols(e);t&&(a=a.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,a)}return n}function i(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?l(Object(n),!0).forEach((function(t){r(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):l(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}function o(e,t){if(null==e)return{};var n,a,r=function(e,t){if(null==e)return{};var n,a,r={},l=Object.keys(e);for(a=0;a<l.length;a++)n=l[a],t.indexOf(n)>=0||(r[n]=e[n]);return r}(e,t);if(Object.getOwnPropertySymbols){var l=Object.getOwnPropertySymbols(e);for(a=0;a<l.length;a++)n=l[a],t.indexOf(n)>=0||Object.prototype.propertyIsEnumerable.call(e,n)&&(r[n]=e[n])}return r}var p=a.createContext({}),s=function(e){var t=a.useContext(p),n=t;return e&&(n="function"==typeof e?e(t):i(i({},t),e)),n},u=function(e){var t=s(e.components);return a.createElement(p.Provider,{value:t},e.children)},d={inlineCode:"code",wrapper:function(e){var t=e.children;return a.createElement(a.Fragment,{},t)}},m=a.forwardRef((function(e,t){var n=e.components,r=e.mdxType,l=e.originalType,p=e.parentName,u=o(e,["components","mdxType","originalType","parentName"]),m=s(n),c=r,k=m["".concat(p,".").concat(c)]||m[c]||d[c]||l;return n?a.createElement(k,i(i({ref:t},u),{},{components:n})):a.createElement(k,i({ref:t},u))}));function c(e,t){var n=arguments,r=t&&t.mdxType;if("string"==typeof e||r){var l=n.length,i=new Array(l);i[0]=m;var o={};for(var p in t)hasOwnProperty.call(t,p)&&(o[p]=t[p]);o.originalType=e,o.mdxType="string"==typeof e?e:r,i[1]=o;for(var s=2;s<l;s++)i[s]=n[s];return a.createElement.apply(null,i)}return a.createElement.apply(null,n)}m.displayName="MDXCreateElement"},5883:function(e,t,n){n.r(t),n.d(t,{assets:function(){return u},contentTitle:function(){return p},default:function(){return c},frontMatter:function(){return o},metadata:function(){return s},toc:function(){return d}});var a=n(7462),r=n(3366),l=(n(7294),n(3905)),i=["components"],o={title:"Common properties",sidebar_position:3,slug:"/propertie"},p=void 0,s={unversionedId:"en/Properties",id:"en/Properties",title:"Common properties",description:"play",source:"@site/docs/en/Properties.mdx",sourceDirName:"en",slug:"/propertie",permalink:"/document/propertie",draft:!1,tags:[],version:"current",sidebarPosition:3,frontMatter:{title:"Common properties",sidebar_position:3,slug:"/propertie"},sidebar:"en",previous:{title:"Basic options",permalink:"/document/options"},next:{title:"Advanced propertys",permalink:"/document/advance"}},u={},d=[{value:"play",id:"play",level:2},{value:"pause",id:"pause",level:2},{value:"toggle",id:"toggle",level:2},{value:"seek",id:"seek",level:2},{value:"forward",id:"forward",level:2},{value:"backward",id:"backward",level:2},{value:"volume",id:"volume",level:2},{value:"url",id:"url",level:2},{value:"switchUrl",id:"switchurl",level:2},{value:"switchQuality",id:"switchquality",level:2},{value:"muted",id:"muted",level:2},{value:"currentTime",id:"currenttime",level:2},{value:"duration",id:"duration",level:2},{value:"screenshot",id:"screenshot",level:2},{value:"getDataURL",id:"getdataurl",level:2},{value:"getBlobUrl",id:"getbloburl",level:2},{value:"fullscreen",id:"fullscreen",level:2},{value:"fullscreenWeb",id:"fullscreenweb",level:2},{value:"pip",id:"pip",level:2},{value:"poster",id:"poster",level:2},{value:"mini",id:"mini",level:2},{value:"playing",id:"playing",level:2},{value:"autoSize",id:"autosize",level:2},{value:"rect",id:"rect",level:2},{value:"flip",id:"flip",level:2},{value:"playbackRate",id:"playbackrate",level:2},{value:"aspectRatio",id:"aspectratio",level:2},{value:"loop",id:"loop",level:2},{value:"autoHeight",id:"autoheight",level:2},{value:"attr",id:"attr",level:2},{value:"title",id:"title",level:2},{value:"theme",id:"theme",level:2},{value:"destroy",id:"destroy",level:2}],m={toc:d};function c(e){var t=e.components,n=(0,r.Z)(e,i);return(0,l.kt)("wrapper",(0,a.Z)({},m,n,{components:t,mdxType:"MDXLayout"}),(0,l.kt)("h2",{id:"play"},"play"),(0,l.kt)("ul",null,(0,l.kt)("li",{parentName:"ul"},"Type: ",(0,l.kt)("inlineCode",{parentName:"li"},"Function"))),(0,l.kt)("p",null,"Play video"),(0,l.kt)("div",{className:"run-code"},"\u25b6 Run Code"),(0,l.kt)("pre",null,(0,l.kt)("code",{parentName:"pre",className:"language-js"},"var art = new Artplayer({\n container: '.artplayer-app',\n url: '/assets/sample/video.mp4',\n muted: true,\n});\n\nart.on('ready', () => {\n art.playLine truncated
@@ -0,0 +1 @@
"use strict";(self.webpackChunkartplayer_document=self.webpackChunkartplayer_document||[]).push([[359],{876:function(e,t,n){n.d(t,{Zo:function(){return u},kt:function(){return c}});var a=n(2784);function r(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function l(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var a=Object.getOwnPropertySymbols(e);t&&(a=a.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,a)}return n}function i(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?l(Object(n),!0).forEach((function(t){r(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):l(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}function o(e,t){if(null==e)return{};var n,a,r=function(e,t){if(null==e)return{};var n,a,r={},l=Object.keys(e);for(a=0;a<l.length;a++)n=l[a],t.indexOf(n)>=0||(r[n]=e[n]);return r}(e,t);if(Object.getOwnPropertySymbols){var l=Object.getOwnPropertySymbols(e);for(a=0;a<l.length;a++)n=l[a],t.indexOf(n)>=0||Object.prototype.propertyIsEnumerable.call(e,n)&&(r[n]=e[n])}return r}var p=a.createContext({}),s=function(e){var t=a.useContext(p),n=t;return e&&(n="function"==typeof e?e(t):i(i({},t),e)),n},u=function(e){var t=s(e.components);return a.createElement(p.Provider,{value:t},e.children)},d={inlineCode:"code",wrapper:function(e){var t=e.children;return a.createElement(a.Fragment,{},t)}},m=a.forwardRef((function(e,t){var n=e.components,r=e.mdxType,l=e.originalType,p=e.parentName,u=o(e,["components","mdxType","originalType","parentName"]),m=s(n),c=r,k=m["".concat(p,".").concat(c)]||m[c]||d[c]||l;return n?a.createElement(k,i(i({ref:t},u),{},{components:n})):a.createElement(k,i({ref:t},u))}));function c(e,t){var n=arguments,r=t&&t.mdxType;if("string"==typeof e||r){var l=n.length,i=new Array(l);i[0]=m;var o={};for(var p in t)hasOwnProperty.call(t,p)&&(o[p]=t[p]);o.originalType=e,o.mdxType="string"==typeof e?e:r,i[1]=o;for(var s=2;s<l;s++)i[s]=n[s];return a.createElement.apply(null,i)}return a.createElement.apply(null,n)}m.displayName="MDXCreateElement"},734:function(e,t,n){n.r(t),n.d(t,{assets:function(){return u},contentTitle:function(){return p},default:function(){return c},frontMatter:function(){return o},metadata:function(){return s},toc:function(){return d}});var a=n(7896),r=n(1461),l=(n(2784),n(876)),i=["components"],o={title:"Common properties",sidebar_position:3,slug:"/propertie"},p=void 0,s={unversionedId:"en/Properties",id:"en/Properties",title:"Common properties",description:"play",source:"@site/docs/en/Properties.mdx",sourceDirName:"en",slug:"/propertie",permalink:"/document/propertie",draft:!1,tags:[],version:"current",sidebarPosition:3,frontMatter:{title:"Common properties",sidebar_position:3,slug:"/propertie"},sidebar:"en",previous:{title:"Basic options",permalink:"/document/options"},next:{title:"Advanced propertys",permalink:"/document/advance"}},u={},d=[{value:"play",id:"play",level:2},{value:"pause",id:"pause",level:2},{value:"toggle",id:"toggle",level:2},{value:"seek",id:"seek",level:2},{value:"forward",id:"forward",level:2},{value:"backward",id:"backward",level:2},{value:"volume",id:"volume",level:2},{value:"url",id:"url",level:2},{value:"switchUrl",id:"switchurl",level:2},{value:"switchQuality",id:"switchquality",level:2},{value:"muted",id:"muted",level:2},{value:"currentTime",id:"currenttime",level:2},{value:"duration",id:"duration",level:2},{value:"screenshot",id:"screenshot",level:2},{value:"getDataURL",id:"getdataurl",level:2},{value:"getBlobUrl",id:"getbloburl",level:2},{value:"fullscreen",id:"fullscreen",level:2},{value:"fullscreenWeb",id:"fullscreenweb",level:2},{value:"pip",id:"pip",level:2},{value:"poster",id:"poster",level:2},{value:"mini",id:"mini",level:2},{value:"playing",id:"playing",level:2},{value:"autoSize",id:"autosize",level:2},{value:"rect",id:"rect",level:2},{value:"flip",id:"flip",level:2},{value:"playbackRate",id:"playbackrate",level:2},{value:"aspectRatio",id:"aspectratio",level:2},{value:"loop",id:"loop",level:2},{value:"autoHeight",id:"autoheight",level:2},{value:"attr",id:"attr",level:2},{value:"title",id:"title",level:2},{value:"theme",id:"theme",level:2},{value:"airplay",id:"airplay",level:2},{value:"destroy",id:"destroy",level:2}],m={toc:d};function c(e){var t=e.components,n=(0,r.Z)(e,i);return(0,l.kt)("wrapper",(0,a.Z)({},m,n,{components:t,mdxType:"MDXLayout"}),(0,l.kt)("h2",{id:"play"},"play"),(0,l.kt)("ul",null,(0,l.kt)("li",{parentName:"ul"},"Type: ",(0,l.kt)("inlineCode",{parentName:"li"},"Function"))),(0,l.kt)("p",null,"Play video"),(0,l.kt)("div",{className:"run-code"},"\u25b6 Run Code"),(0,l.kt)("pre",null,(0,l.kt)("code",{parentName:"pre",className:"language-js"},"var art = new Artplayer({\n container: '.artplayer-app',\n url: '/assets/sample/video.mp4',\n muted: true,\n});\n\naLine truncated
@@ -1 +0,0 @@
"use strict";(self.webpackChunkartplayer_document=self.webpackChunkartplayer_document||[]).push([[601],{3905:function(e,t,n){n.d(t,{Zo:function(){return u},kt:function(){return m}});var r=n(7294);function o(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function a(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,r)}return n}function i(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?a(Object(n),!0).forEach((function(t){o(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):a(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}function p(e,t){if(null==e)return{};var n,r,o=function(e,t){if(null==e)return{};var n,r,o={},a=Object.keys(e);for(r=0;r<a.length;r++)n=a[r],t.indexOf(n)>=0||(o[n]=e[n]);return o}(e,t);if(Object.getOwnPropertySymbols){var a=Object.getOwnPropertySymbols(e);for(r=0;r<a.length;r++)n=a[r],t.indexOf(n)>=0||Object.prototype.propertyIsEnumerable.call(e,n)&&(o[n]=e[n])}return o}var c=r.createContext({}),s=function(e){var t=r.useContext(c),n=t;return e&&(n="function"==typeof e?e(t):i(i({},t),e)),n},u=function(e){var t=s(e.components);return r.createElement(c.Provider,{value:t},e.children)},l={inlineCode:"code",wrapper:function(e){var t=e.children;return r.createElement(r.Fragment,{},t)}},y=r.forwardRef((function(e,t){var n=e.components,o=e.mdxType,a=e.originalType,c=e.parentName,u=p(e,["components","mdxType","originalType","parentName"]),y=s(n),m=o,f=y["".concat(c,".").concat(m)]||y[m]||l[m]||a;return n?r.createElement(f,i(i({ref:t},u),{},{components:n})):r.createElement(f,i({ref:t},u))}));function m(e,t){var n=arguments,o=t&&t.mdxType;if("string"==typeof e||o){var a=n.length,i=new Array(a);i[0]=y;var p={};for(var c in t)hasOwnProperty.call(t,c)&&(p[c]=t[c]);p.originalType=e,p.mdxType="string"==typeof e?e:o,i[1]=p;for(var s=2;s<a;s++)i[s]=n[s];return r.createElement.apply(null,i)}return r.createElement.apply(null,n)}y.displayName="MDXCreateElement"},7702:function(e,t,n){n.r(t),n.d(t,{assets:function(){return u},contentTitle:function(){return c},default:function(){return m},frontMatter:function(){return p},metadata:function(){return s},toc:function(){return l}});var r=n(7462),o=n(3366),a=(n(7294),n(3905)),i=["components"],p={title:"How to import types",sidebar_position:4},c=void 0,s={unversionedId:"en/Questions/How_to_import_types",id:"en/Questions/How_to_import_types",title:"How to import types",description:"Sometimes you lose TypeScript syntax prompt, then you can import types manually",source:"@site/docs/en/Questions/How_to_import_types.mdx",sourceDirName:"en/Questions",slug:"/en/Questions/How_to_import_types",permalink:"/document/en/Questions/How_to_import_types",draft:!1,tags:[],version:"current",sidebarPosition:4,frontMatter:{title:"How to import types",sidebar_position:4},sidebar:"en",previous:{title:"Handle a single component",permalink:"/document/en/Questions/Handle_single_component"},next:{title:"How to add video ads",permalink:"/document/en/Questions/How_to_add_video_ads"}},u={},l=[],y={toc:l};function m(e){var t=e.components,n=(0,o.Z)(e,i);return(0,a.kt)("wrapper",(0,r.Z)({},y,n,{components:t,mdxType:"MDXLayout"}),(0,a.kt)("p",null,"Sometimes you lose ",(0,a.kt)("inlineCode",{parentName:"p"},"TypeScript")," syntax prompt, then you can import types manually"),(0,a.kt)("pre",null,(0,a.kt)("code",{parentName:"pre",className:"language-js"},'/**\n * @typedef { import("artplayer/types/artplayer") } Artplayer\n */\n\n/**\n * @type {Artplayer} - An Artplayer instance.\n */\nconst art1 = {};\n\n/**\n * @param {Artplayer} art2 - An Artplayer instance.\n */\nfunction getInstance(art2) {\n //\n}\n')))}m.isMDXComponent=!0}}]);
@@ -0,0 +1 @@
"use strict";(self.webpackChunkartplayer_document=self.webpackChunkartplayer_document||[]).push([[601],{876:function(e,t,n){n.d(t,{Zo:function(){return u},kt:function(){return m}});var r=n(2784);function o(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function a(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,r)}return n}function i(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?a(Object(n),!0).forEach((function(t){o(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):a(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}function p(e,t){if(null==e)return{};var n,r,o=function(e,t){if(null==e)return{};var n,r,o={},a=Object.keys(e);for(r=0;r<a.length;r++)n=a[r],t.indexOf(n)>=0||(o[n]=e[n]);return o}(e,t);if(Object.getOwnPropertySymbols){var a=Object.getOwnPropertySymbols(e);for(r=0;r<a.length;r++)n=a[r],t.indexOf(n)>=0||Object.prototype.propertyIsEnumerable.call(e,n)&&(o[n]=e[n])}return o}var c=r.createContext({}),s=function(e){var t=r.useContext(c),n=t;return e&&(n="function"==typeof e?e(t):i(i({},t),e)),n},u=function(e){var t=s(e.components);return r.createElement(c.Provider,{value:t},e.children)},l={inlineCode:"code",wrapper:function(e){var t=e.children;return r.createElement(r.Fragment,{},t)}},y=r.forwardRef((function(e,t){var n=e.components,o=e.mdxType,a=e.originalType,c=e.parentName,u=p(e,["components","mdxType","originalType","parentName"]),y=s(n),m=o,f=y["".concat(c,".").concat(m)]||y[m]||l[m]||a;return n?r.createElement(f,i(i({ref:t},u),{},{components:n})):r.createElement(f,i({ref:t},u))}));function m(e,t){var n=arguments,o=t&&t.mdxType;if("string"==typeof e||o){var a=n.length,i=new Array(a);i[0]=y;var p={};for(var c in t)hasOwnProperty.call(t,c)&&(p[c]=t[c]);p.originalType=e,p.mdxType="string"==typeof e?e:o,i[1]=p;for(var s=2;s<a;s++)i[s]=n[s];return r.createElement.apply(null,i)}return r.createElement.apply(null,n)}y.displayName="MDXCreateElement"},5848:function(e,t,n){n.r(t),n.d(t,{assets:function(){return u},contentTitle:function(){return c},default:function(){return m},frontMatter:function(){return p},metadata:function(){return s},toc:function(){return l}});var r=n(7896),o=n(1461),a=(n(2784),n(876)),i=["components"],p={title:"How to import types",sidebar_position:4},c=void 0,s={unversionedId:"en/Questions/How_to_import_types",id:"en/Questions/How_to_import_types",title:"How to import types",description:"Sometimes you lose TypeScript syntax prompt, then you can import types manually",source:"@site/docs/en/Questions/How_to_import_types.mdx",sourceDirName:"en/Questions",slug:"/en/Questions/How_to_import_types",permalink:"/document/en/Questions/How_to_import_types",draft:!1,tags:[],version:"current",sidebarPosition:4,frontMatter:{title:"How to import types",sidebar_position:4},sidebar:"en",previous:{title:"Handle a single component",permalink:"/document/en/Questions/Handle_single_component"},next:{title:"How to add setting panel",permalink:"/document/en/Questions/How_to_add_setting_panel"}},u={},l=[],y={toc:l};function m(e){var t=e.components,n=(0,o.Z)(e,i);return(0,a.kt)("wrapper",(0,r.Z)({},y,n,{components:t,mdxType:"MDXLayout"}),(0,a.kt)("p",null,"Sometimes you lose ",(0,a.kt)("inlineCode",{parentName:"p"},"TypeScript")," syntax prompt, then you can import types manually"),(0,a.kt)("pre",null,(0,a.kt)("code",{parentName:"pre",className:"language-js"},'/**\n * @typedef { import("artplayer/types/artplayer") } Artplayer\n */\n\n/**\n * @type {Artplayer} - An Artplayer instance.\n */\nconst art1 = {};\n\n/**\n * @param {Artplayer} art2 - An Artplayer instance.\n */\nfunction getInstance(art2) {\n //\n}\n')))}m.isMDXComponent=!0}}]);
@@ -0,0 +1 @@
"use strict";(self.webpackChunkartplayer_document=self.webpackChunkartplayer_document||[]).push([[667],{876:function(e,n,t){t.d(n,{Zo:function(){return p},kt:function(){return d}});var r=t(2784);function a(e,n,t){return n in e?Object.defineProperty(e,n,{value:t,enumerable:!0,configurable:!0,writable:!0}):e[n]=t,e}function o(e,n){var t=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);n&&(r=r.filter((function(n){return Object.getOwnPropertyDescriptor(e,n).enumerable}))),t.push.apply(t,r)}return t}function i(e){for(var n=1;n<arguments.length;n++){var t=null!=arguments[n]?arguments[n]:{};n%2?o(Object(t),!0).forEach((function(n){a(e,n,t[n])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(t)):o(Object(t)).forEach((function(n){Object.defineProperty(e,n,Object.getOwnPropertyDescriptor(t,n))}))}return e}function u(e,n){if(null==e)return{};var t,r,a=function(e,n){if(null==e)return{};var t,r,a={},o=Object.keys(e);for(r=0;r<o.length;r++)t=o[r],n.indexOf(t)>=0||(a[t]=e[t]);return a}(e,n);if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);for(r=0;r<o.length;r++)t=o[r],n.indexOf(t)>=0||Object.prototype.propertyIsEnumerable.call(e,t)&&(a[t]=e[t])}return a}var c=r.createContext({}),l=function(e){var n=r.useContext(c),t=n;return e&&(t="function"==typeof e?e(n):i(i({},n),e)),t},p=function(e){var n=l(e.components);return r.createElement(c.Provider,{value:n},e.children)},s={inlineCode:"code",wrapper:function(e){var n=e.children;return r.createElement(r.Fragment,{},n)}},m=r.forwardRef((function(e,n){var t=e.components,a=e.mdxType,o=e.originalType,c=e.parentName,p=u(e,["components","mdxType","originalType","parentName"]),m=l(t),d=a,f=m["".concat(c,".").concat(d)]||m[d]||s[d]||o;return t?r.createElement(f,i(i({ref:n},p),{},{components:t})):r.createElement(f,i({ref:n},p))}));function d(e,n){var t=arguments,a=n&&n.mdxType;if("string"==typeof e||a){var o=t.length,i=new Array(o);i[0]=m;var u={};for(var c in n)hasOwnProperty.call(n,c)&&(u[c]=n[c]);u.originalType=e,u.mdxType="string"==typeof e?e:a,i[1]=u;for(var l=2;l<o;l++)i[l]=t[l];return r.createElement.apply(null,i)}return r.createElement.apply(null,t)}m.displayName="MDXCreateElement"},1016:function(e,n,t){t.r(n),t.d(n,{assets:function(){return p},contentTitle:function(){return c},default:function(){return d},frontMatter:function(){return u},metadata:function(){return l},toc:function(){return s}});var r=t(7896),a=t(1461),o=(t(2784),t(876)),i=["components"],u={title:"Danmuku plugin",sidebar_position:1},c=void 0,l={unversionedId:"en/Plugins/danmuku",id:"en/Plugins/danmuku",title:"Danmuku plugin",description:"The documentation of the current danmaku library plug-in, only the Chinese version",source:"@site/docs/en/Plugins/danmuku.mdx",sourceDirName:"en/Plugins",slug:"/en/Plugins/danmuku",permalink:"/document/en/Plugins/danmuku",draft:!1,tags:[],version:"current",sidebarPosition:1,frontMatter:{title:"Danmuku plugin",sidebar_position:1},sidebar:"en",previous:{title:"Third party librarys",permalink:"/document/libraries"},next:{title:"Ads Plugin",permalink:"/document/en/Plugins/ads"}},p={},s=[],m={toc:s};function d(e){var n=e.components,t=(0,a.Z)(e,i);return(0,o.kt)("wrapper",(0,r.Z)({},m,t,{components:n,mdxType:"MDXLayout"}),(0,o.kt)("div",{className:"admonition admonition-danger alert alert--danger"},(0,o.kt)("div",{parentName:"div",className:"admonition-heading"},(0,o.kt)("h5",{parentName:"div"},(0,o.kt)("span",{parentName:"h5",className:"admonition-icon"},(0,o.kt)("svg",{parentName:"span",xmlns:"http://www.w3.org/2000/svg",width:"12",height:"16",viewBox:"0 0 12 16"},(0,o.kt)("path",{parentName:"svg",fillRule:"evenodd",d:"M5.05.31c.81 2.17.41 3.38-.52 4.31C3.55 5.67 1.98 6.45.9 7.98c-1.45 2.05-1.7 6.53 3.53 7.7-2.2-1.16-2.67-4.52-.3-6.61-.61 2.03.53 3.33 1.94 2.86 1.39-.47 2.3.53 2.27 1.67-.02.78-.31 1.44-1.13 1.81 3.42-.59 4.78-3.42 4.78-5.56 0-2.84-2.53-3.22-1.25-5.61-1.52.13-2.03 1.13-1.89 2.75.09 1.08-1.02 1.8-1.86 1.33-.67-.41-.66-1.19-.06-1.78C8.18 5.31 8.68 2.45 5.05.32L5.03.3l.02.01z"}))),"Tip")),(0,o.kt)("div",{parentName:"div",className:"admonition-content"},(0,o.kt)("p",{parentName:"div"},"The documentation of the current danmaku library plug-in, only the Chinese version"))),(0,o.kt)("p",null,"\ud83d\udc49 ",(0,o.kt)("a",{parentName:"p",href:"https://artplayer.org/document/zh-cn/Plugins/danmuku/"},"https://artplayer.org/document/zh-cn/Plugins/danmuku/")))}d.isMDXComponent=!0}}]);
@@ -1 +0,0 @@
"use strict";(self.webpackChunkartplayer_document=self.webpackChunkartplayer_document||[]).push([[667],{3905:function(e,n,t){t.d(n,{Zo:function(){return p},kt:function(){return d}});var r=t(7294);function a(e,n,t){return n in e?Object.defineProperty(e,n,{value:t,enumerable:!0,configurable:!0,writable:!0}):e[n]=t,e}function o(e,n){var t=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);n&&(r=r.filter((function(n){return Object.getOwnPropertyDescriptor(e,n).enumerable}))),t.push.apply(t,r)}return t}function i(e){for(var n=1;n<arguments.length;n++){var t=null!=arguments[n]?arguments[n]:{};n%2?o(Object(t),!0).forEach((function(n){a(e,n,t[n])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(t)):o(Object(t)).forEach((function(n){Object.defineProperty(e,n,Object.getOwnPropertyDescriptor(t,n))}))}return e}function u(e,n){if(null==e)return{};var t,r,a=function(e,n){if(null==e)return{};var t,r,a={},o=Object.keys(e);for(r=0;r<o.length;r++)t=o[r],n.indexOf(t)>=0||(a[t]=e[t]);return a}(e,n);if(Object.getOwnPropertySymbols){var o=Object.getOwnPropertySymbols(e);for(r=0;r<o.length;r++)t=o[r],n.indexOf(t)>=0||Object.prototype.propertyIsEnumerable.call(e,t)&&(a[t]=e[t])}return a}var c=r.createContext({}),l=function(e){var n=r.useContext(c),t=n;return e&&(t="function"==typeof e?e(n):i(i({},n),e)),t},p=function(e){var n=l(e.components);return r.createElement(c.Provider,{value:n},e.children)},s={inlineCode:"code",wrapper:function(e){var n=e.children;return r.createElement(r.Fragment,{},n)}},m=r.forwardRef((function(e,n){var t=e.components,a=e.mdxType,o=e.originalType,c=e.parentName,p=u(e,["components","mdxType","originalType","parentName"]),m=l(t),d=a,f=m["".concat(c,".").concat(d)]||m[d]||s[d]||o;return t?r.createElement(f,i(i({ref:n},p),{},{components:t})):r.createElement(f,i({ref:n},p))}));function d(e,n){var t=arguments,a=n&&n.mdxType;if("string"==typeof e||a){var o=t.length,i=new Array(o);i[0]=m;var u={};for(var c in n)hasOwnProperty.call(n,c)&&(u[c]=n[c]);u.originalType=e,u.mdxType="string"==typeof e?e:a,i[1]=u;for(var l=2;l<o;l++)i[l]=t[l];return r.createElement.apply(null,i)}return r.createElement.apply(null,t)}m.displayName="MDXCreateElement"},1856:function(e,n,t){t.r(n),t.d(n,{assets:function(){return p},contentTitle:function(){return c},default:function(){return d},frontMatter:function(){return u},metadata:function(){return l},toc:function(){return s}});var r=t(7462),a=t(3366),o=(t(7294),t(3905)),i=["components"],u={title:"Danmuku plugin",sidebar_position:1},c=void 0,l={unversionedId:"en/Plugins/danmuku",id:"en/Plugins/danmuku",title:"Danmuku plugin",description:"The documentation of the current danmaku library plug-in, only the Chinese version",source:"@site/docs/en/Plugins/danmuku.mdx",sourceDirName:"en/Plugins",slug:"/en/Plugins/danmuku",permalink:"/document/en/Plugins/danmuku",draft:!1,tags:[],version:"current",sidebarPosition:1,frontMatter:{title:"Danmuku plugin",sidebar_position:1},sidebar:"en",previous:{title:"Third party librarys",permalink:"/document/libraries"},next:{title:"Add select in the controls",permalink:"/document/en/Questions/Create_selector_in_the_controls"}},p={},s=[],m={toc:s};function d(e){var n=e.components,t=(0,a.Z)(e,i);return(0,o.kt)("wrapper",(0,r.Z)({},m,t,{components:n,mdxType:"MDXLayout"}),(0,o.kt)("div",{className:"admonition admonition-danger alert alert--danger"},(0,o.kt)("div",{parentName:"div",className:"admonition-heading"},(0,o.kt)("h5",{parentName:"div"},(0,o.kt)("span",{parentName:"h5",className:"admonition-icon"},(0,o.kt)("svg",{parentName:"span",xmlns:"http://www.w3.org/2000/svg",width:"12",height:"16",viewBox:"0 0 12 16"},(0,o.kt)("path",{parentName:"svg",fillRule:"evenodd",d:"M5.05.31c.81 2.17.41 3.38-.52 4.31C3.55 5.67 1.98 6.45.9 7.98c-1.45 2.05-1.7 6.53 3.53 7.7-2.2-1.16-2.67-4.52-.3-6.61-.61 2.03.53 3.33 1.94 2.86 1.39-.47 2.3.53 2.27 1.67-.02.78-.31 1.44-1.13 1.81 3.42-.59 4.78-3.42 4.78-5.56 0-2.84-2.53-3.22-1.25-5.61-1.52.13-2.03 1.13-1.89 2.75.09 1.08-1.02 1.8-1.86 1.33-.67-.41-.66-1.19-.06-1.78C8.18 5.31 8.68 2.45 5.05.32L5.03.3l.02.01z"}))),"Tip")),(0,o.kt)("div",{parentName:"div",className:"admonition-content"},(0,o.kt)("p",{parentName:"div"},"The documentation of the current danmaku library plug-in, only the Chinese version"))),(0,o.kt)("p",null,"\ud83d\udc49 ",(0,o.kt)("a",{parentName:"p",href:"https://artplayer.org/document/zh-cn/Plugins/danmuku/"},"https://artplayer.org/document/zh-cn/Plugins/danmuku/")))}d.isMDXComponent=!0}}]);
@@ -0,0 +1 @@
"use strict";(self.webpackChunkartplayer_document=self.webpackChunkartplayer_document||[]).push([[167],{876:function(e,t,n){n.d(t,{Zo:function(){return s},kt:function(){return y}});var r=n(2784);function o(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function i(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,r)}return n}function a(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?i(Object(n),!0).forEach((function(t){o(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):i(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}function c(e,t){if(null==e)return{};var n,r,o=function(e,t){if(null==e)return{};var n,r,o={},i=Object.keys(e);for(r=0;r<i.length;r++)n=i[r],t.indexOf(n)>=0||(o[n]=e[n]);return o}(e,t);if(Object.getOwnPropertySymbols){var i=Object.getOwnPropertySymbols(e);for(r=0;r<i.length;r++)n=i[r],t.indexOf(n)>=0||Object.prototype.propertyIsEnumerable.call(e,n)&&(o[n]=e[n])}return o}var p=r.createContext({}),u=function(e){var t=r.useContext(p),n=t;return e&&(n="function"==typeof e?e(t):a(a({},t),e)),n},s=function(e){var t=u(e.components);return r.createElement(p.Provider,{value:t},e.children)},l={inlineCode:"code",wrapper:function(e){var t=e.children;return r.createElement(r.Fragment,{},t)}},f=r.forwardRef((function(e,t){var n=e.components,o=e.mdxType,i=e.originalType,p=e.parentName,s=c(e,["components","mdxType","originalType","parentName"]),f=u(n),y=o,m=f["".concat(p,".").concat(y)]||f[y]||l[y]||i;return n?r.createElement(m,a(a({ref:t},s),{},{components:n})):r.createElement(m,a({ref:t},s))}));function y(e,t){var n=arguments,o=t&&t.mdxType;if("string"==typeof e||o){var i=n.length,a=new Array(i);a[0]=f;var c={};for(var p in t)hasOwnProperty.call(t,p)&&(c[p]=t[p]);c.originalType=e,c.mdxType="string"==typeof e?e:o,a[1]=c;for(var u=2;u<i;u++)a[u]=n[u];return r.createElement.apply(null,a)}return r.createElement.apply(null,n)}f.displayName="MDXCreateElement"},6562:function(e,t,n){n.r(t),n.d(t,{assets:function(){return s},contentTitle:function(){return p},default:function(){return y},frontMatter:function(){return c},metadata:function(){return u},toc:function(){return l}});var r=n(7896),o=n(1461),i=(n(2784),n(876)),a=["components"],c={title:"\u5982\u4f55\u5bfc\u5165\u7c7b\u578b",sidebar_position:4},p=void 0,u={unversionedId:"zh-cn/Questions/How_to_import_types",id:"zh-cn/Questions/How_to_import_types",title:"\u5982\u4f55\u5bfc\u5165\u7c7b\u578b",description:"\u6709\u65f6\u4f60\u4f1a\u4e22\u5931 TypeScript \u7684\u8bed\u6cd5\u63d0\u793a\uff0c\u8fd9\u65f6\u5019\u4f60\u53ef\u4ee5\u624b\u52a8\u5bfc\u5165\u7c7b\u578b",source:"@site/docs/zh-cn/Questions/How_to_import_types.mdx",sourceDirName:"zh-cn/Questions",slug:"/zh-cn/Questions/How_to_import_types",permalink:"/document/zh-cn/Questions/How_to_import_types",draft:!1,tags:[],version:"current",sidebarPosition:4,frontMatter:{title:"\u5982\u4f55\u5bfc\u5165\u7c7b\u578b",sidebar_position:4},sidebar:"zh-cn",previous:{title:"\u5904\u7406\u5355\u4e2a\u7ec4\u4ef6",permalink:"/document/zh-cn/Questions/Handle_single_component"},next:{title:"\u600e\u4e48\u6dfb\u52a0\u8bbe\u7f6e\u9762\u677f",permalink:"/document/zh-cn/Questions/How_to_add_setting_panel"}},s={},l=[],f={toc:l};function y(e){var t=e.components,n=(0,o.Z)(e,a);return(0,i.kt)("wrapper",(0,r.Z)({},f,n,{components:t,mdxType:"MDXLayout"}),(0,i.kt)("p",null,"\u6709\u65f6\u4f60\u4f1a\u4e22\u5931 ",(0,i.kt)("inlineCode",{parentName:"p"},"TypeScript")," \u7684\u8bed\u6cd5\u63d0\u793a\uff0c\u8fd9\u65f6\u5019\u4f60\u53ef\u4ee5\u624b\u52a8\u5bfc\u5165\u7c7b\u578b "),(0,i.kt)("pre",null,(0,i.kt)("code",{parentName:"pre",className:"language-js"},'/**\n * @typedef { import("artplayer/types/artplayer") } Artplayer\n */\n\n/**\n * @type {Artplayer} - \u4e00\u4e2a Artplayer \u5b9e\u4f8b\n */\nconst art1 = {};\n\n/**\n * @param {Artplayer} art2 - \u4e00\u4e2a Artplayer \u5b9e\u4f8b\n */\nfunction getInstance(art2) {\n //\n}\n')))}y.isMDXComponent=!0}}]);
@@ -1 +0,0 @@
"use strict";(self.webpackChunkartplayer_document=self.webpackChunkartplayer_document||[]).push([[167],{3905:function(e,t,n){n.d(t,{Zo:function(){return s},kt:function(){return y}});var r=n(7294);function o(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function i(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,r)}return n}function a(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?i(Object(n),!0).forEach((function(t){o(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):i(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}function c(e,t){if(null==e)return{};var n,r,o=function(e,t){if(null==e)return{};var n,r,o={},i=Object.keys(e);for(r=0;r<i.length;r++)n=i[r],t.indexOf(n)>=0||(o[n]=e[n]);return o}(e,t);if(Object.getOwnPropertySymbols){var i=Object.getOwnPropertySymbols(e);for(r=0;r<i.length;r++)n=i[r],t.indexOf(n)>=0||Object.prototype.propertyIsEnumerable.call(e,n)&&(o[n]=e[n])}return o}var p=r.createContext({}),u=function(e){var t=r.useContext(p),n=t;return e&&(n="function"==typeof e?e(t):a(a({},t),e)),n},s=function(e){var t=u(e.components);return r.createElement(p.Provider,{value:t},e.children)},l={inlineCode:"code",wrapper:function(e){var t=e.children;return r.createElement(r.Fragment,{},t)}},f=r.forwardRef((function(e,t){var n=e.components,o=e.mdxType,i=e.originalType,p=e.parentName,s=c(e,["components","mdxType","originalType","parentName"]),f=u(n),y=o,m=f["".concat(p,".").concat(y)]||f[y]||l[y]||i;return n?r.createElement(m,a(a({ref:t},s),{},{components:n})):r.createElement(m,a({ref:t},s))}));function y(e,t){var n=arguments,o=t&&t.mdxType;if("string"==typeof e||o){var i=n.length,a=new Array(i);a[0]=f;var c={};for(var p in t)hasOwnProperty.call(t,p)&&(c[p]=t[p]);c.originalType=e,c.mdxType="string"==typeof e?e:o,a[1]=c;for(var u=2;u<i;u++)a[u]=n[u];return r.createElement.apply(null,a)}return r.createElement.apply(null,n)}f.displayName="MDXCreateElement"},1288:function(e,t,n){n.r(t),n.d(t,{assets:function(){return s},contentTitle:function(){return p},default:function(){return y},frontMatter:function(){return c},metadata:function(){return u},toc:function(){return l}});var r=n(7462),o=n(3366),i=(n(7294),n(3905)),a=["components"],c={title:"\u5982\u4f55\u5bfc\u5165\u7c7b\u578b",sidebar_position:4},p=void 0,u={unversionedId:"zh-cn/Questions/How_to_import_types",id:"zh-cn/Questions/How_to_import_types",title:"\u5982\u4f55\u5bfc\u5165\u7c7b\u578b",description:"\u6709\u65f6\u4f60\u4f1a\u4e22\u5931 TypeScript \u7684\u8bed\u6cd5\u63d0\u793a\uff0c\u8fd9\u65f6\u5019\u4f60\u53ef\u4ee5\u624b\u52a8\u5bfc\u5165\u7c7b\u578b",source:"@site/docs/zh-cn/Questions/How_to_import_types.mdx",sourceDirName:"zh-cn/Questions",slug:"/zh-cn/Questions/How_to_import_types",permalink:"/document/zh-cn/Questions/How_to_import_types",draft:!1,tags:[],version:"current",sidebarPosition:4,frontMatter:{title:"\u5982\u4f55\u5bfc\u5165\u7c7b\u578b",sidebar_position:4},sidebar:"zh-cn",previous:{title:"\u5904\u7406\u5355\u4e2a\u7ec4\u4ef6",permalink:"/document/zh-cn/Questions/Handle_single_component"},next:{title:"\u5982\u4f55\u6dfb\u52a0\u89c6\u9891\u5e7f\u544a",permalink:"/document/zh-cn/Questions/How_to_add_video_ads"}},s={},l=[],f={toc:l};function y(e){var t=e.components,n=(0,o.Z)(e,a);return(0,i.kt)("wrapper",(0,r.Z)({},f,n,{components:t,mdxType:"MDXLayout"}),(0,i.kt)("p",null,"\u6709\u65f6\u4f60\u4f1a\u4e22\u5931 ",(0,i.kt)("inlineCode",{parentName:"p"},"TypeScript")," \u7684\u8bed\u6cd5\u63d0\u793a\uff0c\u8fd9\u65f6\u5019\u4f60\u53ef\u4ee5\u624b\u52a8\u5bfc\u5165\u7c7b\u578b "),(0,i.kt)("pre",null,(0,i.kt)("code",{parentName:"pre",className:"language-js"},'/**\n * @typedef { import("artplayer/types/artplayer") } Artplayer\n */\n\n/**\n * @type {Artplayer} - \u4e00\u4e2a Artplayer \u5b9e\u4f8b\n */\nconst art1 = {};\n\n/**\n * @param {Artplayer} art2 - \u4e00\u4e2a Artplayer \u5b9e\u4f8b\n */\nfunction getInstance(art2) {\n //\n}\n')))}y.isMDXComponent=!0}}]);
@@ -1,2 +1,2 @@
/*! For license information please see 878.0f9d5667.js.LICENSE.txt */
(self.webpackChunkartplayer_document=self.webpackChunkartplayer_document||[]).push([[878],{1639:function(e,t,n){"use strict";e.exports=n(9281)},7114:function(e,t,n){"use strict";var i=n(5670),r={wrapper:{position:"relative",display:"inline-block"},hint:{position:"absolute",top:"0",left:"0",borderColor:"transparent",boxShadow:"none",opacity:"1"},input:{position:"relative",verticalAlign:"top",backgroundColor:"transparent"},inputWithNoHint:{position:"relative",verticalAlign:"top"},dropdown:{position:"absolute",top:"100%",left:"0",zIndex:"100",display:"none"},suggestions:{display:"block"},suggestion:{whiteSpace:"nowrap",cursor:"pointer"},suggestionChild:{whiteSpace:"normal"},ltr:{left:"0",right:"auto"},rtl:{left:"auto",right:"0"},defaultClasses:{root:"algolia-autocomplete",prefix:"aa",noPrefix:!1,dropdownMenu:"dropdown-menu",input:"input",hint:"hint",suggestions:"suggestions",suggestion:"suggestion",cursor:"cursor",dataset:"dataset",empty:"empty"},appendTo:{wrapper:{position:"absolute",zIndex:"100",display:"none"},input:{},inputWithNoHint:{},dropdown:{display:"block"}}};i.isMsie()&&i.mixin(r.input,{backgroundImage:"url(data:image/gif;base64,R0lGODlhAQABAIAAAAAAAP///yH5BAEAAAAALAAAAAABAAEAAAIBRAA7)"}),i.isMsie()&&i.isMsie()<=7&&i.mixin(r.input,{marginTop:"-1px"}),e.exports=r},3312:function(e,t,n){"use strict";var i="aaDataset",r="aaValue",s="aaDatum",o=n(5670),a=n(3855),u=n(6619),c=n(7114),l=n(6823);function h(e){var t;(e=e||{}).templates=e.templates||{},e.source||o.error("missing source"),e.name&&(t=e.name,!/^[_a-zA-Z0-9-]+$/.test(t))&&o.error("invalid dataset name: "+e.name),this.query=null,this._isEmpty=!0,this.highlight=!!e.highlight,this.name=void 0===e.name||null===e.name?o.getUniqueId():e.name,this.source=e.source,this.displayFn=function(e){return e=e||"value",o.isFunction(e)?e:t;function t(t){return t[e]}}(e.display||e.displayKey),this.debounce=e.debounce,this.cache=!1!==e.cache,this.templates=function(e,t){return{empty:e.empty&&o.templatify(e.empty),header:e.header&&o.templatify(e.header),footer:e.footer&&o.templatify(e.footer),suggestion:e.suggestion||n};function n(e){return"<p>"+t(e)+"</p>"}}(e.templates,this.displayFn),this.css=o.mixin({},c,e.appendTo?c.appendTo:{}),this.cssClasses=e.cssClasses=o.mixin({},c.defaultClasses,e.cssClasses||{}),this.cssClasses.prefix=e.cssClasses.formattedPrefix||o.formatPrefix(this.cssClasses.prefix,this.cssClasses.noPrefix);var n=o.className(this.cssClasses.prefix,this.cssClasses.dataset);this.$el=e.$menu&&e.$menu.find(n+"-"+this.name).length>0?a.element(e.$menu.find(n+"-"+this.name)[0]):a.element(u.dataset.replace("%CLASS%",this.name).replace("%PREFIX%",this.cssClasses.prefix).replace("%DATASET%",this.cssClasses.dataset)),this.$menu=e.$menu,this.clearCachedSuggestions()}h.extractDatasetName=function(e){return a.element(e).data(i)},h.extractValue=function(e){return a.element(e).data(r)},h.extractDatum=function(e){var t=a.element(e).data(s);return"string"==typeof t&&(t=JSON.parse(t)),t},o.mixin(h.prototype,l,{_render:function(e,t){if(this.$el){var n,c=this,l=[].slice.call(arguments,2);if(this.$el.empty(),n=t&&t.length,this._isEmpty=!n,!n&&this.templates.empty)this.$el.html(h.apply(this,l)).prepend(c.templates.header?f.apply(this,l):null).append(c.templates.footer?d.apply(this,l):null);else if(n)this.$el.html(p.apply(this,l)).prepend(c.templates.header?f.apply(this,l):null).append(c.templates.footer?d.apply(this,l):null);else if(t&&!Array.isArray(t))throw new TypeError("suggestions must be an array");this.$menu&&this.$menu.addClass(this.cssClasses.prefix+(n?"with":"without")+"-"+this.name).removeClass(this.cssClasses.prefix+(n?"without":"with")+"-"+this.name),this.trigger("rendered",e)}function h(){var t=[].slice.call(arguments,0);return t=[{query:e,isEmpty:!0}].concat(t),c.templates.empty.apply(this,t)}function p(){var e,n,l=[].slice.call(arguments,0),h=this,p=u.suggestions.replace("%PREFIX%",this.cssClasses.prefix).replace("%SUGGESTIONS%",this.cssClasses.suggestions);return e=a.element(p).css(this.css.suggestions),n=o.map(t,f),e.append.apply(e,n),e;function f(e){var t,n=u.suggestion.replace("%PREFIX%",h.cssClasses.prefix).replace("%SUGGESTION%",h.cssClasses.suggestion);return(t=a.element(n).attr({role:"option",id:["option",Math.floor(1e8*Math.random())].join("-")}).append(c.templates.suggestion.apply(this,[e].concat(l)))).data(i,c.name),t.data(r,c.displayFn(e)||void 0),t.data(s,JSON.stringify(e)),t.children().each((function(){a.element(this).css(h.css.suggestionChild)})),t}}function f(){var t=[].slice.call(arguments,0);return t=[{query:e,isEmpty:!n}].concat(t),c.templates.header.apply(this,t)}function d(){var t=[].slice.call(arguments,0);return t=[{query:e,isEmpty:!n}].concat(t),c.templates.footer.apply(this,t)}},getRoot:function(){return this.$el},update:function(e){function t(t){if(!this.canceled&&e===this.query){var n=[].slice.call(arguments,1);this.cacheSuggestions(e,t,n),this._render.apply(this,[e,t].concat(n))}}if(this.query=e,this.canceled=!1,this.shouldFetchFroLine truncated
/*! For license information please see 878.f94e2fc9.js.LICENSE.txt */
(self.webpackChunkartplayer_document=self.webpackChunkartplayer_document||[]).push([[878],{1639:function(e,t,n){"use strict";e.exports=n(9281)},7114:function(e,t,n){"use strict";var i=n(5670),r={wrapper:{position:"relative",display:"inline-block"},hint:{position:"absolute",top:"0",left:"0",borderColor:"transparent",boxShadow:"none",opacity:"1"},input:{position:"relative",verticalAlign:"top",backgroundColor:"transparent"},inputWithNoHint:{position:"relative",verticalAlign:"top"},dropdown:{position:"absolute",top:"100%",left:"0",zIndex:"100",display:"none"},suggestions:{display:"block"},suggestion:{whiteSpace:"nowrap",cursor:"pointer"},suggestionChild:{whiteSpace:"normal"},ltr:{left:"0",right:"auto"},rtl:{left:"auto",right:"0"},defaultClasses:{root:"algolia-autocomplete",prefix:"aa",noPrefix:!1,dropdownMenu:"dropdown-menu",input:"input",hint:"hint",suggestions:"suggestions",suggestion:"suggestion",cursor:"cursor",dataset:"dataset",empty:"empty"},appendTo:{wrapper:{position:"absolute",zIndex:"100",display:"none"},input:{},inputWithNoHint:{},dropdown:{display:"block"}}};i.isMsie()&&i.mixin(r.input,{backgroundImage:"url(data:image/gif;base64,R0lGODlhAQABAIAAAAAAAP///yH5BAEAAAAALAAAAAABAAEAAAIBRAA7)"}),i.isMsie()&&i.isMsie()<=7&&i.mixin(r.input,{marginTop:"-1px"}),e.exports=r},3312:function(e,t,n){"use strict";var i="aaDataset",r="aaValue",s="aaDatum",o=n(5670),a=n(3855),u=n(6619),c=n(7114),l=n(6823);function h(e){var t;(e=e||{}).templates=e.templates||{},e.source||o.error("missing source"),e.name&&(t=e.name,!/^[_a-zA-Z0-9-]+$/.test(t))&&o.error("invalid dataset name: "+e.name),this.query=null,this._isEmpty=!0,this.highlight=!!e.highlight,this.name=void 0===e.name||null===e.name?o.getUniqueId():e.name,this.source=e.source,this.displayFn=function(e){return e=e||"value",o.isFunction(e)?e:t;function t(t){return t[e]}}(e.display||e.displayKey),this.debounce=e.debounce,this.cache=!1!==e.cache,this.templates=function(e,t){return{empty:e.empty&&o.templatify(e.empty),header:e.header&&o.templatify(e.header),footer:e.footer&&o.templatify(e.footer),suggestion:e.suggestion||n};function n(e){return"<p>"+t(e)+"</p>"}}(e.templates,this.displayFn),this.css=o.mixin({},c,e.appendTo?c.appendTo:{}),this.cssClasses=e.cssClasses=o.mixin({},c.defaultClasses,e.cssClasses||{}),this.cssClasses.prefix=e.cssClasses.formattedPrefix||o.formatPrefix(this.cssClasses.prefix,this.cssClasses.noPrefix);var n=o.className(this.cssClasses.prefix,this.cssClasses.dataset);this.$el=e.$menu&&e.$menu.find(n+"-"+this.name).length>0?a.element(e.$menu.find(n+"-"+this.name)[0]):a.element(u.dataset.replace("%CLASS%",this.name).replace("%PREFIX%",this.cssClasses.prefix).replace("%DATASET%",this.cssClasses.dataset)),this.$menu=e.$menu,this.clearCachedSuggestions()}h.extractDatasetName=function(e){return a.element(e).data(i)},h.extractValue=function(e){return a.element(e).data(r)},h.extractDatum=function(e){var t=a.element(e).data(s);return"string"==typeof t&&(t=JSON.parse(t)),t},o.mixin(h.prototype,l,{_render:function(e,t){if(this.$el){var n,c=this,l=[].slice.call(arguments,2);if(this.$el.empty(),n=t&&t.length,this._isEmpty=!n,!n&&this.templates.empty)this.$el.html(h.apply(this,l)).prepend(c.templates.header?f.apply(this,l):null).append(c.templates.footer?d.apply(this,l):null);else if(n)this.$el.html(p.apply(this,l)).prepend(c.templates.header?f.apply(this,l):null).append(c.templates.footer?d.apply(this,l):null);else if(t&&!Array.isArray(t))throw new TypeError("suggestions must be an array");this.$menu&&this.$menu.addClass(this.cssClasses.prefix+(n?"with":"without")+"-"+this.name).removeClass(this.cssClasses.prefix+(n?"without":"with")+"-"+this.name),this.trigger("rendered",e)}function h(){var t=[].slice.call(arguments,0);return t=[{query:e,isEmpty:!0}].concat(t),c.templates.empty.apply(this,t)}function p(){var e,n,l=[].slice.call(arguments,0),h=this,p=u.suggestions.replace("%PREFIX%",this.cssClasses.prefix).replace("%SUGGESTIONS%",this.cssClasses.suggestions);return e=a.element(p).css(this.css.suggestions),n=o.map(t,f),e.append.apply(e,n),e;function f(e){var t,n=u.suggestion.replace("%PREFIX%",h.cssClasses.prefix).replace("%SUGGESTION%",h.cssClasses.suggestion);return(t=a.element(n).attr({role:"option",id:["option",Math.floor(1e8*Math.random())].join("-")}).append(c.templates.suggestion.apply(this,[e].concat(l)))).data(i,c.name),t.data(r,c.displayFn(e)||void 0),t.data(s,JSON.stringify(e)),t.children().each((function(){a.element(this).css(h.css.suggestionChild)})),t}}function f(){var t=[].slice.call(arguments,0);return t=[{query:e,isEmpty:!n}].concat(t),c.templates.header.apply(this,t)}function d(){var t=[].slice.call(arguments,0);return t=[{query:e,isEmpty:!n}].concat(t),c.templates.footer.apply(this,t)}},getRoot:function(){return this.$el},update:function(e){function t(t){if(!this.canceled&&e===this.query){var n=[].slice.call(arguments,1);this.cacheSuggestions(e,t,n),this._render.apply(this,[e,t].concat(n))}}if(this.query=e,this.canceled=!1,this.shouldFetchFroLine truncated
@@ -0,0 +1 @@
"use strict";(self.webpackChunkartplayer_document=self.webpackChunkartplayer_document||[]).push([[283],{876:function(e,t,n){n.d(t,{Zo:function(){return c},kt:function(){return m}});var a=n(2784);function r(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function l(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var a=Object.getOwnPropertySymbols(e);t&&(a=a.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,a)}return n}function i(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?l(Object(n),!0).forEach((function(t){r(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):l(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}function o(e,t){if(null==e)return{};var n,a,r=function(e,t){if(null==e)return{};var n,a,r={},l=Object.keys(e);for(a=0;a<l.length;a++)n=l[a],t.indexOf(n)>=0||(r[n]=e[n]);return r}(e,t);if(Object.getOwnPropertySymbols){var l=Object.getOwnPropertySymbols(e);for(a=0;a<l.length;a++)n=l[a],t.indexOf(n)>=0||Object.prototype.propertyIsEnumerable.call(e,n)&&(r[n]=e[n])}return r}var s=a.createContext({}),p=function(e){var t=a.useContext(s),n=t;return e&&(n="function"==typeof e?e(t):i(i({},t),e)),n},c=function(e){var t=p(e.components);return a.createElement(s.Provider,{value:t},e.children)},u={inlineCode:"code",wrapper:function(e){var t=e.children;return a.createElement(a.Fragment,{},t)}},d=a.forwardRef((function(e,t){var n=e.components,r=e.mdxType,l=e.originalType,s=e.parentName,c=o(e,["components","mdxType","originalType","parentName"]),d=p(n),m=r,k=d["".concat(s,".").concat(m)]||d[m]||u[m]||l;return n?a.createElement(k,i(i({ref:t},c),{},{components:n})):a.createElement(k,i({ref:t},c))}));function m(e,t){var n=arguments,r=t&&t.mdxType;if("string"==typeof e||r){var l=n.length,i=new Array(l);i[0]=d;var o={};for(var s in t)hasOwnProperty.call(t,s)&&(o[s]=t[s]);o.originalType=e,o.mdxType="string"==typeof e?e:r,i[1]=o;for(var p=2;p<l;p++)i[p]=n[p];return a.createElement.apply(null,i)}return a.createElement.apply(null,n)}d.displayName="MDXCreateElement"},2376:function(e,t,n){n.r(t),n.d(t,{assets:function(){return c},contentTitle:function(){return s},default:function(){return m},frontMatter:function(){return o},metadata:function(){return p},toc:function(){return u}});var a=n(7896),r=n(1461),l=(n(2784),n(876)),i=["components"],o={title:"Static propertys",sidebar_position:5,slug:"/class"},s=void 0,p={unversionedId:"en/Class",id:"en/Class",title:"Static propertys",description:"Static attributes exist in the constructor artplayer, and the player instance is not directly associated",source:"@site/docs/en/Class.mdx",sourceDirName:"en",slug:"/class",permalink:"/document/class",draft:!1,tags:[],version:"current",sidebarPosition:5,frontMatter:{title:"Static propertys",sidebar_position:5,slug:"/class"},sidebar:"en",previous:{title:"Advanced propertys",permalink:"/document/advance"},next:{title:"Common events",permalink:"/document/events"}},c={},u=[{value:"instances",id:"instances",level:2},{value:"version",id:"version",level:2},{value:"env",id:"env",level:2},{value:"utils",id:"utils",level:2},{value:"config",id:"config",level:2},{value:"scheme",id:"scheme",level:2},{value:"validator",id:"validator",level:2},{value:"option",id:"option",level:2},{value:"html",id:"html",level:2},{value:"kindOf",id:"kindof",level:2}],d={toc:u};function m(e){var t=e.components,n=(0,r.Z)(e,i);return(0,l.kt)("wrapper",(0,a.Z)({},d,n,{components:t,mdxType:"MDXLayout"}),(0,l.kt)("div",{className:"admonition admonition-tip alert alert--success"},(0,l.kt)("div",{parentName:"div",className:"admonition-heading"},(0,l.kt)("h5",{parentName:"div"},(0,l.kt)("span",{parentName:"h5",className:"admonition-icon"},(0,l.kt)("svg",{parentName:"span",xmlns:"http://www.w3.org/2000/svg",width:"12",height:"16",viewBox:"0 0 12 16"},(0,l.kt)("path",{parentName:"svg",fillRule:"evenodd",d:"M6.5 0C3.48 0 1 2.19 1 5c0 .92.55 2.25 1 3 1.34 2.25 1.78 2.78 2 4v1h5v-1c.22-1.22.66-1.75 2-4 .45-.75 1-2.08 1-3 0-2.81-2.48-5-5.5-5zm3.64 7.48c-.25.44-.47.8-.67 1.11-.86 1.41-1.25 2.06-1.45 3.23-.02.05-.02.11-.02.17H5c0-.06 0-.13-.02-.17-.2-1.17-.59-1.83-1.45-3.23-.2-.31-.42-.67-.67-1.11C2.44 6.78 2 5.65 2 5c0-2.2 2.02-4 4.5-4 1.22 0 2.36.42 3.22 1.19C10.55 2.94 11 3.94 11 5c0 .66-.44 1.78-.86 2.48zM4 14h5c-.23 1.14-1.3 2-2.5 2s-2.27-.86-2.5-2z"}))),"Tip")),(0,l.kt)("div",{parentName:"div",className:"admonition-content"},(0,l.kt)("p",{parentName:"div"},"Static attributes exist in the constructor artplayer, and the player instance is not directly associated"))),(0,l.kt)("h2",{id:"instances"},"instances"),(0,l.kt)("ul",null,(0,l.kt)("li",{parentName:"ul"},"Type: ",(0,l.kt)("inlineCode",{parentName:"li"},"Array"))),(0,l.kt)("p",null,"A array that saves all player instances, and can manage multiple instances through this prLine truncated
@@ -1 +0,0 @@
"use strict";(self.webpackChunkartplayer_document=self.webpackChunkartplayer_document||[]).push([[283],{3905:function(e,t,n){n.d(t,{Zo:function(){return c},kt:function(){return m}});var a=n(7294);function r(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function l(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var a=Object.getOwnPropertySymbols(e);t&&(a=a.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,a)}return n}function i(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?l(Object(n),!0).forEach((function(t){r(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):l(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}function o(e,t){if(null==e)return{};var n,a,r=function(e,t){if(null==e)return{};var n,a,r={},l=Object.keys(e);for(a=0;a<l.length;a++)n=l[a],t.indexOf(n)>=0||(r[n]=e[n]);return r}(e,t);if(Object.getOwnPropertySymbols){var l=Object.getOwnPropertySymbols(e);for(a=0;a<l.length;a++)n=l[a],t.indexOf(n)>=0||Object.prototype.propertyIsEnumerable.call(e,n)&&(r[n]=e[n])}return r}var s=a.createContext({}),p=function(e){var t=a.useContext(s),n=t;return e&&(n="function"==typeof e?e(t):i(i({},t),e)),n},c=function(e){var t=p(e.components);return a.createElement(s.Provider,{value:t},e.children)},u={inlineCode:"code",wrapper:function(e){var t=e.children;return a.createElement(a.Fragment,{},t)}},d=a.forwardRef((function(e,t){var n=e.components,r=e.mdxType,l=e.originalType,s=e.parentName,c=o(e,["components","mdxType","originalType","parentName"]),d=p(n),m=r,k=d["".concat(s,".").concat(m)]||d[m]||u[m]||l;return n?a.createElement(k,i(i({ref:t},c),{},{components:n})):a.createElement(k,i({ref:t},c))}));function m(e,t){var n=arguments,r=t&&t.mdxType;if("string"==typeof e||r){var l=n.length,i=new Array(l);i[0]=d;var o={};for(var s in t)hasOwnProperty.call(t,s)&&(o[s]=t[s]);o.originalType=e,o.mdxType="string"==typeof e?e:r,i[1]=o;for(var p=2;p<l;p++)i[p]=n[p];return a.createElement.apply(null,i)}return a.createElement.apply(null,n)}d.displayName="MDXCreateElement"},2606:function(e,t,n){n.r(t),n.d(t,{assets:function(){return c},contentTitle:function(){return s},default:function(){return m},frontMatter:function(){return o},metadata:function(){return p},toc:function(){return u}});var a=n(7462),r=n(3366),l=(n(7294),n(3905)),i=["components"],o={title:"Static propertys",sidebar_position:5,slug:"/class"},s=void 0,p={unversionedId:"en/Class",id:"en/Class",title:"Static propertys",description:"Static attributes exist in the constructor artplayer, and the player instance is not directly associated",source:"@site/docs/en/Class.mdx",sourceDirName:"en",slug:"/class",permalink:"/document/class",draft:!1,tags:[],version:"current",sidebarPosition:5,frontMatter:{title:"Static propertys",sidebar_position:5,slug:"/class"},sidebar:"en",previous:{title:"Advanced propertys",permalink:"/document/advance"},next:{title:"Common events",permalink:"/document/events"}},c={},u=[{value:"instances",id:"instances",level:2},{value:"version",id:"version",level:2},{value:"env",id:"env",level:2},{value:"utils",id:"utils",level:2},{value:"config",id:"config",level:2},{value:"scheme",id:"scheme",level:2},{value:"validator",id:"validator",level:2},{value:"option",id:"option",level:2},{value:"html",id:"html",level:2},{value:"kindOf",id:"kindof",level:2}],d={toc:u};function m(e){var t=e.components,n=(0,r.Z)(e,i);return(0,l.kt)("wrapper",(0,a.Z)({},d,n,{components:t,mdxType:"MDXLayout"}),(0,l.kt)("div",{className:"admonition admonition-tip alert alert--success"},(0,l.kt)("div",{parentName:"div",className:"admonition-heading"},(0,l.kt)("h5",{parentName:"div"},(0,l.kt)("span",{parentName:"h5",className:"admonition-icon"},(0,l.kt)("svg",{parentName:"span",xmlns:"http://www.w3.org/2000/svg",width:"12",height:"16",viewBox:"0 0 12 16"},(0,l.kt)("path",{parentName:"svg",fillRule:"evenodd",d:"M6.5 0C3.48 0 1 2.19 1 5c0 .92.55 2.25 1 3 1.34 2.25 1.78 2.78 2 4v1h5v-1c.22-1.22.66-1.75 2-4 .45-.75 1-2.08 1-3 0-2.81-2.48-5-5.5-5zm3.64 7.48c-.25.44-.47.8-.67 1.11-.86 1.41-1.25 2.06-1.45 3.23-.02.05-.02.11-.02.17H5c0-.06 0-.13-.02-.17-.2-1.17-.59-1.83-1.45-3.23-.2-.31-.42-.67-.67-1.11C2.44 6.78 2 5.65 2 5c0-2.2 2.02-4 4.5-4 1.22 0 2.36.42 3.22 1.19C10.55 2.94 11 3.94 11 5c0 .66-.44 1.78-.86 2.48zM4 14h5c-.23 1.14-1.3 2-2.5 2s-2.27-.86-2.5-2z"}))),"Tip")),(0,l.kt)("div",{parentName:"div",className:"admonition-content"},(0,l.kt)("p",{parentName:"div"},"Static attributes exist in the constructor artplayer, and the player instance is not directly associated"))),(0,l.kt)("h2",{id:"instances"},"instances"),(0,l.kt)("ul",null,(0,l.kt)("li",{parentName:"ul"},"Type: ",(0,l.kt)("inlineCode",{parentName:"li"},"Array"))),(0,l.kt)("p",null,"A array that saves all player instances, and can manage multiple instances through this Line truncated
@@ -1 +0,0 @@
"use strict";(self.webpackChunkartplayer_document=self.webpackChunkartplayer_document||[]).push([[53],{1109:function(e){e.exports=JSON.parse('{"pluginId":"default","version":"current","label":"Next","banner":null,"badge":false,"className":"docs-version-current","isLast":true,"docsSidebars":{"en":[{"type":"link","label":"Quick start","href":"/document/","docId":"en/Overview"},{"type":"link","label":"Basic options","href":"/document/options","docId":"en/Options"},{"type":"link","label":"Common properties","href":"/document/propertie","docId":"en/Properties"},{"type":"link","label":"Advanced propertys","href":"/document/advance","docId":"en/Advance"},{"type":"link","label":"Static propertys","href":"/document/class","docId":"en/Class"},{"type":"link","label":"Common events","href":"/document/events","docId":"en/Events"},{"type":"link","label":"Third party librarys","href":"/document/libraries","docId":"en/Libraries"},{"type":"category","label":"Official plugins","collapsible":true,"collapsed":true,"items":[{"type":"link","label":"Danmuku plugin","href":"/document/en/Plugins/danmuku","docId":"en/Plugins/danmuku"}]},{"type":"category","label":"Common problems","collapsible":true,"collapsed":true,"items":[{"type":"link","label":"Add select in the controls","href":"/document/en/Questions/Create_selector_in_the_controls","docId":"en/Questions/Create_selector_in_the_controls"},{"type":"link","label":"Add button to the controls","href":"/document/en/Questions/Create_button_in_the_controls","docId":"en/Questions/Create_button_in_the_controls"},{"type":"link","label":"Handle a single component","href":"/document/en/Questions/Handle_single_component","docId":"en/Questions/Handle_single_component"},{"type":"link","label":"How to import types","href":"/document/en/Questions/How_to_import_types","docId":"en/Questions/How_to_import_types"},{"type":"link","label":"How to add video ads","href":"/document/en/Questions/How_to_add_video_ads","docId":"en/Questions/How_to_add_video_ads"},{"type":"link","label":"How to add setting panel","href":"/document/en/Questions/How_to_add_setting_panel","docId":"en/Questions/How_to_add_setting_panel"},{"type":"link","label":"Use with React Portal","href":"/document/en/Questions/Use_with_react_portal","docId":"en/Questions/Use_with_react_portal"}]}],"zh-cn":[{"type":"link","label":"\u5feb\u901f\u4e0a\u624b","href":"/document/zh-cn","docId":"zh-cn/Overview"},{"type":"link","label":"\u57fa\u7840\u53c2\u6570","href":"/document/zh-cn/options","docId":"zh-cn/Options"},{"type":"link","label":"\u5e38\u7528\u5c5e\u6027","href":"/document/zh-cn/propertie","docId":"zh-cn/Properties"},{"type":"link","label":"\u9ad8\u7ea7\u5c5e\u6027","href":"/document/zh-cn/advance","docId":"zh-cn/Advance"},{"type":"link","label":"\u9759\u6001\u5c5e\u6027","href":"/document/zh-cn/class","docId":"zh-cn/Class"},{"type":"link","label":"\u5b9e\u4f8b\u4e8b\u4ef6","href":"/document/zh-cn/events","docId":"zh-cn/Events"},{"type":"link","label":"\u7b2c\u4e09\u65b9\u5e93","href":"/document/zh-cn/libraries","docId":"zh-cn/Libraries"},{"type":"category","label":"\u5b98\u65b9\u63d2\u4ef6","collapsible":true,"collapsed":true,"items":[{"type":"link","label":"\u5f39\u5e55\u5e93\u63d2\u4ef6","href":"/document/zh-cn/Plugins/danmuku","docId":"zh-cn/Plugins/danmuku"}]},{"type":"category","label":"\u5e38\u89c1\u95ee\u9898","collapsible":true,"collapsed":true,"items":[{"type":"link","label":"\u5728\u63a7\u5236\u680f\u6dfb\u52a0\u5217\u8868","href":"/document/zh-cn/Questions/Create_selector_in_the_controls","docId":"zh-cn/Questions/Create_selector_in_the_controls"},{"type":"link","label":"\u5728\u63a7\u5236\u680f\u6dfb\u52a0\u6309\u94ae","href":"/document/zh-cn/Questions/Create_button_in_the_controls","docId":"zh-cn/Questions/Create_button_in_the_controls"},{"type":"link","label":"\u5904\u7406\u5355\u4e2a\u7ec4\u4ef6","href":"/document/zh-cn/Questions/Handle_single_component","docId":"zh-cn/Questions/Handle_single_component"},{"type":"link","label":"\u5982\u4f55\u5bfc\u5165\u7c7b\u578b","href":"/document/zh-cn/Questions/How_to_import_types","docId":"zh-cn/Questions/How_to_import_types"},{"type":"link","label":"\u5982\u4f55\u6dfb\u52a0\u89c6\u9891\u5e7f\u544a","href":"/document/zh-cn/Questions/How_to_add_video_ads","docId":"zh-cn/Questions/How_to_add_video_ads"},{"type":"link","label":"\u600e\u4e48\u6dfb\u52a0\u8bbe\u7f6e\u9762\u677f","href":"/document/zh-cn/Questions/How_to_add_setting_panel","docId":"zh-cn/Questions/How_to_add_setting_panel"},{"type":"link","label":"\u4e0e React Portal \u4f7f\u7528","href":"/document/zh-cn/Questions/Use_with_react_portal","docId":"zh-cn/Questions/Use_with_react_portal"}]}]},"docs":{"en/Advance":{"id":"en/Advance","title":"Advanced propertys","description":"This page is some additional supplements to the commonly used properties, you need to read in depth to develop custom functions.","sidebar":"en"},"en/Class":{"id":"en/Class","title":"Static propertys","description":"Static attributes exist in the construcLine truncated
@@ -0,0 +1 @@
"use strict";(self.webpackChunkartplayer_document=self.webpackChunkartplayer_document||[]).push([[53],{1109:function(e){e.exports=JSON.parse('{"pluginId":"default","version":"current","label":"Next","banner":null,"badge":false,"className":"docs-version-current","isLast":true,"docsSidebars":{"en":[{"type":"link","label":"Quick start","href":"/document/","docId":"en/Overview"},{"type":"link","label":"Basic options","href":"/document/options","docId":"en/Options"},{"type":"link","label":"Common properties","href":"/document/propertie","docId":"en/Properties"},{"type":"link","label":"Advanced propertys","href":"/document/advance","docId":"en/Advance"},{"type":"link","label":"Static propertys","href":"/document/class","docId":"en/Class"},{"type":"link","label":"Common events","href":"/document/events","docId":"en/Events"},{"type":"link","label":"Third party librarys","href":"/document/libraries","docId":"en/Libraries"},{"type":"category","label":"Official plugins","collapsible":true,"collapsed":true,"items":[{"type":"link","label":"Danmuku plugin","href":"/document/en/Plugins/danmuku","docId":"en/Plugins/danmuku"},{"type":"link","label":"Ads Plugin","href":"/document/en/Plugins/ads","docId":"en/Plugins/ads"}]},{"type":"category","label":"Common problems","collapsible":true,"collapsed":true,"items":[{"type":"link","label":"Add select in the controls","href":"/document/en/Questions/Create_selector_in_the_controls","docId":"en/Questions/Create_selector_in_the_controls"},{"type":"link","label":"Add button to the controls","href":"/document/en/Questions/Create_button_in_the_controls","docId":"en/Questions/Create_button_in_the_controls"},{"type":"link","label":"Handle a single component","href":"/document/en/Questions/Handle_single_component","docId":"en/Questions/Handle_single_component"},{"type":"link","label":"How to import types","href":"/document/en/Questions/How_to_import_types","docId":"en/Questions/How_to_import_types"},{"type":"link","label":"How to add setting panel","href":"/document/en/Questions/How_to_add_setting_panel","docId":"en/Questions/How_to_add_setting_panel"},{"type":"link","label":"Use with React Portal","href":"/document/en/Questions/Use_with_react_portal","docId":"en/Questions/Use_with_react_portal"}]}],"zh-cn":[{"type":"link","label":"\u5feb\u901f\u4e0a\u624b","href":"/document/zh-cn","docId":"zh-cn/Overview"},{"type":"link","label":"\u57fa\u7840\u53c2\u6570","href":"/document/zh-cn/options","docId":"zh-cn/Options"},{"type":"link","label":"\u5e38\u7528\u5c5e\u6027","href":"/document/zh-cn/propertie","docId":"zh-cn/Properties"},{"type":"link","label":"\u9ad8\u7ea7\u5c5e\u6027","href":"/document/zh-cn/advance","docId":"zh-cn/Advance"},{"type":"link","label":"\u9759\u6001\u5c5e\u6027","href":"/document/zh-cn/class","docId":"zh-cn/Class"},{"type":"link","label":"\u5b9e\u4f8b\u4e8b\u4ef6","href":"/document/zh-cn/events","docId":"zh-cn/Events"},{"type":"link","label":"\u7b2c\u4e09\u65b9\u5e93","href":"/document/zh-cn/libraries","docId":"zh-cn/Libraries"},{"type":"category","label":"\u5b98\u65b9\u63d2\u4ef6","collapsible":true,"collapsed":true,"items":[{"type":"link","label":"\u5f39\u5e55\u5e93\u63d2\u4ef6","href":"/document/zh-cn/Plugins/danmuku","docId":"zh-cn/Plugins/danmuku"},{"type":"link","label":"\u5e7f\u544a\u63d2\u4ef6","href":"/document/zh-cn/Plugins/ads","docId":"zh-cn/Plugins/ads"}]},{"type":"category","label":"\u5e38\u89c1\u95ee\u9898","collapsible":true,"collapsed":true,"items":[{"type":"link","label":"\u5728\u63a7\u5236\u680f\u6dfb\u52a0\u5217\u8868","href":"/document/zh-cn/Questions/Create_selector_in_the_controls","docId":"zh-cn/Questions/Create_selector_in_the_controls"},{"type":"link","label":"\u5728\u63a7\u5236\u680f\u6dfb\u52a0\u6309\u94ae","href":"/document/zh-cn/Questions/Create_button_in_the_controls","docId":"zh-cn/Questions/Create_button_in_the_controls"},{"type":"link","label":"\u5904\u7406\u5355\u4e2a\u7ec4\u4ef6","href":"/document/zh-cn/Questions/Handle_single_component","docId":"zh-cn/Questions/Handle_single_component"},{"type":"link","label":"\u5982\u4f55\u5bfc\u5165\u7c7b\u578b","href":"/document/zh-cn/Questions/How_to_import_types","docId":"zh-cn/Questions/How_to_import_types"},{"type":"link","label":"\u600e\u4e48\u6dfb\u52a0\u8bbe\u7f6e\u9762\u677f","href":"/document/zh-cn/Questions/How_to_add_setting_panel","docId":"zh-cn/Questions/How_to_add_setting_panel"},{"type":"link","label":"\u4e0e React Portal \u4f7f\u7528","href":"/document/zh-cn/Questions/Use_with_react_portal","docId":"zh-cn/Questions/Use_with_react_portal"}]}]},"docs":{"en/Advance":{"id":"en/Advance","title":"Advanced propertys","description":"This page is some additional supplements to the commonly used properties, you need to read in depth to develop custom functions.","sidebar":"en"},"en/Class":{"id":"en/Class","title":"Static propertys","description":"Static attributes exist in the constructor artplayer, and the player instance is not directly associated","sidebar":"en"},"en/Events":{"id":"en/EventLine truncated
@@ -1 +0,0 @@
"use strict";(self.webpackChunkartplayer_document=self.webpackChunkartplayer_document||[]).push([[146],{3905:function(e,t,n){n.d(t,{Zo:function(){return l},kt:function(){return m}});var r=n(7294);function o(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function i(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,r)}return n}function c(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?i(Object(n),!0).forEach((function(t){o(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):i(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}function a(e,t){if(null==e)return{};var n,r,o=function(e,t){if(null==e)return{};var n,r,o={},i=Object.keys(e);for(r=0;r<i.length;r++)n=i[r],t.indexOf(n)>=0||(o[n]=e[n]);return o}(e,t);if(Object.getOwnPropertySymbols){var i=Object.getOwnPropertySymbols(e);for(r=0;r<i.length;r++)n=i[r],t.indexOf(n)>=0||Object.prototype.propertyIsEnumerable.call(e,n)&&(o[n]=e[n])}return o}var u=r.createContext({}),s=function(e){var t=r.useContext(u),n=t;return e&&(n="function"==typeof e?e(t):c(c({},t),e)),n},l=function(e){var t=s(e.components);return r.createElement(u.Provider,{value:t},e.children)},p={inlineCode:"code",wrapper:function(e){var t=e.children;return r.createElement(r.Fragment,{},t)}},f=r.forwardRef((function(e,t){var n=e.components,o=e.mdxType,i=e.originalType,u=e.parentName,l=a(e,["components","mdxType","originalType","parentName"]),f=s(n),m=o,d=f["".concat(u,".").concat(m)]||f[m]||p[m]||i;return n?r.createElement(d,c(c({ref:t},l),{},{components:n})):r.createElement(d,c({ref:t},l))}));function m(e,t){var n=arguments,o=t&&t.mdxType;if("string"==typeof e||o){var i=n.length,c=new Array(i);c[0]=f;var a={};for(var u in t)hasOwnProperty.call(t,u)&&(a[u]=t[u]);a.originalType=e,a.mdxType="string"==typeof e?e:o,c[1]=a;for(var s=2;s<i;s++)c[s]=n[s];return r.createElement.apply(null,c)}return r.createElement.apply(null,n)}f.displayName="MDXCreateElement"},998:function(e,t,n){n.r(t),n.d(t,{assets:function(){return l},contentTitle:function(){return u},default:function(){return m},frontMatter:function(){return a},metadata:function(){return s},toc:function(){return p}});var r=n(7462),o=n(3366),i=(n(7294),n(3905)),c=["components"],a={title:"\u5728\u63a7\u5236\u680f\u6dfb\u52a0\u6309\u94ae",sidebar_position:2},u=void 0,s={unversionedId:"zh-cn/Questions/Create_button_in_the_controls",id:"zh-cn/Questions/Create_button_in_the_controls",title:"\u5728\u63a7\u5236\u680f\u6dfb\u52a0\u6309\u94ae",description:"\u6709\u65f6\u4f60\u9700\u8981\u5728\u63a7\u5236\u680f\u6dfb\u52a0\u6309\u94ae\uff0c\u5982\u5f00\u5173\u6309\u94ae\u6216\u8005\u5355\u9009\u6309\u94ae\u7b49\u7b49\uff0c\u4f60\u751a\u81f3\u53ef\u4ee5\u4f7f\u7528\u7b2c\u4e09\u65b9\u7684\u6837\u5f0f\u5e93\u5982 bootstrap",source:"@site/docs/zh-cn/Questions/Create_button_in_the_controls.mdx",sourceDirName:"zh-cn/Questions",slug:"/zh-cn/Questions/Create_button_in_the_controls",permalink:"/document/zh-cn/Questions/Create_button_in_the_controls",draft:!1,tags:[],version:"current",sidebarPosition:2,frontMatter:{title:"\u5728\u63a7\u5236\u680f\u6dfb\u52a0\u6309\u94ae",sidebar_position:2},sidebar:"zh-cn",previous:{title:"\u5728\u63a7\u5236\u680f\u6dfb\u52a0\u5217\u8868",permalink:"/document/zh-cn/Questions/Create_selector_in_the_controls"},next:{title:"\u5904\u7406\u5355\u4e2a\u7ec4\u4ef6",permalink:"/document/zh-cn/Questions/Handle_single_component"}},l={},p=[],f={toc:p};function m(e){var t=e.components,n=(0,o.Z)(e,c);return(0,i.kt)("wrapper",(0,r.Z)({},f,n,{components:t,mdxType:"MDXLayout"}),(0,i.kt)("p",null,"\u6709\u65f6\u4f60\u9700\u8981\u5728\u63a7\u5236\u680f\u6dfb\u52a0\u6309\u94ae\uff0c\u5982\u5f00\u5173\u6309\u94ae\u6216\u8005\u5355\u9009\u6309\u94ae\u7b49\u7b49\uff0c\u4f60\u751a\u81f3\u53ef\u4ee5\u4f7f\u7528\u7b2c\u4e09\u65b9\u7684\u6837\u5f0f\u5e93\u5982 ",(0,i.kt)("inlineCode",{parentName:"p"},"bootstrap")),(0,i.kt)("div",{className:"run-code"},"\u25b6 Run Code"),(0,i.kt)("pre",null,(0,i.kt)("code",{parentName:"pre",className:"language-js"},"var time = 0;\nvar art = new Artplayer({\n container: '.artplayer-app',\n url: '/assets/sample/video.mp4',\n controls: [\n {\n position: 'right',\n html: '<button type=\"button\">Click Me!</button>',\n click: function (_, event) {\n // \u7b2c\u4e8c\u4e2a\u53c2\u6570\u662f\u4e8b\u4ef6\u5bf9\u8c61\n time += 1;\n event.target.innerText = 'You Click ' + time;\n },\n },\n ],\n});\n")))}m.isMDXComponent=!0}}]);
@@ -0,0 +1 @@
"use strict";(self.webpackChunkartplayer_document=self.webpackChunkartplayer_document||[]).push([[146],{876:function(e,t,n){n.d(t,{Zo:function(){return l},kt:function(){return m}});var r=n(2784);function o(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function i(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,r)}return n}function c(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?i(Object(n),!0).forEach((function(t){o(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):i(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}function a(e,t){if(null==e)return{};var n,r,o=function(e,t){if(null==e)return{};var n,r,o={},i=Object.keys(e);for(r=0;r<i.length;r++)n=i[r],t.indexOf(n)>=0||(o[n]=e[n]);return o}(e,t);if(Object.getOwnPropertySymbols){var i=Object.getOwnPropertySymbols(e);for(r=0;r<i.length;r++)n=i[r],t.indexOf(n)>=0||Object.prototype.propertyIsEnumerable.call(e,n)&&(o[n]=e[n])}return o}var u=r.createContext({}),s=function(e){var t=r.useContext(u),n=t;return e&&(n="function"==typeof e?e(t):c(c({},t),e)),n},l=function(e){var t=s(e.components);return r.createElement(u.Provider,{value:t},e.children)},p={inlineCode:"code",wrapper:function(e){var t=e.children;return r.createElement(r.Fragment,{},t)}},f=r.forwardRef((function(e,t){var n=e.components,o=e.mdxType,i=e.originalType,u=e.parentName,l=a(e,["components","mdxType","originalType","parentName"]),f=s(n),m=o,d=f["".concat(u,".").concat(m)]||f[m]||p[m]||i;return n?r.createElement(d,c(c({ref:t},l),{},{components:n})):r.createElement(d,c({ref:t},l))}));function m(e,t){var n=arguments,o=t&&t.mdxType;if("string"==typeof e||o){var i=n.length,c=new Array(i);c[0]=f;var a={};for(var u in t)hasOwnProperty.call(t,u)&&(a[u]=t[u]);a.originalType=e,a.mdxType="string"==typeof e?e:o,c[1]=a;for(var s=2;s<i;s++)c[s]=n[s];return r.createElement.apply(null,c)}return r.createElement.apply(null,n)}f.displayName="MDXCreateElement"},5312:function(e,t,n){n.r(t),n.d(t,{assets:function(){return l},contentTitle:function(){return u},default:function(){return m},frontMatter:function(){return a},metadata:function(){return s},toc:function(){return p}});var r=n(7896),o=n(1461),i=(n(2784),n(876)),c=["components"],a={title:"\u5728\u63a7\u5236\u680f\u6dfb\u52a0\u6309\u94ae",sidebar_position:2},u=void 0,s={unversionedId:"zh-cn/Questions/Create_button_in_the_controls",id:"zh-cn/Questions/Create_button_in_the_controls",title:"\u5728\u63a7\u5236\u680f\u6dfb\u52a0\u6309\u94ae",description:"\u6709\u65f6\u4f60\u9700\u8981\u5728\u63a7\u5236\u680f\u6dfb\u52a0\u6309\u94ae\uff0c\u5982\u5f00\u5173\u6309\u94ae\u6216\u8005\u5355\u9009\u6309\u94ae\u7b49\u7b49\uff0c\u4f60\u751a\u81f3\u53ef\u4ee5\u4f7f\u7528\u7b2c\u4e09\u65b9\u7684\u6837\u5f0f\u5e93\u5982 bootstrap",source:"@site/docs/zh-cn/Questions/Create_button_in_the_controls.mdx",sourceDirName:"zh-cn/Questions",slug:"/zh-cn/Questions/Create_button_in_the_controls",permalink:"/document/zh-cn/Questions/Create_button_in_the_controls",draft:!1,tags:[],version:"current",sidebarPosition:2,frontMatter:{title:"\u5728\u63a7\u5236\u680f\u6dfb\u52a0\u6309\u94ae",sidebar_position:2},sidebar:"zh-cn",previous:{title:"\u5728\u63a7\u5236\u680f\u6dfb\u52a0\u5217\u8868",permalink:"/document/zh-cn/Questions/Create_selector_in_the_controls"},next:{title:"\u5904\u7406\u5355\u4e2a\u7ec4\u4ef6",permalink:"/document/zh-cn/Questions/Handle_single_component"}},l={},p=[],f={toc:p};function m(e){var t=e.components,n=(0,o.Z)(e,c);return(0,i.kt)("wrapper",(0,r.Z)({},f,n,{components:t,mdxType:"MDXLayout"}),(0,i.kt)("p",null,"\u6709\u65f6\u4f60\u9700\u8981\u5728\u63a7\u5236\u680f\u6dfb\u52a0\u6309\u94ae\uff0c\u5982\u5f00\u5173\u6309\u94ae\u6216\u8005\u5355\u9009\u6309\u94ae\u7b49\u7b49\uff0c\u4f60\u751a\u81f3\u53ef\u4ee5\u4f7f\u7528\u7b2c\u4e09\u65b9\u7684\u6837\u5f0f\u5e93\u5982 ",(0,i.kt)("inlineCode",{parentName:"p"},"bootstrap")),(0,i.kt)("div",{className:"run-code"},"\u25b6 Run Code"),(0,i.kt)("pre",null,(0,i.kt)("code",{parentName:"pre",className:"language-js"},"var time = 0;\nvar art = new Artplayer({\n container: '.artplayer-app',\n url: '/assets/sample/video.mp4',\n controls: [\n {\n position: 'right',\n html: '<button type=\"button\">Click Me!</button>',\n click: function (_, event) {\n // \u7b2c\u4e8c\u4e2a\u53c2\u6570\u662f\u4e8b\u4ef6\u5bf9\u8c61\n time += 1;\n event.target.innerText = 'You Click ' + time;\n },\n },\n ],\n});\n")))}m.isMDXComponent=!0}}]);
@@ -1 +1 @@
"use strict";(self.webpackChunkartplayer_document=self.webpackChunkartplayer_document||[]).push([[894],{3769:function(e){e.exports=JSON.parse('{"name":"docusaurus-plugin-content-docs","id":"default"}')}}]);
"use strict";(self.webpackChunkartplayer_document=self.webpackChunkartplayer_document||[]).push([[178],{3769:function(e){e.exports=JSON.parse('{"name":"docusaurus-plugin-content-docs","id":"default"}')}}]);
@@ -0,0 +1 @@
"use strict";(self.webpackChunkartplayer_document=self.webpackChunkartplayer_document||[]).push([[87],{876:function(e,t,n){n.d(t,{Zo:function(){return c},kt:function(){return m}});var r=n(2784);function a(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function l(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,r)}return n}function o(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?l(Object(n),!0).forEach((function(t){a(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):l(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}function s(e,t){if(null==e)return{};var n,r,a=function(e,t){if(null==e)return{};var n,r,a={},l=Object.keys(e);for(r=0;r<l.length;r++)n=l[r],t.indexOf(n)>=0||(a[n]=e[n]);return a}(e,t);if(Object.getOwnPropertySymbols){var l=Object.getOwnPropertySymbols(e);for(r=0;r<l.length;r++)n=l[r],t.indexOf(n)>=0||Object.prototype.propertyIsEnumerable.call(e,n)&&(a[n]=e[n])}return a}var i=r.createContext({}),u=function(e){var t=r.useContext(i),n=t;return e&&(n="function"==typeof e?e(t):o(o({},t),e)),n},c=function(e){var t=u(e.components);return r.createElement(i.Provider,{value:t},e.children)},p={inlineCode:"code",wrapper:function(e){var t=e.children;return r.createElement(r.Fragment,{},t)}},d=r.forwardRef((function(e,t){var n=e.components,a=e.mdxType,l=e.originalType,i=e.parentName,c=s(e,["components","mdxType","originalType","parentName"]),d=u(n),m=a,h=d["".concat(i,".").concat(m)]||d[m]||p[m]||l;return n?r.createElement(h,o(o({ref:t},c),{},{components:n})):r.createElement(h,o({ref:t},c))}));function m(e,t){var n=arguments,a=t&&t.mdxType;if("string"==typeof e||a){var l=n.length,o=new Array(l);o[0]=d;var s={};for(var i in t)hasOwnProperty.call(t,i)&&(s[i]=t[i]);s.originalType=e,s.mdxType="string"==typeof e?e:a,o[1]=s;for(var u=2;u<l;u++)o[u]=n[u];return r.createElement.apply(null,o)}return r.createElement.apply(null,n)}d.displayName="MDXCreateElement"},5443:function(e,t,n){n.r(t),n.d(t,{assets:function(){return c},contentTitle:function(){return i},default:function(){return m},frontMatter:function(){return s},metadata:function(){return u},toc:function(){return p}});var r=n(7896),a=n(1461),l=(n(2784),n(876)),o=["components"],s={title:"\u7b2c\u4e09\u65b9\u5e93",sidebar_position:7,slug:"/zh-cn/libraries"},i=void 0,u={unversionedId:"zh-cn/Libraries",id:"zh-cn/Libraries",title:"\u7b2c\u4e09\u65b9\u5e93",description:"flv.js",source:"@site/docs/zh-cn/Libraries.mdx",sourceDirName:"zh-cn",slug:"/zh-cn/libraries",permalink:"/document/zh-cn/libraries",draft:!1,tags:[],version:"current",sidebarPosition:7,frontMatter:{title:"\u7b2c\u4e09\u65b9\u5e93",sidebar_position:7,slug:"/zh-cn/libraries"},sidebar:"zh-cn",previous:{title:"\u5b9e\u4f8b\u4e8b\u4ef6",permalink:"/document/zh-cn/events"},next:{title:"\u5f39\u5e55\u5e93\u63d2\u4ef6",permalink:"/document/zh-cn/Plugins/danmuku"}},c={},p=[{value:"flv.js",id:"flvjs",level:2},{value:"hls.js",id:"hlsjs",level:2},{value:"dash.js",id:"dashjs",level:2},{value:"shaka-player",id:"shaka-player",level:2},{value:"webtorrent",id:"webtorrent",level:2}],d={toc:p};function m(e){var t=e.components,n=(0,a.Z)(e,o);return(0,l.kt)("wrapper",(0,r.Z)({},d,n,{components:t,mdxType:"MDXLayout"}),(0,l.kt)("h2",{id:"flvjs"},"flv.js"),(0,l.kt)("ul",null,(0,l.kt)("li",{parentName:"ul"},"\u4e3b\u9875: ",(0,l.kt)("a",{parentName:"li",href:"https://github.com/Bilibili/flv.js"},"https://github.com/Bilibili/flv.js"))),(0,l.kt)("div",{className:"run-code","data-libs":"https://unpkg.com/flv.js@1.6.2/dist/flv.js"},"\u25b6 Run Code"),(0,l.kt)("pre",null,(0,l.kt)("code",{parentName:"pre",className:"language-js"},"var art = new Artplayer({\n container: '.artplayer-app',\n autoplay: true,\n url: '/assets/sample/video.flv',\n customType: {\n flv: function (video, url) {\n if (flvjs.isSupported()) {\n const flvPlayer = flvjs.createPlayer({\n type: 'flv',\n url: url,\n });\n flvPlayer.attachMediaElement(video);\n flvPlayer.load();\n } else {\n art.notice.show = '\u4e0d\u652f\u6301\u64ad\u653e\u683c\u5f0f\uff1aflv';\n }\n },\n },\n});\n")),(0,l.kt)("h2",{id:"hlsjs"},"hls.js"),(0,l.kt)("ul",null,(0,l.kt)("li",{parentName:"ul"},"\u4e3b\u9875: ",(0,l.kt)("a",{parentName:"li",href:"https://github.com/video-dev/hls.js"},"https://github.com/video-dev/hls.js"))),(0,l.kt)("div",{className:"run-code","data-libs":"https://cdnjs.cloudflare.com/ajax/libs/hls.js/8.0.0-beta.3/hls.min.js"},"\u25b6 Run Code"),(0,l.kt)("pre",null,(0,l.kt)("code",{parentName:"pre",className:"language-js"},"var art = new ArLine truncated
@@ -1 +0,0 @@
"use strict";(self.webpackChunkartplayer_document=self.webpackChunkartplayer_document||[]).push([[87],{3905:function(e,t,n){n.d(t,{Zo:function(){return c},kt:function(){return m}});var r=n(7294);function a(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function l(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,r)}return n}function o(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?l(Object(n),!0).forEach((function(t){a(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):l(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}function s(e,t){if(null==e)return{};var n,r,a=function(e,t){if(null==e)return{};var n,r,a={},l=Object.keys(e);for(r=0;r<l.length;r++)n=l[r],t.indexOf(n)>=0||(a[n]=e[n]);return a}(e,t);if(Object.getOwnPropertySymbols){var l=Object.getOwnPropertySymbols(e);for(r=0;r<l.length;r++)n=l[r],t.indexOf(n)>=0||Object.prototype.propertyIsEnumerable.call(e,n)&&(a[n]=e[n])}return a}var i=r.createContext({}),u=function(e){var t=r.useContext(i),n=t;return e&&(n="function"==typeof e?e(t):o(o({},t),e)),n},c=function(e){var t=u(e.components);return r.createElement(i.Provider,{value:t},e.children)},p={inlineCode:"code",wrapper:function(e){var t=e.children;return r.createElement(r.Fragment,{},t)}},d=r.forwardRef((function(e,t){var n=e.components,a=e.mdxType,l=e.originalType,i=e.parentName,c=s(e,["components","mdxType","originalType","parentName"]),d=u(n),m=a,h=d["".concat(i,".").concat(m)]||d[m]||p[m]||l;return n?r.createElement(h,o(o({ref:t},c),{},{components:n})):r.createElement(h,o({ref:t},c))}));function m(e,t){var n=arguments,a=t&&t.mdxType;if("string"==typeof e||a){var l=n.length,o=new Array(l);o[0]=d;var s={};for(var i in t)hasOwnProperty.call(t,i)&&(s[i]=t[i]);s.originalType=e,s.mdxType="string"==typeof e?e:a,o[1]=s;for(var u=2;u<l;u++)o[u]=n[u];return r.createElement.apply(null,o)}return r.createElement.apply(null,n)}d.displayName="MDXCreateElement"},9713:function(e,t,n){n.r(t),n.d(t,{assets:function(){return c},contentTitle:function(){return i},default:function(){return m},frontMatter:function(){return s},metadata:function(){return u},toc:function(){return p}});var r=n(7462),a=n(3366),l=(n(7294),n(3905)),o=["components"],s={title:"\u7b2c\u4e09\u65b9\u5e93",sidebar_position:7,slug:"/zh-cn/libraries"},i=void 0,u={unversionedId:"zh-cn/Libraries",id:"zh-cn/Libraries",title:"\u7b2c\u4e09\u65b9\u5e93",description:"flv.js",source:"@site/docs/zh-cn/Libraries.mdx",sourceDirName:"zh-cn",slug:"/zh-cn/libraries",permalink:"/document/zh-cn/libraries",draft:!1,tags:[],version:"current",sidebarPosition:7,frontMatter:{title:"\u7b2c\u4e09\u65b9\u5e93",sidebar_position:7,slug:"/zh-cn/libraries"},sidebar:"zh-cn",previous:{title:"\u5b9e\u4f8b\u4e8b\u4ef6",permalink:"/document/zh-cn/events"},next:{title:"\u5f39\u5e55\u5e93\u63d2\u4ef6",permalink:"/document/zh-cn/Plugins/danmuku"}},c={},p=[{value:"flv.js",id:"flvjs",level:2},{value:"hls.js",id:"hlsjs",level:2},{value:"dash.js",id:"dashjs",level:2},{value:"shaka-player",id:"shaka-player",level:2},{value:"webtorrent",id:"webtorrent",level:2}],d={toc:p};function m(e){var t=e.components,n=(0,a.Z)(e,o);return(0,l.kt)("wrapper",(0,r.Z)({},d,n,{components:t,mdxType:"MDXLayout"}),(0,l.kt)("h2",{id:"flvjs"},"flv.js"),(0,l.kt)("ul",null,(0,l.kt)("li",{parentName:"ul"},"\u4e3b\u9875: ",(0,l.kt)("a",{parentName:"li",href:"https://github.com/Bilibili/flv.js"},"https://github.com/Bilibili/flv.js"))),(0,l.kt)("div",{className:"run-code","data-libs":"https://unpkg.com/flv.js@1.6.2/dist/flv.js"},"\u25b6 Run Code"),(0,l.kt)("pre",null,(0,l.kt)("code",{parentName:"pre",className:"language-js"},"var art = new Artplayer({\n container: '.artplayer-app',\n autoplay: true,\n url: '/assets/sample/video.flv',\n customType: {\n flv: function (video, url) {\n if (flvjs.isSupported()) {\n const flvPlayer = flvjs.createPlayer({\n type: 'flv',\n url: url,\n });\n flvPlayer.attachMediaElement(video);\n flvPlayer.load();\n } else {\n art.notice.show = '\u4e0d\u652f\u6301\u64ad\u653e\u683c\u5f0f\uff1aflv';\n }\n },\n },\n});\n")),(0,l.kt)("h2",{id:"hlsjs"},"hls.js"),(0,l.kt)("ul",null,(0,l.kt)("li",{parentName:"ul"},"\u4e3b\u9875: ",(0,l.kt)("a",{parentName:"li",href:"https://github.com/video-dev/hls.js"},"https://github.com/video-dev/hls.js"))),(0,l.kt)("div",{className:"run-code","data-libs":"https://cdnjs.cloudflare.com/ajax/libs/hls.js/8.0.0-beta.3/hls.min.js"},"\u25b6 Run Code"),(0,l.kt)("pre",null,(0,l.kt)("code",{parentName:"pre",className:"language-js"},"var art = new Line truncated
@@ -0,0 +1 @@
"use strict";(self.webpackChunkartplayer_document=self.webpackChunkartplayer_document||[]).push([[235],{876:function(e,n,t){t.d(n,{Zo:function(){return s},kt:function(){return m}});var l=t(2784);function a(e,n,t){return n in e?Object.defineProperty(e,n,{value:t,enumerable:!0,configurable:!0,writable:!0}):e[n]=t,e}function r(e,n){var t=Object.keys(e);if(Object.getOwnPropertySymbols){var l=Object.getOwnPropertySymbols(e);n&&(l=l.filter((function(n){return Object.getOwnPropertyDescriptor(e,n).enumerable}))),t.push.apply(t,l)}return t}function i(e){for(var n=1;n<arguments.length;n++){var t=null!=arguments[n]?arguments[n]:{};n%2?r(Object(t),!0).forEach((function(n){a(e,n,t[n])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(t)):r(Object(t)).forEach((function(n){Object.defineProperty(e,n,Object.getOwnPropertyDescriptor(t,n))}))}return e}function o(e,n){if(null==e)return{};var t,l,a=function(e,n){if(null==e)return{};var t,l,a={},r=Object.keys(e);for(l=0;l<r.length;l++)t=r[l],n.indexOf(t)>=0||(a[t]=e[t]);return a}(e,n);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);for(l=0;l<r.length;l++)t=r[l],n.indexOf(t)>=0||Object.prototype.propertyIsEnumerable.call(e,t)&&(a[t]=e[t])}return a}var c=l.createContext({}),u=function(e){var n=l.useContext(c),t=n;return e&&(t="function"==typeof e?e(n):i(i({},n),e)),t},s=function(e){var n=u(e.components);return l.createElement(c.Provider,{value:n},e.children)},p={inlineCode:"code",wrapper:function(e){var n=e.children;return l.createElement(l.Fragment,{},n)}},d=l.forwardRef((function(e,n){var t=e.components,a=e.mdxType,r=e.originalType,c=e.parentName,s=o(e,["components","mdxType","originalType","parentName"]),d=u(t),m=a,k=d["".concat(c,".").concat(m)]||d[m]||p[m]||r;return t?l.createElement(k,i(i({ref:n},s),{},{components:t})):l.createElement(k,i({ref:n},s))}));function m(e,n){var t=arguments,a=n&&n.mdxType;if("string"==typeof e||a){var r=t.length,i=new Array(r);i[0]=d;var o={};for(var c in n)hasOwnProperty.call(n,c)&&(o[c]=n[c]);o.originalType=e,o.mdxType="string"==typeof e?e:a,i[1]=o;for(var u=2;u<r;u++)i[u]=t[u];return l.createElement.apply(null,i)}return l.createElement.apply(null,t)}d.displayName="MDXCreateElement"},4801:function(e,n,t){t.r(n),t.d(n,{assets:function(){return s},contentTitle:function(){return c},default:function(){return m},frontMatter:function(){return o},metadata:function(){return u},toc:function(){return p}});var l=t(7896),a=t(1461),r=(t(2784),t(876)),i=["components"],o={title:"\u9759\u6001\u5c5e\u6027",sidebar_position:5,slug:"/zh-cn/class"},c=void 0,u={unversionedId:"zh-cn/Class",id:"zh-cn/Class",title:"\u9759\u6001\u5c5e\u6027",description:"\u9759\u6001\u5c5e\u6027\u5b58\u5728\u4e8e\u6784\u9020\u51fd\u6570 Artplayer \u4e0a\uff0c\u548c\u64ad\u653e\u5668\u5b9e\u4f8b\u6ca1\u6709\u76f4\u63a5\u5173\u8054",source:"@site/docs/zh-cn/Class.mdx",sourceDirName:"zh-cn",slug:"/zh-cn/class",permalink:"/document/zh-cn/class",draft:!1,tags:[],version:"current",sidebarPosition:5,frontMatter:{title:"\u9759\u6001\u5c5e\u6027",sidebar_position:5,slug:"/zh-cn/class"},sidebar:"zh-cn",previous:{title:"\u9ad8\u7ea7\u5c5e\u6027",permalink:"/document/zh-cn/advance"},next:{title:"\u5b9e\u4f8b\u4e8b\u4ef6",permalink:"/document/zh-cn/events"}},s={},p=[{value:"instances",id:"instances",level:2},{value:"version",id:"version",level:2},{value:"env",id:"env",level:2},{value:"utils",id:"utils",level:2},{value:"config",id:"config",level:2},{value:"scheme",id:"scheme",level:2},{value:"validator",id:"validator",level:2},{value:"option",id:"option",level:2},{value:"html",id:"html",level:2},{value:"kindOf",id:"kindof",level:2}],d={toc:p};function m(e){var n=e.components,t=(0,a.Z)(e,i);return(0,r.kt)("wrapper",(0,l.Z)({},d,t,{components:n,mdxType:"MDXLayout"}),(0,r.kt)("div",{className:"admonition admonition-tip alert alert--success"},(0,r.kt)("div",{parentName:"div",className:"admonition-heading"},(0,r.kt)("h5",{parentName:"div"},(0,r.kt)("span",{parentName:"h5",className:"admonition-icon"},(0,r.kt)("svg",{parentName:"span",xmlns:"http://www.w3.org/2000/svg",width:"12",height:"16",viewBox:"0 0 12 16"},(0,r.kt)("path",{parentName:"svg",fillRule:"evenodd",d:"M6.5 0C3.48 0 1 2.19 1 5c0 .92.55 2.25 1 3 1.34 2.25 1.78 2.78 2 4v1h5v-1c.22-1.22.66-1.75 2-4 .45-.75 1-2.08 1-3 0-2.81-2.48-5-5.5-5zm3.64 7.48c-.25.44-.47.8-.67 1.11-.86 1.41-1.25 2.06-1.45 3.23-.02.05-.02.11-.02.17H5c0-.06 0-.13-.02-.17-.2-1.17-.59-1.83-1.45-3.23-.2-.31-.42-.67-.67-1.11C2.44 6.78 2 5.65 2 5c0-2.2 2.02-4 4.5-4 1.22 0 2.36.42 3.22 1.19C10.55 2.94 11 3.94 11 5c0 .66-.44 1.78-.86 2.48zM4 14h5c-.23 1.14-1.3 2-2.5 2s-2.27-.86-2.5-2z"}))),"\u63d0\u793a")),(0,r.kt)("div",{parentName:"div",className:"admonition-content"},(0,r.kt)("p",{parentName:"div"},"\u9759\u6001\u5c5e\u6027\u5b58\u5728\u4e8e\u6784\u9020\u51fd\u6570 ",(0,r.kt)("inlineCode",{parentName:"p"},"Artplayer")," \u4e0a\uff0c\u548c\u64ad\u653e\u5668\u5b9e\u4f8b\u6ca1\u6709\u76f4\u63a5\u5173\u8054"))),(0,Line truncated
@@ -1 +0,0 @@
"use strict";(self.webpackChunkartplayer_document=self.webpackChunkartplayer_document||[]).push([[235],{3905:function(e,n,t){t.d(n,{Zo:function(){return s},kt:function(){return m}});var l=t(7294);function a(e,n,t){return n in e?Object.defineProperty(e,n,{value:t,enumerable:!0,configurable:!0,writable:!0}):e[n]=t,e}function r(e,n){var t=Object.keys(e);if(Object.getOwnPropertySymbols){var l=Object.getOwnPropertySymbols(e);n&&(l=l.filter((function(n){return Object.getOwnPropertyDescriptor(e,n).enumerable}))),t.push.apply(t,l)}return t}function i(e){for(var n=1;n<arguments.length;n++){var t=null!=arguments[n]?arguments[n]:{};n%2?r(Object(t),!0).forEach((function(n){a(e,n,t[n])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(t)):r(Object(t)).forEach((function(n){Object.defineProperty(e,n,Object.getOwnPropertyDescriptor(t,n))}))}return e}function o(e,n){if(null==e)return{};var t,l,a=function(e,n){if(null==e)return{};var t,l,a={},r=Object.keys(e);for(l=0;l<r.length;l++)t=r[l],n.indexOf(t)>=0||(a[t]=e[t]);return a}(e,n);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);for(l=0;l<r.length;l++)t=r[l],n.indexOf(t)>=0||Object.prototype.propertyIsEnumerable.call(e,t)&&(a[t]=e[t])}return a}var c=l.createContext({}),u=function(e){var n=l.useContext(c),t=n;return e&&(t="function"==typeof e?e(n):i(i({},n),e)),t},s=function(e){var n=u(e.components);return l.createElement(c.Provider,{value:n},e.children)},p={inlineCode:"code",wrapper:function(e){var n=e.children;return l.createElement(l.Fragment,{},n)}},d=l.forwardRef((function(e,n){var t=e.components,a=e.mdxType,r=e.originalType,c=e.parentName,s=o(e,["components","mdxType","originalType","parentName"]),d=u(t),m=a,k=d["".concat(c,".").concat(m)]||d[m]||p[m]||r;return t?l.createElement(k,i(i({ref:n},s),{},{components:t})):l.createElement(k,i({ref:n},s))}));function m(e,n){var t=arguments,a=n&&n.mdxType;if("string"==typeof e||a){var r=t.length,i=new Array(r);i[0]=d;var o={};for(var c in n)hasOwnProperty.call(n,c)&&(o[c]=n[c]);o.originalType=e,o.mdxType="string"==typeof e?e:a,i[1]=o;for(var u=2;u<r;u++)i[u]=t[u];return l.createElement.apply(null,i)}return l.createElement.apply(null,t)}d.displayName="MDXCreateElement"},287:function(e,n,t){t.r(n),t.d(n,{assets:function(){return s},contentTitle:function(){return c},default:function(){return m},frontMatter:function(){return o},metadata:function(){return u},toc:function(){return p}});var l=t(7462),a=t(3366),r=(t(7294),t(3905)),i=["components"],o={title:"\u9759\u6001\u5c5e\u6027",sidebar_position:5,slug:"/zh-cn/class"},c=void 0,u={unversionedId:"zh-cn/Class",id:"zh-cn/Class",title:"\u9759\u6001\u5c5e\u6027",description:"\u9759\u6001\u5c5e\u6027\u5b58\u5728\u4e8e\u6784\u9020\u51fd\u6570 Artplayer \u4e0a\uff0c\u548c\u64ad\u653e\u5668\u5b9e\u4f8b\u6ca1\u6709\u76f4\u63a5\u5173\u8054",source:"@site/docs/zh-cn/Class.mdx",sourceDirName:"zh-cn",slug:"/zh-cn/class",permalink:"/document/zh-cn/class",draft:!1,tags:[],version:"current",sidebarPosition:5,frontMatter:{title:"\u9759\u6001\u5c5e\u6027",sidebar_position:5,slug:"/zh-cn/class"},sidebar:"zh-cn",previous:{title:"\u9ad8\u7ea7\u5c5e\u6027",permalink:"/document/zh-cn/advance"},next:{title:"\u5b9e\u4f8b\u4e8b\u4ef6",permalink:"/document/zh-cn/events"}},s={},p=[{value:"instances",id:"instances",level:2},{value:"version",id:"version",level:2},{value:"env",id:"env",level:2},{value:"utils",id:"utils",level:2},{value:"config",id:"config",level:2},{value:"scheme",id:"scheme",level:2},{value:"validator",id:"validator",level:2},{value:"option",id:"option",level:2},{value:"html",id:"html",level:2},{value:"kindOf",id:"kindof",level:2}],d={toc:p};function m(e){var n=e.components,t=(0,a.Z)(e,i);return(0,r.kt)("wrapper",(0,l.Z)({},d,t,{components:n,mdxType:"MDXLayout"}),(0,r.kt)("div",{className:"admonition admonition-tip alert alert--success"},(0,r.kt)("div",{parentName:"div",className:"admonition-heading"},(0,r.kt)("h5",{parentName:"div"},(0,r.kt)("span",{parentName:"h5",className:"admonition-icon"},(0,r.kt)("svg",{parentName:"span",xmlns:"http://www.w3.org/2000/svg",width:"12",height:"16",viewBox:"0 0 12 16"},(0,r.kt)("path",{parentName:"svg",fillRule:"evenodd",d:"M6.5 0C3.48 0 1 2.19 1 5c0 .92.55 2.25 1 3 1.34 2.25 1.78 2.78 2 4v1h5v-1c.22-1.22.66-1.75 2-4 .45-.75 1-2.08 1-3 0-2.81-2.48-5-5.5-5zm3.64 7.48c-.25.44-.47.8-.67 1.11-.86 1.41-1.25 2.06-1.45 3.23-.02.05-.02.11-.02.17H5c0-.06 0-.13-.02-.17-.2-1.17-.59-1.83-1.45-3.23-.2-.31-.42-.67-.67-1.11C2.44 6.78 2 5.65 2 5c0-2.2 2.02-4 4.5-4 1.22 0 2.36.42 3.22 1.19C10.55 2.94 11 3.94 11 5c0 .66-.44 1.78-.86 2.48zM4 14h5c-.23 1.14-1.3 2-2.5 2s-2.27-.86-2.5-2z"}))),"\u63d0\u793a")),(0,r.kt)("div",{parentName:"div",className:"admonition-content"},(0,r.kt)("p",{parentName:"div"},"\u9759\u6001\u5c5e\u6027\u5b58\u5728\u4e8e\u6784\u9020\u51fd\u6570 ",(0,r.kt)("inlineCode",{parentName:"p"},"Artplayer")," \u4e0a\uff0c\u548c\u64ad\u653e\u5668\u5b9e\u4f8b\u6ca1\u6709\u76f4\u63a5\u5173\u8054"))),(0Line truncated
@@ -0,0 +1 @@
"use strict";(self.webpackChunkartplayer_document=self.webpackChunkartplayer_document||[]).push([[228],{876:function(e,t,n){n.d(t,{Zo:function(){return d},kt:function(){return s}});var a=n(2784);function l(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function r(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var a=Object.getOwnPropertySymbols(e);t&&(a=a.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,a)}return n}function i(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?r(Object(n),!0).forEach((function(t){l(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):r(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}function p(e,t){if(null==e)return{};var n,a,l=function(e,t){if(null==e)return{};var n,a,l={},r=Object.keys(e);for(a=0;a<r.length;a++)n=r[a],t.indexOf(n)>=0||(l[n]=e[n]);return l}(e,t);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);for(a=0;a<r.length;a++)n=r[a],t.indexOf(n)>=0||Object.prototype.propertyIsEnumerable.call(e,n)&&(l[n]=e[n])}return l}var m=a.createContext({}),o=function(e){var t=a.useContext(m),n=t;return e&&(n="function"==typeof e?e(t):i(i({},t),e)),n},d=function(e){var t=o(e.components);return a.createElement(m.Provider,{value:t},e.children)},u={inlineCode:"code",wrapper:function(e){var t=e.children;return a.createElement(a.Fragment,{},t)}},k=a.forwardRef((function(e,t){var n=e.components,l=e.mdxType,r=e.originalType,m=e.parentName,d=p(e,["components","mdxType","originalType","parentName"]),k=o(n),s=l,N=k["".concat(m,".").concat(s)]||k[s]||u[s]||r;return n?a.createElement(N,i(i({ref:t},d),{},{components:n})):a.createElement(N,i({ref:t},d))}));function s(e,t){var n=arguments,l=t&&t.mdxType;if("string"==typeof e||l){var r=n.length,i=new Array(r);i[0]=k;var p={};for(var m in t)hasOwnProperty.call(t,m)&&(p[m]=t[m]);p.originalType=e,p.mdxType="string"==typeof e?e:l,i[1]=p;for(var o=2;o<r;o++)i[o]=n[o];return a.createElement.apply(null,i)}return a.createElement.apply(null,n)}k.displayName="MDXCreateElement"},3595:function(e,t,n){n.r(t),n.d(t,{assets:function(){return d},contentTitle:function(){return m},default:function(){return s},frontMatter:function(){return p},metadata:function(){return o},toc:function(){return u}});var a=n(7896),l=n(1461),r=(n(2784),n(876)),i=["components"],p={title:"\u57fa\u7840\u53c2\u6570",sidebar_position:2,slug:"/zh-cn/options"},m=void 0,o={unversionedId:"zh-cn/Options",id:"zh-cn/Options",title:"\u57fa\u7840\u53c2\u6570",description:"container",source:"@site/docs/zh-cn/Options.mdx",sourceDirName:"zh-cn",slug:"/zh-cn/options",permalink:"/document/zh-cn/options",draft:!1,tags:[],version:"current",sidebarPosition:2,frontMatter:{title:"\u57fa\u7840\u53c2\u6570",sidebar_position:2,slug:"/zh-cn/options"},sidebar:"zh-cn",previous:{title:"\u5feb\u901f\u4e0a\u624b",permalink:"/document/zh-cn"},next:{title:"\u5e38\u7528\u5c5e\u6027",permalink:"/document/zh-cn/propertie"}},d={},u=[{value:"container",id:"container",level:2},{value:"url",id:"url",level:2},{value:"Ready Callback",id:"ready-callback",level:2},{value:"poster",id:"poster",level:2},{value:"title",id:"title",level:2},{value:"theme",id:"theme",level:2},{value:"volume",id:"volume",level:2},{value:"isLive",id:"islive",level:2},{value:"muted",id:"muted",level:2},{value:"autoplay",id:"autoplay",level:2},{value:"autoSize",id:"autosize",level:2},{value:"autoMini",id:"automini",level:2},{value:"loop",id:"loop",level:2},{value:"flip",id:"flip",level:2},{value:"playbackRate",id:"playbackrate",level:2},{value:"aspectRatio",id:"aspectratio",level:2},{value:"screenshot",id:"screenshot",level:2},{value:"setting",id:"setting",level:2},{value:"hotkey",id:"hotkey",level:2},{value:"pip",id:"pip",level:2},{value:"mutex",id:"mutex",level:2},{value:"fullscreen",id:"fullscreen",level:2},{value:"fullscreenWeb",id:"fullscreenweb",level:2},{value:"subtitleOffset",id:"subtitleoffset",level:2},{value:"miniProgressBar",id:"miniprogressbar",level:2},{value:"useSSR",id:"usessr",level:2},{value:"playsInline",id:"playsinline",level:2},{value:"layers",id:"layers",level:2},{value:"settings",id:"settings",level:2},{value:"contextmenu",id:"contextmenu",level:2},{value:"controls",id:"controls",level:2},{value:"quality",id:"quality",level:2},{value:"highlight",id:"highlight",level:2},{value:"plugins",id:"plugins",level:2},{value:"whitelist",id:"whitelist",level:2},{value:"thumbnails",id:"thumbnails",level:2},{value:"subtitle",id:"subtitle",level:2},{value:"moreVideoAttr",id:"morevideoattr",level:2},{value:"icons",id:"icons",level:2},{value:"type",id:"type",level:2},{value:"customType",id:"customtype",level:2},{value:"lang",id:"lang",level:2},{value:"lock",id:"lock",level:2},{value:"fastForward",id:"fastforward",level:2},{value:"autoPlayback",id:"autoplayback",levelLine truncated
@@ -1 +0,0 @@
"use strict";(self.webpackChunkartplayer_document=self.webpackChunkartplayer_document||[]).push([[228],{3905:function(e,t,n){n.d(t,{Zo:function(){return d},kt:function(){return s}});var a=n(7294);function l(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function r(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var a=Object.getOwnPropertySymbols(e);t&&(a=a.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,a)}return n}function i(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?r(Object(n),!0).forEach((function(t){l(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):r(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}function p(e,t){if(null==e)return{};var n,a,l=function(e,t){if(null==e)return{};var n,a,l={},r=Object.keys(e);for(a=0;a<r.length;a++)n=r[a],t.indexOf(n)>=0||(l[n]=e[n]);return l}(e,t);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);for(a=0;a<r.length;a++)n=r[a],t.indexOf(n)>=0||Object.prototype.propertyIsEnumerable.call(e,n)&&(l[n]=e[n])}return l}var o=a.createContext({}),m=function(e){var t=a.useContext(o),n=t;return e&&(n="function"==typeof e?e(t):i(i({},t),e)),n},d=function(e){var t=m(e.components);return a.createElement(o.Provider,{value:t},e.children)},u={inlineCode:"code",wrapper:function(e){var t=e.children;return a.createElement(a.Fragment,{},t)}},k=a.forwardRef((function(e,t){var n=e.components,l=e.mdxType,r=e.originalType,o=e.parentName,d=p(e,["components","mdxType","originalType","parentName"]),k=m(n),s=l,N=k["".concat(o,".").concat(s)]||k[s]||u[s]||r;return n?a.createElement(N,i(i({ref:t},d),{},{components:n})):a.createElement(N,i({ref:t},d))}));function s(e,t){var n=arguments,l=t&&t.mdxType;if("string"==typeof e||l){var r=n.length,i=new Array(r);i[0]=k;var p={};for(var o in t)hasOwnProperty.call(t,o)&&(p[o]=t[o]);p.originalType=e,p.mdxType="string"==typeof e?e:l,i[1]=p;for(var m=2;m<r;m++)i[m]=n[m];return a.createElement.apply(null,i)}return a.createElement.apply(null,n)}k.displayName="MDXCreateElement"},2623:function(e,t,n){n.r(t),n.d(t,{assets:function(){return d},contentTitle:function(){return o},default:function(){return s},frontMatter:function(){return p},metadata:function(){return m},toc:function(){return u}});var a=n(7462),l=n(3366),r=(n(7294),n(3905)),i=["components"],p={title:"\u57fa\u7840\u53c2\u6570",sidebar_position:2,slug:"/zh-cn/options"},o=void 0,m={unversionedId:"zh-cn/Options",id:"zh-cn/Options",title:"\u57fa\u7840\u53c2\u6570",description:"container",source:"@site/docs/zh-cn/Options.mdx",sourceDirName:"zh-cn",slug:"/zh-cn/options",permalink:"/document/zh-cn/options",draft:!1,tags:[],version:"current",sidebarPosition:2,frontMatter:{title:"\u57fa\u7840\u53c2\u6570",sidebar_position:2,slug:"/zh-cn/options"},sidebar:"zh-cn",previous:{title:"\u5feb\u901f\u4e0a\u624b",permalink:"/document/zh-cn"},next:{title:"\u5e38\u7528\u5c5e\u6027",permalink:"/document/zh-cn/propertie"}},d={},u=[{value:"container",id:"container",level:2},{value:"url",id:"url",level:2},{value:"Ready Callback",id:"ready-callback",level:2},{value:"poster",id:"poster",level:2},{value:"title",id:"title",level:2},{value:"theme",id:"theme",level:2},{value:"volume",id:"volume",level:2},{value:"isLive",id:"islive",level:2},{value:"muted",id:"muted",level:2},{value:"autoplay",id:"autoplay",level:2},{value:"autoSize",id:"autosize",level:2},{value:"autoMini",id:"automini",level:2},{value:"loop",id:"loop",level:2},{value:"flip",id:"flip",level:2},{value:"playbackRate",id:"playbackrate",level:2},{value:"aspectRatio",id:"aspectratio",level:2},{value:"screenshot",id:"screenshot",level:2},{value:"setting",id:"setting",level:2},{value:"hotkey",id:"hotkey",level:2},{value:"pip",id:"pip",level:2},{value:"mutex",id:"mutex",level:2},{value:"fullscreen",id:"fullscreen",level:2},{value:"fullscreenWeb",id:"fullscreenweb",level:2},{value:"subtitleOffset",id:"subtitleoffset",level:2},{value:"miniProgressBar",id:"miniprogressbar",level:2},{value:"useSSR",id:"usessr",level:2},{value:"playsInline",id:"playsinline",level:2},{value:"layers",id:"layers",level:2},{value:"settings",id:"settings",level:2},{value:"contextmenu",id:"contextmenu",level:2},{value:"controls",id:"controls",level:2},{value:"quality",id:"quality",level:2},{value:"highlight",id:"highlight",level:2},{value:"plugins",id:"plugins",level:2},{value:"whitelist",id:"whitelist",level:2},{value:"thumbnails",id:"thumbnails",level:2},{value:"subtitle",id:"subtitle",level:2},{value:"moreVideoAttr",id:"morevideoattr",level:2},{value:"icons",id:"icons",level:2},{value:"type",id:"type",level:2},{value:"customType",id:"customtype",level:2},{value:"lang",id:"lang",level:2},{value:"lock",id:"lock",level:2},{value:"fastForward",id:"fastforward",level:2},{value:"autoPlayback",id:"autoplayback",levLine truncated
@@ -1 +0,0 @@
"use strict";(self.webpackChunkartplayer_document=self.webpackChunkartplayer_document||[]).push([[696],{3905:function(e,t,n){n.d(t,{Zo:function(){return u},kt:function(){return k}});var a=n(7294);function l(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function r(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var a=Object.getOwnPropertySymbols(e);t&&(a=a.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,a)}return n}function i(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?r(Object(n),!0).forEach((function(t){l(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):r(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}function o(e,t){if(null==e)return{};var n,a,l=function(e,t){if(null==e)return{};var n,a,l={},r=Object.keys(e);for(a=0;a<r.length;a++)n=r[a],t.indexOf(n)>=0||(l[n]=e[n]);return l}(e,t);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);for(a=0;a<r.length;a++)n=r[a],t.indexOf(n)>=0||Object.prototype.propertyIsEnumerable.call(e,n)&&(l[n]=e[n])}return l}var p=a.createContext({}),d=function(e){var t=a.useContext(p),n=t;return e&&(n="function"==typeof e?e(t):i(i({},t),e)),n},u=function(e){var t=d(e.components);return a.createElement(p.Provider,{value:t},e.children)},s={inlineCode:"code",wrapper:function(e){var t=e.children;return a.createElement(a.Fragment,{},t)}},m=a.forwardRef((function(e,t){var n=e.components,l=e.mdxType,r=e.originalType,p=e.parentName,u=o(e,["components","mdxType","originalType","parentName"]),m=d(n),k=l,c=m["".concat(p,".").concat(k)]||m[k]||s[k]||r;return n?a.createElement(c,i(i({ref:t},u),{},{components:n})):a.createElement(c,i({ref:t},u))}));function k(e,t){var n=arguments,l=t&&t.mdxType;if("string"==typeof e||l){var r=n.length,i=new Array(r);i[0]=m;var o={};for(var p in t)hasOwnProperty.call(t,p)&&(o[p]=t[p]);o.originalType=e,o.mdxType="string"==typeof e?e:l,i[1]=o;for(var d=2;d<r;d++)i[d]=n[d];return a.createElement.apply(null,i)}return a.createElement.apply(null,n)}m.displayName="MDXCreateElement"},8761:function(e,t,n){n.r(t),n.d(t,{assets:function(){return u},contentTitle:function(){return p},default:function(){return k},frontMatter:function(){return o},metadata:function(){return d},toc:function(){return s}});var a=n(7462),l=n(3366),r=(n(7294),n(3905)),i=["components"],o={title:"Advanced propertys",sidebar_position:4,slug:"/advance"},p=void 0,d={unversionedId:"en/Advance",id:"en/Advance",title:"Advanced propertys",description:"This page is some additional supplements to the commonly used properties, you need to read in depth to develop custom functions.",source:"@site/docs/en/Advance.mdx",sourceDirName:"en",slug:"/advance",permalink:"/document/advance",draft:!1,tags:[],version:"current",sidebarPosition:4,frontMatter:{title:"Advanced propertys",sidebar_position:4,slug:"/advance"},sidebar:"en",previous:{title:"Common properties",permalink:"/document/propertie"},next:{title:"Static propertys",permalink:"/document/class"}},u={},s=[{value:"id",id:"id",level:2},{value:"option",id:"option",level:2},{value:"isFocus",id:"isfocus",level:2},{value:"isInput",id:"isinput",level:2},{value:"isLock",id:"islock",level:2},{value:"isDestroy",id:"isdestroy",level:2},{value:"whitelist",id:"whitelist",level:2},{value:"template",id:"template",level:2},{value:"query",id:"query",level:3},{value:"query",id:"query-1",level:2},{value:"events",id:"events",level:2},{value:"proxy",id:"proxy",level:2},{value:"storage",id:"storage",level:2},{value:"icons",id:"icons",level:2},{value:"i18n",id:"i18n",level:2},{value:"get",id:"get",level:3},{value:"update",id:"update",level:3},{value:"player",id:"player",level:2},{value:"subtitle",id:"subtitle",level:2},{value:"show",id:"show",level:3},{value:"style",id:"style",level:3},{value:"url",id:"url",level:3},{value:"switch",id:"switch",level:3},{value:"info",id:"info",level:2},{value:"layers",id:"layers",level:2},{value:"show",id:"show-1",level:3},{value:"add",id:"add",level:3},{value:"notice",id:"notice",level:2},{value:"show",id:"show-2",level:3},{value:"controls",id:"controls",level:2},{value:"show",id:"show-3",level:3},{value:"add",id:"add-1",level:3},{value:"contextmenu",id:"contextmenu",level:2},{value:"show",id:"show-4",level:3},{value:"add",id:"add-2",level:3},{value:"loading",id:"loading",level:2},{value:"show",id:"show-5",level:3},{value:"mask",id:"mask",level:2},{value:"show",id:"show-6",level:3},{value:"hotkey",id:"hotkey",level:2},{value:"add",id:"add-3",level:3},{value:"setting",id:"setting",level:2},{value:"show",id:"show-7",level:3},{value:"plugins",id:"plugins",level:2},{value:"add",id:"add-4",level:3}],m={toc:s};function k(e){var t=e.components,n=(0,l.Z)(e,i);return(0,r.kt)("wrapper",(0,a.Z)({},m,n,{components:t,mdxType:"MDXLayout"}),(0,r.kt)("div",{className:"admonLine truncated
@@ -0,0 +1 @@
"use strict";(self.webpackChunkartplayer_document=self.webpackChunkartplayer_document||[]).push([[696],{876:function(e,t,n){n.d(t,{Zo:function(){return u},kt:function(){return k}});var a=n(2784);function l(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function r(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var a=Object.getOwnPropertySymbols(e);t&&(a=a.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,a)}return n}function i(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?r(Object(n),!0).forEach((function(t){l(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):r(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}function o(e,t){if(null==e)return{};var n,a,l=function(e,t){if(null==e)return{};var n,a,l={},r=Object.keys(e);for(a=0;a<r.length;a++)n=r[a],t.indexOf(n)>=0||(l[n]=e[n]);return l}(e,t);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);for(a=0;a<r.length;a++)n=r[a],t.indexOf(n)>=0||Object.prototype.propertyIsEnumerable.call(e,n)&&(l[n]=e[n])}return l}var p=a.createContext({}),d=function(e){var t=a.useContext(p),n=t;return e&&(n="function"==typeof e?e(t):i(i({},t),e)),n},u=function(e){var t=d(e.components);return a.createElement(p.Provider,{value:t},e.children)},s={inlineCode:"code",wrapper:function(e){var t=e.children;return a.createElement(a.Fragment,{},t)}},m=a.forwardRef((function(e,t){var n=e.components,l=e.mdxType,r=e.originalType,p=e.parentName,u=o(e,["components","mdxType","originalType","parentName"]),m=d(n),k=l,c=m["".concat(p,".").concat(k)]||m[k]||s[k]||r;return n?a.createElement(c,i(i({ref:t},u),{},{components:n})):a.createElement(c,i({ref:t},u))}));function k(e,t){var n=arguments,l=t&&t.mdxType;if("string"==typeof e||l){var r=n.length,i=new Array(r);i[0]=m;var o={};for(var p in t)hasOwnProperty.call(t,p)&&(o[p]=t[p]);o.originalType=e,o.mdxType="string"==typeof e?e:l,i[1]=o;for(var d=2;d<r;d++)i[d]=n[d];return a.createElement.apply(null,i)}return a.createElement.apply(null,n)}m.displayName="MDXCreateElement"},2565:function(e,t,n){n.r(t),n.d(t,{assets:function(){return u},contentTitle:function(){return p},default:function(){return k},frontMatter:function(){return o},metadata:function(){return d},toc:function(){return s}});var a=n(7896),l=n(1461),r=(n(2784),n(876)),i=["components"],o={title:"Advanced propertys",sidebar_position:4,slug:"/advance"},p=void 0,d={unversionedId:"en/Advance",id:"en/Advance",title:"Advanced propertys",description:"This page is some additional supplements to the commonly used properties, you need to read in depth to develop custom functions.",source:"@site/docs/en/Advance.mdx",sourceDirName:"en",slug:"/advance",permalink:"/document/advance",draft:!1,tags:[],version:"current",sidebarPosition:4,frontMatter:{title:"Advanced propertys",sidebar_position:4,slug:"/advance"},sidebar:"en",previous:{title:"Common properties",permalink:"/document/propertie"},next:{title:"Static propertys",permalink:"/document/class"}},u={},s=[{value:"id",id:"id",level:2},{value:"option",id:"option",level:2},{value:"isFocus",id:"isfocus",level:2},{value:"isInput",id:"isinput",level:2},{value:"isLock",id:"islock",level:2},{value:"isDestroy",id:"isdestroy",level:2},{value:"whitelist",id:"whitelist",level:2},{value:"template",id:"template",level:2},{value:"query",id:"query",level:3},{value:"query",id:"query-1",level:2},{value:"events",id:"events",level:2},{value:"proxy",id:"proxy",level:2},{value:"storage",id:"storage",level:2},{value:"icons",id:"icons",level:2},{value:"i18n",id:"i18n",level:2},{value:"get",id:"get",level:3},{value:"update",id:"update",level:3},{value:"player",id:"player",level:2},{value:"subtitle",id:"subtitle",level:2},{value:"show",id:"show",level:3},{value:"style",id:"style",level:3},{value:"url",id:"url",level:3},{value:"switch",id:"switch",level:3},{value:"info",id:"info",level:2},{value:"layers",id:"layers",level:2},{value:"show",id:"show-1",level:3},{value:"add",id:"add",level:3},{value:"notice",id:"notice",level:2},{value:"show",id:"show-2",level:3},{value:"controls",id:"controls",level:2},{value:"show",id:"show-3",level:3},{value:"add",id:"add-1",level:3},{value:"contextmenu",id:"contextmenu",level:2},{value:"show",id:"show-4",level:3},{value:"add",id:"add-2",level:3},{value:"loading",id:"loading",level:2},{value:"show",id:"show-5",level:3},{value:"mask",id:"mask",level:2},{value:"show",id:"show-6",level:3},{value:"hotkey",id:"hotkey",level:2},{value:"add",id:"add-3",level:3},{value:"setting",id:"setting",level:2},{value:"show",id:"show-7",level:3},{value:"plugins",id:"plugins",level:2},{value:"add",id:"add-4",level:3}],m={toc:s};function k(e){var t=e.components,n=(0,l.Z)(e,i);return(0,r.kt)("wrapper",(0,a.Z)({},m,n,{components:t,mdxType:"MDXLayout"}),(0,r.kt)("div",{className:"admonitLine truncated
@@ -1 +0,0 @@
"use strict";(self.webpackChunkartplayer_document=self.webpackChunkartplayer_document||[]).push([[122],{3905:function(e,t,n){n.d(t,{Zo:function(){return u},kt:function(){return d}});var r=n(7294);function a(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function l(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,r)}return n}function s(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?l(Object(n),!0).forEach((function(t){a(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):l(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}function i(e,t){if(null==e)return{};var n,r,a=function(e,t){if(null==e)return{};var n,r,a={},l=Object.keys(e);for(r=0;r<l.length;r++)n=l[r],t.indexOf(n)>=0||(a[n]=e[n]);return a}(e,t);if(Object.getOwnPropertySymbols){var l=Object.getOwnPropertySymbols(e);for(r=0;r<l.length;r++)n=l[r],t.indexOf(n)>=0||Object.prototype.propertyIsEnumerable.call(e,n)&&(a[n]=e[n])}return a}var o=r.createContext({}),p=function(e){var t=r.useContext(o),n=t;return e&&(n="function"==typeof e?e(t):s(s({},t),e)),n},u=function(e){var t=p(e.components);return r.createElement(o.Provider,{value:t},e.children)},c={inlineCode:"code",wrapper:function(e){var t=e.children;return r.createElement(r.Fragment,{},t)}},m=r.forwardRef((function(e,t){var n=e.components,a=e.mdxType,l=e.originalType,o=e.parentName,u=i(e,["components","mdxType","originalType","parentName"]),m=p(n),d=a,y=m["".concat(o,".").concat(d)]||m[d]||c[d]||l;return n?r.createElement(y,s(s({ref:t},u),{},{components:n})):r.createElement(y,s({ref:t},u))}));function d(e,t){var n=arguments,a=t&&t.mdxType;if("string"==typeof e||a){var l=n.length,s=new Array(l);s[0]=m;var i={};for(var o in t)hasOwnProperty.call(t,o)&&(i[o]=t[o]);i.originalType=e,i.mdxType="string"==typeof e?e:a,s[1]=i;for(var p=2;p<l;p++)s[p]=n[p];return r.createElement.apply(null,s)}return r.createElement.apply(null,n)}m.displayName="MDXCreateElement"},2360:function(e,t,n){n.d(t,{Z:function(){return s}});var r=n(7294),a=n(6010),l="tabItem_OmH5";function s(e){var t=e.children,n=e.hidden,s=e.className;return r.createElement("div",{role:"tabpanel",className:(0,a.Z)(l,s),hidden:n},t)}},9877:function(e,t,n){n.d(t,{Z:function(){return d}});var r=n(7462),a=n(7294),l=n(2389),s=n(7392),i=n(7094),o=n(2466),p=n(6010),u="tabList_uSqn",c="tabItem_LplD";function m(e){var t,n,l,m=e.lazy,d=e.block,y=e.defaultValue,v=e.values,f=e.groupId,h=e.className,b=a.Children.map(e.children,(function(e){if((0,a.isValidElement)(e)&&void 0!==e.props.value)return e;throw new Error("Docusaurus error: Bad <Tabs> child <"+("string"==typeof e.type?e.type:e.type.name)+'>: all children of the <Tabs> component should be <TabItem>, and every <TabItem> should have a unique "value" prop.')})),g=null!=v?v:b.map((function(e){var t=e.props;return{value:t.value,label:t.label,attributes:t.attributes}})),k=(0,s.l)(g,(function(e,t){return e.value===t.value}));if(k.length>0)throw new Error('Docusaurus error: Duplicate values "'+k.map((function(e){return e.value})).join(", ")+'" found in <Tabs>. Every value needs to be unique.');var N=null===y?y:null!=(t=null!=y?y:null==(n=b.find((function(e){return e.props.default})))?void 0:n.props.value)?t:null==(l=b[0])?void 0:l.props.value;if(null!==N&&!g.some((function(e){return e.value===N})))throw new Error('Docusaurus error: The <Tabs> has a defaultValue "'+N+'" but none of its children has the corresponding value. Available values are: '+g.map((function(e){return e.value})).join(", ")+". If you intend to show no default tab, use defaultValue={null} instead.");var x=(0,i.U)(),j=x.tabGroupChoices,w=x.setTabGroupChoices,T=(0,a.useState)(N),A=T[0],O=T[1],I=[],Z=(0,o.o5)().blockElementScrollPositionUntilNextRender;if(null!=f){var E=j[f];null!=E&&E!==A&&g.some((function(e){return e.value===E}))&&O(E)}var P=function(e){var t=e.currentTarget,n=I.indexOf(t),r=g[n].value;r!==A&&(Z(t),O(r),null!=f&&w(f,r))},L=function(e){var t,n=null;switch(e.key){case"ArrowRight":var r=I.indexOf(e.currentTarget)+1;n=I[r]||I[0];break;case"ArrowLeft":var a=I.indexOf(e.currentTarget)-1;n=I[a]||I[I.length-1]}null==(t=n)||t.focus()};return a.createElement("div",{className:(0,p.Z)("tabs-container",u)},a.createElement("ul",{role:"tablist","aria-orientation":"horizontal",className:(0,p.Z)("tabs",{"tabs--block":d},h)},g.map((function(e){var t=e.value,n=e.label,l=e.attributes;return a.createElement("li",(0,r.Z)({role:"tab",tabIndex:A===t?0:-1,"aria-selected":A===t,key:t,ref:function(e){return I.push(e)},onKeyDown:L,onFocus:P,onClick:P},l,{className:(0,p.Z)("tabs__item",c,null==l?void 0:l.className,{"tabs__item--active":A===t})}),null!=n?n:t)}))),m?(0,a.cloneElement)(b.filter((function(e){Line truncated
@@ -0,0 +1 @@
"use strict";(self.webpackChunkartplayer_document=self.webpackChunkartplayer_document||[]).push([[122],{876:function(e,t,n){n.d(t,{Zo:function(){return u},kt:function(){return d}});var r=n(2784);function a(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function l(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,r)}return n}function s(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?l(Object(n),!0).forEach((function(t){a(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):l(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}function i(e,t){if(null==e)return{};var n,r,a=function(e,t){if(null==e)return{};var n,r,a={},l=Object.keys(e);for(r=0;r<l.length;r++)n=l[r],t.indexOf(n)>=0||(a[n]=e[n]);return a}(e,t);if(Object.getOwnPropertySymbols){var l=Object.getOwnPropertySymbols(e);for(r=0;r<l.length;r++)n=l[r],t.indexOf(n)>=0||Object.prototype.propertyIsEnumerable.call(e,n)&&(a[n]=e[n])}return a}var o=r.createContext({}),p=function(e){var t=r.useContext(o),n=t;return e&&(n="function"==typeof e?e(t):s(s({},t),e)),n},u=function(e){var t=p(e.components);return r.createElement(o.Provider,{value:t},e.children)},c={inlineCode:"code",wrapper:function(e){var t=e.children;return r.createElement(r.Fragment,{},t)}},m=r.forwardRef((function(e,t){var n=e.components,a=e.mdxType,l=e.originalType,o=e.parentName,u=i(e,["components","mdxType","originalType","parentName"]),m=p(n),d=a,y=m["".concat(o,".").concat(d)]||m[d]||c[d]||l;return n?r.createElement(y,s(s({ref:t},u),{},{components:n})):r.createElement(y,s({ref:t},u))}));function d(e,t){var n=arguments,a=t&&t.mdxType;if("string"==typeof e||a){var l=n.length,s=new Array(l);s[0]=m;var i={};for(var o in t)hasOwnProperty.call(t,o)&&(i[o]=t[o]);i.originalType=e,i.mdxType="string"==typeof e?e:a,s[1]=i;for(var p=2;p<l;p++)s[p]=n[p];return r.createElement.apply(null,s)}return r.createElement.apply(null,n)}m.displayName="MDXCreateElement"},8294:function(e,t,n){n.d(t,{Z:function(){return s}});var r=n(2784),a=n(6277),l="tabItem_zQZC";function s(e){var t=e.children,n=e.hidden,s=e.className;return r.createElement("div",{role:"tabpanel",className:(0,a.Z)(l,s),hidden:n},t)}},7370:function(e,t,n){n.d(t,{Z:function(){return d}});var r=n(7896),a=n(2784),l=n(9741),s=n(2244),i=n(8963),o=n(4126),p=n(6277),u="tabList_vG2x",c="tabItem_yrY8";function m(e){var t,n,l,m=e.lazy,d=e.block,y=e.defaultValue,v=e.values,f=e.groupId,h=e.className,b=a.Children.map(e.children,(function(e){if((0,a.isValidElement)(e)&&void 0!==e.props.value)return e;throw new Error("Docusaurus error: Bad <Tabs> child <"+("string"==typeof e.type?e.type:e.type.name)+'>: all children of the <Tabs> component should be <TabItem>, and every <TabItem> should have a unique "value" prop.')})),g=null!=v?v:b.map((function(e){var t=e.props;return{value:t.value,label:t.label,attributes:t.attributes}})),k=(0,s.l)(g,(function(e,t){return e.value===t.value}));if(k.length>0)throw new Error('Docusaurus error: Duplicate values "'+k.map((function(e){return e.value})).join(", ")+'" found in <Tabs>. Every value needs to be unique.');var N=null===y?y:null!=(t=null!=y?y:null==(n=b.find((function(e){return e.props.default})))?void 0:n.props.value)?t:null==(l=b[0])?void 0:l.props.value;if(null!==N&&!g.some((function(e){return e.value===N})))throw new Error('Docusaurus error: The <Tabs> has a defaultValue "'+N+'" but none of its children has the corresponding value. Available values are: '+g.map((function(e){return e.value})).join(", ")+". If you intend to show no default tab, use defaultValue={null} instead.");var x=(0,i.U)(),j=x.tabGroupChoices,w=x.setTabGroupChoices,T=(0,a.useState)(N),A=T[0],O=T[1],I=[],Z=(0,o.o5)().blockElementScrollPositionUntilNextRender;if(null!=f){var E=j[f];null!=E&&E!==A&&g.some((function(e){return e.value===E}))&&O(E)}var P=function(e){var t=e.currentTarget,n=I.indexOf(t),r=g[n].value;r!==A&&(Z(t),O(r),null!=f&&w(f,r))},C=function(e){var t,n=null;switch(e.key){case"ArrowRight":var r=I.indexOf(e.currentTarget)+1;n=I[r]||I[0];break;case"ArrowLeft":var a=I.indexOf(e.currentTarget)-1;n=I[a]||I[I.length-1]}null==(t=n)||t.focus()};return a.createElement("div",{className:(0,p.Z)("tabs-container",u)},a.createElement("ul",{role:"tablist","aria-orientation":"horizontal",className:(0,p.Z)("tabs",{"tabs--block":d},h)},g.map((function(e){var t=e.value,n=e.label,l=e.attributes;return a.createElement("li",(0,r.Z)({role:"tab",tabIndex:A===t?0:-1,"aria-selected":A===t,key:t,ref:function(e){return I.push(e)},onKeyDown:C,onFocus:P,onClick:P},l,{className:(0,p.Z)("tabs__item",c,null==l?void 0:l.className,{"tabs__item--active":A===t})}),null!=n?n:t)}))),m?(0,a.cloneElement)(b.filter((function(e){rLine truncated
@@ -1 +0,0 @@
"use strict";(self.webpackChunkartplayer_document=self.webpackChunkartplayer_document||[]).push([[376],{3905:function(n,e,t){t.d(e,{Zo:function(){return l},kt:function(){return f}});var r=t(7294);function o(n,e,t){return e in n?Object.defineProperty(n,e,{value:t,enumerable:!0,configurable:!0,writable:!0}):n[e]=t,n}function a(n,e){var t=Object.keys(n);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(n);e&&(r=r.filter((function(e){return Object.getOwnPropertyDescriptor(n,e).enumerable}))),t.push.apply(t,r)}return t}function i(n){for(var e=1;e<arguments.length;e++){var t=null!=arguments[e]?arguments[e]:{};e%2?a(Object(t),!0).forEach((function(e){o(n,e,t[e])})):Object.getOwnPropertyDescriptors?Object.defineProperties(n,Object.getOwnPropertyDescriptors(t)):a(Object(t)).forEach((function(e){Object.defineProperty(n,e,Object.getOwnPropertyDescriptor(t,e))}))}return n}function s(n,e){if(null==n)return{};var t,r,o=function(n,e){if(null==n)return{};var t,r,o={},a=Object.keys(n);for(r=0;r<a.length;r++)t=a[r],e.indexOf(t)>=0||(o[t]=n[t]);return o}(n,e);if(Object.getOwnPropertySymbols){var a=Object.getOwnPropertySymbols(n);for(r=0;r<a.length;r++)t=a[r],e.indexOf(t)>=0||Object.prototype.propertyIsEnumerable.call(n,t)&&(o[t]=n[t])}return o}var c=r.createContext({}),u=function(n){var e=r.useContext(c),t=e;return n&&(t="function"==typeof n?n(e):i(i({},e),n)),t},l=function(n){var e=u(n.components);return r.createElement(c.Provider,{value:e},n.children)},p={inlineCode:"code",wrapper:function(n){var e=n.children;return r.createElement(r.Fragment,{},e)}},d=r.forwardRef((function(n,e){var t=n.components,o=n.mdxType,a=n.originalType,c=n.parentName,l=s(n,["components","mdxType","originalType","parentName"]),d=u(t),f=o,m=d["".concat(c,".").concat(f)]||d[f]||p[f]||a;return t?r.createElement(m,i(i({ref:e},l),{},{components:t})):r.createElement(m,i({ref:e},l))}));function f(n,e){var t=arguments,o=e&&e.mdxType;if("string"==typeof n||o){var a=t.length,i=new Array(a);i[0]=d;var s={};for(var c in e)hasOwnProperty.call(e,c)&&(s[c]=e[c]);s.originalType=n,s.mdxType="string"==typeof n?n:o,i[1]=s;for(var u=2;u<a;u++)i[u]=t[u];return r.createElement.apply(null,i)}return r.createElement.apply(null,t)}d.displayName="MDXCreateElement"},10:function(n,e,t){t.r(e),t.d(e,{assets:function(){return l},contentTitle:function(){return c},default:function(){return f},frontMatter:function(){return s},metadata:function(){return u},toc:function(){return p}});var r=t(7462),o=t(3366),a=(t(7294),t(3905)),i=["components"],s={title:"\u5982\u4f55\u6dfb\u52a0\u89c6\u9891\u5e7f\u544a",sidebar_position:5},c=void 0,u={unversionedId:"zh-cn/Questions/How_to_add_video_ads",id:"zh-cn/Questions/How_to_add_video_ads",title:"\u5982\u4f55\u6dfb\u52a0\u89c6\u9891\u5e7f\u544a",description:"\u89c6\u9891\u5e7f\u544a\u5b58\u5728\u4e8e\u6b63\u5f0f\u89c6\u9891\u64ad\u653e\u4e4b\u524d\uff0c\u652f\u6301\u591a\u4e2a\u89c6\u9891\u5e7f\u544a",source:"@site/docs/zh-cn/Questions/How_to_add_video_ads.mdx",sourceDirName:"zh-cn/Questions",slug:"/zh-cn/Questions/How_to_add_video_ads",permalink:"/document/zh-cn/Questions/How_to_add_video_ads",draft:!1,tags:[],version:"current",sidebarPosition:5,frontMatter:{title:"\u5982\u4f55\u6dfb\u52a0\u89c6\u9891\u5e7f\u544a",sidebar_position:5},sidebar:"zh-cn",previous:{title:"\u5982\u4f55\u5bfc\u5165\u7c7b\u578b",permalink:"/document/zh-cn/Questions/How_to_import_types"},next:{title:"\u600e\u4e48\u6dfb\u52a0\u8bbe\u7f6e\u9762\u677f",permalink:"/document/zh-cn/Questions/How_to_add_setting_panel"}},l={},p=[],d={toc:p};function f(n){var e=n.components,t=(0,o.Z)(n,i);return(0,a.kt)("wrapper",(0,r.Z)({},d,t,{components:e,mdxType:"MDXLayout"}),(0,a.kt)("p",null,"\u89c6\u9891\u5e7f\u544a\u5b58\u5728\u4e8e\u6b63\u5f0f\u89c6\u9891\u64ad\u653e\u4e4b\u524d\uff0c\u652f\u6301\u591a\u4e2a\u89c6\u9891\u5e7f\u544a"),(0,a.kt)("div",{className:"run-code"},"\u25b6 Run Code"),(0,a.kt)("pre",null,(0,a.kt)("code",{parentName:"pre",className:"language-js"},"var art = new Artplayer({\n container: '.artplayer-app',\n url: 'https://artplayer.org/assets/sample/video.mp4',\n muted: true,\n autoSize: true,\n autoplay: true,\n ads: [\n {\n url: '/assets/sample/test1.mp4',\n },\n {\n url: '/assets/sample/test2.webm',\n },\n ],\n controls: [\n {\n position: 'right',\n html: '\u8df3\u8fc7\u5e7f\u544a',\n click: function () {\n art.ads.end();\n },\n },\n ],\n layers: [\n {\n html: '\u8df3\u8fc7\u5e7f\u544a',\n style: {\n position: 'absolute',\n top: '20px',\n right: '20px',\n },\n click: function () {\n art.ads.end();\n },\n },\n ],\n});\n\nart.on('ready', function () {\n // \u5f53\u6bcf\u4e2a\u89c6\u9891\u5e7f\u544a\u64ad\u653e\u65f6\u89e6\u53d1\n art.on('ads:start', function (item) {\ Line truncated
@@ -0,0 +1 @@
"use strict";(self.webpackChunkartplayer_document=self.webpackChunkartplayer_document||[]).push([[881],{876:function(e,t,n){n.d(t,{Zo:function(){return l},kt:function(){return d}});var r=n(2784);function o(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function i(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,r)}return n}function a(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?i(Object(n),!0).forEach((function(t){o(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):i(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}function c(e,t){if(null==e)return{};var n,r,o=function(e,t){if(null==e)return{};var n,r,o={},i=Object.keys(e);for(r=0;r<i.length;r++)n=i[r],t.indexOf(n)>=0||(o[n]=e[n]);return o}(e,t);if(Object.getOwnPropertySymbols){var i=Object.getOwnPropertySymbols(e);for(r=0;r<i.length;r++)n=i[r],t.indexOf(n)>=0||Object.prototype.propertyIsEnumerable.call(e,n)&&(o[n]=e[n])}return o}var u=r.createContext({}),s=function(e){var t=r.useContext(u),n=t;return e&&(n="function"==typeof e?e(t):a(a({},t),e)),n},l=function(e){var t=s(e.components);return r.createElement(u.Provider,{value:t},e.children)},p={inlineCode:"code",wrapper:function(e){var t=e.children;return r.createElement(r.Fragment,{},t)}},f=r.forwardRef((function(e,t){var n=e.components,o=e.mdxType,i=e.originalType,u=e.parentName,l=c(e,["components","mdxType","originalType","parentName"]),f=s(n),d=o,m=f["".concat(u,".").concat(d)]||f[d]||p[d]||i;return n?r.createElement(m,a(a({ref:t},l),{},{components:n})):r.createElement(m,a({ref:t},l))}));function d(e,t){var n=arguments,o=t&&t.mdxType;if("string"==typeof e||o){var i=n.length,a=new Array(i);a[0]=f;var c={};for(var u in t)hasOwnProperty.call(t,u)&&(c[u]=t[u]);c.originalType=e,c.mdxType="string"==typeof e?e:o,a[1]=c;for(var s=2;s<i;s++)a[s]=n[s];return r.createElement.apply(null,a)}return r.createElement.apply(null,n)}f.displayName="MDXCreateElement"},3191:function(e,t,n){n.r(t),n.d(t,{assets:function(){return l},contentTitle:function(){return u},default:function(){return d},frontMatter:function(){return c},metadata:function(){return s},toc:function(){return p}});var r=n(7896),o=n(1461),i=(n(2784),n(876)),a=["components"],c={title:"Add button to the controls",sidebar_position:2},u=void 0,s={unversionedId:"en/Questions/Create_button_in_the_controls",id:"en/Questions/Create_button_in_the_controls",title:"Add button to the controls",description:"\u25b6 Run Code",source:"@site/docs/en/Questions/Create_button_in_the_controls.mdx",sourceDirName:"en/Questions",slug:"/en/Questions/Create_button_in_the_controls",permalink:"/document/en/Questions/Create_button_in_the_controls",draft:!1,tags:[],version:"current",sidebarPosition:2,frontMatter:{title:"Add button to the controls",sidebar_position:2},sidebar:"en",previous:{title:"Add select in the controls",permalink:"/document/en/Questions/Create_selector_in_the_controls"},next:{title:"Handle a single component",permalink:"/document/en/Questions/Handle_single_component"}},l={},p=[],f={toc:p};function d(e){var t=e.components,n=(0,o.Z)(e,a);return(0,i.kt)("wrapper",(0,r.Z)({},f,n,{components:t,mdxType:"MDXLayout"}),(0,i.kt)("div",{className:"run-code"},"\u25b6 Run Code"),(0,i.kt)("pre",null,(0,i.kt)("code",{parentName:"pre",className:"language-js"},"var time = 0;\nvar art = new Artplayer({\n container: '.artplayer-app',\n url: '/assets/sample/video.mp4',\n controls: [\n {\n position: 'right',\n html: '<button type=\"button\">Click Me!</button>',\n click: function (_, event) {\n // The second parameter is an event object\n time += 1;\n event.target.innerText = 'You Click ' + time;\n },\n },\n ],\n});\n")))}d.isMDXComponent=!0}}]);
@@ -1 +0,0 @@
"use strict";(self.webpackChunkartplayer_document=self.webpackChunkartplayer_document||[]).push([[881],{3905:function(e,t,n){n.d(t,{Zo:function(){return l},kt:function(){return d}});var r=n(7294);function o(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function i(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,r)}return n}function a(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?i(Object(n),!0).forEach((function(t){o(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):i(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}function c(e,t){if(null==e)return{};var n,r,o=function(e,t){if(null==e)return{};var n,r,o={},i=Object.keys(e);for(r=0;r<i.length;r++)n=i[r],t.indexOf(n)>=0||(o[n]=e[n]);return o}(e,t);if(Object.getOwnPropertySymbols){var i=Object.getOwnPropertySymbols(e);for(r=0;r<i.length;r++)n=i[r],t.indexOf(n)>=0||Object.prototype.propertyIsEnumerable.call(e,n)&&(o[n]=e[n])}return o}var u=r.createContext({}),s=function(e){var t=r.useContext(u),n=t;return e&&(n="function"==typeof e?e(t):a(a({},t),e)),n},l=function(e){var t=s(e.components);return r.createElement(u.Provider,{value:t},e.children)},p={inlineCode:"code",wrapper:function(e){var t=e.children;return r.createElement(r.Fragment,{},t)}},f=r.forwardRef((function(e,t){var n=e.components,o=e.mdxType,i=e.originalType,u=e.parentName,l=c(e,["components","mdxType","originalType","parentName"]),f=s(n),d=o,m=f["".concat(u,".").concat(d)]||f[d]||p[d]||i;return n?r.createElement(m,a(a({ref:t},l),{},{components:n})):r.createElement(m,a({ref:t},l))}));function d(e,t){var n=arguments,o=t&&t.mdxType;if("string"==typeof e||o){var i=n.length,a=new Array(i);a[0]=f;var c={};for(var u in t)hasOwnProperty.call(t,u)&&(c[u]=t[u]);c.originalType=e,c.mdxType="string"==typeof e?e:o,a[1]=c;for(var s=2;s<i;s++)a[s]=n[s];return r.createElement.apply(null,a)}return r.createElement.apply(null,n)}f.displayName="MDXCreateElement"},7224:function(e,t,n){n.r(t),n.d(t,{assets:function(){return l},contentTitle:function(){return u},default:function(){return d},frontMatter:function(){return c},metadata:function(){return s},toc:function(){return p}});var r=n(7462),o=n(3366),i=(n(7294),n(3905)),a=["components"],c={title:"Add button to the controls",sidebar_position:2},u=void 0,s={unversionedId:"en/Questions/Create_button_in_the_controls",id:"en/Questions/Create_button_in_the_controls",title:"Add button to the controls",description:"\u25b6 Run Code",source:"@site/docs/en/Questions/Create_button_in_the_controls.mdx",sourceDirName:"en/Questions",slug:"/en/Questions/Create_button_in_the_controls",permalink:"/document/en/Questions/Create_button_in_the_controls",draft:!1,tags:[],version:"current",sidebarPosition:2,frontMatter:{title:"Add button to the controls",sidebar_position:2},sidebar:"en",previous:{title:"Add select in the controls",permalink:"/document/en/Questions/Create_selector_in_the_controls"},next:{title:"Handle a single component",permalink:"/document/en/Questions/Handle_single_component"}},l={},p=[],f={toc:p};function d(e){var t=e.components,n=(0,o.Z)(e,a);return(0,i.kt)("wrapper",(0,r.Z)({},f,n,{components:t,mdxType:"MDXLayout"}),(0,i.kt)("div",{className:"run-code"},"\u25b6 Run Code"),(0,i.kt)("pre",null,(0,i.kt)("code",{parentName:"pre",className:"language-js"},"var time = 0;\nvar art = new Artplayer({\n container: '.artplayer-app',\n url: '/assets/sample/video.mp4',\n controls: [\n {\n position: 'right',\n html: '<button type=\"button\">Click Me!</button>',\n click: function (_, event) {\n // The second parameter is an event object\n time += 1;\n event.target.innerText = 'You Click ' + time;\n },\n },\n ],\n});\n")))}d.isMDXComponent=!0}}]);
@@ -0,0 +1 @@
"use strict";(self.webpackChunkartplayer_document=self.webpackChunkartplayer_document||[]).push([[740],{876:function(t,n,e){e.d(n,{Zo:function(){return d},kt:function(){return c}});var a=e(2784);function r(t,n,e){return n in t?Object.defineProperty(t,n,{value:e,enumerable:!0,configurable:!0,writable:!0}):t[n]=e,t}function l(t,n){var e=Object.keys(t);if(Object.getOwnPropertySymbols){var a=Object.getOwnPropertySymbols(t);n&&(a=a.filter((function(n){return Object.getOwnPropertyDescriptor(t,n).enumerable}))),e.push.apply(e,a)}return e}function i(t){for(var n=1;n<arguments.length;n++){var e=null!=arguments[n]?arguments[n]:{};n%2?l(Object(e),!0).forEach((function(n){r(t,n,e[n])})):Object.getOwnPropertyDescriptors?Object.defineProperties(t,Object.getOwnPropertyDescriptors(e)):l(Object(e)).forEach((function(n){Object.defineProperty(t,n,Object.getOwnPropertyDescriptor(e,n))}))}return t}function o(t,n){if(null==t)return{};var e,a,r=function(t,n){if(null==t)return{};var e,a,r={},l=Object.keys(t);for(a=0;a<l.length;a++)e=l[a],n.indexOf(e)>=0||(r[e]=t[e]);return r}(t,n);if(Object.getOwnPropertySymbols){var l=Object.getOwnPropertySymbols(t);for(a=0;a<l.length;a++)e=l[a],n.indexOf(e)>=0||Object.prototype.propertyIsEnumerable.call(t,e)&&(r[e]=t[e])}return r}var m=a.createContext({}),p=function(t){var n=a.useContext(m),e=n;return t&&(e="function"==typeof t?t(n):i(i({},n),t)),e},d=function(t){var n=p(t.components);return a.createElement(m.Provider,{value:n},t.children)},u={inlineCode:"code",wrapper:function(t){var n=t.children;return a.createElement(a.Fragment,{},n)}},s=a.forwardRef((function(t,n){var e=t.components,r=t.mdxType,l=t.originalType,m=t.parentName,d=o(t,["components","mdxType","originalType","parentName"]),s=p(e),c=r,k=s["".concat(m,".").concat(c)]||s[c]||u[c]||l;return e?a.createElement(k,i(i({ref:n},d),{},{components:e})):a.createElement(k,i({ref:n},d))}));function c(t,n){var e=arguments,r=n&&n.mdxType;if("string"==typeof t||r){var l=e.length,i=new Array(l);i[0]=s;var o={};for(var m in n)hasOwnProperty.call(n,m)&&(o[m]=n[m]);o.originalType=t,o.mdxType="string"==typeof t?t:r,i[1]=o;for(var p=2;p<l;p++)i[p]=e[p];return a.createElement.apply(null,i)}return a.createElement.apply(null,e)}s.displayName="MDXCreateElement"},7861:function(t,n,e){e.r(n),e.d(n,{assets:function(){return d},contentTitle:function(){return m},default:function(){return c},frontMatter:function(){return o},metadata:function(){return p},toc:function(){return u}});var a=e(7896),r=e(1461),l=(e(2784),e(876)),i=["components"],o={title:"\u600e\u4e48\u6dfb\u52a0\u8bbe\u7f6e\u9762\u677f",sidebar_position:6},m=void 0,p={unversionedId:"zh-cn/Questions/How_to_add_setting_panel",id:"zh-cn/Questions/How_to_add_setting_panel",title:"\u600e\u4e48\u6dfb\u52a0\u8bbe\u7f6e\u9762\u677f",description:"\u6dfb\u52a0\u9009\u62e9\u5217\u8868",source:"@site/docs/zh-cn/Questions/How_to_add_setting_panel.mdx",sourceDirName:"zh-cn/Questions",slug:"/zh-cn/Questions/How_to_add_setting_panel",permalink:"/document/zh-cn/Questions/How_to_add_setting_panel",draft:!1,tags:[],version:"current",sidebarPosition:6,frontMatter:{title:"\u600e\u4e48\u6dfb\u52a0\u8bbe\u7f6e\u9762\u677f",sidebar_position:6},sidebar:"zh-cn",previous:{title:"\u5982\u4f55\u5bfc\u5165\u7c7b\u578b",permalink:"/document/zh-cn/Questions/How_to_import_types"},next:{title:"\u4e0e React Portal \u4f7f\u7528",permalink:"/document/zh-cn/Questions/Use_with_react_portal"}},d={},u=[{value:"\u6dfb\u52a0\u9009\u62e9\u5217\u8868",id:"\u6dfb\u52a0\u9009\u62e9\u5217\u8868",level:2},{value:"\u6dfb\u52a0\u5207\u6362\u6309\u94ae",id:"\u6dfb\u52a0\u5207\u6362\u6309\u94ae",level:2},{value:"\u6dfb\u52a0\u8303\u56f4\u6ed1\u52a8",id:"\u6dfb\u52a0\u8303\u56f4\u6ed1\u52a8",level:2}],s={toc:u};function c(t){var n=t.components,e=(0,r.Z)(t,i);return(0,l.kt)("wrapper",(0,a.Z)({},s,e,{components:n,mdxType:"MDXLayout"}),(0,l.kt)("h2",{id:"\u6dfb\u52a0\u9009\u62e9\u5217\u8868"},"\u6dfb\u52a0\u9009\u62e9\u5217\u8868"),(0,l.kt)("p",null,"\u8bbe\u7f6e\u9762\u677f\u7c7b\u4f3c\u4e8e\u5217\u8868\u9009\u62e9\u7684\u96c6\u5408\uff0c\u800c\u4e14\u652f\u6301\u591a\u5c42\u5d4c\u5957"),(0,l.kt)("table",null,(0,l.kt)("thead",{parentName:"table"},(0,l.kt)("tr",{parentName:"thead"},(0,l.kt)("th",{parentName:"tr",align:null},"\u5c5e\u6027"),(0,l.kt)("th",{parentName:"tr",align:null},"\u7c7b\u578b"),(0,l.kt)("th",{parentName:"tr",align:null},"\u63cf\u8ff0"))),(0,l.kt)("tbody",{parentName:"table"},(0,l.kt)("tr",{parentName:"tbody"},(0,l.kt)("td",{parentName:"tr",align:null},(0,l.kt)("inlineCode",{parentName:"td"},"html")),(0,l.kt)("td",{parentName:"tr",align:null},(0,l.kt)("inlineCode",{parentName:"td"},"String"),"\u3001",(0,l.kt)("inlineCode",{parentName:"td"},"Element")),(0,l.kt)("td",{parentName:"tr",align:null},"\u5143\u7d20\u7684 DOM \u5143\u7d20")),(0,l.kt)("tr",{parentName:"tbody"},(0,l.kt)("td",{parentName:"tr",align:null},(0,l.kt)("inlineCode",{parentName:"td"},"icon")),(0,l.kt)("td",{parentName:"tr",align:null},(0,l.kt)("inlineCode",{parentName:"td"}Line truncated
@@ -1 +0,0 @@
"use strict";(self.webpackChunkartplayer_document=self.webpackChunkartplayer_document||[]).push([[740],{3905:function(t,n,e){e.d(n,{Zo:function(){return d},kt:function(){return c}});var a=e(7294);function r(t,n,e){return n in t?Object.defineProperty(t,n,{value:e,enumerable:!0,configurable:!0,writable:!0}):t[n]=e,t}function l(t,n){var e=Object.keys(t);if(Object.getOwnPropertySymbols){var a=Object.getOwnPropertySymbols(t);n&&(a=a.filter((function(n){return Object.getOwnPropertyDescriptor(t,n).enumerable}))),e.push.apply(e,a)}return e}function i(t){for(var n=1;n<arguments.length;n++){var e=null!=arguments[n]?arguments[n]:{};n%2?l(Object(e),!0).forEach((function(n){r(t,n,e[n])})):Object.getOwnPropertyDescriptors?Object.defineProperties(t,Object.getOwnPropertyDescriptors(e)):l(Object(e)).forEach((function(n){Object.defineProperty(t,n,Object.getOwnPropertyDescriptor(e,n))}))}return t}function o(t,n){if(null==t)return{};var e,a,r=function(t,n){if(null==t)return{};var e,a,r={},l=Object.keys(t);for(a=0;a<l.length;a++)e=l[a],n.indexOf(e)>=0||(r[e]=t[e]);return r}(t,n);if(Object.getOwnPropertySymbols){var l=Object.getOwnPropertySymbols(t);for(a=0;a<l.length;a++)e=l[a],n.indexOf(e)>=0||Object.prototype.propertyIsEnumerable.call(t,e)&&(r[e]=t[e])}return r}var m=a.createContext({}),p=function(t){var n=a.useContext(m),e=n;return t&&(e="function"==typeof t?t(n):i(i({},n),t)),e},d=function(t){var n=p(t.components);return a.createElement(m.Provider,{value:n},t.children)},u={inlineCode:"code",wrapper:function(t){var n=t.children;return a.createElement(a.Fragment,{},n)}},s=a.forwardRef((function(t,n){var e=t.components,r=t.mdxType,l=t.originalType,m=t.parentName,d=o(t,["components","mdxType","originalType","parentName"]),s=p(e),c=r,k=s["".concat(m,".").concat(c)]||s[c]||u[c]||l;return e?a.createElement(k,i(i({ref:n},d),{},{components:e})):a.createElement(k,i({ref:n},d))}));function c(t,n){var e=arguments,r=n&&n.mdxType;if("string"==typeof t||r){var l=e.length,i=new Array(l);i[0]=s;var o={};for(var m in n)hasOwnProperty.call(n,m)&&(o[m]=n[m]);o.originalType=t,o.mdxType="string"==typeof t?t:r,i[1]=o;for(var p=2;p<l;p++)i[p]=e[p];return a.createElement.apply(null,i)}return a.createElement.apply(null,e)}s.displayName="MDXCreateElement"},4043:function(t,n,e){e.r(n),e.d(n,{assets:function(){return d},contentTitle:function(){return m},default:function(){return c},frontMatter:function(){return o},metadata:function(){return p},toc:function(){return u}});var a=e(7462),r=e(3366),l=(e(7294),e(3905)),i=["components"],o={title:"\u600e\u4e48\u6dfb\u52a0\u8bbe\u7f6e\u9762\u677f",sidebar_position:6},m=void 0,p={unversionedId:"zh-cn/Questions/How_to_add_setting_panel",id:"zh-cn/Questions/How_to_add_setting_panel",title:"\u600e\u4e48\u6dfb\u52a0\u8bbe\u7f6e\u9762\u677f",description:"\u6dfb\u52a0\u9009\u62e9\u5217\u8868",source:"@site/docs/zh-cn/Questions/How_to_add_setting_panel.mdx",sourceDirName:"zh-cn/Questions",slug:"/zh-cn/Questions/How_to_add_setting_panel",permalink:"/document/zh-cn/Questions/How_to_add_setting_panel",draft:!1,tags:[],version:"current",sidebarPosition:6,frontMatter:{title:"\u600e\u4e48\u6dfb\u52a0\u8bbe\u7f6e\u9762\u677f",sidebar_position:6},sidebar:"zh-cn",previous:{title:"\u5982\u4f55\u6dfb\u52a0\u89c6\u9891\u5e7f\u544a",permalink:"/document/zh-cn/Questions/How_to_add_video_ads"},next:{title:"\u4e0e React Portal \u4f7f\u7528",permalink:"/document/zh-cn/Questions/Use_with_react_portal"}},d={},u=[{value:"\u6dfb\u52a0\u9009\u62e9\u5217\u8868",id:"\u6dfb\u52a0\u9009\u62e9\u5217\u8868",level:2},{value:"\u6dfb\u52a0\u5207\u6362\u6309\u94ae",id:"\u6dfb\u52a0\u5207\u6362\u6309\u94ae",level:2},{value:"\u6dfb\u52a0\u8303\u56f4\u6ed1\u52a8",id:"\u6dfb\u52a0\u8303\u56f4\u6ed1\u52a8",level:2}],s={toc:u};function c(t){var n=t.components,e=(0,r.Z)(t,i);return(0,l.kt)("wrapper",(0,a.Z)({},s,e,{components:n,mdxType:"MDXLayout"}),(0,l.kt)("h2",{id:"\u6dfb\u52a0\u9009\u62e9\u5217\u8868"},"\u6dfb\u52a0\u9009\u62e9\u5217\u8868"),(0,l.kt)("p",null,"\u8bbe\u7f6e\u9762\u677f\u7c7b\u4f3c\u4e8e\u5217\u8868\u9009\u62e9\u7684\u96c6\u5408\uff0c\u800c\u4e14\u652f\u6301\u591a\u5c42\u5d4c\u5957"),(0,l.kt)("table",null,(0,l.kt)("thead",{parentName:"table"},(0,l.kt)("tr",{parentName:"thead"},(0,l.kt)("th",{parentName:"tr",align:null},"\u5c5e\u6027"),(0,l.kt)("th",{parentName:"tr",align:null},"\u7c7b\u578b"),(0,l.kt)("th",{parentName:"tr",align:null},"\u63cf\u8ff0"))),(0,l.kt)("tbody",{parentName:"table"},(0,l.kt)("tr",{parentName:"tbody"},(0,l.kt)("td",{parentName:"tr",align:null},(0,l.kt)("inlineCode",{parentName:"td"},"html")),(0,l.kt)("td",{parentName:"tr",align:null},(0,l.kt)("inlineCode",{parentName:"td"},"String"),"\u3001",(0,l.kt)("inlineCode",{parentName:"td"},"Element")),(0,l.kt)("td",{parentName:"tr",align:null},"\u5143\u7d20\u7684 DOM \u5143\u7d20")),(0,l.kt)("tr",{parentName:"tbody"},(0,l.kt)("td",{parentName:"tr",align:null},(0,l.kt)("inlineCode",{parentName:"td"},"icon")),(0,l.kt)("td",{parentName:"tr",align:null},(0,l.kt)("inlineCode",{pLine truncated
@@ -1 +0,0 @@
"use strict";(self.webpackChunkartplayer_document=self.webpackChunkartplayer_document||[]).push([[591],{3905:function(e,t,n){n.d(t,{Zo:function(){return p},kt:function(){return m}});var r=n(7294);function a(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function l(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,r)}return n}function o(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?l(Object(n),!0).forEach((function(t){a(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):l(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}function s(e,t){if(null==e)return{};var n,r,a=function(e,t){if(null==e)return{};var n,r,a={},l=Object.keys(e);for(r=0;r<l.length;r++)n=l[r],t.indexOf(n)>=0||(a[n]=e[n]);return a}(e,t);if(Object.getOwnPropertySymbols){var l=Object.getOwnPropertySymbols(e);for(r=0;r<l.length;r++)n=l[r],t.indexOf(n)>=0||Object.prototype.propertyIsEnumerable.call(e,n)&&(a[n]=e[n])}return a}var i=r.createContext({}),u=function(e){var t=r.useContext(i),n=t;return e&&(n="function"==typeof e?e(t):o(o({},t),e)),n},p=function(e){var t=u(e.components);return r.createElement(i.Provider,{value:t},e.children)},c={inlineCode:"code",wrapper:function(e){var t=e.children;return r.createElement(r.Fragment,{},t)}},d=r.forwardRef((function(e,t){var n=e.components,a=e.mdxType,l=e.originalType,i=e.parentName,p=s(e,["components","mdxType","originalType","parentName"]),d=u(n),m=a,f=d["".concat(i,".").concat(m)]||d[m]||c[m]||l;return n?r.createElement(f,o(o({ref:t},p),{},{components:n})):r.createElement(f,o({ref:t},p))}));function m(e,t){var n=arguments,a=t&&t.mdxType;if("string"==typeof e||a){var l=n.length,o=new Array(l);o[0]=d;var s={};for(var i in t)hasOwnProperty.call(t,i)&&(s[i]=t[i]);s.originalType=e,s.mdxType="string"==typeof e?e:a,o[1]=s;for(var u=2;u<l;u++)o[u]=n[u];return r.createElement.apply(null,o)}return r.createElement.apply(null,n)}d.displayName="MDXCreateElement"},6165:function(e,t,n){n.r(t),n.d(t,{assets:function(){return p},contentTitle:function(){return i},default:function(){return m},frontMatter:function(){return s},metadata:function(){return u},toc:function(){return c}});var r=n(7462),a=n(3366),l=(n(7294),n(3905)),o=["components"],s={title:"Third party librarys",sidebar_position:7,slug:"/libraries"},i=void 0,u={unversionedId:"en/Libraries",id:"en/Libraries",title:"Third party librarys",description:"flv.js",source:"@site/docs/en/Libraries.mdx",sourceDirName:"en",slug:"/libraries",permalink:"/document/libraries",draft:!1,tags:[],version:"current",sidebarPosition:7,frontMatter:{title:"Third party librarys",sidebar_position:7,slug:"/libraries"},sidebar:"en",previous:{title:"Common events",permalink:"/document/events"},next:{title:"Danmuku plugin",permalink:"/document/en/Plugins/danmuku"}},p={},c=[{value:"flv.js",id:"flvjs",level:2},{value:"hls.js",id:"hlsjs",level:2},{value:"dash.js",id:"dashjs",level:2},{value:"shaka-player",id:"shaka-player",level:2},{value:"webtorrent",id:"webtorrent",level:2}],d={toc:c};function m(e){var t=e.components,n=(0,a.Z)(e,o);return(0,l.kt)("wrapper",(0,r.Z)({},d,n,{components:t,mdxType:"MDXLayout"}),(0,l.kt)("h2",{id:"flvjs"},"flv.js"),(0,l.kt)("ul",null,(0,l.kt)("li",{parentName:"ul"},"Homepage: ",(0,l.kt)("a",{parentName:"li",href:"https://github.com/Bilibili/flv.js"},"https://github.com/Bilibili/flv.js"))),(0,l.kt)("div",{className:"run-code","data-libs":"https://unpkg.com/flv.js@1.6.2/dist/flv.js"},"\u25b6 Run Code"),(0,l.kt)("pre",null,(0,l.kt)("code",{parentName:"pre",className:"language-js"},"var art = new Artplayer({\n container: '.artplayer-app',\n autoplay: true,\n url: '/assets/sample/video.flv',\n customType: {\n flv: function (video, url) {\n if (flvjs.isSupported()) {\n const flvPlayer = flvjs.createPlayer({\n type: 'flv',\n url: url,\n });\n flvPlayer.attachMediaElement(video);\n flvPlayer.load();\n } else {\n art.notice.show = 'Does not support playback of flv';\n }\n },\n },\n});\n")),(0,l.kt)("h2",{id:"hlsjs"},"hls.js"),(0,l.kt)("ul",null,(0,l.kt)("li",{parentName:"ul"},"Homepage: ",(0,l.kt)("a",{parentName:"li",href:"https://github.com/video-dev/hls.js"},"https://github.com/video-dev/hls.js"))),(0,l.kt)("div",{className:"run-code","data-libs":"https://cdnjs.cloudflare.com/ajax/libs/hls.js/8.0.0-beta.3/hls.min.js"},"\u25b6 Run Code"),(0,l.kt)("pre",null,(0,l.kt)("code",{parentName:"pre",className:"language-js"},"var art = new Artplayer({\n container: '.artplayer-app',\n autoplay: true,\n url: 'https://test-streams.mux.dev/x36xhz Line truncated
@@ -0,0 +1 @@
"use strict";(self.webpackChunkartplayer_document=self.webpackChunkartplayer_document||[]).push([[591],{876:function(e,t,n){n.d(t,{Zo:function(){return p},kt:function(){return m}});var r=n(2784);function a(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function l(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);t&&(r=r.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,r)}return n}function o(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?l(Object(n),!0).forEach((function(t){a(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):l(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}function s(e,t){if(null==e)return{};var n,r,a=function(e,t){if(null==e)return{};var n,r,a={},l=Object.keys(e);for(r=0;r<l.length;r++)n=l[r],t.indexOf(n)>=0||(a[n]=e[n]);return a}(e,t);if(Object.getOwnPropertySymbols){var l=Object.getOwnPropertySymbols(e);for(r=0;r<l.length;r++)n=l[r],t.indexOf(n)>=0||Object.prototype.propertyIsEnumerable.call(e,n)&&(a[n]=e[n])}return a}var i=r.createContext({}),u=function(e){var t=r.useContext(i),n=t;return e&&(n="function"==typeof e?e(t):o(o({},t),e)),n},p=function(e){var t=u(e.components);return r.createElement(i.Provider,{value:t},e.children)},c={inlineCode:"code",wrapper:function(e){var t=e.children;return r.createElement(r.Fragment,{},t)}},d=r.forwardRef((function(e,t){var n=e.components,a=e.mdxType,l=e.originalType,i=e.parentName,p=s(e,["components","mdxType","originalType","parentName"]),d=u(n),m=a,f=d["".concat(i,".").concat(m)]||d[m]||c[m]||l;return n?r.createElement(f,o(o({ref:t},p),{},{components:n})):r.createElement(f,o({ref:t},p))}));function m(e,t){var n=arguments,a=t&&t.mdxType;if("string"==typeof e||a){var l=n.length,o=new Array(l);o[0]=d;var s={};for(var i in t)hasOwnProperty.call(t,i)&&(s[i]=t[i]);s.originalType=e,s.mdxType="string"==typeof e?e:a,o[1]=s;for(var u=2;u<l;u++)o[u]=n[u];return r.createElement.apply(null,o)}return r.createElement.apply(null,n)}d.displayName="MDXCreateElement"},8213:function(e,t,n){n.r(t),n.d(t,{assets:function(){return p},contentTitle:function(){return i},default:function(){return m},frontMatter:function(){return s},metadata:function(){return u},toc:function(){return c}});var r=n(7896),a=n(1461),l=(n(2784),n(876)),o=["components"],s={title:"Third party librarys",sidebar_position:7,slug:"/libraries"},i=void 0,u={unversionedId:"en/Libraries",id:"en/Libraries",title:"Third party librarys",description:"flv.js",source:"@site/docs/en/Libraries.mdx",sourceDirName:"en",slug:"/libraries",permalink:"/document/libraries",draft:!1,tags:[],version:"current",sidebarPosition:7,frontMatter:{title:"Third party librarys",sidebar_position:7,slug:"/libraries"},sidebar:"en",previous:{title:"Common events",permalink:"/document/events"},next:{title:"Danmuku plugin",permalink:"/document/en/Plugins/danmuku"}},p={},c=[{value:"flv.js",id:"flvjs",level:2},{value:"hls.js",id:"hlsjs",level:2},{value:"dash.js",id:"dashjs",level:2},{value:"shaka-player",id:"shaka-player",level:2},{value:"webtorrent",id:"webtorrent",level:2}],d={toc:c};function m(e){var t=e.components,n=(0,a.Z)(e,o);return(0,l.kt)("wrapper",(0,r.Z)({},d,n,{components:t,mdxType:"MDXLayout"}),(0,l.kt)("h2",{id:"flvjs"},"flv.js"),(0,l.kt)("ul",null,(0,l.kt)("li",{parentName:"ul"},"Homepage: ",(0,l.kt)("a",{parentName:"li",href:"https://github.com/Bilibili/flv.js"},"https://github.com/Bilibili/flv.js"))),(0,l.kt)("div",{className:"run-code","data-libs":"https://unpkg.com/flv.js@1.6.2/dist/flv.js"},"\u25b6 Run Code"),(0,l.kt)("pre",null,(0,l.kt)("code",{parentName:"pre",className:"language-js"},"var art = new Artplayer({\n container: '.artplayer-app',\n autoplay: true,\n url: '/assets/sample/video.flv',\n customType: {\n flv: function (video, url) {\n if (flvjs.isSupported()) {\n const flvPlayer = flvjs.createPlayer({\n type: 'flv',\n url: url,\n });\n flvPlayer.attachMediaElement(video);\n flvPlayer.load();\n } else {\n art.notice.show = 'Does not support playback of flv';\n }\n },\n },\n});\n")),(0,l.kt)("h2",{id:"hlsjs"},"hls.js"),(0,l.kt)("ul",null,(0,l.kt)("li",{parentName:"ul"},"Homepage: ",(0,l.kt)("a",{parentName:"li",href:"https://github.com/video-dev/hls.js"},"https://github.com/video-dev/hls.js"))),(0,l.kt)("div",{className:"run-code","data-libs":"https://cdnjs.cloudflare.com/ajax/libs/hls.js/8.0.0-beta.3/hls.min.js"},"\u25b6 Run Code"),(0,l.kt)("pre",null,(0,l.kt)("code",{parentName:"pre",className:"language-js"},"var art = new Artplayer({\n container: '.artplayer-app',\n autoplay: true,\n url: 'https://test-streams.mux.dev/x36xhzz/ Line truncated
@@ -0,0 +1 @@
"use strict";(self.webpackChunkartplayer_document=self.webpackChunkartplayer_document||[]).push([[509],{876:function(e,n,t){t.d(n,{Zo:function(){return u},kt:function(){return m}});var r=t(2784);function a(e,n,t){return n in e?Object.defineProperty(e,n,{value:t,enumerable:!0,configurable:!0,writable:!0}):e[n]=t,e}function l(e,n){var t=Object.keys(e);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(e);n&&(r=r.filter((function(n){return Object.getOwnPropertyDescriptor(e,n).enumerable}))),t.push.apply(t,r)}return t}function i(e){for(var n=1;n<arguments.length;n++){var t=null!=arguments[n]?arguments[n]:{};n%2?l(Object(t),!0).forEach((function(n){a(e,n,t[n])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(t)):l(Object(t)).forEach((function(n){Object.defineProperty(e,n,Object.getOwnPropertyDescriptor(t,n))}))}return e}function o(e,n){if(null==e)return{};var t,r,a=function(e,n){if(null==e)return{};var t,r,a={},l=Object.keys(e);for(r=0;r<l.length;r++)t=l[r],n.indexOf(t)>=0||(a[t]=e[t]);return a}(e,n);if(Object.getOwnPropertySymbols){var l=Object.getOwnPropertySymbols(e);for(r=0;r<l.length;r++)t=l[r],n.indexOf(t)>=0||Object.prototype.propertyIsEnumerable.call(e,t)&&(a[t]=e[t])}return a}var s=r.createContext({}),p=function(e){var n=r.useContext(s),t=n;return e&&(t="function"==typeof e?e(n):i(i({},n),e)),t},u=function(e){var n=p(e.components);return r.createElement(s.Provider,{value:n},e.children)},c={inlineCode:"code",wrapper:function(e){var n=e.children;return r.createElement(r.Fragment,{},n)}},d=r.forwardRef((function(e,n){var t=e.components,a=e.mdxType,l=e.originalType,s=e.parentName,u=o(e,["components","mdxType","originalType","parentName"]),d=p(t),m=a,f=d["".concat(s,".").concat(m)]||d[m]||c[m]||l;return t?r.createElement(f,i(i({ref:n},u),{},{components:t})):r.createElement(f,i({ref:n},u))}));function m(e,n){var t=arguments,a=n&&n.mdxType;if("string"==typeof e||a){var l=t.length,i=new Array(l);i[0]=d;var o={};for(var s in n)hasOwnProperty.call(n,s)&&(o[s]=n[s]);o.originalType=e,o.mdxType="string"==typeof e?e:a,i[1]=o;for(var p=2;p<l;p++)i[p]=t[p];return r.createElement.apply(null,i)}return r.createElement.apply(null,t)}d.displayName="MDXCreateElement"},7439:function(e,n,t){t.r(n),t.d(n,{assets:function(){return u},contentTitle:function(){return s},default:function(){return m},frontMatter:function(){return o},metadata:function(){return p},toc:function(){return c}});var r=t(7896),a=t(1461),l=(t(2784),t(876)),i=["components"],o={title:"Ads Plugin",sidebar_position:2},s=void 0,p={unversionedId:"en/Plugins/ads",id:"en/Plugins/ads",title:"Ads Plugin",description:"Demo",source:"@site/docs/en/Plugins/ads.mdx",sourceDirName:"en/Plugins",slug:"/en/Plugins/ads",permalink:"/document/en/Plugins/ads",draft:!1,tags:[],version:"current",sidebarPosition:2,frontMatter:{title:"Ads Plugin",sidebar_position:2},sidebar:"en",previous:{title:"Danmuku plugin",permalink:"/document/en/Plugins/danmuku"},next:{title:"Add select in the controls",permalink:"/document/en/Questions/Create_selector_in_the_controls"}},u={},c=[{value:"Demo",id:"demo",level:2},{value:"Install",id:"install",level:2},{value:"Install from <code>npm</code>:",id:"install-from-npm",level:3},{value:"Install from <code>yarn</code>:",id:"install-from-yarn",level:3},{value:"Install from <code>script</code>:",id:"install-from-script",level:3},{value:"Use",id:"use",level:2}],d={toc:c};function m(e){var n=e.components,t=(0,a.Z)(e,i);return(0,l.kt)("wrapper",(0,r.Z)({},d,t,{components:n,mdxType:"MDXLayout"}),(0,l.kt)("h2",{id:"demo"},"Demo"),(0,l.kt)("p",null,"\ud83d\udc49 ",(0,l.kt)("a",{parentName:"p",href:"https://artplayer.org/?libs=./uncompiled/artplayer-plugin-ads/index.js&example=ads"},"View Demo")),(0,l.kt)("h2",{id:"install"},"Install"),(0,l.kt)("h3",{id:"install-from-npm"},"Install from ",(0,l.kt)("inlineCode",{parentName:"h3"},"npm"),":"),(0,l.kt)("pre",null,(0,l.kt)("code",{parentName:"pre",className:"language-bash"},"$ npm install artplayer-plugin-ads\n")),(0,l.kt)("h3",{id:"install-from-yarn"},"Install from ",(0,l.kt)("inlineCode",{parentName:"h3"},"yarn"),":"),(0,l.kt)("pre",null,(0,l.kt)("code",{parentName:"pre",className:"language-bash"},"$ yarn add artplayer-plugin-ads\n")),(0,l.kt)("h3",{id:"install-from-script"},"Install from ",(0,l.kt)("inlineCode",{parentName:"h3"},"script"),":"),(0,l.kt)("pre",null,(0,l.kt)("code",{parentName:"pre",className:"language-html"},'\x3c!-- local --\x3e\n<script src="path/to/artplayer-plugin-ads.js"><\/script>\n\n\x3c!-- jsdelivr --\x3e\n<script src="https://cdn.jsdelivr.net/npm/artplayer-plugin-ads/dist/artplayer-plugin-ads.js"><\/script>\n\n\x3c!-- unpkg --\x3e\n<script src="https://unpkg.com/artplayer-plugin-ads/dist/artplayer-plugin-ads.js"><\/script>\n')),(0,l.kt)("p",null,"Then you can access the plugin function through ",(0,l.kt)("inlineCode",{parentName:"p"},"window.artplayerPluginAds")),(0,l.kt)("h2",{id:"use"},"Use"),(0,l.kt)("div",{className:"run-code",Line truncated
@@ -0,0 +1 @@
"use strict";(self.webpackChunkartplayer_document=self.webpackChunkartplayer_document||[]).push([[14],{876:function(e,t,n){n.d(t,{Zo:function(){return p},kt:function(){return c}});var a=n(2784);function r(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function l(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var a=Object.getOwnPropertySymbols(e);t&&(a=a.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,a)}return n}function o(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?l(Object(n),!0).forEach((function(t){r(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):l(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}function i(e,t){if(null==e)return{};var n,a,r=function(e,t){if(null==e)return{};var n,a,r={},l=Object.keys(e);for(a=0;a<l.length;a++)n=l[a],t.indexOf(n)>=0||(r[n]=e[n]);return r}(e,t);if(Object.getOwnPropertySymbols){var l=Object.getOwnPropertySymbols(e);for(a=0;a<l.length;a++)n=l[a],t.indexOf(n)>=0||Object.prototype.propertyIsEnumerable.call(e,n)&&(r[n]=e[n])}return r}var d=a.createContext({}),s=function(e){var t=a.useContext(d),n=t;return e&&(n="function"==typeof e?e(t):o(o({},t),e)),n},p=function(e){var t=s(e.components);return a.createElement(d.Provider,{value:t},e.children)},u={inlineCode:"code",wrapper:function(e){var t=e.children;return a.createElement(a.Fragment,{},t)}},m=a.forwardRef((function(e,t){var n=e.components,r=e.mdxType,l=e.originalType,d=e.parentName,p=i(e,["components","mdxType","originalType","parentName"]),m=s(n),c=r,v=m["".concat(d,".").concat(c)]||m[c]||u[c]||l;return n?a.createElement(v,o(o({ref:t},p),{},{components:n})):a.createElement(v,o({ref:t},p))}));function c(e,t){var n=arguments,r=t&&t.mdxType;if("string"==typeof e||r){var l=n.length,o=new Array(l);o[0]=m;var i={};for(var d in t)hasOwnProperty.call(t,d)&&(i[d]=t[d]);i.originalType=e,i.mdxType="string"==typeof e?e:r,o[1]=i;for(var s=2;s<l;s++)o[s]=n[s];return a.createElement.apply(null,o)}return a.createElement.apply(null,n)}m.displayName="MDXCreateElement"},7928:function(e,t,n){n.r(t),n.d(t,{assets:function(){return p},contentTitle:function(){return d},default:function(){return c},frontMatter:function(){return i},metadata:function(){return s},toc:function(){return u}});var a=n(7896),r=n(1461),l=(n(2784),n(876)),o=["components"],i={title:"Common events",sidebar_position:6,slug:"/events"},d=void 0,s={unversionedId:"en/Events",id:"en/Events",title:"Common events",description:"The event of the player is divided into two, a native event of a video, and another is a custom event. The native event comes from Video Elements, is the original event of the Video Element, in order to distinguish it and custom events, the native event adds a prefix video:",source:"@site/docs/en/Events.mdx",sourceDirName:"en",slug:"/events",permalink:"/document/events",draft:!1,tags:[],version:"current",sidebarPosition:6,frontMatter:{title:"Common events",sidebar_position:6,slug:"/events"},sidebar:"en",previous:{title:"Static propertys",permalink:"/document/class"},next:{title:"Third party librarys",permalink:"/document/libraries"}},p={},u=[{value:"Native event",id:"native-event",level:2},{value:"Custom event",id:"custom-event",level:2},{value:"ready",id:"ready",level:3},{value:"play",id:"play",level:3},{value:"pause",id:"pause",level:3},{value:"seek",id:"seek",level:3},{value:"volume",id:"volume",level:3},{value:"destroy",id:"destroy",level:3},{value:"focus",id:"focus",level:3},{value:"blur",id:"blur",level:3},{value:"hover",id:"hover",level:3},{value:"resize",id:"resize",level:3},{value:"mousemove",id:"mousemove",level:3},{value:"url",id:"url",level:3},{value:"fullscreen",id:"fullscreen",level:3},{value:"fullscreenWeb",id:"fullscreenweb",level:3},{value:"hotkey",id:"hotkey",level:3}],m={toc:u};function c(e){var t=e.components,n=(0,r.Z)(e,o);return(0,l.kt)("wrapper",(0,a.Z)({},m,n,{components:t,mdxType:"MDXLayout"}),(0,l.kt)("p",null,"The event of the player is divided into two, a ",(0,l.kt)("inlineCode",{parentName:"p"},"native event")," of a video, and another is a ",(0,l.kt)("inlineCode",{parentName:"p"},"custom event"),". The ",(0,l.kt)("inlineCode",{parentName:"p"},"native event")," comes from ",(0,l.kt)("inlineCode",{parentName:"p"},"Video Elements"),", is the original event of the ",(0,l.kt)("inlineCode",{parentName:"p"},"Video Element"),", in order to distinguish it and ",(0,l.kt)("inlineCode",{parentName:"p"},"custom events"),", the native event adds a prefix ",(0,l.kt)("inlineCode",{parentName:"p"},"video:")),(0,l.kt)("h2",{id:"native-event"},"Native event"),(0,l.kt)("p",null,"For more information, please read ",(0,l.kt)("a",{parentName:"p",href:"https://developer.mozilla.org/en-US/docs/Web/HTML/Element/video#events"},"Mozilla Video Events")),(0,l.kt)("table",null,(0,l.ktLine truncated
@@ -1 +0,0 @@
"use strict";(self.webpackChunkartplayer_document=self.webpackChunkartplayer_document||[]).push([[14],{3905:function(e,t,n){n.d(t,{Zo:function(){return p},kt:function(){return c}});var a=n(7294);function r(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function l(e,t){var n=Object.keys(e);if(Object.getOwnPropertySymbols){var a=Object.getOwnPropertySymbols(e);t&&(a=a.filter((function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable}))),n.push.apply(n,a)}return n}function o(e){for(var t=1;t<arguments.length;t++){var n=null!=arguments[t]?arguments[t]:{};t%2?l(Object(n),!0).forEach((function(t){r(e,t,n[t])})):Object.getOwnPropertyDescriptors?Object.defineProperties(e,Object.getOwnPropertyDescriptors(n)):l(Object(n)).forEach((function(t){Object.defineProperty(e,t,Object.getOwnPropertyDescriptor(n,t))}))}return e}function i(e,t){if(null==e)return{};var n,a,r=function(e,t){if(null==e)return{};var n,a,r={},l=Object.keys(e);for(a=0;a<l.length;a++)n=l[a],t.indexOf(n)>=0||(r[n]=e[n]);return r}(e,t);if(Object.getOwnPropertySymbols){var l=Object.getOwnPropertySymbols(e);for(a=0;a<l.length;a++)n=l[a],t.indexOf(n)>=0||Object.prototype.propertyIsEnumerable.call(e,n)&&(r[n]=e[n])}return r}var d=a.createContext({}),s=function(e){var t=a.useContext(d),n=t;return e&&(n="function"==typeof e?e(t):o(o({},t),e)),n},p=function(e){var t=s(e.components);return a.createElement(d.Provider,{value:t},e.children)},u={inlineCode:"code",wrapper:function(e){var t=e.children;return a.createElement(a.Fragment,{},t)}},m=a.forwardRef((function(e,t){var n=e.components,r=e.mdxType,l=e.originalType,d=e.parentName,p=i(e,["components","mdxType","originalType","parentName"]),m=s(n),c=r,v=m["".concat(d,".").concat(c)]||m[c]||u[c]||l;return n?a.createElement(v,o(o({ref:t},p),{},{components:n})):a.createElement(v,o({ref:t},p))}));function c(e,t){var n=arguments,r=t&&t.mdxType;if("string"==typeof e||r){var l=n.length,o=new Array(l);o[0]=m;var i={};for(var d in t)hasOwnProperty.call(t,d)&&(i[d]=t[d]);i.originalType=e,i.mdxType="string"==typeof e?e:r,o[1]=i;for(var s=2;s<l;s++)o[s]=n[s];return a.createElement.apply(null,o)}return a.createElement.apply(null,n)}m.displayName="MDXCreateElement"},7733:function(e,t,n){n.r(t),n.d(t,{assets:function(){return p},contentTitle:function(){return d},default:function(){return c},frontMatter:function(){return i},metadata:function(){return s},toc:function(){return u}});var a=n(7462),r=n(3366),l=(n(7294),n(3905)),o=["components"],i={title:"Common events",sidebar_position:6,slug:"/events"},d=void 0,s={unversionedId:"en/Events",id:"en/Events",title:"Common events",description:"The event of the player is divided into two, a native event of a video, and another is a custom event. The native event comes from Video Elements, is the original event of the Video Element, in order to distinguish it and custom events, the native event adds a prefix video:",source:"@site/docs/en/Events.mdx",sourceDirName:"en",slug:"/events",permalink:"/document/events",draft:!1,tags:[],version:"current",sidebarPosition:6,frontMatter:{title:"Common events",sidebar_position:6,slug:"/events"},sidebar:"en",previous:{title:"Static propertys",permalink:"/document/class"},next:{title:"Third party librarys",permalink:"/document/libraries"}},p={},u=[{value:"Native event",id:"native-event",level:2},{value:"Custom event",id:"custom-event",level:2},{value:"ready",id:"ready",level:3},{value:"play",id:"play",level:3},{value:"pause",id:"pause",level:3},{value:"seek",id:"seek",level:3},{value:"volume",id:"volume",level:3},{value:"destroy",id:"destroy",level:3},{value:"focus",id:"focus",level:3},{value:"blur",id:"blur",level:3},{value:"hover",id:"hover",level:3},{value:"resize",id:"resize",level:3},{value:"mousemove",id:"mousemove",level:3},{value:"url",id:"url",level:3},{value:"fullscreen",id:"fullscreen",level:3},{value:"fullscreenWeb",id:"fullscreenweb",level:3},{value:"hotkey",id:"hotkey",level:3}],m={toc:u};function c(e){var t=e.components,n=(0,r.Z)(e,o);return(0,l.kt)("wrapper",(0,a.Z)({},m,n,{components:t,mdxType:"MDXLayout"}),(0,l.kt)("p",null,"The event of the player is divided into two, a ",(0,l.kt)("inlineCode",{parentName:"p"},"native event")," of a video, and another is a ",(0,l.kt)("inlineCode",{parentName:"p"},"custom event"),". The ",(0,l.kt)("inlineCode",{parentName:"p"},"native event")," comes from ",(0,l.kt)("inlineCode",{parentName:"p"},"Video Elements"),", is the original event of the ",(0,l.kt)("inlineCode",{parentName:"p"},"Video Element"),", in order to distinguish it and ",(0,l.kt)("inlineCode",{parentName:"p"},"custom events"),", the native event adds a prefix ",(0,l.kt)("inlineCode",{parentName:"p"},"video:")),(0,l.kt)("h2",{id:"native-event"},"Native event"),(0,l.kt)("p",null,"For more information, please read ",(0,l.kt)("a",{parentName:"p",href:"https://developer.mozilla.org/en-US/docs/Web/HTML/Element/video#events"},"Mozilla Video Events")),(0,l.kt)("table",null,(0,l.Line truncated
-2
View File
@@ -1,2 +0,0 @@
/*! For license information please see main.9ce4b94b.js.LICENSE.txt */
(self.webpackChunkartplayer_document=self.webpackChunkartplayer_document||[]).push([[179],{9782:function(e,t){"use strict";t.Z={title:"Artplayer.js",tagline:"Public Product Api Document",url:"https://artplayer.org",baseUrl:"/document/",onBrokenLinks:"ignore",onBrokenMarkdownLinks:"ignore",organizationName:"zhw2590582",projectName:"Artplayer",favicon:"img/favicon.ico",clientModules:["/Users/harvey/Desktop/github/ArtPlayer/packages/artplayer-document/src/script/main.js"],themeConfig:{docs:{sidebar:{hideable:!0,autoCollapseCategories:!1},versionPersistence:"localStorage"},navbar:{title:"Artplayer.js",logo:{alt:"Artplayer.js",src:"img/logo.png",href:"https://artplayer.org/document",target:"_self",width:28,height:28},items:[{href:"https://artplayer.org",position:"left",label:"Online Editor"},{href:"https://github.com/zhw2590582/ArtPlayer",position:"left",label:"Github"},{href:"#",label:"QQ\u7fa4: 320881312",position:"right"},{label:"English",position:"right",items:[{label:"English",href:"/"},{label:"\u4e2d\u6587",href:"/zh-cn/"}]}],hideOnScroll:!1},footer:{style:"dark",copyright:"Copyright \xa9 2022 Artplayer.js, Inc. Built with Docusaurus.",links:[]},prism:{theme:{plain:{color:"#393A34",backgroundColor:"#f6f8fa"},styles:[{types:["comment","prolog","doctype","cdata"],style:{color:"#999988",fontStyle:"italic"}},{types:["namespace"],style:{opacity:.7}},{types:["string","attr-value"],style:{color:"#e3116c"}},{types:["punctuation","operator"],style:{color:"#393A34"}},{types:["entity","url","symbol","number","boolean","variable","constant","property","regex","inserted"],style:{color:"#36acaa"}},{types:["atrule","keyword","attr-name","selector"],style:{color:"#00a4db"}},{types:["function","deleted","tag"],style:{color:"#d73a49"}},{types:["function-variable"],style:{color:"#6f42c1"}},{types:["tag","selector","keyword"],style:{color:"#00009f"}}]},darkTheme:{plain:{color:"#F8F8F2",backgroundColor:"#282A36"},styles:[{types:["prolog","constant","builtin"],style:{color:"rgb(189, 147, 249)"}},{types:["inserted","function"],style:{color:"rgb(80, 250, 123)"}},{types:["deleted"],style:{color:"rgb(255, 85, 85)"}},{types:["changed"],style:{color:"rgb(255, 184, 108)"}},{types:["punctuation","symbol"],style:{color:"rgb(248, 248, 242)"}},{types:["string","char","tag","selector"],style:{color:"rgb(255, 121, 198)"}},{types:["keyword","variable"],style:{color:"rgb(189, 147, 249)",fontStyle:"italic"}},{types:["comment"],style:{color:"rgb(98, 114, 164)"}},{types:["attr-name"],style:{color:"rgb(241, 250, 140)"}}]},additionalLanguages:[],magicComments:[{className:"theme-code-block-highlighted-line",line:"highlight-next-line",block:{start:"highlight-start",end:"highlight-end"}}]},colorMode:{defaultMode:"light",disableSwitch:!1,respectPrefersColorScheme:!1},metadata:[],tableOfContents:{minHeadingLevel:2,maxHeadingLevel:3}},plugins:["/Users/harvey/Desktop/github/ArtPlayer/packages/artplayer-document/node_modules/docusaurus-lunr-search/src/index.js"],presets:[["@docusaurus/preset-classic",{docs:{path:"./docs",routeBasePath:"/",sidebarPath:"/Users/harvey/Desktop/github/ArtPlayer/packages/artplayer-document/sidebars.js"},blog:!1,theme:{customCss:"/Users/harvey/Desktop/github/ArtPlayer/packages/artplayer-document/src/css/custom.css"}}]],baseUrlIssueBanner:!0,i18n:{defaultLocale:"en",locales:["en"],localeConfigs:{}},onDuplicateRoutes:"warn",staticDirectories:["static"],customFields:{},themes:[],scripts:[],stylesheets:[],titleDelimiter:"|",noIndex:!1}},723:function(e,t,n){"use strict";n.d(t,{Z:function(){return p}});var r=n(7294),a=n(7462),o=n(8356),i=n.n(o);function l(e){var t=e.error,n=e.retry,a=e.pastDelay;return t?r.createElement("div",{style:{textAlign:"center",color:"#fff",backgroundColor:"#fa383e",borderColor:"#fa383e",borderStyle:"solid",borderRadius:"0.25rem",borderWidth:"1px",boxSizing:"border-box",display:"block",padding:"1rem",flex:"0 0 50%",marginLeft:"25%",marginRight:"25%",marginTop:"5rem",maxWidth:"50%",width:"100%"}},r.createElement("p",null,t.message),r.createElement("div",null,r.createElement("button",{type:"button",onClick:n},"Retry"))):a?r.createElement("div",{style:{display:"flex",justifyContent:"center",alignItems:"center",height:"100vh"}},r.createElement("svg",{id:"loader",style:{width:128,height:110,position:"absolute",top:"calc(100vh - 64%)"},viewBox:"0 0 45 45",xmlns:"http://www.w3.org/2000/svg",stroke:"#61dafb"},r.createElement("g",{fill:"none",fillRule:"evenodd",transform:"translate(1 1)",strokeWidth:"2"},r.createElement("circle",{cx:"22",cy:"22",r:"6",strokeOpacity:"0"},r.createElement("animate",{attributeName:"r",begin:"1.5s",dur:"3s",values:"6;22",calcMode:"linear",repeatCount:"indefinite"}),r.createElement("animate",{attributeName:"stroke-opacity",begin:"1.5s",dur:"3s",values:"1;0",calcMode:"linear",repeatCount:"indefinite"}),r.createElement("animate",{attributeName:"stroke-width",begin:"1.5s",dur:"3s",values:"2;0",calcMode:"linear",repeatCount:"indefinite"})),r.createElement("circle",{cx:"22",cy:"22",r:"6",strokeOLine truncated
+2
View File
@@ -0,0 +1,2 @@
/*! For license information please see main.ac59e946.js.LICENSE.txt */
(self.webpackChunkartplayer_document=self.webpackChunkartplayer_document||[]).push([[179],{108:function(e,t,n){"use strict";n.d(t,{_:function(){return a},t:function(){return o}});var r=n(2784),a=r.createContext(!1);function o(e){var t=e.children,n=(0,r.useState)(!1),o=n[0],i=n[1];return(0,r.useEffect)((function(){i(!0)}),[]),r.createElement(a.Provider,{value:o},t)}},2918:function(e,t,n){"use strict";var r=n(2784),a=n(8316),o=n(7933),i=n(2175),l=n(1263),u=[n(5749),n(6817),n(5615),n(401),n(1964),n(6681)],s=n(9895),c=n(3181),d=n(9702),f=new Map;function p(e){if(f.has(e.pathname))return Object.assign({},e,{pathname:f.get(e.pathname)});if((0,d.f)(s.Z,e.pathname).some((function(e){return!0===e.route.exact})))return f.set(e.pathname,e.pathname),e;var t=e.pathname.trim().replace(/(?:\/index)?\.html$/,"")||"/";return f.set(e.pathname,t),Object.assign({},e,{pathname:t})}var m=n(108),h=n(4299),g=n(1665);function v(e){for(var t=arguments.length,n=new Array(t>1?t-1:0),r=1;r<t;r++)n[r-1]=arguments[r];var a=u.map((function(t){var r,a,o=null!=(r=null==t||null==(a=t.default)?void 0:a[e])?r:t[e];return null==o?void 0:o.apply(void 0,n)}));return function(){return a.forEach((function(e){return null==e?void 0:e()}))}}var b=function(e){var t=e.children,n=e.location,a=e.previousLocation;return(0,r.useLayoutEffect)((function(){a!==n&&(a&&function(e){var t=e.hash;if(t){var n=decodeURIComponent(t.substring(1)),r=document.getElementById(n);null==r||r.scrollIntoView()}else window.scrollTo(0,0)}(n),v("onRouteDidUpdate",{previousLocation:a,location:n}))}),[a,n]),t};function y(e){var t=(0,d.f)(s.Z,e);return Promise.all(t.map((function(e){var t;return null==(t=e.route.component)||null==t.preload?void 0:t.preload()})))}var w=function(e){function t(t){var n;return(n=e.call(this,t)||this).previousLocation=null,n.routeUpdateCleanupCb=l.Z.canUseDOM?v("onRouteUpdate",{previousLocation:null,location:n.props.location}):function(){},n.state={nextRouteHasLoaded:!0},n}(0,g.Z)(t,e);var n=t.prototype;return n.shouldComponentUpdate=function(e,t){var n=this;if(e.location===this.props.location)return t.nextRouteHasLoaded;var r=e.location;return this.previousLocation=this.props.location,this.setState({nextRouteHasLoaded:!1}),this.routeUpdateCleanupCb=v("onRouteUpdate",{previousLocation:this.previousLocation,location:r}),y(r.pathname).then((function(){null==n.routeUpdateCleanupCb||n.routeUpdateCleanupCb(),n.setState({nextRouteHasLoaded:!0})})).catch((function(e){return console.warn(e)})),!1},n.render=function(){var e=this.props,t=e.children,n=e.location;return r.createElement(b,{previousLocation:this.previousLocation,location:n},r.createElement(c.AW,{location:n,render:function(){return t}}))},t}(r.Component),k=n(9854),E=n(7614),S="docusaurus-base-url-issue-banner-container",_="docusaurus-base-url-issue-banner-suggestion-container",x="__DOCUSAURUS_INSERT_BASEURL_BANNER";function C(e){return"\nwindow['"+x+"'] = true;\n\ndocument.addEventListener('DOMContentLoaded', maybeInsertBanner);\n\nfunction maybeInsertBanner() {\n var shouldInsert = window['"+x+"'];\n shouldInsert && insertBanner();\n}\n\nfunction insertBanner() {\n var bannerContainer = document.getElementById('"+S+"');\n if (!bannerContainer) {\n return;\n }\n var bannerHtml = "+JSON.stringify(function(e){return'\n<div id="docusaurus-base-url-issue-banner" style="border: thick solid red; background-color: rgb(255, 230, 179); margin: 20px; padding: 20px; font-size: 20px;">\n <p style="font-weight: bold; font-size: 30px;">Your Docusaurus site did not load properly.</p>\n <p>A very common reason is a wrong site <a href="https://docusaurus.io/docs/docusaurus.config.js/#baseurl" style="font-weight: bold;">baseUrl configuration</a>.</p>\n <p>Current configured baseUrl = <span style="font-weight: bold; color: red;">'+e+"</span> "+("/"===e?" (default value)":"")+'</p>\n <p>We suggest trying baseUrl = <span id="'+_+'" style="font-weight: bold; color: green;"></span></p>\n</div>\n'}(e)).replace(/</g,"\\<")+";\n bannerContainer.innerHTML = bannerHtml;\n var suggestionContainer = document.getElementById('"+_+"');\n var actualHomePagePath = window.location.pathname;\n var suggestedBaseUrl = actualHomePagePath.substr(-1) === '/'\n ? actualHomePagePath\n : actualHomePagePath + '/';\n suggestionContainer.innerHTML = suggestedBaseUrl;\n}\n"}function T(){var e=(0,E.Z)().siteConfig.baseUrl;return(0,r.useLayoutEffect)((function(){window[x]=!1}),[]),r.createElement(r.Fragment,null,!l.Z.canUseDOM&&r.createElement(k.Z,null,r.createElement("script",null,C(e))),r.createElement("div",{id:S}))}function A(){var e=(0,E.Z)().siteConfig,t=e.baseUrl,n=e.baseUrlIssueBanner,a=(0,c.TH)().pathname;return n&&a===t?r.createElement(T,null):null}var P=n(77);function L(){var e=(0,E.Z)(),t=e.siteConfig,n=t.favicon,a=t.tagline,o=t.title,i=e.i18n,l=i.currentLocale,u=i.localeConfigs,s=(0,P.Z)(n),c=u[l],d=c.htmlLang,f=c.direction;return r.createElement(k.Z,{defaultTitle:o+(a?" \xb7 "+a:"")},r.createElement("hLine truncated
@@ -1 +0,0 @@
!function(){"use strict";var e,t,n,r,f,a={},c={};function o(e){var t=c[e];if(void 0!==t)return t.exports;var n=c[e]={id:e,loaded:!1,exports:{}};return a[e].call(n.exports,n,n.exports,o),n.loaded=!0,n.exports}o.m=a,o.c=c,e=[],o.O=function(t,n,r,f){if(!n){var a=1/0;for(d=0;d<e.length;d++){n=e[d][0],r=e[d][1],f=e[d][2];for(var c=!0,u=0;u<n.length;u++)(!1&f||a>=f)&&Object.keys(o.O).every((function(e){return o.O[e](n[u])}))?n.splice(u--,1):(c=!1,f<a&&(a=f));if(c){e.splice(d--,1);var i=r();void 0!==i&&(t=i)}}return t}f=f||0;for(var d=e.length;d>0&&e[d-1][2]>f;d--)e[d]=e[d-1];e[d]=[n,r,f]},o.n=function(e){var t=e&&e.__esModule?function(){return e.default}:function(){return e};return o.d(t,{a:t}),t},n=Object.getPrototypeOf?function(e){return Object.getPrototypeOf(e)}:function(e){return e.__proto__},o.t=function(e,r){if(1&r&&(e=this(e)),8&r)return e;if("object"==typeof e&&e){if(4&r&&e.__esModule)return e;if(16&r&&"function"==typeof e.then)return e}var f=Object.create(null);o.r(f);var a={};t=t||[null,n({}),n([]),n(n)];for(var c=2&r&&e;"object"==typeof c&&!~t.indexOf(c);c=n(c))Object.getOwnPropertyNames(c).forEach((function(t){a[t]=function(){return e[t]}}));return a.default=function(){return e},o.d(f,a),f},o.d=function(e,t){for(var n in t)o.o(t,n)&&!o.o(e,n)&&Object.defineProperty(e,n,{enumerable:!0,get:t[n]})},o.f={},o.e=function(e){return Promise.all(Object.keys(o.f).reduce((function(t,n){return o.f[n](e,t),t}),[]))},o.u=function(e){return"assets/js/"+({14:"faf6497a",28:"58e1c627",48:"60b6f9d9",53:"935f2afb",78:"3bed75f7",87:"a5cb9b40",122:"bd0361f4",146:"9bc5160c",167:"8707c5fa",201:"289862a0",220:"5d64abea",228:"a94f89e4",235:"a87a33e0",250:"3295c742",280:"3242b9a0",283:"8aff36b5",359:"6d693eaf",376:"c1870555",514:"1be78505",558:"41890f3a",591:"f4b604e6",601:"6edbf6fb",610:"3c6a0f85",615:"1fd37a74",619:"55c4a126",645:"571421b9",667:"701cf4af",696:"ba9533a1",740:"f1478c6c",784:"1cbc9196",881:"e434372a",894:"bbdb8589",898:"0d27fd9a",918:"17896441"}[e]||e)+"."+{14:"f311cd28",28:"71c47112",48:"7382891b",53:"1ed2caf4",78:"b90cf704",87:"b42e72b3",122:"2c38bfb6",146:"7239afe4",167:"6e21eb8c",201:"a7079592",220:"4742c5c1",228:"b6bd92b4",235:"b7afa659",245:"dd7e9f1f",250:"c0eb89ee",280:"408d806c",283:"ec084d59",343:"e9b08a58",359:"1c24bfc1",376:"dfe03f8f",514:"b9120311",558:"aaf59c53",591:"1489f678",601:"523bcc96",608:"1d321a91",610:"53e0bc80",615:"d6a451a2",619:"943e022d",645:"bd81ea31",667:"f8f2a448",696:"7e3769fb",740:"862a408c",784:"2dd1fd8d",878:"0f9d5667",881:"c02b87d1",894:"b738498d",898:"dc1b5780",918:"8d80cfd5"}[e]+".js"},o.miniCssF=function(e){},o.g=function(){if("object"==typeof globalThis)return globalThis;try{return this||new Function("return this")()}catch(e){if("object"==typeof window)return window}}(),o.o=function(e,t){return Object.prototype.hasOwnProperty.call(e,t)},r={},f="artplayer-document:",o.l=function(e,t,n,a){if(r[e])r[e].push(t);else{var c,u;if(void 0!==n)for(var i=document.getElementsByTagName("script"),d=0;d<i.length;d++){var b=i[d];if(b.getAttribute("src")==e||b.getAttribute("data-webpack")==f+n){c=b;break}}c||(u=!0,(c=document.createElement("script")).charset="utf-8",c.timeout=120,o.nc&&c.setAttribute("nonce",o.nc),c.setAttribute("data-webpack",f+n),c.src=e),r[e]=[t];var l=function(t,n){c.onerror=c.onload=null,clearTimeout(s);var f=r[e];if(delete r[e],c.parentNode&&c.parentNode.removeChild(c),f&&f.forEach((function(e){return e(n)})),t)return t(n)},s=setTimeout(l.bind(null,void 0,{type:"timeout",target:c}),12e4);c.onerror=l.bind(null,c.onerror),c.onload=l.bind(null,c.onload),u&&document.head.appendChild(c)}},o.r=function(e){"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(e,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(e,"__esModule",{value:!0})},o.p="/document/",o.gca=function(e){return e={17896441:"918",faf6497a:"14","58e1c627":"28","60b6f9d9":"48","935f2afb":"53","3bed75f7":"78",a5cb9b40:"87",bd0361f4:"122","9bc5160c":"146","8707c5fa":"167","289862a0":"201","5d64abea":"220",a94f89e4:"228",a87a33e0:"235","3295c742":"250","3242b9a0":"280","8aff36b5":"283","6d693eaf":"359",c1870555:"376","1be78505":"514","41890f3a":"558",f4b604e6:"591","6edbf6fb":"601","3c6a0f85":"610","1fd37a74":"615","55c4a126":"619","571421b9":"645","701cf4af":"667",ba9533a1:"696",f1478c6c:"740","1cbc9196":"784",e434372a:"881",bbdb8589:"894","0d27fd9a":"898"}[e]||e,o.p+o.u(e)},function(){var e={303:0,532:0};o.f.j=function(t,n){var r=o.o(e,t)?e[t]:void 0;if(0!==r)if(r)n.push(r[2]);else if(/^(303|532)$/.test(t))e[t]=0;else{var f=new Promise((function(n,f){r=e[t]=[n,f]}));n.push(r[2]=f);var a=o.p+o.u(t),c=new Error;o.l(a,(function(n){if(o.o(e,t)&&(0!==(r=e[t])&&(e[t]=void 0),r)){var f=n&&("load"===n.type?"missing":n.type),a=n&&n.target&&n.target.src;c.message="Loading chunk "+t+" failed.\n("+f+": "+a+")",c.name="ChunkLoadError",c.type=f,c.request=a,r[1](c)}}),"chunk-"+t,t)}},o.O.j=function(t){return 0===e[t]};var t=function(t,n){var r,f,a=n[0],c=n[1],u=n[2],i=0;if(a.some((function(t){return 0Line truncated
@@ -0,0 +1 @@
!function(){"use strict";var e,t,n,r,a,f={},o={};function c(e){var t=o[e];if(void 0!==t)return t.exports;var n=o[e]={id:e,loaded:!1,exports:{}};return f[e].call(n.exports,n,n.exports,c),n.loaded=!0,n.exports}c.m=f,c.c=o,e=[],c.O=function(t,n,r,a){if(!n){var f=1/0;for(d=0;d<e.length;d++){n=e[d][0],r=e[d][1],a=e[d][2];for(var o=!0,u=0;u<n.length;u++)(!1&a||f>=a)&&Object.keys(c.O).every((function(e){return c.O[e](n[u])}))?n.splice(u--,1):(o=!1,a<f&&(f=a));if(o){e.splice(d--,1);var i=r();void 0!==i&&(t=i)}}return t}a=a||0;for(var d=e.length;d>0&&e[d-1][2]>a;d--)e[d]=e[d-1];e[d]=[n,r,a]},c.n=function(e){var t=e&&e.__esModule?function(){return e.default}:function(){return e};return c.d(t,{a:t}),t},n=Object.getPrototypeOf?function(e){return Object.getPrototypeOf(e)}:function(e){return e.__proto__},c.t=function(e,r){if(1&r&&(e=this(e)),8&r)return e;if("object"==typeof e&&e){if(4&r&&e.__esModule)return e;if(16&r&&"function"==typeof e.then)return e}var a=Object.create(null);c.r(a);var f={};t=t||[null,n({}),n([]),n(n)];for(var o=2&r&&e;"object"==typeof o&&!~t.indexOf(o);o=n(o))Object.getOwnPropertyNames(o).forEach((function(t){f[t]=function(){return e[t]}}));return f.default=function(){return e},c.d(a,f),a},c.d=function(e,t){for(var n in t)c.o(t,n)&&!c.o(e,n)&&Object.defineProperty(e,n,{enumerable:!0,get:t[n]})},c.f={},c.e=function(e){return Promise.all(Object.keys(c.f).reduce((function(t,n){return c.f[n](e,t),t}),[]))},c.u=function(e){return"assets/js/"+({14:"faf6497a",28:"58e1c627",48:"60b6f9d9",53:"935f2afb",78:"3bed75f7",87:"a5cb9b40",122:"bd0361f4",146:"9bc5160c",167:"8707c5fa",178:"a2b05b94",201:"289862a0",220:"5d64abea",228:"a94f89e4",235:"a87a33e0",250:"3295c742",280:"3242b9a0",283:"8aff36b5",359:"6d693eaf",509:"f94d3623",514:"1be78505",558:"41890f3a",591:"f4b604e6",601:"6edbf6fb",610:"3c6a0f85",615:"1fd37a74",619:"55c4a126",645:"571421b9",667:"701cf4af",696:"ba9533a1",740:"f1478c6c",778:"40f8650c",784:"1cbc9196",881:"e434372a",918:"17896441"}[e]||e)+"."+{4:"18dc9579",14:"ee5fc657",28:"b88f36cd",48:"2da2818d",53:"c4f71b33",78:"d015eee3",87:"5e013713",122:"f22ddaed",146:"8ed11933",167:"4a032f66",178:"2a8252df",201:"95676090",220:"4f085d73",228:"3b1b5a98",235:"347c0dae",250:"ffab7df4",280:"23c8c5ab",283:"cae4e043",359:"38a42ee4",489:"21a70c84",509:"8920bdb1",514:"4348f36c",558:"d1fe0796",591:"b5cbe40e",601:"6a63c5a6",605:"05c1d58b",610:"c4104e4b",615:"6850ebac",619:"fc51e1a9",645:"f55055dc",667:"01917933",696:"bbe4bfa9",740:"3227e53e",778:"8b096f94",784:"d7221d00",878:"f94e2fc9",881:"5126fc7d",918:"d2893c7a"}[e]+".js"},c.miniCssF=function(e){},c.g=function(){if("object"==typeof globalThis)return globalThis;try{return this||new Function("return this")()}catch(e){if("object"==typeof window)return window}}(),c.o=function(e,t){return Object.prototype.hasOwnProperty.call(e,t)},r={},a="artplayer-document:",c.l=function(e,t,n,f){if(r[e])r[e].push(t);else{var o,u;if(void 0!==n)for(var i=document.getElementsByTagName("script"),d=0;d<i.length;d++){var b=i[d];if(b.getAttribute("src")==e||b.getAttribute("data-webpack")==a+n){o=b;break}}o||(u=!0,(o=document.createElement("script")).charset="utf-8",o.timeout=120,c.nc&&o.setAttribute("nonce",c.nc),o.setAttribute("data-webpack",a+n),o.src=e),r[e]=[t];var l=function(t,n){o.onerror=o.onload=null,clearTimeout(s);var a=r[e];if(delete r[e],o.parentNode&&o.parentNode.removeChild(o),a&&a.forEach((function(e){return e(n)})),t)return t(n)},s=setTimeout(l.bind(null,void 0,{type:"timeout",target:o}),12e4);o.onerror=l.bind(null,o.onerror),o.onload=l.bind(null,o.onload),u&&document.head.appendChild(o)}},c.r=function(e){"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(e,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(e,"__esModule",{value:!0})},c.p="/document/",c.gca=function(e){return e={17896441:"918",faf6497a:"14","58e1c627":"28","60b6f9d9":"48","935f2afb":"53","3bed75f7":"78",a5cb9b40:"87",bd0361f4:"122","9bc5160c":"146","8707c5fa":"167",a2b05b94:"178","289862a0":"201","5d64abea":"220",a94f89e4:"228",a87a33e0:"235","3295c742":"250","3242b9a0":"280","8aff36b5":"283","6d693eaf":"359",f94d3623:"509","1be78505":"514","41890f3a":"558",f4b604e6:"591","6edbf6fb":"601","3c6a0f85":"610","1fd37a74":"615","55c4a126":"619","571421b9":"645","701cf4af":"667",ba9533a1:"696",f1478c6c:"740","40f8650c":"778","1cbc9196":"784",e434372a:"881"}[e]||e,c.p+c.u(e)},function(){var e={303:0,532:0};c.f.j=function(t,n){var r=c.o(e,t)?e[t]:void 0;if(0!==r)if(r)n.push(r[2]);else if(/^(303|532)$/.test(t))e[t]=0;else{var a=new Promise((function(n,a){r=e[t]=[n,a]}));n.push(r[2]=a);var f=c.p+c.u(t),o=new Error;c.l(f,(function(n){if(c.o(e,t)&&(0!==(r=e[t])&&(e[t]=void 0),r)){var a=n&&("load"===n.type?"missing":n.type),f=n&&n.target&&n.target.src;o.message="Loading chunk "+t+" failed.\n("+a+": "+f+")",o.name="ChunkLoadError",o.type=a,o.request=f,r[1](o)}}),"chunk-"+t,t)}},c.O.j=function(t){return 0===e[t]};var t=function(t,n){var r,a,f=n[0],o=n[1],u=n[2],i=0;if(f.some((function(t){return 0!=Line truncated
+6 -6
View File
@@ -4,14 +4,14 @@
<meta charset="UTF-8">
<meta name="viewport" content="width=device-width,initial-scale=1">
<meta name="generator" content="Docusaurus v2.0.0-beta.20">
<title data-rh="true">Static propertys | Artplayer.js</title><meta data-rh="true" name="twitter:card" content="summary_large_image"><meta data-rh="true" property="og:url" content="https://artplayer.org/document/class"><meta data-rh="true" name="docusaurus_locale" content="en"><meta data-rh="true" name="docsearch:language" content="en"><meta data-rh="true" name="docusaurus_version" content="current"><meta data-rh="true" name="docusaurus_tag" content="docs-default-current"><meta data-rh="true" name="docsearch:version" content="current"><meta data-rh="true" name="docsearch:docusaurus_tag" content="docs-default-current"><meta data-rh="true" property="og:title" content="Static propertys | Artplayer.js"><meta data-rh="true" name="description" content="Static attributes exist in the constructor artplayer, and the player instance is not directly associated"><meta data-rh="true" property="og:description" content="Static attributes exist in the constructor artplayer, and the player instance is not directly associated"><link data-rh="true" rel="icon" href="/document/img/favicon.ico"><link data-rh="true" rel="canonical" href="https://artplayer.org/document/class"><link data-rh="true" rel="alternate" href="https://artplayer.org/document/class" hreflang="en"><link data-rh="true" rel="alternate" href="https://artplayer.org/document/class" hreflang="x-default"><link rel="stylesheet" href="/document/assets/css/styles.eba261b7.css">
<link rel="preload" href="/document/assets/js/runtime~main.222c91cd.js" as="script">
<link rel="preload" href="/document/assets/js/main.9ce4b94b.js" as="script">
<title data-rh="true">Static propertys | Artplayer.js</title><meta data-rh="true" name="twitter:card" content="summary_large_image"><meta data-rh="true" property="og:url" content="https://artplayer.org/document/class"><meta data-rh="true" name="docusaurus_locale" content="en"><meta data-rh="true" name="docsearch:language" content="en"><meta data-rh="true" name="docusaurus_version" content="current"><meta data-rh="true" name="docusaurus_tag" content="docs-default-current"><meta data-rh="true" name="docsearch:version" content="current"><meta data-rh="true" name="docsearch:docusaurus_tag" content="docs-default-current"><meta data-rh="true" property="og:title" content="Static propertys | Artplayer.js"><meta data-rh="true" name="description" content="Static attributes exist in the constructor artplayer, and the player instance is not directly associated"><meta data-rh="true" property="og:description" content="Static attributes exist in the constructor artplayer, and the player instance is not directly associated"><link data-rh="true" rel="icon" href="/document/img/favicon.ico"><link data-rh="true" rel="canonical" href="https://artplayer.org/document/class"><link data-rh="true" rel="alternate" href="https://artplayer.org/document/class" hreflang="en"><link data-rh="true" rel="alternate" href="https://artplayer.org/document/class" hreflang="x-default"><link rel="stylesheet" href="/document/assets/css/styles.7b2fc50a.css">
<link rel="preload" href="/document/assets/js/runtime~main.f9808e8d.js" as="script">
<link rel="preload" href="/document/assets/js/main.ac59e946.js" as="script">
</head>
<body class="navigation-with-keyboard">
<script>!function(){function t(t){document.documentElement.setAttribute("data-theme",t)}var e=function(){var t=null;try{t=localStorage.getItem("theme")}catch(t){}return t}();t(null!==e?e:"light")}()</script><div id="__docusaurus">
<div role="region"><a href="#" class="skipToContent_ZgBM">Skip to main content</a></div><nav class="navbar navbar--fixed-top"><div class="navbar__inner"><div class="navbar__items"><button aria-label="Navigation bar toggle" class="navbar__toggle clean-btn" type="button" tabindex="0"><svg width="30" height="30" viewBox="0 0 30 30" aria-hidden="true"><path stroke="currentColor" stroke-linecap="round" stroke-miterlimit="10" stroke-width="2" d="M4 7h22M4 15h22M4 23h22"></path></svg></button><a href="https://artplayer.org/document" target="_self" rel="noopener noreferrer" class="navbar__brand"><div class="navbar__logo"><img src="/document/img/logo.png" alt="Artplayer.js" class="themedImage_W2Cr themedImage--light_TfLj" height="28" width="28"><img src="/document/img/logo.png" alt="Artplayer.js" class="themedImage_W2Cr themedImage--dark_oUvU" height="28" width="28"></div><b class="navbar__title text--truncate">Artplayer.js</b></a><a href="https://artplayer.org" target="_blank" rel="noopener noreferrer" class="navbar__item navbar__link">Online Editor<svg width="13.5" height="13.5" aria-hidden="true" viewBox="0 0 24 24" class="iconExternalLink_I5OW"><path fill="currentColor" d="M21 13v10h-21v-19h12v2h-10v15h17v-8h2zm3-12h-10.988l4.035 4-6.977 7.07 2.828 2.828 6.977-7.07 4.125 4.172v-11z"></path></svg></a><a href="https://github.com/zhw2590582/ArtPlayer" target="_blank" rel="noopener noreferrer" class="navbar__item navbar__link">Github<svg width="13.5" height="13.5" aria-hidden="true" viewBox="0 0 24 24" class="iconExternalLink_I5OW"><path fill="currentColor" d="M21 13v10h-21v-19h12v2h-10v15h17v-8h2zm3-12h-10.988l4.035 4-6.977 7.07 2.828 2.828 6.977-7.07 4.125 4.172v-11z"></path></svg></a></div><div class="navbar__items navbar__items--right"><a href="#" class="navbar__item navbar__link">QQ群: 320881312</a><div class="navbar__item dropdown dropdown--hoverable dropdown--right"><a href="#" aria-haspopup="true" aria-expanded="false" role="button" class="navbar__link">English</a><ul class="dropdown__menu"><li><a class="dropdown__link" href="/document/">English</a></li><li><a class="dropdown__link" href="/document/zh-cn/">中文</a></li></ul></div><div class="toggle_S7eR colorModeToggle_vKtC"><button class="clean-btn toggleButton_rCf9 toggleButtonDisabled_Pu9x" type="button" disabled="" title="Switch between dark and light mode (currently light mode)" aria-label="Switch between dark and light mode (currently light mode)"><svg viewBox="0 0 24 24" width="24" height="24" class="lightToggleIcon_v35p"><path fill="currentColor" d="M12,9c1.65,0,3,1.35,3,3s-1.35,3-3,3s-3-1.35-3-3S10.35,9,12,9 M12,7c-2.76,0-5,2.24-5,5s2.24,5,5,5s5-2.24,5-5 S14.76,7,12,7L12,7z M2,13l2,0c0.55,0,1-0.45,1-1s-0.45-1-1-1l-2,0c-0.55,0-1,0.45-1,1S1.45,13,2,13z M20,13l2,0c0.55,0,1-0.45,1-1 s-0.45-1-1-1l-2,0c-0.55,0-1,0.45-1,1S19.45,13,20,13z M11,2v2c0,0.55,0.45,1,1,1s1-0.45,1-1V2c0-0.55-0.45-1-1-1S11,1.45,11,2z M11,20v2c0,0.55,0.45,1,1,1s1-0.45,1-1v-2c0-0.55-0.45-1-1-1C11.45,19,11,19.45,11,20z M5.99,4.58c-0.39-0.39-1.03-0.39-1.41,0 c-0.39,0.39-0.39,1.03,0,1.41l1.06,1.06c0.39,0.39,1.03,0.39,1.41,0s0.39-1.03,0-1.41L5.99,4.58z M18.36,16.95 c-0.39-0.39-1.03-0.39-1.41,0c-0.39,0.39-0.39,1.03,0,1.41l1.06,1.06c0.39,0.39,1.03,0.39,1.41,0c0.39-0.39,0.39-1.03,0-1.41 L18.36,16.95z M19.42,5.99c0.39-0.39,0.39-1.03,0-1.41c-0.39-0.39-1.03-0.39-1.41,0l-1.06,1.06c-0.39,0.39-0.39,1.03,0,1.41 s1.03,0.39,1.41,0L19.42,5.99z M7.05,18.36c0.39-0.39,0.39-1.03,0-1.41c-0.39-0.39-1.03-0.39-1.41,0l-1.06,1.06 c-0.39,0.39-0.39,1.03,0,1.41s1.03,0.39,1.41,0L7.05,18.36z"></path></svg><svg viewBox="0 0 24 24" width="24" height="24" class="darkToggleIcon_nQuB"><path fill="currentColor" d="M9.37,5.51C9.19,6.15,9.1,6.82,9.1,7.5c0,4.08,3.32,7.4,7.4,7.4c0.68,0,1.35-0.09,1.99-0.27C17.45,17.19,14.93,19,12,19 c-3.86,0-7-3.14-7-7C5,9.07,6.81,6.55,9.37,5.51z M12,3c-4.97,0-9,4.03-9,9s4.03,9,9,9s9-4.03,9-9c0-0.46-0.04-0.92-0.1-1.36 c-0.98,1.37-2.58,2.26-4.4,2.26c-2.98,0-5.4-2.42-5.4-5.4c0-1.81,0.89-3.42,2.26-4.4C12.92,3.04,12.46,3,12,3L12,3z"></path></svg></button></div><div class="searchBox_dLyj"><div class="navbar__search"><span aria-label="expand searchbar" role="button" class="search-icon" tabindex="0"></span><input type="search" id="search_input_react" placeholder="Search" aria-label="Search" class="navbar__search-input search-bar"></div></div></div></div><div role="presentation" class="navbar-sidebar__backdrop"></div></nav><div class="main-wrapper docsWrapper_mKqt"><button aria-label="Scroll back to top" class="clean-btn theme-back-to-top-button backToTopButton_RiI4" type="button"></button><div class="docPage_ualW"><aside class="theme-doc-sidebar-container docSidebarContainer_UQUJ"><div class="sidebar_RiAD"><nav class="menu thin-scrollbar menu_izAj"><ul class="theme-doc-sidebar-menu menu__list"><li class="theme-doc-sidebar-item-link theme-doc-sidebar-item-link-level-1 menu__list-item"><a class="menu__link" href="/document/">Quick start</a></li><li class="theme-doc-sidebar-item-link theme-doc-sidebLine truncated
<script src="/document/assets/js/runtime~main.222c91cd.js"></script>
<script src="/document/assets/js/main.9ce4b94b.js"></script>
<div role="region"><a href="#" class="skipToContent_cbSD">Skip to main content</a></div><nav class="navbar navbar--fixed-top"><div class="navbar__inner"><div class="navbar__items"><button aria-label="Navigation bar toggle" class="navbar__toggle clean-btn" type="button" tabindex="0"><svg width="30" height="30" viewBox="0 0 30 30" aria-hidden="true"><path stroke="currentColor" stroke-linecap="round" stroke-miterlimit="10" stroke-width="2" d="M4 7h22M4 15h22M4 23h22"></path></svg></button><a href="https://artplayer.org/document" target="_self" rel="noopener noreferrer" class="navbar__brand"><div class="navbar__logo"><img src="/document/img/logo.png" alt="Artplayer.js" class="themedImage_WmJs themedImage--light_gXqO" height="28" width="28"><img src="/document/img/logo.png" alt="Artplayer.js" class="themedImage_WmJs themedImage--dark_X1Zc" height="28" width="28"></div><b class="navbar__title text--truncate">Artplayer.js</b></a><a href="https://artplayer.org" target="_blank" rel="noopener noreferrer" class="navbar__item navbar__link">Online Editor<svg width="13.5" height="13.5" aria-hidden="true" viewBox="0 0 24 24" class="iconExternalLink_cOdw"><path fill="currentColor" d="M21 13v10h-21v-19h12v2h-10v15h17v-8h2zm3-12h-10.988l4.035 4-6.977 7.07 2.828 2.828 6.977-7.07 4.125 4.172v-11z"></path></svg></a><a href="https://github.com/zhw2590582/ArtPlayer" target="_blank" rel="noopener noreferrer" class="navbar__item navbar__link">Github<svg width="13.5" height="13.5" aria-hidden="true" viewBox="0 0 24 24" class="iconExternalLink_cOdw"><path fill="currentColor" d="M21 13v10h-21v-19h12v2h-10v15h17v-8h2zm3-12h-10.988l4.035 4-6.977 7.07 2.828 2.828 6.977-7.07 4.125 4.172v-11z"></path></svg></a></div><div class="navbar__items navbar__items--right"><a href="#" class="navbar__item navbar__link">QQ群: 320881312</a><div class="navbar__item dropdown dropdown--hoverable dropdown--right"><a href="#" aria-haspopup="true" aria-expanded="false" role="button" class="navbar__link">English</a><ul class="dropdown__menu"><li><a class="dropdown__link" href="/document/">English</a></li><li><a class="dropdown__link" href="/document/zh-cn/">中文</a></li></ul></div><div class="toggle_F6nl colorModeToggle_ndsa"><button class="clean-btn toggleButton_Szei toggleButtonDisabled_qp8o" type="button" disabled="" title="Switch between dark and light mode (currently light mode)" aria-label="Switch between dark and light mode (currently light mode)"><svg viewBox="0 0 24 24" width="24" height="24" class="lightToggleIcon_y2PQ"><path fill="currentColor" d="M12,9c1.65,0,3,1.35,3,3s-1.35,3-3,3s-3-1.35-3-3S10.35,9,12,9 M12,7c-2.76,0-5,2.24-5,5s2.24,5,5,5s5-2.24,5-5 S14.76,7,12,7L12,7z M2,13l2,0c0.55,0,1-0.45,1-1s-0.45-1-1-1l-2,0c-0.55,0-1,0.45-1,1S1.45,13,2,13z M20,13l2,0c0.55,0,1-0.45,1-1 s-0.45-1-1-1l-2,0c-0.55,0-1,0.45-1,1S19.45,13,20,13z M11,2v2c0,0.55,0.45,1,1,1s1-0.45,1-1V2c0-0.55-0.45-1-1-1S11,1.45,11,2z M11,20v2c0,0.55,0.45,1,1,1s1-0.45,1-1v-2c0-0.55-0.45-1-1-1C11.45,19,11,19.45,11,20z M5.99,4.58c-0.39-0.39-1.03-0.39-1.41,0 c-0.39,0.39-0.39,1.03,0,1.41l1.06,1.06c0.39,0.39,1.03,0.39,1.41,0s0.39-1.03,0-1.41L5.99,4.58z M18.36,16.95 c-0.39-0.39-1.03-0.39-1.41,0c-0.39,0.39-0.39,1.03,0,1.41l1.06,1.06c0.39,0.39,1.03,0.39,1.41,0c0.39-0.39,0.39-1.03,0-1.41 L18.36,16.95z M19.42,5.99c0.39-0.39,0.39-1.03,0-1.41c-0.39-0.39-1.03-0.39-1.41,0l-1.06,1.06c-0.39,0.39-0.39,1.03,0,1.41 s1.03,0.39,1.41,0L19.42,5.99z M7.05,18.36c0.39-0.39,0.39-1.03,0-1.41c-0.39-0.39-1.03-0.39-1.41,0l-1.06,1.06 c-0.39,0.39-0.39,1.03,0,1.41s1.03,0.39,1.41,0L7.05,18.36z"></path></svg><svg viewBox="0 0 24 24" width="24" height="24" class="darkToggleIcon_sMpk"><path fill="currentColor" d="M9.37,5.51C9.19,6.15,9.1,6.82,9.1,7.5c0,4.08,3.32,7.4,7.4,7.4c0.68,0,1.35-0.09,1.99-0.27C17.45,17.19,14.93,19,12,19 c-3.86,0-7-3.14-7-7C5,9.07,6.81,6.55,9.37,5.51z M12,3c-4.97,0-9,4.03-9,9s4.03,9,9,9s9-4.03,9-9c0-0.46-0.04-0.92-0.1-1.36 c-0.98,1.37-2.58,2.26-4.4,2.26c-2.98,0-5.4-2.42-5.4-5.4c0-1.81,0.89-3.42,2.26-4.4C12.92,3.04,12.46,3,12,3L12,3z"></path></svg></button></div><div class="searchBox_xKlU"><div class="navbar__search"><span aria-label="expand searchbar" role="button" class="search-icon" tabindex="0"></span><input type="search" id="search_input_react" placeholder="Search" aria-label="Search" class="navbar__search-input search-bar"></div></div></div></div><div role="presentation" class="navbar-sidebar__backdrop"></div></nav><div class="main-wrapper docsWrapper_GpM1"><button aria-label="Scroll back to top" class="clean-btn theme-back-to-top-button backToTopButton_EOoS" type="button"></button><div class="docPage_vgSg"><aside class="theme-doc-sidebar-container docSidebarContainer_RUQH"><div class="sidebar_gEXq"><nav class="menu thin-scrollbar menu_squC"><ul class="theme-doc-sidebar-menu menu__list"><li class="theme-doc-sidebar-item-link theme-doc-sidebar-item-link-level-1 menu__list-item"><a class="menu__link" href="/document/">Quick start</a></li><li class="theme-doc-sidebar-item-link theme-doc-sidebLine truncated
<script src="/document/assets/js/runtime~main.f9808e8d.js"></script>
<script src="/document/assets/js/main.ac59e946.js"></script>
</body>
</html>
+17
View File
@@ -0,0 +1,17 @@
<!doctype html>
<html lang="en" dir="ltr" class="docs-wrapper docs-doc-page docs-version-current plugin-docs plugin-id-default docs-doc-id-en/Plugins/ads">
<head>
<meta charset="UTF-8">
<meta name="viewport" content="width=device-width,initial-scale=1">
<meta name="generator" content="Docusaurus v2.0.0-beta.20">
<title data-rh="true">Ads Plugin | Artplayer.js</title><meta data-rh="true" name="twitter:card" content="summary_large_image"><meta data-rh="true" property="og:url" content="https://artplayer.org/document/en/Plugins/ads"><meta data-rh="true" name="docusaurus_locale" content="en"><meta data-rh="true" name="docsearch:language" content="en"><meta data-rh="true" name="docusaurus_version" content="current"><meta data-rh="true" name="docusaurus_tag" content="docs-default-current"><meta data-rh="true" name="docsearch:version" content="current"><meta data-rh="true" name="docsearch:docusaurus_tag" content="docs-default-current"><meta data-rh="true" property="og:title" content="Ads Plugin | Artplayer.js"><meta data-rh="true" name="description" content="Demo"><meta data-rh="true" property="og:description" content="Demo"><link data-rh="true" rel="icon" href="/document/img/favicon.ico"><link data-rh="true" rel="canonical" href="https://artplayer.org/document/en/Plugins/ads"><link data-rh="true" rel="alternate" href="https://artplayer.org/document/en/Plugins/ads" hreflang="en"><link data-rh="true" rel="alternate" href="https://artplayer.org/document/en/Plugins/ads" hreflang="x-default"><link rel="stylesheet" href="/document/assets/css/styles.7b2fc50a.css">
<link rel="preload" href="/document/assets/js/runtime~main.f9808e8d.js" as="script">
<link rel="preload" href="/document/assets/js/main.ac59e946.js" as="script">
</head>
<body class="navigation-with-keyboard">
<script>!function(){function t(t){document.documentElement.setAttribute("data-theme",t)}var e=function(){var t=null;try{t=localStorage.getItem("theme")}catch(t){}return t}();t(null!==e?e:"light")}()</script><div id="__docusaurus">
<div role="region"><a href="#" class="skipToContent_cbSD">Skip to main content</a></div><nav class="navbar navbar--fixed-top"><div class="navbar__inner"><div class="navbar__items"><button aria-label="Navigation bar toggle" class="navbar__toggle clean-btn" type="button" tabindex="0"><svg width="30" height="30" viewBox="0 0 30 30" aria-hidden="true"><path stroke="currentColor" stroke-linecap="round" stroke-miterlimit="10" stroke-width="2" d="M4 7h22M4 15h22M4 23h22"></path></svg></button><a href="https://artplayer.org/document" target="_self" rel="noopener noreferrer" class="navbar__brand"><div class="navbar__logo"><img src="/document/img/logo.png" alt="Artplayer.js" class="themedImage_WmJs themedImage--light_gXqO" height="28" width="28"><img src="/document/img/logo.png" alt="Artplayer.js" class="themedImage_WmJs themedImage--dark_X1Zc" height="28" width="28"></div><b class="navbar__title text--truncate">Artplayer.js</b></a><a href="https://artplayer.org" target="_blank" rel="noopener noreferrer" class="navbar__item navbar__link">Online Editor<svg width="13.5" height="13.5" aria-hidden="true" viewBox="0 0 24 24" class="iconExternalLink_cOdw"><path fill="currentColor" d="M21 13v10h-21v-19h12v2h-10v15h17v-8h2zm3-12h-10.988l4.035 4-6.977 7.07 2.828 2.828 6.977-7.07 4.125 4.172v-11z"></path></svg></a><a href="https://github.com/zhw2590582/ArtPlayer" target="_blank" rel="noopener noreferrer" class="navbar__item navbar__link">Github<svg width="13.5" height="13.5" aria-hidden="true" viewBox="0 0 24 24" class="iconExternalLink_cOdw"><path fill="currentColor" d="M21 13v10h-21v-19h12v2h-10v15h17v-8h2zm3-12h-10.988l4.035 4-6.977 7.07 2.828 2.828 6.977-7.07 4.125 4.172v-11z"></path></svg></a></div><div class="navbar__items navbar__items--right"><a href="#" class="navbar__item navbar__link">QQ群: 320881312</a><div class="navbar__item dropdown dropdown--hoverable dropdown--right"><a href="#" aria-haspopup="true" aria-expanded="false" role="button" class="navbar__link">English</a><ul class="dropdown__menu"><li><a class="dropdown__link" href="/document/">English</a></li><li><a class="dropdown__link" href="/document/zh-cn/">中文</a></li></ul></div><div class="toggle_F6nl colorModeToggle_ndsa"><button class="clean-btn toggleButton_Szei toggleButtonDisabled_qp8o" type="button" disabled="" title="Switch between dark and light mode (currently light mode)" aria-label="Switch between dark and light mode (currently light mode)"><svg viewBox="0 0 24 24" width="24" height="24" class="lightToggleIcon_y2PQ"><path fill="currentColor" d="M12,9c1.65,0,3,1.35,3,3s-1.35,3-3,3s-3-1.35-3-3S10.35,9,12,9 M12,7c-2.76,0-5,2.24-5,5s2.24,5,5,5s5-2.24,5-5 S14.76,7,12,7L12,7z M2,13l2,0c0.55,0,1-0.45,1-1s-0.45-1-1-1l-2,0c-0.55,0-1,0.45-1,1S1.45,13,2,13z M20,13l2,0c0.55,0,1-0.45,1-1 s-0.45-1-1-1l-2,0c-0.55,0-1,0.45-1,1S19.45,13,20,13z M11,2v2c0,0.55,0.45,1,1,1s1-0.45,1-1V2c0-0.55-0.45-1-1-1S11,1.45,11,2z M11,20v2c0,0.55,0.45,1,1,1s1-0.45,1-1v-2c0-0.55-0.45-1-1-1C11.45,19,11,19.45,11,20z M5.99,4.58c-0.39-0.39-1.03-0.39-1.41,0 c-0.39,0.39-0.39,1.03,0,1.41l1.06,1.06c0.39,0.39,1.03,0.39,1.41,0s0.39-1.03,0-1.41L5.99,4.58z M18.36,16.95 c-0.39-0.39-1.03-0.39-1.41,0c-0.39,0.39-0.39,1.03,0,1.41l1.06,1.06c0.39,0.39,1.03,0.39,1.41,0c0.39-0.39,0.39-1.03,0-1.41 L18.36,16.95z M19.42,5.99c0.39-0.39,0.39-1.03,0-1.41c-0.39-0.39-1.03-0.39-1.41,0l-1.06,1.06c-0.39,0.39-0.39,1.03,0,1.41 s1.03,0.39,1.41,0L19.42,5.99z M7.05,18.36c0.39-0.39,0.39-1.03,0-1.41c-0.39-0.39-1.03-0.39-1.41,0l-1.06,1.06 c-0.39,0.39-0.39,1.03,0,1.41s1.03,0.39,1.41,0L7.05,18.36z"></path></svg><svg viewBox="0 0 24 24" width="24" height="24" class="darkToggleIcon_sMpk"><path fill="currentColor" d="M9.37,5.51C9.19,6.15,9.1,6.82,9.1,7.5c0,4.08,3.32,7.4,7.4,7.4c0.68,0,1.35-0.09,1.99-0.27C17.45,17.19,14.93,19,12,19 c-3.86,0-7-3.14-7-7C5,9.07,6.81,6.55,9.37,5.51z M12,3c-4.97,0-9,4.03-9,9s4.03,9,9,9s9-4.03,9-9c0-0.46-0.04-0.92-0.1-1.36 c-0.98,1.37-2.58,2.26-4.4,2.26c-2.98,0-5.4-2.42-5.4-5.4c0-1.81,0.89-3.42,2.26-4.4C12.92,3.04,12.46,3,12,3L12,3z"></path></svg></button></div><div class="searchBox_xKlU"><div class="navbar__search"><span aria-label="expand searchbar" role="button" class="search-icon" tabindex="0"></span><input type="search" id="search_input_react" placeholder="Search" aria-label="Search" class="navbar__search-input search-bar"></div></div></div></div><div role="presentation" class="navbar-sidebar__backdrop"></div></nav><div class="main-wrapper docsWrapper_GpM1"><button aria-label="Scroll back to top" class="clean-btn theme-back-to-top-button backToTopButton_EOoS" type="button"></button><div class="docPage_vgSg"><aside class="theme-doc-sidebar-container docSidebarContainer_RUQH"><div class="sidebar_gEXq"><nav class="menu thin-scrollbar menu_squC"><ul class="theme-doc-sidebar-menu menu__list"><li class="theme-doc-sidebar-item-link theme-doc-sidebar-item-link-level-1 menu__list-item"><a class="menu__link" href="/document/">Quick start</a></li><li class="theme-doc-sidebar-item-link theme-doc-sidebLine truncated
<script src="/document/assets/js/runtime~main.f9808e8d.js"></script>
<script src="/document/assets/js/main.ac59e946.js"></script>
</body>
</html>
+6 -6
View File
@@ -4,14 +4,14 @@
<meta charset="UTF-8">
<meta name="viewport" content="width=device-width,initial-scale=1">
<meta name="generator" content="Docusaurus v2.0.0-beta.20">
<title data-rh="true">Danmuku plugin | Artplayer.js</title><meta data-rh="true" name="twitter:card" content="summary_large_image"><meta data-rh="true" property="og:url" content="https://artplayer.org/document/en/Plugins/danmuku"><meta data-rh="true" name="docusaurus_locale" content="en"><meta data-rh="true" name="docsearch:language" content="en"><meta data-rh="true" name="docusaurus_version" content="current"><meta data-rh="true" name="docusaurus_tag" content="docs-default-current"><meta data-rh="true" name="docsearch:version" content="current"><meta data-rh="true" name="docsearch:docusaurus_tag" content="docs-default-current"><meta data-rh="true" property="og:title" content="Danmuku plugin | Artplayer.js"><meta data-rh="true" name="description" content="The documentation of the current danmaku library plug-in, only the Chinese version"><meta data-rh="true" property="og:description" content="The documentation of the current danmaku library plug-in, only the Chinese version"><link data-rh="true" rel="icon" href="/document/img/favicon.ico"><link data-rh="true" rel="canonical" href="https://artplayer.org/document/en/Plugins/danmuku"><link data-rh="true" rel="alternate" href="https://artplayer.org/document/en/Plugins/danmuku" hreflang="en"><link data-rh="true" rel="alternate" href="https://artplayer.org/document/en/Plugins/danmuku" hreflang="x-default"><link rel="stylesheet" href="/document/assets/css/styles.eba261b7.css">
<link rel="preload" href="/document/assets/js/runtime~main.222c91cd.js" as="script">
<link rel="preload" href="/document/assets/js/main.9ce4b94b.js" as="script">
<title data-rh="true">Danmuku plugin | Artplayer.js</title><meta data-rh="true" name="twitter:card" content="summary_large_image"><meta data-rh="true" property="og:url" content="https://artplayer.org/document/en/Plugins/danmuku"><meta data-rh="true" name="docusaurus_locale" content="en"><meta data-rh="true" name="docsearch:language" content="en"><meta data-rh="true" name="docusaurus_version" content="current"><meta data-rh="true" name="docusaurus_tag" content="docs-default-current"><meta data-rh="true" name="docsearch:version" content="current"><meta data-rh="true" name="docsearch:docusaurus_tag" content="docs-default-current"><meta data-rh="true" property="og:title" content="Danmuku plugin | Artplayer.js"><meta data-rh="true" name="description" content="The documentation of the current danmaku library plug-in, only the Chinese version"><meta data-rh="true" property="og:description" content="The documentation of the current danmaku library plug-in, only the Chinese version"><link data-rh="true" rel="icon" href="/document/img/favicon.ico"><link data-rh="true" rel="canonical" href="https://artplayer.org/document/en/Plugins/danmuku"><link data-rh="true" rel="alternate" href="https://artplayer.org/document/en/Plugins/danmuku" hreflang="en"><link data-rh="true" rel="alternate" href="https://artplayer.org/document/en/Plugins/danmuku" hreflang="x-default"><link rel="stylesheet" href="/document/assets/css/styles.7b2fc50a.css">
<link rel="preload" href="/document/assets/js/runtime~main.f9808e8d.js" as="script">
<link rel="preload" href="/document/assets/js/main.ac59e946.js" as="script">
</head>
<body class="navigation-with-keyboard">
<script>!function(){function t(t){document.documentElement.setAttribute("data-theme",t)}var e=function(){var t=null;try{t=localStorage.getItem("theme")}catch(t){}return t}();t(null!==e?e:"light")}()</script><div id="__docusaurus">
<div role="region"><a href="#" class="skipToContent_ZgBM">Skip to main content</a></div><nav class="navbar navbar--fixed-top"><div class="navbar__inner"><div class="navbar__items"><button aria-label="Navigation bar toggle" class="navbar__toggle clean-btn" type="button" tabindex="0"><svg width="30" height="30" viewBox="0 0 30 30" aria-hidden="true"><path stroke="currentColor" stroke-linecap="round" stroke-miterlimit="10" stroke-width="2" d="M4 7h22M4 15h22M4 23h22"></path></svg></button><a href="https://artplayer.org/document" target="_self" rel="noopener noreferrer" class="navbar__brand"><div class="navbar__logo"><img src="/document/img/logo.png" alt="Artplayer.js" class="themedImage_W2Cr themedImage--light_TfLj" height="28" width="28"><img src="/document/img/logo.png" alt="Artplayer.js" class="themedImage_W2Cr themedImage--dark_oUvU" height="28" width="28"></div><b class="navbar__title text--truncate">Artplayer.js</b></a><a href="https://artplayer.org" target="_blank" rel="noopener noreferrer" class="navbar__item navbar__link">Online Editor<svg width="13.5" height="13.5" aria-hidden="true" viewBox="0 0 24 24" class="iconExternalLink_I5OW"><path fill="currentColor" d="M21 13v10h-21v-19h12v2h-10v15h17v-8h2zm3-12h-10.988l4.035 4-6.977 7.07 2.828 2.828 6.977-7.07 4.125 4.172v-11z"></path></svg></a><a href="https://github.com/zhw2590582/ArtPlayer" target="_blank" rel="noopener noreferrer" class="navbar__item navbar__link">Github<svg width="13.5" height="13.5" aria-hidden="true" viewBox="0 0 24 24" class="iconExternalLink_I5OW"><path fill="currentColor" d="M21 13v10h-21v-19h12v2h-10v15h17v-8h2zm3-12h-10.988l4.035 4-6.977 7.07 2.828 2.828 6.977-7.07 4.125 4.172v-11z"></path></svg></a></div><div class="navbar__items navbar__items--right"><a href="#" class="navbar__item navbar__link">QQ群: 320881312</a><div class="navbar__item dropdown dropdown--hoverable dropdown--right"><a href="#" aria-haspopup="true" aria-expanded="false" role="button" class="navbar__link">English</a><ul class="dropdown__menu"><li><a class="dropdown__link" href="/document/">English</a></li><li><a class="dropdown__link" href="/document/zh-cn/">中文</a></li></ul></div><div class="toggle_S7eR colorModeToggle_vKtC"><button class="clean-btn toggleButton_rCf9 toggleButtonDisabled_Pu9x" type="button" disabled="" title="Switch between dark and light mode (currently light mode)" aria-label="Switch between dark and light mode (currently light mode)"><svg viewBox="0 0 24 24" width="24" height="24" class="lightToggleIcon_v35p"><path fill="currentColor" d="M12,9c1.65,0,3,1.35,3,3s-1.35,3-3,3s-3-1.35-3-3S10.35,9,12,9 M12,7c-2.76,0-5,2.24-5,5s2.24,5,5,5s5-2.24,5-5 S14.76,7,12,7L12,7z M2,13l2,0c0.55,0,1-0.45,1-1s-0.45-1-1-1l-2,0c-0.55,0-1,0.45-1,1S1.45,13,2,13z M20,13l2,0c0.55,0,1-0.45,1-1 s-0.45-1-1-1l-2,0c-0.55,0-1,0.45-1,1S19.45,13,20,13z M11,2v2c0,0.55,0.45,1,1,1s1-0.45,1-1V2c0-0.55-0.45-1-1-1S11,1.45,11,2z M11,20v2c0,0.55,0.45,1,1,1s1-0.45,1-1v-2c0-0.55-0.45-1-1-1C11.45,19,11,19.45,11,20z M5.99,4.58c-0.39-0.39-1.03-0.39-1.41,0 c-0.39,0.39-0.39,1.03,0,1.41l1.06,1.06c0.39,0.39,1.03,0.39,1.41,0s0.39-1.03,0-1.41L5.99,4.58z M18.36,16.95 c-0.39-0.39-1.03-0.39-1.41,0c-0.39,0.39-0.39,1.03,0,1.41l1.06,1.06c0.39,0.39,1.03,0.39,1.41,0c0.39-0.39,0.39-1.03,0-1.41 L18.36,16.95z M19.42,5.99c0.39-0.39,0.39-1.03,0-1.41c-0.39-0.39-1.03-0.39-1.41,0l-1.06,1.06c-0.39,0.39-0.39,1.03,0,1.41 s1.03,0.39,1.41,0L19.42,5.99z M7.05,18.36c0.39-0.39,0.39-1.03,0-1.41c-0.39-0.39-1.03-0.39-1.41,0l-1.06,1.06 c-0.39,0.39-0.39,1.03,0,1.41s1.03,0.39,1.41,0L7.05,18.36z"></path></svg><svg viewBox="0 0 24 24" width="24" height="24" class="darkToggleIcon_nQuB"><path fill="currentColor" d="M9.37,5.51C9.19,6.15,9.1,6.82,9.1,7.5c0,4.08,3.32,7.4,7.4,7.4c0.68,0,1.35-0.09,1.99-0.27C17.45,17.19,14.93,19,12,19 c-3.86,0-7-3.14-7-7C5,9.07,6.81,6.55,9.37,5.51z M12,3c-4.97,0-9,4.03-9,9s4.03,9,9,9s9-4.03,9-9c0-0.46-0.04-0.92-0.1-1.36 c-0.98,1.37-2.58,2.26-4.4,2.26c-2.98,0-5.4-2.42-5.4-5.4c0-1.81,0.89-3.42,2.26-4.4C12.92,3.04,12.46,3,12,3L12,3z"></path></svg></button></div><div class="searchBox_dLyj"><div class="navbar__search"><span aria-label="expand searchbar" role="button" class="search-icon" tabindex="0"></span><input type="search" id="search_input_react" placeholder="Search" aria-label="Search" class="navbar__search-input search-bar"></div></div></div></div><div role="presentation" class="navbar-sidebar__backdrop"></div></nav><div class="main-wrapper docsWrapper_mKqt"><button aria-label="Scroll back to top" class="clean-btn theme-back-to-top-button backToTopButton_RiI4" type="button"></button><div class="docPage_ualW"><aside class="theme-doc-sidebar-container docSidebarContainer_UQUJ"><div class="sidebar_RiAD"><nav class="menu thin-scrollbar menu_izAj"><ul class="theme-doc-sidebar-menu menu__list"><li class="theme-doc-sidebar-item-link theme-doc-sidebar-item-link-level-1 menu__list-item"><a class="menu__link" href="/document/">Quick start</a></li><li class="theme-doc-sidebar-item-link theme-doc-sidebLine truncated
<script src="/document/assets/js/runtime~main.222c91cd.js"></script>
<script src="/document/assets/js/main.9ce4b94b.js"></script>
<div role="region"><a href="#" class="skipToContent_cbSD">Skip to main content</a></div><nav class="navbar navbar--fixed-top"><div class="navbar__inner"><div class="navbar__items"><button aria-label="Navigation bar toggle" class="navbar__toggle clean-btn" type="button" tabindex="0"><svg width="30" height="30" viewBox="0 0 30 30" aria-hidden="true"><path stroke="currentColor" stroke-linecap="round" stroke-miterlimit="10" stroke-width="2" d="M4 7h22M4 15h22M4 23h22"></path></svg></button><a href="https://artplayer.org/document" target="_self" rel="noopener noreferrer" class="navbar__brand"><div class="navbar__logo"><img src="/document/img/logo.png" alt="Artplayer.js" class="themedImage_WmJs themedImage--light_gXqO" height="28" width="28"><img src="/document/img/logo.png" alt="Artplayer.js" class="themedImage_WmJs themedImage--dark_X1Zc" height="28" width="28"></div><b class="navbar__title text--truncate">Artplayer.js</b></a><a href="https://artplayer.org" target="_blank" rel="noopener noreferrer" class="navbar__item navbar__link">Online Editor<svg width="13.5" height="13.5" aria-hidden="true" viewBox="0 0 24 24" class="iconExternalLink_cOdw"><path fill="currentColor" d="M21 13v10h-21v-19h12v2h-10v15h17v-8h2zm3-12h-10.988l4.035 4-6.977 7.07 2.828 2.828 6.977-7.07 4.125 4.172v-11z"></path></svg></a><a href="https://github.com/zhw2590582/ArtPlayer" target="_blank" rel="noopener noreferrer" class="navbar__item navbar__link">Github<svg width="13.5" height="13.5" aria-hidden="true" viewBox="0 0 24 24" class="iconExternalLink_cOdw"><path fill="currentColor" d="M21 13v10h-21v-19h12v2h-10v15h17v-8h2zm3-12h-10.988l4.035 4-6.977 7.07 2.828 2.828 6.977-7.07 4.125 4.172v-11z"></path></svg></a></div><div class="navbar__items navbar__items--right"><a href="#" class="navbar__item navbar__link">QQ群: 320881312</a><div class="navbar__item dropdown dropdown--hoverable dropdown--right"><a href="#" aria-haspopup="true" aria-expanded="false" role="button" class="navbar__link">English</a><ul class="dropdown__menu"><li><a class="dropdown__link" href="/document/">English</a></li><li><a class="dropdown__link" href="/document/zh-cn/">中文</a></li></ul></div><div class="toggle_F6nl colorModeToggle_ndsa"><button class="clean-btn toggleButton_Szei toggleButtonDisabled_qp8o" type="button" disabled="" title="Switch between dark and light mode (currently light mode)" aria-label="Switch between dark and light mode (currently light mode)"><svg viewBox="0 0 24 24" width="24" height="24" class="lightToggleIcon_y2PQ"><path fill="currentColor" d="M12,9c1.65,0,3,1.35,3,3s-1.35,3-3,3s-3-1.35-3-3S10.35,9,12,9 M12,7c-2.76,0-5,2.24-5,5s2.24,5,5,5s5-2.24,5-5 S14.76,7,12,7L12,7z M2,13l2,0c0.55,0,1-0.45,1-1s-0.45-1-1-1l-2,0c-0.55,0-1,0.45-1,1S1.45,13,2,13z M20,13l2,0c0.55,0,1-0.45,1-1 s-0.45-1-1-1l-2,0c-0.55,0-1,0.45-1,1S19.45,13,20,13z M11,2v2c0,0.55,0.45,1,1,1s1-0.45,1-1V2c0-0.55-0.45-1-1-1S11,1.45,11,2z M11,20v2c0,0.55,0.45,1,1,1s1-0.45,1-1v-2c0-0.55-0.45-1-1-1C11.45,19,11,19.45,11,20z M5.99,4.58c-0.39-0.39-1.03-0.39-1.41,0 c-0.39,0.39-0.39,1.03,0,1.41l1.06,1.06c0.39,0.39,1.03,0.39,1.41,0s0.39-1.03,0-1.41L5.99,4.58z M18.36,16.95 c-0.39-0.39-1.03-0.39-1.41,0c-0.39,0.39-0.39,1.03,0,1.41l1.06,1.06c0.39,0.39,1.03,0.39,1.41,0c0.39-0.39,0.39-1.03,0-1.41 L18.36,16.95z M19.42,5.99c0.39-0.39,0.39-1.03,0-1.41c-0.39-0.39-1.03-0.39-1.41,0l-1.06,1.06c-0.39,0.39-0.39,1.03,0,1.41 s1.03,0.39,1.41,0L19.42,5.99z M7.05,18.36c0.39-0.39,0.39-1.03,0-1.41c-0.39-0.39-1.03-0.39-1.41,0l-1.06,1.06 c-0.39,0.39-0.39,1.03,0,1.41s1.03,0.39,1.41,0L7.05,18.36z"></path></svg><svg viewBox="0 0 24 24" width="24" height="24" class="darkToggleIcon_sMpk"><path fill="currentColor" d="M9.37,5.51C9.19,6.15,9.1,6.82,9.1,7.5c0,4.08,3.32,7.4,7.4,7.4c0.68,0,1.35-0.09,1.99-0.27C17.45,17.19,14.93,19,12,19 c-3.86,0-7-3.14-7-7C5,9.07,6.81,6.55,9.37,5.51z M12,3c-4.97,0-9,4.03-9,9s4.03,9,9,9s9-4.03,9-9c0-0.46-0.04-0.92-0.1-1.36 c-0.98,1.37-2.58,2.26-4.4,2.26c-2.98,0-5.4-2.42-5.4-5.4c0-1.81,0.89-3.42,2.26-4.4C12.92,3.04,12.46,3,12,3L12,3z"></path></svg></button></div><div class="searchBox_xKlU"><div class="navbar__search"><span aria-label="expand searchbar" role="button" class="search-icon" tabindex="0"></span><input type="search" id="search_input_react" placeholder="Search" aria-label="Search" class="navbar__search-input search-bar"></div></div></div></div><div role="presentation" class="navbar-sidebar__backdrop"></div></nav><div class="main-wrapper docsWrapper_GpM1"><button aria-label="Scroll back to top" class="clean-btn theme-back-to-top-button backToTopButton_EOoS" type="button"></button><div class="docPage_vgSg"><aside class="theme-doc-sidebar-container docSidebarContainer_RUQH"><div class="sidebar_gEXq"><nav class="menu thin-scrollbar menu_squC"><ul class="theme-doc-sidebar-menu menu__list"><li class="theme-doc-sidebar-item-link theme-doc-sidebar-item-link-level-1 menu__list-item"><a class="menu__link" href="/document/">Quick start</a></li><li class="theme-doc-sidebar-item-link theme-doc-sidebLine truncated
<script src="/document/assets/js/runtime~main.f9808e8d.js"></script>
<script src="/document/assets/js/main.ac59e946.js"></script>
</body>
</html>
@@ -4,14 +4,14 @@
<meta charset="UTF-8">
<meta name="viewport" content="width=device-width,initial-scale=1">
<meta name="generator" content="Docusaurus v2.0.0-beta.20">
<title data-rh="true">Add button to the controls | Artplayer.js</title><meta data-rh="true" name="twitter:card" content="summary_large_image"><meta data-rh="true" property="og:url" content="https://artplayer.org/document/en/Questions/Create_button_in_the_controls"><meta data-rh="true" name="docusaurus_locale" content="en"><meta data-rh="true" name="docsearch:language" content="en"><meta data-rh="true" name="docusaurus_version" content="current"><meta data-rh="true" name="docusaurus_tag" content="docs-default-current"><meta data-rh="true" name="docsearch:version" content="current"><meta data-rh="true" name="docsearch:docusaurus_tag" content="docs-default-current"><meta data-rh="true" property="og:title" content="Add button to the controls | Artplayer.js"><meta data-rh="true" name="description" content="▶ Run Code"><meta data-rh="true" property="og:description" content="▶ Run Code"><link data-rh="true" rel="icon" href="/document/img/favicon.ico"><link data-rh="true" rel="canonical" href="https://artplayer.org/document/en/Questions/Create_button_in_the_controls"><link data-rh="true" rel="alternate" href="https://artplayer.org/document/en/Questions/Create_button_in_the_controls" hreflang="en"><link data-rh="true" rel="alternate" href="https://artplayer.org/document/en/Questions/Create_button_in_the_controls" hreflang="x-default"><link rel="stylesheet" href="/document/assets/css/styles.eba261b7.css">
<link rel="preload" href="/document/assets/js/runtime~main.222c91cd.js" as="script">
<link rel="preload" href="/document/assets/js/main.9ce4b94b.js" as="script">
<title data-rh="true">Add button to the controls | Artplayer.js</title><meta data-rh="true" name="twitter:card" content="summary_large_image"><meta data-rh="true" property="og:url" content="https://artplayer.org/document/en/Questions/Create_button_in_the_controls"><meta data-rh="true" name="docusaurus_locale" content="en"><meta data-rh="true" name="docsearch:language" content="en"><meta data-rh="true" name="docusaurus_version" content="current"><meta data-rh="true" name="docusaurus_tag" content="docs-default-current"><meta data-rh="true" name="docsearch:version" content="current"><meta data-rh="true" name="docsearch:docusaurus_tag" content="docs-default-current"><meta data-rh="true" property="og:title" content="Add button to the controls | Artplayer.js"><meta data-rh="true" name="description" content="▶ Run Code"><meta data-rh="true" property="og:description" content="▶ Run Code"><link data-rh="true" rel="icon" href="/document/img/favicon.ico"><link data-rh="true" rel="canonical" href="https://artplayer.org/document/en/Questions/Create_button_in_the_controls"><link data-rh="true" rel="alternate" href="https://artplayer.org/document/en/Questions/Create_button_in_the_controls" hreflang="en"><link data-rh="true" rel="alternate" href="https://artplayer.org/document/en/Questions/Create_button_in_the_controls" hreflang="x-default"><link rel="stylesheet" href="/document/assets/css/styles.7b2fc50a.css">
<link rel="preload" href="/document/assets/js/runtime~main.f9808e8d.js" as="script">
<link rel="preload" href="/document/assets/js/main.ac59e946.js" as="script">
</head>
<body class="navigation-with-keyboard">
<script>!function(){function t(t){document.documentElement.setAttribute("data-theme",t)}var e=function(){var t=null;try{t=localStorage.getItem("theme")}catch(t){}return t}();t(null!==e?e:"light")}()</script><div id="__docusaurus">
<div role="region"><a href="#" class="skipToContent_ZgBM">Skip to main content</a></div><nav class="navbar navbar--fixed-top"><div class="navbar__inner"><div class="navbar__items"><button aria-label="Navigation bar toggle" class="navbar__toggle clean-btn" type="button" tabindex="0"><svg width="30" height="30" viewBox="0 0 30 30" aria-hidden="true"><path stroke="currentColor" stroke-linecap="round" stroke-miterlimit="10" stroke-width="2" d="M4 7h22M4 15h22M4 23h22"></path></svg></button><a href="https://artplayer.org/document" target="_self" rel="noopener noreferrer" class="navbar__brand"><div class="navbar__logo"><img src="/document/img/logo.png" alt="Artplayer.js" class="themedImage_W2Cr themedImage--light_TfLj" height="28" width="28"><img src="/document/img/logo.png" alt="Artplayer.js" class="themedImage_W2Cr themedImage--dark_oUvU" height="28" width="28"></div><b class="navbar__title text--truncate">Artplayer.js</b></a><a href="https://artplayer.org" target="_blank" rel="noopener noreferrer" class="navbar__item navbar__link">Online Editor<svg width="13.5" height="13.5" aria-hidden="true" viewBox="0 0 24 24" class="iconExternalLink_I5OW"><path fill="currentColor" d="M21 13v10h-21v-19h12v2h-10v15h17v-8h2zm3-12h-10.988l4.035 4-6.977 7.07 2.828 2.828 6.977-7.07 4.125 4.172v-11z"></path></svg></a><a href="https://github.com/zhw2590582/ArtPlayer" target="_blank" rel="noopener noreferrer" class="navbar__item navbar__link">Github<svg width="13.5" height="13.5" aria-hidden="true" viewBox="0 0 24 24" class="iconExternalLink_I5OW"><path fill="currentColor" d="M21 13v10h-21v-19h12v2h-10v15h17v-8h2zm3-12h-10.988l4.035 4-6.977 7.07 2.828 2.828 6.977-7.07 4.125 4.172v-11z"></path></svg></a></div><div class="navbar__items navbar__items--right"><a href="#" class="navbar__item navbar__link">QQ群: 320881312</a><div class="navbar__item dropdown dropdown--hoverable dropdown--right"><a href="#" aria-haspopup="true" aria-expanded="false" role="button" class="navbar__link">English</a><ul class="dropdown__menu"><li><a class="dropdown__link" href="/document/">English</a></li><li><a class="dropdown__link" href="/document/zh-cn/">中文</a></li></ul></div><div class="toggle_S7eR colorModeToggle_vKtC"><button class="clean-btn toggleButton_rCf9 toggleButtonDisabled_Pu9x" type="button" disabled="" title="Switch between dark and light mode (currently light mode)" aria-label="Switch between dark and light mode (currently light mode)"><svg viewBox="0 0 24 24" width="24" height="24" class="lightToggleIcon_v35p"><path fill="currentColor" d="M12,9c1.65,0,3,1.35,3,3s-1.35,3-3,3s-3-1.35-3-3S10.35,9,12,9 M12,7c-2.76,0-5,2.24-5,5s2.24,5,5,5s5-2.24,5-5 S14.76,7,12,7L12,7z M2,13l2,0c0.55,0,1-0.45,1-1s-0.45-1-1-1l-2,0c-0.55,0-1,0.45-1,1S1.45,13,2,13z M20,13l2,0c0.55,0,1-0.45,1-1 s-0.45-1-1-1l-2,0c-0.55,0-1,0.45-1,1S19.45,13,20,13z M11,2v2c0,0.55,0.45,1,1,1s1-0.45,1-1V2c0-0.55-0.45-1-1-1S11,1.45,11,2z M11,20v2c0,0.55,0.45,1,1,1s1-0.45,1-1v-2c0-0.55-0.45-1-1-1C11.45,19,11,19.45,11,20z M5.99,4.58c-0.39-0.39-1.03-0.39-1.41,0 c-0.39,0.39-0.39,1.03,0,1.41l1.06,1.06c0.39,0.39,1.03,0.39,1.41,0s0.39-1.03,0-1.41L5.99,4.58z M18.36,16.95 c-0.39-0.39-1.03-0.39-1.41,0c-0.39,0.39-0.39,1.03,0,1.41l1.06,1.06c0.39,0.39,1.03,0.39,1.41,0c0.39-0.39,0.39-1.03,0-1.41 L18.36,16.95z M19.42,5.99c0.39-0.39,0.39-1.03,0-1.41c-0.39-0.39-1.03-0.39-1.41,0l-1.06,1.06c-0.39,0.39-0.39,1.03,0,1.41 s1.03,0.39,1.41,0L19.42,5.99z M7.05,18.36c0.39-0.39,0.39-1.03,0-1.41c-0.39-0.39-1.03-0.39-1.41,0l-1.06,1.06 c-0.39,0.39-0.39,1.03,0,1.41s1.03,0.39,1.41,0L7.05,18.36z"></path></svg><svg viewBox="0 0 24 24" width="24" height="24" class="darkToggleIcon_nQuB"><path fill="currentColor" d="M9.37,5.51C9.19,6.15,9.1,6.82,9.1,7.5c0,4.08,3.32,7.4,7.4,7.4c0.68,0,1.35-0.09,1.99-0.27C17.45,17.19,14.93,19,12,19 c-3.86,0-7-3.14-7-7C5,9.07,6.81,6.55,9.37,5.51z M12,3c-4.97,0-9,4.03-9,9s4.03,9,9,9s9-4.03,9-9c0-0.46-0.04-0.92-0.1-1.36 c-0.98,1.37-2.58,2.26-4.4,2.26c-2.98,0-5.4-2.42-5.4-5.4c0-1.81,0.89-3.42,2.26-4.4C12.92,3.04,12.46,3,12,3L12,3z"></path></svg></button></div><div class="searchBox_dLyj"><div class="navbar__search"><span aria-label="expand searchbar" role="button" class="search-icon" tabindex="0"></span><input type="search" id="search_input_react" placeholder="Search" aria-label="Search" class="navbar__search-input search-bar"></div></div></div></div><div role="presentation" class="navbar-sidebar__backdrop"></div></nav><div class="main-wrapper docsWrapper_mKqt"><button aria-label="Scroll back to top" class="clean-btn theme-back-to-top-button backToTopButton_RiI4" type="button"></button><div class="docPage_ualW"><aside class="theme-doc-sidebar-container docSidebarContainer_UQUJ"><div class="sidebar_RiAD"><nav class="menu thin-scrollbar menu_izAj"><ul class="theme-doc-sidebar-menu menu__list"><li class="theme-doc-sidebar-item-link theme-doc-sidebar-item-link-level-1 menu__list-item"><a class="menu__link" href="/document/">Quick start</a></li><li class="theme-doc-sidebar-item-link theme-doc-sidebLine truncated
<script src="/document/assets/js/runtime~main.222c91cd.js"></script>
<script src="/document/assets/js/main.9ce4b94b.js"></script>
<div role="region"><a href="#" class="skipToContent_cbSD">Skip to main content</a></div><nav class="navbar navbar--fixed-top"><div class="navbar__inner"><div class="navbar__items"><button aria-label="Navigation bar toggle" class="navbar__toggle clean-btn" type="button" tabindex="0"><svg width="30" height="30" viewBox="0 0 30 30" aria-hidden="true"><path stroke="currentColor" stroke-linecap="round" stroke-miterlimit="10" stroke-width="2" d="M4 7h22M4 15h22M4 23h22"></path></svg></button><a href="https://artplayer.org/document" target="_self" rel="noopener noreferrer" class="navbar__brand"><div class="navbar__logo"><img src="/document/img/logo.png" alt="Artplayer.js" class="themedImage_WmJs themedImage--light_gXqO" height="28" width="28"><img src="/document/img/logo.png" alt="Artplayer.js" class="themedImage_WmJs themedImage--dark_X1Zc" height="28" width="28"></div><b class="navbar__title text--truncate">Artplayer.js</b></a><a href="https://artplayer.org" target="_blank" rel="noopener noreferrer" class="navbar__item navbar__link">Online Editor<svg width="13.5" height="13.5" aria-hidden="true" viewBox="0 0 24 24" class="iconExternalLink_cOdw"><path fill="currentColor" d="M21 13v10h-21v-19h12v2h-10v15h17v-8h2zm3-12h-10.988l4.035 4-6.977 7.07 2.828 2.828 6.977-7.07 4.125 4.172v-11z"></path></svg></a><a href="https://github.com/zhw2590582/ArtPlayer" target="_blank" rel="noopener noreferrer" class="navbar__item navbar__link">Github<svg width="13.5" height="13.5" aria-hidden="true" viewBox="0 0 24 24" class="iconExternalLink_cOdw"><path fill="currentColor" d="M21 13v10h-21v-19h12v2h-10v15h17v-8h2zm3-12h-10.988l4.035 4-6.977 7.07 2.828 2.828 6.977-7.07 4.125 4.172v-11z"></path></svg></a></div><div class="navbar__items navbar__items--right"><a href="#" class="navbar__item navbar__link">QQ群: 320881312</a><div class="navbar__item dropdown dropdown--hoverable dropdown--right"><a href="#" aria-haspopup="true" aria-expanded="false" role="button" class="navbar__link">English</a><ul class="dropdown__menu"><li><a class="dropdown__link" href="/document/">English</a></li><li><a class="dropdown__link" href="/document/zh-cn/">中文</a></li></ul></div><div class="toggle_F6nl colorModeToggle_ndsa"><button class="clean-btn toggleButton_Szei toggleButtonDisabled_qp8o" type="button" disabled="" title="Switch between dark and light mode (currently light mode)" aria-label="Switch between dark and light mode (currently light mode)"><svg viewBox="0 0 24 24" width="24" height="24" class="lightToggleIcon_y2PQ"><path fill="currentColor" d="M12,9c1.65,0,3,1.35,3,3s-1.35,3-3,3s-3-1.35-3-3S10.35,9,12,9 M12,7c-2.76,0-5,2.24-5,5s2.24,5,5,5s5-2.24,5-5 S14.76,7,12,7L12,7z M2,13l2,0c0.55,0,1-0.45,1-1s-0.45-1-1-1l-2,0c-0.55,0-1,0.45-1,1S1.45,13,2,13z M20,13l2,0c0.55,0,1-0.45,1-1 s-0.45-1-1-1l-2,0c-0.55,0-1,0.45-1,1S19.45,13,20,13z M11,2v2c0,0.55,0.45,1,1,1s1-0.45,1-1V2c0-0.55-0.45-1-1-1S11,1.45,11,2z M11,20v2c0,0.55,0.45,1,1,1s1-0.45,1-1v-2c0-0.55-0.45-1-1-1C11.45,19,11,19.45,11,20z M5.99,4.58c-0.39-0.39-1.03-0.39-1.41,0 c-0.39,0.39-0.39,1.03,0,1.41l1.06,1.06c0.39,0.39,1.03,0.39,1.41,0s0.39-1.03,0-1.41L5.99,4.58z M18.36,16.95 c-0.39-0.39-1.03-0.39-1.41,0c-0.39,0.39-0.39,1.03,0,1.41l1.06,1.06c0.39,0.39,1.03,0.39,1.41,0c0.39-0.39,0.39-1.03,0-1.41 L18.36,16.95z M19.42,5.99c0.39-0.39,0.39-1.03,0-1.41c-0.39-0.39-1.03-0.39-1.41,0l-1.06,1.06c-0.39,0.39-0.39,1.03,0,1.41 s1.03,0.39,1.41,0L19.42,5.99z M7.05,18.36c0.39-0.39,0.39-1.03,0-1.41c-0.39-0.39-1.03-0.39-1.41,0l-1.06,1.06 c-0.39,0.39-0.39,1.03,0,1.41s1.03,0.39,1.41,0L7.05,18.36z"></path></svg><svg viewBox="0 0 24 24" width="24" height="24" class="darkToggleIcon_sMpk"><path fill="currentColor" d="M9.37,5.51C9.19,6.15,9.1,6.82,9.1,7.5c0,4.08,3.32,7.4,7.4,7.4c0.68,0,1.35-0.09,1.99-0.27C17.45,17.19,14.93,19,12,19 c-3.86,0-7-3.14-7-7C5,9.07,6.81,6.55,9.37,5.51z M12,3c-4.97,0-9,4.03-9,9s4.03,9,9,9s9-4.03,9-9c0-0.46-0.04-0.92-0.1-1.36 c-0.98,1.37-2.58,2.26-4.4,2.26c-2.98,0-5.4-2.42-5.4-5.4c0-1.81,0.89-3.42,2.26-4.4C12.92,3.04,12.46,3,12,3L12,3z"></path></svg></button></div><div class="searchBox_xKlU"><div class="navbar__search"><span aria-label="expand searchbar" role="button" class="search-icon" tabindex="0"></span><input type="search" id="search_input_react" placeholder="Search" aria-label="Search" class="navbar__search-input search-bar"></div></div></div></div><div role="presentation" class="navbar-sidebar__backdrop"></div></nav><div class="main-wrapper docsWrapper_GpM1"><button aria-label="Scroll back to top" class="clean-btn theme-back-to-top-button backToTopButton_EOoS" type="button"></button><div class="docPage_vgSg"><aside class="theme-doc-sidebar-container docSidebarContainer_RUQH"><div class="sidebar_gEXq"><nav class="menu thin-scrollbar menu_squC"><ul class="theme-doc-sidebar-menu menu__list"><li class="theme-doc-sidebar-item-link theme-doc-sidebar-item-link-level-1 menu__list-item"><a class="menu__link" href="/document/">Quick start</a></li><li class="theme-doc-sidebar-item-link theme-doc-sidebLine truncated
<script src="/document/assets/js/runtime~main.f9808e8d.js"></script>
<script src="/document/assets/js/main.ac59e946.js"></script>
</body>
</html>
@@ -4,14 +4,14 @@
<meta charset="UTF-8">
<meta name="viewport" content="width=device-width,initial-scale=1">
<meta name="generator" content="Docusaurus v2.0.0-beta.20">
<title data-rh="true">Add select in the controls | Artplayer.js</title><meta data-rh="true" name="twitter:card" content="summary_large_image"><meta data-rh="true" property="og:url" content="https://artplayer.org/document/en/Questions/Create_selector_in_the_controls"><meta data-rh="true" name="docusaurus_locale" content="en"><meta data-rh="true" name="docsearch:language" content="en"><meta data-rh="true" name="docusaurus_version" content="current"><meta data-rh="true" name="docusaurus_tag" content="docs-default-current"><meta data-rh="true" name="docsearch:version" content="current"><meta data-rh="true" name="docsearch:docusaurus_tag" content="docs-default-current"><meta data-rh="true" property="og:title" content="Add select in the controls | Artplayer.js"><meta data-rh="true" name="description" content="Sometimes you need to add a list in the controls, then you can use the selector and onSelect attribute when adding controls"><meta data-rh="true" property="og:description" content="Sometimes you need to add a list in the controls, then you can use the selector and onSelect attribute when adding controls"><link data-rh="true" rel="icon" href="/document/img/favicon.ico"><link data-rh="true" rel="canonical" href="https://artplayer.org/document/en/Questions/Create_selector_in_the_controls"><link data-rh="true" rel="alternate" href="https://artplayer.org/document/en/Questions/Create_selector_in_the_controls" hreflang="en"><link data-rh="true" rel="alternate" href="https://artplayer.org/document/en/Questions/Create_selector_in_the_controls" hreflang="x-default"><link rel="stylesheet" href="/document/assets/css/styles.eba261b7.css">
<link rel="preload" href="/document/assets/js/runtime~main.222c91cd.js" as="script">
<link rel="preload" href="/document/assets/js/main.9ce4b94b.js" as="script">
<title data-rh="true">Add select in the controls | Artplayer.js</title><meta data-rh="true" name="twitter:card" content="summary_large_image"><meta data-rh="true" property="og:url" content="https://artplayer.org/document/en/Questions/Create_selector_in_the_controls"><meta data-rh="true" name="docusaurus_locale" content="en"><meta data-rh="true" name="docsearch:language" content="en"><meta data-rh="true" name="docusaurus_version" content="current"><meta data-rh="true" name="docusaurus_tag" content="docs-default-current"><meta data-rh="true" name="docsearch:version" content="current"><meta data-rh="true" name="docsearch:docusaurus_tag" content="docs-default-current"><meta data-rh="true" property="og:title" content="Add select in the controls | Artplayer.js"><meta data-rh="true" name="description" content="Sometimes you need to add a list in the controls, then you can use the selector and onSelect attribute when adding controls"><meta data-rh="true" property="og:description" content="Sometimes you need to add a list in the controls, then you can use the selector and onSelect attribute when adding controls"><link data-rh="true" rel="icon" href="/document/img/favicon.ico"><link data-rh="true" rel="canonical" href="https://artplayer.org/document/en/Questions/Create_selector_in_the_controls"><link data-rh="true" rel="alternate" href="https://artplayer.org/document/en/Questions/Create_selector_in_the_controls" hreflang="en"><link data-rh="true" rel="alternate" href="https://artplayer.org/document/en/Questions/Create_selector_in_the_controls" hreflang="x-default"><link rel="stylesheet" href="/document/assets/css/styles.7b2fc50a.css">
<link rel="preload" href="/document/assets/js/runtime~main.f9808e8d.js" as="script">
<link rel="preload" href="/document/assets/js/main.ac59e946.js" as="script">
</head>
<body class="navigation-with-keyboard">
<script>!function(){function t(t){document.documentElement.setAttribute("data-theme",t)}var e=function(){var t=null;try{t=localStorage.getItem("theme")}catch(t){}return t}();t(null!==e?e:"light")}()</script><div id="__docusaurus">
<div role="region"><a href="#" class="skipToContent_ZgBM">Skip to main content</a></div><nav class="navbar navbar--fixed-top"><div class="navbar__inner"><div class="navbar__items"><button aria-label="Navigation bar toggle" class="navbar__toggle clean-btn" type="button" tabindex="0"><svg width="30" height="30" viewBox="0 0 30 30" aria-hidden="true"><path stroke="currentColor" stroke-linecap="round" stroke-miterlimit="10" stroke-width="2" d="M4 7h22M4 15h22M4 23h22"></path></svg></button><a href="https://artplayer.org/document" target="_self" rel="noopener noreferrer" class="navbar__brand"><div class="navbar__logo"><img src="/document/img/logo.png" alt="Artplayer.js" class="themedImage_W2Cr themedImage--light_TfLj" height="28" width="28"><img src="/document/img/logo.png" alt="Artplayer.js" class="themedImage_W2Cr themedImage--dark_oUvU" height="28" width="28"></div><b class="navbar__title text--truncate">Artplayer.js</b></a><a href="https://artplayer.org" target="_blank" rel="noopener noreferrer" class="navbar__item navbar__link">Online Editor<svg width="13.5" height="13.5" aria-hidden="true" viewBox="0 0 24 24" class="iconExternalLink_I5OW"><path fill="currentColor" d="M21 13v10h-21v-19h12v2h-10v15h17v-8h2zm3-12h-10.988l4.035 4-6.977 7.07 2.828 2.828 6.977-7.07 4.125 4.172v-11z"></path></svg></a><a href="https://github.com/zhw2590582/ArtPlayer" target="_blank" rel="noopener noreferrer" class="navbar__item navbar__link">Github<svg width="13.5" height="13.5" aria-hidden="true" viewBox="0 0 24 24" class="iconExternalLink_I5OW"><path fill="currentColor" d="M21 13v10h-21v-19h12v2h-10v15h17v-8h2zm3-12h-10.988l4.035 4-6.977 7.07 2.828 2.828 6.977-7.07 4.125 4.172v-11z"></path></svg></a></div><div class="navbar__items navbar__items--right"><a href="#" class="navbar__item navbar__link">QQ群: 320881312</a><div class="navbar__item dropdown dropdown--hoverable dropdown--right"><a href="#" aria-haspopup="true" aria-expanded="false" role="button" class="navbar__link">English</a><ul class="dropdown__menu"><li><a class="dropdown__link" href="/document/">English</a></li><li><a class="dropdown__link" href="/document/zh-cn/">中文</a></li></ul></div><div class="toggle_S7eR colorModeToggle_vKtC"><button class="clean-btn toggleButton_rCf9 toggleButtonDisabled_Pu9x" type="button" disabled="" title="Switch between dark and light mode (currently light mode)" aria-label="Switch between dark and light mode (currently light mode)"><svg viewBox="0 0 24 24" width="24" height="24" class="lightToggleIcon_v35p"><path fill="currentColor" d="M12,9c1.65,0,3,1.35,3,3s-1.35,3-3,3s-3-1.35-3-3S10.35,9,12,9 M12,7c-2.76,0-5,2.24-5,5s2.24,5,5,5s5-2.24,5-5 S14.76,7,12,7L12,7z M2,13l2,0c0.55,0,1-0.45,1-1s-0.45-1-1-1l-2,0c-0.55,0-1,0.45-1,1S1.45,13,2,13z M20,13l2,0c0.55,0,1-0.45,1-1 s-0.45-1-1-1l-2,0c-0.55,0-1,0.45-1,1S19.45,13,20,13z M11,2v2c0,0.55,0.45,1,1,1s1-0.45,1-1V2c0-0.55-0.45-1-1-1S11,1.45,11,2z M11,20v2c0,0.55,0.45,1,1,1s1-0.45,1-1v-2c0-0.55-0.45-1-1-1C11.45,19,11,19.45,11,20z M5.99,4.58c-0.39-0.39-1.03-0.39-1.41,0 c-0.39,0.39-0.39,1.03,0,1.41l1.06,1.06c0.39,0.39,1.03,0.39,1.41,0s0.39-1.03,0-1.41L5.99,4.58z M18.36,16.95 c-0.39-0.39-1.03-0.39-1.41,0c-0.39,0.39-0.39,1.03,0,1.41l1.06,1.06c0.39,0.39,1.03,0.39,1.41,0c0.39-0.39,0.39-1.03,0-1.41 L18.36,16.95z M19.42,5.99c0.39-0.39,0.39-1.03,0-1.41c-0.39-0.39-1.03-0.39-1.41,0l-1.06,1.06c-0.39,0.39-0.39,1.03,0,1.41 s1.03,0.39,1.41,0L19.42,5.99z M7.05,18.36c0.39-0.39,0.39-1.03,0-1.41c-0.39-0.39-1.03-0.39-1.41,0l-1.06,1.06 c-0.39,0.39-0.39,1.03,0,1.41s1.03,0.39,1.41,0L7.05,18.36z"></path></svg><svg viewBox="0 0 24 24" width="24" height="24" class="darkToggleIcon_nQuB"><path fill="currentColor" d="M9.37,5.51C9.19,6.15,9.1,6.82,9.1,7.5c0,4.08,3.32,7.4,7.4,7.4c0.68,0,1.35-0.09,1.99-0.27C17.45,17.19,14.93,19,12,19 c-3.86,0-7-3.14-7-7C5,9.07,6.81,6.55,9.37,5.51z M12,3c-4.97,0-9,4.03-9,9s4.03,9,9,9s9-4.03,9-9c0-0.46-0.04-0.92-0.1-1.36 c-0.98,1.37-2.58,2.26-4.4,2.26c-2.98,0-5.4-2.42-5.4-5.4c0-1.81,0.89-3.42,2.26-4.4C12.92,3.04,12.46,3,12,3L12,3z"></path></svg></button></div><div class="searchBox_dLyj"><div class="navbar__search"><span aria-label="expand searchbar" role="button" class="search-icon" tabindex="0"></span><input type="search" id="search_input_react" placeholder="Search" aria-label="Search" class="navbar__search-input search-bar"></div></div></div></div><div role="presentation" class="navbar-sidebar__backdrop"></div></nav><div class="main-wrapper docsWrapper_mKqt"><button aria-label="Scroll back to top" class="clean-btn theme-back-to-top-button backToTopButton_RiI4" type="button"></button><div class="docPage_ualW"><aside class="theme-doc-sidebar-container docSidebarContainer_UQUJ"><div class="sidebar_RiAD"><nav class="menu thin-scrollbar menu_izAj"><ul class="theme-doc-sidebar-menu menu__list"><li class="theme-doc-sidebar-item-link theme-doc-sidebar-item-link-level-1 menu__list-item"><a class="menu__link" href="/document/">Quick start</a></li><li class="theme-doc-sidebar-item-link theme-doc-sidebLine truncated
<script src="/document/assets/js/runtime~main.222c91cd.js"></script>
<script src="/document/assets/js/main.9ce4b94b.js"></script>
<div role="region"><a href="#" class="skipToContent_cbSD">Skip to main content</a></div><nav class="navbar navbar--fixed-top"><div class="navbar__inner"><div class="navbar__items"><button aria-label="Navigation bar toggle" class="navbar__toggle clean-btn" type="button" tabindex="0"><svg width="30" height="30" viewBox="0 0 30 30" aria-hidden="true"><path stroke="currentColor" stroke-linecap="round" stroke-miterlimit="10" stroke-width="2" d="M4 7h22M4 15h22M4 23h22"></path></svg></button><a href="https://artplayer.org/document" target="_self" rel="noopener noreferrer" class="navbar__brand"><div class="navbar__logo"><img src="/document/img/logo.png" alt="Artplayer.js" class="themedImage_WmJs themedImage--light_gXqO" height="28" width="28"><img src="/document/img/logo.png" alt="Artplayer.js" class="themedImage_WmJs themedImage--dark_X1Zc" height="28" width="28"></div><b class="navbar__title text--truncate">Artplayer.js</b></a><a href="https://artplayer.org" target="_blank" rel="noopener noreferrer" class="navbar__item navbar__link">Online Editor<svg width="13.5" height="13.5" aria-hidden="true" viewBox="0 0 24 24" class="iconExternalLink_cOdw"><path fill="currentColor" d="M21 13v10h-21v-19h12v2h-10v15h17v-8h2zm3-12h-10.988l4.035 4-6.977 7.07 2.828 2.828 6.977-7.07 4.125 4.172v-11z"></path></svg></a><a href="https://github.com/zhw2590582/ArtPlayer" target="_blank" rel="noopener noreferrer" class="navbar__item navbar__link">Github<svg width="13.5" height="13.5" aria-hidden="true" viewBox="0 0 24 24" class="iconExternalLink_cOdw"><path fill="currentColor" d="M21 13v10h-21v-19h12v2h-10v15h17v-8h2zm3-12h-10.988l4.035 4-6.977 7.07 2.828 2.828 6.977-7.07 4.125 4.172v-11z"></path></svg></a></div><div class="navbar__items navbar__items--right"><a href="#" class="navbar__item navbar__link">QQ群: 320881312</a><div class="navbar__item dropdown dropdown--hoverable dropdown--right"><a href="#" aria-haspopup="true" aria-expanded="false" role="button" class="navbar__link">English</a><ul class="dropdown__menu"><li><a class="dropdown__link" href="/document/">English</a></li><li><a class="dropdown__link" href="/document/zh-cn/">中文</a></li></ul></div><div class="toggle_F6nl colorModeToggle_ndsa"><button class="clean-btn toggleButton_Szei toggleButtonDisabled_qp8o" type="button" disabled="" title="Switch between dark and light mode (currently light mode)" aria-label="Switch between dark and light mode (currently light mode)"><svg viewBox="0 0 24 24" width="24" height="24" class="lightToggleIcon_y2PQ"><path fill="currentColor" d="M12,9c1.65,0,3,1.35,3,3s-1.35,3-3,3s-3-1.35-3-3S10.35,9,12,9 M12,7c-2.76,0-5,2.24-5,5s2.24,5,5,5s5-2.24,5-5 S14.76,7,12,7L12,7z M2,13l2,0c0.55,0,1-0.45,1-1s-0.45-1-1-1l-2,0c-0.55,0-1,0.45-1,1S1.45,13,2,13z M20,13l2,0c0.55,0,1-0.45,1-1 s-0.45-1-1-1l-2,0c-0.55,0-1,0.45-1,1S19.45,13,20,13z M11,2v2c0,0.55,0.45,1,1,1s1-0.45,1-1V2c0-0.55-0.45-1-1-1S11,1.45,11,2z M11,20v2c0,0.55,0.45,1,1,1s1-0.45,1-1v-2c0-0.55-0.45-1-1-1C11.45,19,11,19.45,11,20z M5.99,4.58c-0.39-0.39-1.03-0.39-1.41,0 c-0.39,0.39-0.39,1.03,0,1.41l1.06,1.06c0.39,0.39,1.03,0.39,1.41,0s0.39-1.03,0-1.41L5.99,4.58z M18.36,16.95 c-0.39-0.39-1.03-0.39-1.41,0c-0.39,0.39-0.39,1.03,0,1.41l1.06,1.06c0.39,0.39,1.03,0.39,1.41,0c0.39-0.39,0.39-1.03,0-1.41 L18.36,16.95z M19.42,5.99c0.39-0.39,0.39-1.03,0-1.41c-0.39-0.39-1.03-0.39-1.41,0l-1.06,1.06c-0.39,0.39-0.39,1.03,0,1.41 s1.03,0.39,1.41,0L19.42,5.99z M7.05,18.36c0.39-0.39,0.39-1.03,0-1.41c-0.39-0.39-1.03-0.39-1.41,0l-1.06,1.06 c-0.39,0.39-0.39,1.03,0,1.41s1.03,0.39,1.41,0L7.05,18.36z"></path></svg><svg viewBox="0 0 24 24" width="24" height="24" class="darkToggleIcon_sMpk"><path fill="currentColor" d="M9.37,5.51C9.19,6.15,9.1,6.82,9.1,7.5c0,4.08,3.32,7.4,7.4,7.4c0.68,0,1.35-0.09,1.99-0.27C17.45,17.19,14.93,19,12,19 c-3.86,0-7-3.14-7-7C5,9.07,6.81,6.55,9.37,5.51z M12,3c-4.97,0-9,4.03-9,9s4.03,9,9,9s9-4.03,9-9c0-0.46-0.04-0.92-0.1-1.36 c-0.98,1.37-2.58,2.26-4.4,2.26c-2.98,0-5.4-2.42-5.4-5.4c0-1.81,0.89-3.42,2.26-4.4C12.92,3.04,12.46,3,12,3L12,3z"></path></svg></button></div><div class="searchBox_xKlU"><div class="navbar__search"><span aria-label="expand searchbar" role="button" class="search-icon" tabindex="0"></span><input type="search" id="search_input_react" placeholder="Search" aria-label="Search" class="navbar__search-input search-bar"></div></div></div></div><div role="presentation" class="navbar-sidebar__backdrop"></div></nav><div class="main-wrapper docsWrapper_GpM1"><button aria-label="Scroll back to top" class="clean-btn theme-back-to-top-button backToTopButton_EOoS" type="button"></button><div class="docPage_vgSg"><aside class="theme-doc-sidebar-container docSidebarContainer_RUQH"><div class="sidebar_gEXq"><nav class="menu thin-scrollbar menu_squC"><ul class="theme-doc-sidebar-menu menu__list"><li class="theme-doc-sidebar-item-link theme-doc-sidebar-item-link-level-1 menu__list-item"><a class="menu__link" href="/document/">Quick start</a></li><li class="theme-doc-sidebar-item-link theme-doc-sidebLine truncated
<script src="/document/assets/js/runtime~main.f9808e8d.js"></script>
<script src="/document/assets/js/main.ac59e946.js"></script>
</body>
</html>
@@ -4,14 +4,14 @@
<meta charset="UTF-8">
<meta name="viewport" content="width=device-width,initial-scale=1">
<meta name="generator" content="Docusaurus v2.0.0-beta.20">
<title data-rh="true">Handle a single component | Artplayer.js</title><meta data-rh="true" name="twitter:card" content="summary_large_image"><meta data-rh="true" property="og:url" content="https://artplayer.org/document/en/Questions/Handle_single_component"><meta data-rh="true" name="docusaurus_locale" content="en"><meta data-rh="true" name="docsearch:language" content="en"><meta data-rh="true" name="docusaurus_version" content="current"><meta data-rh="true" name="docusaurus_tag" content="docs-default-current"><meta data-rh="true" name="docsearch:version" content="current"><meta data-rh="true" name="docsearch:docusaurus_tag" content="docs-default-current"><meta data-rh="true" property="og:title" content="Handle a single component | Artplayer.js"><meta data-rh="true" name="description" content="When we add custom components in layers, contextmenu, controls, It is best to add a name property that is used to position the DOM element of the component."><meta data-rh="true" property="og:description" content="When we add custom components in layers, contextmenu, controls, It is best to add a name property that is used to position the DOM element of the component."><link data-rh="true" rel="icon" href="/document/img/favicon.ico"><link data-rh="true" rel="canonical" href="https://artplayer.org/document/en/Questions/Handle_single_component"><link data-rh="true" rel="alternate" href="https://artplayer.org/document/en/Questions/Handle_single_component" hreflang="en"><link data-rh="true" rel="alternate" href="https://artplayer.org/document/en/Questions/Handle_single_component" hreflang="x-default"><link rel="stylesheet" href="/document/assets/css/styles.eba261b7.css">
<link rel="preload" href="/document/assets/js/runtime~main.222c91cd.js" as="script">
<link rel="preload" href="/document/assets/js/main.9ce4b94b.js" as="script">
<title data-rh="true">Handle a single component | Artplayer.js</title><meta data-rh="true" name="twitter:card" content="summary_large_image"><meta data-rh="true" property="og:url" content="https://artplayer.org/document/en/Questions/Handle_single_component"><meta data-rh="true" name="docusaurus_locale" content="en"><meta data-rh="true" name="docsearch:language" content="en"><meta data-rh="true" name="docusaurus_version" content="current"><meta data-rh="true" name="docusaurus_tag" content="docs-default-current"><meta data-rh="true" name="docsearch:version" content="current"><meta data-rh="true" name="docsearch:docusaurus_tag" content="docs-default-current"><meta data-rh="true" property="og:title" content="Handle a single component | Artplayer.js"><meta data-rh="true" name="description" content="When we add custom components in layers, contextmenu, controls, It is best to add a name property that is used to position the DOM element of the component."><meta data-rh="true" property="og:description" content="When we add custom components in layers, contextmenu, controls, It is best to add a name property that is used to position the DOM element of the component."><link data-rh="true" rel="icon" href="/document/img/favicon.ico"><link data-rh="true" rel="canonical" href="https://artplayer.org/document/en/Questions/Handle_single_component"><link data-rh="true" rel="alternate" href="https://artplayer.org/document/en/Questions/Handle_single_component" hreflang="en"><link data-rh="true" rel="alternate" href="https://artplayer.org/document/en/Questions/Handle_single_component" hreflang="x-default"><link rel="stylesheet" href="/document/assets/css/styles.7b2fc50a.css">
<link rel="preload" href="/document/assets/js/runtime~main.f9808e8d.js" as="script">
<link rel="preload" href="/document/assets/js/main.ac59e946.js" as="script">
</head>
<body class="navigation-with-keyboard">
<script>!function(){function t(t){document.documentElement.setAttribute("data-theme",t)}var e=function(){var t=null;try{t=localStorage.getItem("theme")}catch(t){}return t}();t(null!==e?e:"light")}()</script><div id="__docusaurus">
<div role="region"><a href="#" class="skipToContent_ZgBM">Skip to main content</a></div><nav class="navbar navbar--fixed-top"><div class="navbar__inner"><div class="navbar__items"><button aria-label="Navigation bar toggle" class="navbar__toggle clean-btn" type="button" tabindex="0"><svg width="30" height="30" viewBox="0 0 30 30" aria-hidden="true"><path stroke="currentColor" stroke-linecap="round" stroke-miterlimit="10" stroke-width="2" d="M4 7h22M4 15h22M4 23h22"></path></svg></button><a href="https://artplayer.org/document" target="_self" rel="noopener noreferrer" class="navbar__brand"><div class="navbar__logo"><img src="/document/img/logo.png" alt="Artplayer.js" class="themedImage_W2Cr themedImage--light_TfLj" height="28" width="28"><img src="/document/img/logo.png" alt="Artplayer.js" class="themedImage_W2Cr themedImage--dark_oUvU" height="28" width="28"></div><b class="navbar__title text--truncate">Artplayer.js</b></a><a href="https://artplayer.org" target="_blank" rel="noopener noreferrer" class="navbar__item navbar__link">Online Editor<svg width="13.5" height="13.5" aria-hidden="true" viewBox="0 0 24 24" class="iconExternalLink_I5OW"><path fill="currentColor" d="M21 13v10h-21v-19h12v2h-10v15h17v-8h2zm3-12h-10.988l4.035 4-6.977 7.07 2.828 2.828 6.977-7.07 4.125 4.172v-11z"></path></svg></a><a href="https://github.com/zhw2590582/ArtPlayer" target="_blank" rel="noopener noreferrer" class="navbar__item navbar__link">Github<svg width="13.5" height="13.5" aria-hidden="true" viewBox="0 0 24 24" class="iconExternalLink_I5OW"><path fill="currentColor" d="M21 13v10h-21v-19h12v2h-10v15h17v-8h2zm3-12h-10.988l4.035 4-6.977 7.07 2.828 2.828 6.977-7.07 4.125 4.172v-11z"></path></svg></a></div><div class="navbar__items navbar__items--right"><a href="#" class="navbar__item navbar__link">QQ群: 320881312</a><div class="navbar__item dropdown dropdown--hoverable dropdown--right"><a href="#" aria-haspopup="true" aria-expanded="false" role="button" class="navbar__link">English</a><ul class="dropdown__menu"><li><a class="dropdown__link" href="/document/">English</a></li><li><a class="dropdown__link" href="/document/zh-cn/">中文</a></li></ul></div><div class="toggle_S7eR colorModeToggle_vKtC"><button class="clean-btn toggleButton_rCf9 toggleButtonDisabled_Pu9x" type="button" disabled="" title="Switch between dark and light mode (currently light mode)" aria-label="Switch between dark and light mode (currently light mode)"><svg viewBox="0 0 24 24" width="24" height="24" class="lightToggleIcon_v35p"><path fill="currentColor" d="M12,9c1.65,0,3,1.35,3,3s-1.35,3-3,3s-3-1.35-3-3S10.35,9,12,9 M12,7c-2.76,0-5,2.24-5,5s2.24,5,5,5s5-2.24,5-5 S14.76,7,12,7L12,7z M2,13l2,0c0.55,0,1-0.45,1-1s-0.45-1-1-1l-2,0c-0.55,0-1,0.45-1,1S1.45,13,2,13z M20,13l2,0c0.55,0,1-0.45,1-1 s-0.45-1-1-1l-2,0c-0.55,0-1,0.45-1,1S19.45,13,20,13z M11,2v2c0,0.55,0.45,1,1,1s1-0.45,1-1V2c0-0.55-0.45-1-1-1S11,1.45,11,2z M11,20v2c0,0.55,0.45,1,1,1s1-0.45,1-1v-2c0-0.55-0.45-1-1-1C11.45,19,11,19.45,11,20z M5.99,4.58c-0.39-0.39-1.03-0.39-1.41,0 c-0.39,0.39-0.39,1.03,0,1.41l1.06,1.06c0.39,0.39,1.03,0.39,1.41,0s0.39-1.03,0-1.41L5.99,4.58z M18.36,16.95 c-0.39-0.39-1.03-0.39-1.41,0c-0.39,0.39-0.39,1.03,0,1.41l1.06,1.06c0.39,0.39,1.03,0.39,1.41,0c0.39-0.39,0.39-1.03,0-1.41 L18.36,16.95z M19.42,5.99c0.39-0.39,0.39-1.03,0-1.41c-0.39-0.39-1.03-0.39-1.41,0l-1.06,1.06c-0.39,0.39-0.39,1.03,0,1.41 s1.03,0.39,1.41,0L19.42,5.99z M7.05,18.36c0.39-0.39,0.39-1.03,0-1.41c-0.39-0.39-1.03-0.39-1.41,0l-1.06,1.06 c-0.39,0.39-0.39,1.03,0,1.41s1.03,0.39,1.41,0L7.05,18.36z"></path></svg><svg viewBox="0 0 24 24" width="24" height="24" class="darkToggleIcon_nQuB"><path fill="currentColor" d="M9.37,5.51C9.19,6.15,9.1,6.82,9.1,7.5c0,4.08,3.32,7.4,7.4,7.4c0.68,0,1.35-0.09,1.99-0.27C17.45,17.19,14.93,19,12,19 c-3.86,0-7-3.14-7-7C5,9.07,6.81,6.55,9.37,5.51z M12,3c-4.97,0-9,4.03-9,9s4.03,9,9,9s9-4.03,9-9c0-0.46-0.04-0.92-0.1-1.36 c-0.98,1.37-2.58,2.26-4.4,2.26c-2.98,0-5.4-2.42-5.4-5.4c0-1.81,0.89-3.42,2.26-4.4C12.92,3.04,12.46,3,12,3L12,3z"></path></svg></button></div><div class="searchBox_dLyj"><div class="navbar__search"><span aria-label="expand searchbar" role="button" class="search-icon" tabindex="0"></span><input type="search" id="search_input_react" placeholder="Search" aria-label="Search" class="navbar__search-input search-bar"></div></div></div></div><div role="presentation" class="navbar-sidebar__backdrop"></div></nav><div class="main-wrapper docsWrapper_mKqt"><button aria-label="Scroll back to top" class="clean-btn theme-back-to-top-button backToTopButton_RiI4" type="button"></button><div class="docPage_ualW"><aside class="theme-doc-sidebar-container docSidebarContainer_UQUJ"><div class="sidebar_RiAD"><nav class="menu thin-scrollbar menu_izAj"><ul class="theme-doc-sidebar-menu menu__list"><li class="theme-doc-sidebar-item-link theme-doc-sidebar-item-link-level-1 menu__list-item"><a class="menu__link" href="/document/">Quick start</a></li><li class="theme-doc-sidebar-item-link theme-doc-sidebLine truncated
<script src="/document/assets/js/runtime~main.222c91cd.js"></script>
<script src="/document/assets/js/main.9ce4b94b.js"></script>
<div role="region"><a href="#" class="skipToContent_cbSD">Skip to main content</a></div><nav class="navbar navbar--fixed-top"><div class="navbar__inner"><div class="navbar__items"><button aria-label="Navigation bar toggle" class="navbar__toggle clean-btn" type="button" tabindex="0"><svg width="30" height="30" viewBox="0 0 30 30" aria-hidden="true"><path stroke="currentColor" stroke-linecap="round" stroke-miterlimit="10" stroke-width="2" d="M4 7h22M4 15h22M4 23h22"></path></svg></button><a href="https://artplayer.org/document" target="_self" rel="noopener noreferrer" class="navbar__brand"><div class="navbar__logo"><img src="/document/img/logo.png" alt="Artplayer.js" class="themedImage_WmJs themedImage--light_gXqO" height="28" width="28"><img src="/document/img/logo.png" alt="Artplayer.js" class="themedImage_WmJs themedImage--dark_X1Zc" height="28" width="28"></div><b class="navbar__title text--truncate">Artplayer.js</b></a><a href="https://artplayer.org" target="_blank" rel="noopener noreferrer" class="navbar__item navbar__link">Online Editor<svg width="13.5" height="13.5" aria-hidden="true" viewBox="0 0 24 24" class="iconExternalLink_cOdw"><path fill="currentColor" d="M21 13v10h-21v-19h12v2h-10v15h17v-8h2zm3-12h-10.988l4.035 4-6.977 7.07 2.828 2.828 6.977-7.07 4.125 4.172v-11z"></path></svg></a><a href="https://github.com/zhw2590582/ArtPlayer" target="_blank" rel="noopener noreferrer" class="navbar__item navbar__link">Github<svg width="13.5" height="13.5" aria-hidden="true" viewBox="0 0 24 24" class="iconExternalLink_cOdw"><path fill="currentColor" d="M21 13v10h-21v-19h12v2h-10v15h17v-8h2zm3-12h-10.988l4.035 4-6.977 7.07 2.828 2.828 6.977-7.07 4.125 4.172v-11z"></path></svg></a></div><div class="navbar__items navbar__items--right"><a href="#" class="navbar__item navbar__link">QQ群: 320881312</a><div class="navbar__item dropdown dropdown--hoverable dropdown--right"><a href="#" aria-haspopup="true" aria-expanded="false" role="button" class="navbar__link">English</a><ul class="dropdown__menu"><li><a class="dropdown__link" href="/document/">English</a></li><li><a class="dropdown__link" href="/document/zh-cn/">中文</a></li></ul></div><div class="toggle_F6nl colorModeToggle_ndsa"><button class="clean-btn toggleButton_Szei toggleButtonDisabled_qp8o" type="button" disabled="" title="Switch between dark and light mode (currently light mode)" aria-label="Switch between dark and light mode (currently light mode)"><svg viewBox="0 0 24 24" width="24" height="24" class="lightToggleIcon_y2PQ"><path fill="currentColor" d="M12,9c1.65,0,3,1.35,3,3s-1.35,3-3,3s-3-1.35-3-3S10.35,9,12,9 M12,7c-2.76,0-5,2.24-5,5s2.24,5,5,5s5-2.24,5-5 S14.76,7,12,7L12,7z M2,13l2,0c0.55,0,1-0.45,1-1s-0.45-1-1-1l-2,0c-0.55,0-1,0.45-1,1S1.45,13,2,13z M20,13l2,0c0.55,0,1-0.45,1-1 s-0.45-1-1-1l-2,0c-0.55,0-1,0.45-1,1S19.45,13,20,13z M11,2v2c0,0.55,0.45,1,1,1s1-0.45,1-1V2c0-0.55-0.45-1-1-1S11,1.45,11,2z M11,20v2c0,0.55,0.45,1,1,1s1-0.45,1-1v-2c0-0.55-0.45-1-1-1C11.45,19,11,19.45,11,20z M5.99,4.58c-0.39-0.39-1.03-0.39-1.41,0 c-0.39,0.39-0.39,1.03,0,1.41l1.06,1.06c0.39,0.39,1.03,0.39,1.41,0s0.39-1.03,0-1.41L5.99,4.58z M18.36,16.95 c-0.39-0.39-1.03-0.39-1.41,0c-0.39,0.39-0.39,1.03,0,1.41l1.06,1.06c0.39,0.39,1.03,0.39,1.41,0c0.39-0.39,0.39-1.03,0-1.41 L18.36,16.95z M19.42,5.99c0.39-0.39,0.39-1.03,0-1.41c-0.39-0.39-1.03-0.39-1.41,0l-1.06,1.06c-0.39,0.39-0.39,1.03,0,1.41 s1.03,0.39,1.41,0L19.42,5.99z M7.05,18.36c0.39-0.39,0.39-1.03,0-1.41c-0.39-0.39-1.03-0.39-1.41,0l-1.06,1.06 c-0.39,0.39-0.39,1.03,0,1.41s1.03,0.39,1.41,0L7.05,18.36z"></path></svg><svg viewBox="0 0 24 24" width="24" height="24" class="darkToggleIcon_sMpk"><path fill="currentColor" d="M9.37,5.51C9.19,6.15,9.1,6.82,9.1,7.5c0,4.08,3.32,7.4,7.4,7.4c0.68,0,1.35-0.09,1.99-0.27C17.45,17.19,14.93,19,12,19 c-3.86,0-7-3.14-7-7C5,9.07,6.81,6.55,9.37,5.51z M12,3c-4.97,0-9,4.03-9,9s4.03,9,9,9s9-4.03,9-9c0-0.46-0.04-0.92-0.1-1.36 c-0.98,1.37-2.58,2.26-4.4,2.26c-2.98,0-5.4-2.42-5.4-5.4c0-1.81,0.89-3.42,2.26-4.4C12.92,3.04,12.46,3,12,3L12,3z"></path></svg></button></div><div class="searchBox_xKlU"><div class="navbar__search"><span aria-label="expand searchbar" role="button" class="search-icon" tabindex="0"></span><input type="search" id="search_input_react" placeholder="Search" aria-label="Search" class="navbar__search-input search-bar"></div></div></div></div><div role="presentation" class="navbar-sidebar__backdrop"></div></nav><div class="main-wrapper docsWrapper_GpM1"><button aria-label="Scroll back to top" class="clean-btn theme-back-to-top-button backToTopButton_EOoS" type="button"></button><div class="docPage_vgSg"><aside class="theme-doc-sidebar-container docSidebarContainer_RUQH"><div class="sidebar_gEXq"><nav class="menu thin-scrollbar menu_squC"><ul class="theme-doc-sidebar-menu menu__list"><li class="theme-doc-sidebar-item-link theme-doc-sidebar-item-link-level-1 menu__list-item"><a class="menu__link" href="/document/">Quick start</a></li><li class="theme-doc-sidebar-item-link theme-doc-sidebLine truncated
<script src="/document/assets/js/runtime~main.f9808e8d.js"></script>
<script src="/document/assets/js/main.ac59e946.js"></script>
</body>
</html>
@@ -4,14 +4,14 @@
<meta charset="UTF-8">
<meta name="viewport" content="width=device-width,initial-scale=1">
<meta name="generator" content="Docusaurus v2.0.0-beta.20">
<title data-rh="true">How to add setting panel | Artplayer.js</title><meta data-rh="true" name="twitter:card" content="summary_large_image"><meta data-rh="true" property="og:url" content="https://artplayer.org/document/en/Questions/How_to_add_setting_panel"><meta data-rh="true" name="docusaurus_locale" content="en"><meta data-rh="true" name="docsearch:language" content="en"><meta data-rh="true" name="docusaurus_version" content="current"><meta data-rh="true" name="docusaurus_tag" content="docs-default-current"><meta data-rh="true" name="docsearch:version" content="current"><meta data-rh="true" name="docsearch:docusaurus_tag" content="docs-default-current"><meta data-rh="true" property="og:title" content="How to add setting panel | Artplayer.js"><meta data-rh="true" name="description" content="Add selector list"><meta data-rh="true" property="og:description" content="Add selector list"><link data-rh="true" rel="icon" href="/document/img/favicon.ico"><link data-rh="true" rel="canonical" href="https://artplayer.org/document/en/Questions/How_to_add_setting_panel"><link data-rh="true" rel="alternate" href="https://artplayer.org/document/en/Questions/How_to_add_setting_panel" hreflang="en"><link data-rh="true" rel="alternate" href="https://artplayer.org/document/en/Questions/How_to_add_setting_panel" hreflang="x-default"><link rel="stylesheet" href="/document/assets/css/styles.eba261b7.css">
<link rel="preload" href="/document/assets/js/runtime~main.222c91cd.js" as="script">
<link rel="preload" href="/document/assets/js/main.9ce4b94b.js" as="script">
<title data-rh="true">How to add setting panel | Artplayer.js</title><meta data-rh="true" name="twitter:card" content="summary_large_image"><meta data-rh="true" property="og:url" content="https://artplayer.org/document/en/Questions/How_to_add_setting_panel"><meta data-rh="true" name="docusaurus_locale" content="en"><meta data-rh="true" name="docsearch:language" content="en"><meta data-rh="true" name="docusaurus_version" content="current"><meta data-rh="true" name="docusaurus_tag" content="docs-default-current"><meta data-rh="true" name="docsearch:version" content="current"><meta data-rh="true" name="docsearch:docusaurus_tag" content="docs-default-current"><meta data-rh="true" property="og:title" content="How to add setting panel | Artplayer.js"><meta data-rh="true" name="description" content="Add selector list"><meta data-rh="true" property="og:description" content="Add selector list"><link data-rh="true" rel="icon" href="/document/img/favicon.ico"><link data-rh="true" rel="canonical" href="https://artplayer.org/document/en/Questions/How_to_add_setting_panel"><link data-rh="true" rel="alternate" href="https://artplayer.org/document/en/Questions/How_to_add_setting_panel" hreflang="en"><link data-rh="true" rel="alternate" href="https://artplayer.org/document/en/Questions/How_to_add_setting_panel" hreflang="x-default"><link rel="stylesheet" href="/document/assets/css/styles.7b2fc50a.css">
<link rel="preload" href="/document/assets/js/runtime~main.f9808e8d.js" as="script">
<link rel="preload" href="/document/assets/js/main.ac59e946.js" as="script">
</head>
<body class="navigation-with-keyboard">
<script>!function(){function t(t){document.documentElement.setAttribute("data-theme",t)}var e=function(){var t=null;try{t=localStorage.getItem("theme")}catch(t){}return t}();t(null!==e?e:"light")}()</script><div id="__docusaurus">
<div role="region"><a href="#" class="skipToContent_ZgBM">Skip to main content</a></div><nav class="navbar navbar--fixed-top"><div class="navbar__inner"><div class="navbar__items"><button aria-label="Navigation bar toggle" class="navbar__toggle clean-btn" type="button" tabindex="0"><svg width="30" height="30" viewBox="0 0 30 30" aria-hidden="true"><path stroke="currentColor" stroke-linecap="round" stroke-miterlimit="10" stroke-width="2" d="M4 7h22M4 15h22M4 23h22"></path></svg></button><a href="https://artplayer.org/document" target="_self" rel="noopener noreferrer" class="navbar__brand"><div class="navbar__logo"><img src="/document/img/logo.png" alt="Artplayer.js" class="themedImage_W2Cr themedImage--light_TfLj" height="28" width="28"><img src="/document/img/logo.png" alt="Artplayer.js" class="themedImage_W2Cr themedImage--dark_oUvU" height="28" width="28"></div><b class="navbar__title text--truncate">Artplayer.js</b></a><a href="https://artplayer.org" target="_blank" rel="noopener noreferrer" class="navbar__item navbar__link">Online Editor<svg width="13.5" height="13.5" aria-hidden="true" viewBox="0 0 24 24" class="iconExternalLink_I5OW"><path fill="currentColor" d="M21 13v10h-21v-19h12v2h-10v15h17v-8h2zm3-12h-10.988l4.035 4-6.977 7.07 2.828 2.828 6.977-7.07 4.125 4.172v-11z"></path></svg></a><a href="https://github.com/zhw2590582/ArtPlayer" target="_blank" rel="noopener noreferrer" class="navbar__item navbar__link">Github<svg width="13.5" height="13.5" aria-hidden="true" viewBox="0 0 24 24" class="iconExternalLink_I5OW"><path fill="currentColor" d="M21 13v10h-21v-19h12v2h-10v15h17v-8h2zm3-12h-10.988l4.035 4-6.977 7.07 2.828 2.828 6.977-7.07 4.125 4.172v-11z"></path></svg></a></div><div class="navbar__items navbar__items--right"><a href="#" class="navbar__item navbar__link">QQ群: 320881312</a><div class="navbar__item dropdown dropdown--hoverable dropdown--right"><a href="#" aria-haspopup="true" aria-expanded="false" role="button" class="navbar__link">English</a><ul class="dropdown__menu"><li><a class="dropdown__link" href="/document/">English</a></li><li><a class="dropdown__link" href="/document/zh-cn/">中文</a></li></ul></div><div class="toggle_S7eR colorModeToggle_vKtC"><button class="clean-btn toggleButton_rCf9 toggleButtonDisabled_Pu9x" type="button" disabled="" title="Switch between dark and light mode (currently light mode)" aria-label="Switch between dark and light mode (currently light mode)"><svg viewBox="0 0 24 24" width="24" height="24" class="lightToggleIcon_v35p"><path fill="currentColor" d="M12,9c1.65,0,3,1.35,3,3s-1.35,3-3,3s-3-1.35-3-3S10.35,9,12,9 M12,7c-2.76,0-5,2.24-5,5s2.24,5,5,5s5-2.24,5-5 S14.76,7,12,7L12,7z M2,13l2,0c0.55,0,1-0.45,1-1s-0.45-1-1-1l-2,0c-0.55,0-1,0.45-1,1S1.45,13,2,13z M20,13l2,0c0.55,0,1-0.45,1-1 s-0.45-1-1-1l-2,0c-0.55,0-1,0.45-1,1S19.45,13,20,13z M11,2v2c0,0.55,0.45,1,1,1s1-0.45,1-1V2c0-0.55-0.45-1-1-1S11,1.45,11,2z M11,20v2c0,0.55,0.45,1,1,1s1-0.45,1-1v-2c0-0.55-0.45-1-1-1C11.45,19,11,19.45,11,20z M5.99,4.58c-0.39-0.39-1.03-0.39-1.41,0 c-0.39,0.39-0.39,1.03,0,1.41l1.06,1.06c0.39,0.39,1.03,0.39,1.41,0s0.39-1.03,0-1.41L5.99,4.58z M18.36,16.95 c-0.39-0.39-1.03-0.39-1.41,0c-0.39,0.39-0.39,1.03,0,1.41l1.06,1.06c0.39,0.39,1.03,0.39,1.41,0c0.39-0.39,0.39-1.03,0-1.41 L18.36,16.95z M19.42,5.99c0.39-0.39,0.39-1.03,0-1.41c-0.39-0.39-1.03-0.39-1.41,0l-1.06,1.06c-0.39,0.39-0.39,1.03,0,1.41 s1.03,0.39,1.41,0L19.42,5.99z M7.05,18.36c0.39-0.39,0.39-1.03,0-1.41c-0.39-0.39-1.03-0.39-1.41,0l-1.06,1.06 c-0.39,0.39-0.39,1.03,0,1.41s1.03,0.39,1.41,0L7.05,18.36z"></path></svg><svg viewBox="0 0 24 24" width="24" height="24" class="darkToggleIcon_nQuB"><path fill="currentColor" d="M9.37,5.51C9.19,6.15,9.1,6.82,9.1,7.5c0,4.08,3.32,7.4,7.4,7.4c0.68,0,1.35-0.09,1.99-0.27C17.45,17.19,14.93,19,12,19 c-3.86,0-7-3.14-7-7C5,9.07,6.81,6.55,9.37,5.51z M12,3c-4.97,0-9,4.03-9,9s4.03,9,9,9s9-4.03,9-9c0-0.46-0.04-0.92-0.1-1.36 c-0.98,1.37-2.58,2.26-4.4,2.26c-2.98,0-5.4-2.42-5.4-5.4c0-1.81,0.89-3.42,2.26-4.4C12.92,3.04,12.46,3,12,3L12,3z"></path></svg></button></div><div class="searchBox_dLyj"><div class="navbar__search"><span aria-label="expand searchbar" role="button" class="search-icon" tabindex="0"></span><input type="search" id="search_input_react" placeholder="Search" aria-label="Search" class="navbar__search-input search-bar"></div></div></div></div><div role="presentation" class="navbar-sidebar__backdrop"></div></nav><div class="main-wrapper docsWrapper_mKqt"><button aria-label="Scroll back to top" class="clean-btn theme-back-to-top-button backToTopButton_RiI4" type="button"></button><div class="docPage_ualW"><aside class="theme-doc-sidebar-container docSidebarContainer_UQUJ"><div class="sidebar_RiAD"><nav class="menu thin-scrollbar menu_izAj"><ul class="theme-doc-sidebar-menu menu__list"><li class="theme-doc-sidebar-item-link theme-doc-sidebar-item-link-level-1 menu__list-item"><a class="menu__link" href="/document/">Quick start</a></li><li class="theme-doc-sidebar-item-link theme-doc-sidebLine truncated
<script src="/document/assets/js/runtime~main.222c91cd.js"></script>
<script src="/document/assets/js/main.9ce4b94b.js"></script>
<div role="region"><a href="#" class="skipToContent_cbSD">Skip to main content</a></div><nav class="navbar navbar--fixed-top"><div class="navbar__inner"><div class="navbar__items"><button aria-label="Navigation bar toggle" class="navbar__toggle clean-btn" type="button" tabindex="0"><svg width="30" height="30" viewBox="0 0 30 30" aria-hidden="true"><path stroke="currentColor" stroke-linecap="round" stroke-miterlimit="10" stroke-width="2" d="M4 7h22M4 15h22M4 23h22"></path></svg></button><a href="https://artplayer.org/document" target="_self" rel="noopener noreferrer" class="navbar__brand"><div class="navbar__logo"><img src="/document/img/logo.png" alt="Artplayer.js" class="themedImage_WmJs themedImage--light_gXqO" height="28" width="28"><img src="/document/img/logo.png" alt="Artplayer.js" class="themedImage_WmJs themedImage--dark_X1Zc" height="28" width="28"></div><b class="navbar__title text--truncate">Artplayer.js</b></a><a href="https://artplayer.org" target="_blank" rel="noopener noreferrer" class="navbar__item navbar__link">Online Editor<svg width="13.5" height="13.5" aria-hidden="true" viewBox="0 0 24 24" class="iconExternalLink_cOdw"><path fill="currentColor" d="M21 13v10h-21v-19h12v2h-10v15h17v-8h2zm3-12h-10.988l4.035 4-6.977 7.07 2.828 2.828 6.977-7.07 4.125 4.172v-11z"></path></svg></a><a href="https://github.com/zhw2590582/ArtPlayer" target="_blank" rel="noopener noreferrer" class="navbar__item navbar__link">Github<svg width="13.5" height="13.5" aria-hidden="true" viewBox="0 0 24 24" class="iconExternalLink_cOdw"><path fill="currentColor" d="M21 13v10h-21v-19h12v2h-10v15h17v-8h2zm3-12h-10.988l4.035 4-6.977 7.07 2.828 2.828 6.977-7.07 4.125 4.172v-11z"></path></svg></a></div><div class="navbar__items navbar__items--right"><a href="#" class="navbar__item navbar__link">QQ群: 320881312</a><div class="navbar__item dropdown dropdown--hoverable dropdown--right"><a href="#" aria-haspopup="true" aria-expanded="false" role="button" class="navbar__link">English</a><ul class="dropdown__menu"><li><a class="dropdown__link" href="/document/">English</a></li><li><a class="dropdown__link" href="/document/zh-cn/">中文</a></li></ul></div><div class="toggle_F6nl colorModeToggle_ndsa"><button class="clean-btn toggleButton_Szei toggleButtonDisabled_qp8o" type="button" disabled="" title="Switch between dark and light mode (currently light mode)" aria-label="Switch between dark and light mode (currently light mode)"><svg viewBox="0 0 24 24" width="24" height="24" class="lightToggleIcon_y2PQ"><path fill="currentColor" d="M12,9c1.65,0,3,1.35,3,3s-1.35,3-3,3s-3-1.35-3-3S10.35,9,12,9 M12,7c-2.76,0-5,2.24-5,5s2.24,5,5,5s5-2.24,5-5 S14.76,7,12,7L12,7z M2,13l2,0c0.55,0,1-0.45,1-1s-0.45-1-1-1l-2,0c-0.55,0-1,0.45-1,1S1.45,13,2,13z M20,13l2,0c0.55,0,1-0.45,1-1 s-0.45-1-1-1l-2,0c-0.55,0-1,0.45-1,1S19.45,13,20,13z M11,2v2c0,0.55,0.45,1,1,1s1-0.45,1-1V2c0-0.55-0.45-1-1-1S11,1.45,11,2z M11,20v2c0,0.55,0.45,1,1,1s1-0.45,1-1v-2c0-0.55-0.45-1-1-1C11.45,19,11,19.45,11,20z M5.99,4.58c-0.39-0.39-1.03-0.39-1.41,0 c-0.39,0.39-0.39,1.03,0,1.41l1.06,1.06c0.39,0.39,1.03,0.39,1.41,0s0.39-1.03,0-1.41L5.99,4.58z M18.36,16.95 c-0.39-0.39-1.03-0.39-1.41,0c-0.39,0.39-0.39,1.03,0,1.41l1.06,1.06c0.39,0.39,1.03,0.39,1.41,0c0.39-0.39,0.39-1.03,0-1.41 L18.36,16.95z M19.42,5.99c0.39-0.39,0.39-1.03,0-1.41c-0.39-0.39-1.03-0.39-1.41,0l-1.06,1.06c-0.39,0.39-0.39,1.03,0,1.41 s1.03,0.39,1.41,0L19.42,5.99z M7.05,18.36c0.39-0.39,0.39-1.03,0-1.41c-0.39-0.39-1.03-0.39-1.41,0l-1.06,1.06 c-0.39,0.39-0.39,1.03,0,1.41s1.03,0.39,1.41,0L7.05,18.36z"></path></svg><svg viewBox="0 0 24 24" width="24" height="24" class="darkToggleIcon_sMpk"><path fill="currentColor" d="M9.37,5.51C9.19,6.15,9.1,6.82,9.1,7.5c0,4.08,3.32,7.4,7.4,7.4c0.68,0,1.35-0.09,1.99-0.27C17.45,17.19,14.93,19,12,19 c-3.86,0-7-3.14-7-7C5,9.07,6.81,6.55,9.37,5.51z M12,3c-4.97,0-9,4.03-9,9s4.03,9,9,9s9-4.03,9-9c0-0.46-0.04-0.92-0.1-1.36 c-0.98,1.37-2.58,2.26-4.4,2.26c-2.98,0-5.4-2.42-5.4-5.4c0-1.81,0.89-3.42,2.26-4.4C12.92,3.04,12.46,3,12,3L12,3z"></path></svg></button></div><div class="searchBox_xKlU"><div class="navbar__search"><span aria-label="expand searchbar" role="button" class="search-icon" tabindex="0"></span><input type="search" id="search_input_react" placeholder="Search" aria-label="Search" class="navbar__search-input search-bar"></div></div></div></div><div role="presentation" class="navbar-sidebar__backdrop"></div></nav><div class="main-wrapper docsWrapper_GpM1"><button aria-label="Scroll back to top" class="clean-btn theme-back-to-top-button backToTopButton_EOoS" type="button"></button><div class="docPage_vgSg"><aside class="theme-doc-sidebar-container docSidebarContainer_RUQH"><div class="sidebar_gEXq"><nav class="menu thin-scrollbar menu_squC"><ul class="theme-doc-sidebar-menu menu__list"><li class="theme-doc-sidebar-item-link theme-doc-sidebar-item-link-level-1 menu__list-item"><a class="menu__link" href="/document/">Quick start</a></li><li class="theme-doc-sidebar-item-link theme-doc-sidebLine truncated
<script src="/document/assets/js/runtime~main.f9808e8d.js"></script>
<script src="/document/assets/js/main.ac59e946.js"></script>
</body>
</html>
Loaded 100 of 230 files, more files were not shown because too many files have changed in this diff. Show more