From 19f80533185d6886458c6ce976534a9d8cb6a0f0 Mon Sep 17 00:00:00 2001 From: unkn0w7n <51942695+unkn0w7n@users.noreply.github.com> Date: Thu, 7 Mar 2024 10:32:16 +0530 Subject: [PATCH] FT update --- recipes/financial_times.recipe | 10 ++++------ recipes/livemint.recipe | 2 +- recipes/the_week_uk.recipe | 2 +- 3 files changed, 6 insertions(+), 8 deletions(-) diff --git a/recipes/financial_times.recipe b/recipes/financial_times.recipe index d99d52afe9..c105cfa725 100644 --- a/recipes/financial_times.recipe +++ b/recipes/financial_times.recipe @@ -27,7 +27,7 @@ class ft(BasicNewsRecipe): .article-info__time-byline {font-size:small; font-weight:bold; } .o-topper__visual, #fig, .main-image, .n-content-image { text-align:center; font-size:small; } blockquote, i { color:#5c5c5c; } - .o-topper__standfirst { font-weight:bold; color:#202020; } + .o-topper__standfirst { font-style:italic; color:#202020; } .o-topper__topic { font-size:small; color:#5c5c5c; } ''' @@ -39,10 +39,10 @@ class ft(BasicNewsRecipe): ] remove_tags = [ - dict(name=['source', 'svg', 'button']), - dict(name='aside', attrs={'class':'n-content-recommended--single-story flourish-disclaimer'}), + dict(name=['source', 'svg', 'button', 'aside']), + dict(name='aside', attrs={'class':'n-content-recommended--single-story'}), dict(attrs={'data-layout-name':'card'}), - classes('in-article-advert') + classes('in-article-advert flourish-disclaimer') ] def get_cover_url(self): @@ -149,6 +149,4 @@ class ft(BasicNewsRecipe): for con in soup.findAll(attrs={'class':'n-content-layout__slot'}): if con.find('figure'): con['id'] = 'fig' - if h3 := soup.find(**classes('o-topper__standfirst')): - h3.name = 'h3' return soup diff --git a/recipes/livemint.recipe b/recipes/livemint.recipe index c316b57250..fd313ddb9d 100644 --- a/recipes/livemint.recipe +++ b/recipes/livemint.recipe @@ -101,7 +101,7 @@ class LiveMint(BasicNewsRecipe): remove_tags = [ dict(name=['meta', 'link', 'svg', 'button', 'iframe']), classes( - 'trendingSimilarHeight moreNews mobAppDownload label msgError msgOk taboolaHeight' + 'trendingSimilarHeight moreNews mobAppDownload label msgError msgOk taboolaHeight gadgetSlider' ' socialHolder imgbig disclamerText disqus-comment-count openinApp2 lastAdSlot bs_logo' ' datePublish sepStory premiumSlider moreStory Joinus moreAbout milestone benefitText' ) diff --git a/recipes/the_week_uk.recipe b/recipes/the_week_uk.recipe index b3a0cb58e9..d7fb87f422 100644 --- a/recipes/the_week_uk.recipe +++ b/recipes/the_week_uk.recipe @@ -14,7 +14,7 @@ class TheWeek(BasicNewsRecipe): 'our editors carefully select commentary from all sides of the debate and artfully stitch them together ' 'into one concise read. By showing you every perspective, we enable you to form your own opinion.' ) - language = 'en_UK' + language = 'en_GB' encoding = 'utf-8' no_stylesheets = True remove_javascript = True