迁移彩票顶部关闭事件
This commit is contained in:
@@ -50,7 +50,7 @@
|
|||||||
x-text="'距开奖 ' + countdownText">
|
x-text="'距开奖 ' + countdownText">
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
<span onclick="closeLotteryPanel()"
|
<span data-lottery-panel-close
|
||||||
style="cursor:pointer; font-size:20px; color:#fff; opacity:.8; line-height:1; margin-left:12px;"
|
style="cursor:pointer; font-size:20px; color:#fff; opacity:.8; line-height:1; margin-left:12px;"
|
||||||
onmouseover="this.style.opacity=1" onmouseout="this.style.opacity=.8">×</span>
|
onmouseover="this.style.opacity=1" onmouseout="this.style.opacity=.8">×</span>
|
||||||
</div>
|
</div>
|
||||||
@@ -635,4 +635,10 @@
|
|||||||
clearInterval(data._timer);
|
clearInterval(data._timer);
|
||||||
}
|
}
|
||||||
};
|
};
|
||||||
|
|
||||||
|
// 顶部关闭按钮由脚本集中绑定,避免标题栏继续保留内联 onclick。
|
||||||
|
document.querySelector('[data-lottery-panel-close]')?.addEventListener('click', function(e) {
|
||||||
|
e.preventDefault();
|
||||||
|
closeLotteryPanel();
|
||||||
|
});
|
||||||
</script>
|
</script>
|
||||||
|
|||||||
Reference in New Issue
Block a user