mirror of
https://github.com/kovidgoyal/calibre.git
synced 2025-06-23 15:30:45 -04:00
Ensure annotations span styles override all others
This commit is contained in:
parent
6834028e6a
commit
05eb665be9
@ -113,6 +113,9 @@ def wrap_text_in_range(style, r, process_wrapper):
|
|||||||
wrapper_elem = document.createElement('span')
|
wrapper_elem = document.createElement('span')
|
||||||
wrapper_elem.dataset.calibreRangeWrapper = v'++wrapper_counter' + ''
|
wrapper_elem.dataset.calibreRangeWrapper = v'++wrapper_counter' + ''
|
||||||
if style:
|
if style:
|
||||||
|
if !style.endsWith(';'):
|
||||||
|
style += ';'
|
||||||
|
style = str.replace(style, ';', ' !important;')
|
||||||
wrapper_elem.setAttribute('style', style)
|
wrapper_elem.setAttribute('style', style)
|
||||||
|
|
||||||
intersecting_wrappers = {}
|
intersecting_wrappers = {}
|
||||||
|
Loading…
x
Reference in New Issue
Block a user