mirror of
https://github.com/zhw2590582/ArtPlayer.git
synced 2026-10-24 14:41:20 -08:00
feat: Add chapter text display on progress hover in artplayer-plugin-chapter
This commit is contained in:
1 parent
33eba49a3b
commit
0804d1790b
5 files changed
+63
-5
No files matched your search
@@ -58,7 +58,7 @@ export default function progress(options) {
|
||||
function showHighlight(event) {
|
||||
const { width } = getPosFromEvent(art, event);
|
||||
const { text } = event.target.dataset;
|
||||
$tip.innerHTML = text;
|
||||
$tip.innerText = text;
|
||||
const tipWidth = $tip.clientWidth;
|
||||
if (width <= tipWidth / 2) {
|
||||
setStyle($tip, 'left', 0);
|
||||
|
||||
Reference in new issue
Block a user