mirror of
https://github.com/kovidgoyal/calibre.git
synced 2025-07-07 18:24:30 -04:00
...
This commit is contained in:
parent
298c6fe3e0
commit
245bae1a2d
@ -395,7 +395,7 @@ def transform_html(container, name, virtualize_resources, link_uid, link_to_map,
|
||||
href = a.get(attr)
|
||||
if href:
|
||||
href = link_replacer(name, href)
|
||||
else:
|
||||
elif attr in a.attrib:
|
||||
a.set(attr, 'javascript:void(0)')
|
||||
if href and href.startswith(link_uid):
|
||||
a.set(attr, 'javascript:void(0)')
|
||||
@ -535,7 +535,7 @@ def virtualize_html(container, name, link_uid, link_to_map, virtualized_names):
|
||||
elif href:
|
||||
a.set('target', '_blank')
|
||||
a.set('rel', 'noopener noreferrer')
|
||||
else:
|
||||
elif attr in a.attrib:
|
||||
a.set(attr, 'javascript:void(0)')
|
||||
|
||||
for a in link_xpath(root):
|
||||
|
Loading…
x
Reference in New Issue
Block a user