refactor: Update video element in Artplayer to support custom canvas or video

This commit is contained in:
Harvey Zack committed 2024-08-22 00:21:23 +08:00
1 parent 5bbbaa398e
commit 52e424ad52
8 files changed
+54 -3

No files matched your search

+8 -1
View File
@@ -1,4 +1,4 @@
import { MP4Clip } from '@webav/av-cliper';
import { MP4Clip, Combinator } from '@webav/av-cliper';
export default function artplayerProxyWebAV() {
return (art) => {
@@ -176,6 +176,13 @@ export default function artplayerProxyWebAV() {
}
async function init() {
const isSupported = await Combinator.isSupported();
if (!isSupported) {
art.notice.show = 'WebAV is not supported';
throw new Error('WebAV is not supported');
}
stop();
reset();