mirror of
https://github.com/zhw2590582/ArtPlayer.git
synced 2026-10-24 23:44:18 -08:00
feat: add danmuku mask plugin for ArtPlayer with initial implementation and documentation
This commit is contained in:
1 parent
a6f0dc50e5
commit
d9bdc9bdeb
10 files changed
+309
No files matched your search
@@ -0,0 +1,11 @@
|
||||
# artplayer-plugin-danmuku-mask
|
||||
|
||||
Danmuku mask plugin for ArtPlayer
|
||||
|
||||
## Demo
|
||||
|
||||
[https://artplayer.org](https://artplayer.org/?libs=./uncompiled/artplayer-plugin-danmuku/index.js%0A./uncompiled/artplayer-plugin-danmuku-mask/index.js&example=danmuku.mask)
|
||||
|
||||
## License
|
||||
|
||||
MIT © Harvey Zack
|
||||
@@ -0,0 +1,24 @@
|
||||
{
|
||||
"license": "MIT",
|
||||
"version": "1.0.0",
|
||||
"name": "artplayer-plugin-danmuku-mask",
|
||||
"types": "types/artplayer-plugin-danmuku-mask.d.ts",
|
||||
"description": "Danmuku mask plugin for ArtPlayer",
|
||||
"main": "dist/artplayer-plugin-danmuku-mask.js",
|
||||
"legacy": "dist/artplayer-plugin-danmuku-mask.legacy.js",
|
||||
"author": "Harvey Zack <laozhaochaguan@gmail.com>",
|
||||
"browserslist": "last 1 Chrome version",
|
||||
"homepage": "https://artplayer.org",
|
||||
"repository": {
|
||||
"type": "git",
|
||||
"url": "git+https://github.com/zhw2590582/ArtPlayer.git"
|
||||
},
|
||||
"bugs": {
|
||||
"url": "https://github.com/zhw2590582/ArtPlayer/issues"
|
||||
},
|
||||
"keywords": [
|
||||
"html5",
|
||||
"video",
|
||||
"player"
|
||||
]
|
||||
}
|
||||
@@ -0,0 +1,26 @@
|
||||
import style from 'bundle-text:./style.less';
|
||||
|
||||
export default function artplayerPluginDanmukuMask(option) {
|
||||
return (art) => {
|
||||
return {
|
||||
name: 'artplayerPluginDanmukuMask',
|
||||
};
|
||||
};
|
||||
}
|
||||
|
||||
if (typeof document !== 'undefined') {
|
||||
const id = 'artplayer-plugin-danmuku-mask';
|
||||
const $style = document.getElementById(id);
|
||||
if ($style) {
|
||||
$style.textContent = style;
|
||||
} else {
|
||||
const $style = document.createElement('style');
|
||||
$style.id = id;
|
||||
$style.textContent = style;
|
||||
document.head.appendChild($style);
|
||||
}
|
||||
}
|
||||
|
||||
if (typeof window !== 'undefined') {
|
||||
window['artplayerPluginDanmukuMask'] = artplayerPluginDanmukuMask;
|
||||
}
|
||||
@@ -0,0 +1,3 @@
|
||||
.artplayer-plugin-danmuku-mask {
|
||||
//
|
||||
}
|
||||
+14
@@ -0,0 +1,14 @@
|
||||
import type Artplayer from 'artplayer';
|
||||
|
||||
export = artplayerPluginDanmukuMask;
|
||||
export as namespace artplayerPluginDanmukuMask;
|
||||
|
||||
type Option = {
|
||||
//
|
||||
};
|
||||
|
||||
type Result = {
|
||||
name: 'artplayerPluginDanmukuMask';
|
||||
};
|
||||
|
||||
declare const artplayerPluginDanmukuMask: (option: Option) => (art: Artplayer) => Result;
|
||||
Reference in new issue
Block a user