mirror of
https://github.com/zhw2590582/ArtPlayer.git
synced 2026-10-25 08:01:20 -08:00
fix art.loop
This commit is contained in:
1 parent
5fc659b454
commit
678e409a3f
4 files changed
+6
-4
No files matched your search
@@ -8,7 +8,7 @@ export default function loop(option) {
|
||||
const $right = append($control, `<span class="art-loop-point"></span>`);
|
||||
|
||||
art.on('loop', (value) => {
|
||||
if (value) {
|
||||
if (value && value.length) {
|
||||
setStyle($control, 'display', 'block');
|
||||
setStyle($left, 'left', `calc(${(value[0] / art.duration) * 100}% - ${$left.clientWidth}px)`);
|
||||
setStyle($right, 'left', `${(value[1] / art.duration) * 100}%`);
|
||||
|
||||
Reference in new issue
Block a user