Update NYTimes

This commit is contained in:
Kovid Goyal 2022-09-15 12:32:44 +05:30
parent 2367d3464c
commit 6c9fc1c833
No known key found for this signature in database
GPG Key ID: 06BC317B515ACE7C
3 changed files with 3 additions and 5 deletions

View File

@ -90,7 +90,6 @@ class NewYorkTimes(BasicNewsRecipe):
no_stylesheets = True
compress_news_images = True
compress_news_images_auto_size = 5
remove_attributes = ['style']
conversion_options = {'flow_size': 0}
@property

View File

@ -90,7 +90,6 @@ class NewYorkTimes(BasicNewsRecipe):
no_stylesheets = True
compress_news_images = True
compress_news_images_auto_size = 5
remove_attributes = ['style']
conversion_options = {'flow_size': 0}
@property

View File

@ -10,7 +10,7 @@ from pprint import pprint
from calibre.utils.iso8601 import parse_iso8601
module_version = 3 # needed for live updates
module_version = 4 # needed for live updates
pprint
@ -93,9 +93,9 @@ def process_image_block(lines, block):
if 'web.archive.org' in img:
img = img.partition('/')[-1]
img = img[img.find('https://'):]
lines.append('<div style="text-align: center"><img src={}/>'.format(quoteattr(img)))
lines.append('<div style="text-align: center"><div style="text-align: center"><img src={}/></div><div style="font-size: smaller">'.format(quoteattr(img)))
lines.extend(caption_lines)
lines.append('</div>')
lines.append('</div></div>')
def json_to_html(raw):