mirror of
git://github.com/kovidgoyal/calibre.git
synced 2026-01-04 14:45:07 +01:00
Dont show border on parent elements when hovering over child elements
This commit is contained in:
parent
b131d9226d
commit
c62f144bd7
1 changed files with 3 additions and 2 deletions
|
|
@ -43,8 +43,9 @@
|
|||
for (let elem of document.body.getElementsByTagName('*')) {
|
||||
var style = window.getComputedStyle(elem);
|
||||
if (style.display === 'block' || style.display === 'flex-box' || style.display === 'box') {
|
||||
elem.classList.add("calibre_toc_hover");
|
||||
elem.onclick = onclick;
|
||||
elem.addEventListener('click', onclick);
|
||||
elem.addEventListener('mouseover', function(ev) { this.classList.add('calibre_toc_hover'); ev.stopPropagation(); });
|
||||
elem.addEventListener('mouseout', function(ev) { this.classList.remove('calibre_toc_hover'); ev.stopPropagation(); });
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
|
|||
Loading…
Reference in a new issue