fix decode error and write some doc

This commit is contained in:
2020-04-13 15:36:37 +08:00
parent 4f941f606b
commit 71885d70ba
8 changed files with 90 additions and 16 deletions

View File

@ -15,17 +15,23 @@ function highlightLink(target) {
});
}
//apply new highlight
$(realTarget).each(function() {
if ($(this).hasClass("link-blink")) {
$(this).attr("stroke", "yellow")
}
if ($(this).hasClass("link-blinkDelay")) {
$(this).attr("fill", "yellow")
}
});
// double one-click, only cancel highlight and don't apply any hightlight
if (realTarget == previousHighlight) {
previousHighlight = "";
} else {
//apply new highlight
$(realTarget).each(function() {
if ($(this).hasClass("link-blink")) {
$(this).attr("stroke", "yellow")
}
if ($(this).hasClass("link-blinkDelay")) {
$(this).attr("fill", "yellow")
}
});
previousHighlight = realTarget
}
previousHighlight = realTarget
//cancel event seperate
event.stopPropagation();
}