mirror of
https://github.com/zhw2590582/ArtPlayer.git
synced 2026-10-22 13:21:20 -08:00
update
This commit is contained in:
1 parent
cba10856da
commit
5508660c19
4 files changed
+7
-5
No files matched your search
@@ -385,10 +385,12 @@ class Danmuku {
|
||||
danmu.$ref = this.getRef();
|
||||
danmu.$ref.innerText = danmu.text;
|
||||
this.$danmuku.appendChild(danmu.$ref);
|
||||
danmu.$ref.style.left = `${clientWidth}px`;
|
||||
danmu.$ref.style.opacity = this.option.opacity;
|
||||
danmu.$ref.style.fontSize = `${this.option.fontSize || danmu.fontSize}px`;
|
||||
danmu.$ref.style.color = danmu.color || '#fff';
|
||||
danmu.$ref.style.border = danmu.border ? `1px solid ${danmu.color || '#fff'}` : 'none';
|
||||
danmu.$ref.style.marginLeft = '0px';
|
||||
danmu.$lastStartTime = Date.now();
|
||||
danmu.$restTime = this.option.synchronousPlayback && this.art.playbackRate ? this.option.speed / Number(this.art.playbackRate) : this.option.speed;
|
||||
const top = _getDanmuTopDefault.default(this, danmu);
|
||||
@@ -399,7 +401,6 @@ class Danmuku {
|
||||
case 0:
|
||||
{
|
||||
danmu.$ref.style.top = `${top}px`;
|
||||
danmu.$ref.style.left = `${clientWidth}px`;
|
||||
const translateX = clientWidth + danmu.$ref.clientWidth;
|
||||
danmu.$ref.style.transform = `translateX(${-translateX}px)`;
|
||||
danmu.$ref.style.transition = `transform ${danmu.$restTime}s linear 0s`;
|
||||
@@ -633,7 +634,7 @@ function getDanmuTop(ins, danmu) {
|
||||
// return target.speed * item.time;
|
||||
// });
|
||||
// });
|
||||
console.log(topMap);
|
||||
console.log(target);
|
||||
if (antiOverlap) switch(target.mode){
|
||||
case 0:
|
||||
break;
|
||||
|
||||
Reference in new issue
Block a user