添加字幕url的getter和setter

This commit is contained in:
zhw2590582 committed 2019-10-01 19:51:10 +08:00
1 parent 8d6dcdf6aa
commit 31d1949da0
5 files changed
+98 -23

No files matched your search

@@ -6,6 +6,15 @@ export default function attachUrlMix(art, player) {
template: { $video },
} = art;
Object.defineProperty(player, 'url', {
get() {
return $video.src;
},
set() {
errorHandle(false, 'You should use this method: art.attachUrl()');
},
});
Object.defineProperty(player, 'attachUrl', {
value: url =>
sleep().then(() => {