mirror of
https://github.com/kovidgoyal/calibre.git
synced 2025-12-26 14:50:18 -05:00
Update El Diplo recipe - Fix cover URL and extra text
This commit is contained in:
parent
7d9a2aee8a
commit
23d397b49e
@ -86,7 +86,7 @@ class ElDiplo2023(BasicNewsRecipe):
|
||||
|
||||
soup = self.index_to_soup(url_sumario)
|
||||
|
||||
container = soup.find('div', class_='px-16')
|
||||
container = soup.find('div', class_='px-5')
|
||||
url = container.find('img')['src']
|
||||
|
||||
return getattr(self, 'cover_url', url)
|
||||
@ -109,6 +109,11 @@ class ElDiplo2023(BasicNewsRecipe):
|
||||
for p in soup.find('div', id='nota_pie').findChildren('p', recursive=False):
|
||||
p['style'] = f'font-size: {font_size};'
|
||||
|
||||
# remove extra text
|
||||
extra_text = soup.find(string="POST TYPE: post")
|
||||
if extra_text:
|
||||
extra_text.parent.decompose()
|
||||
|
||||
return soup
|
||||
|
||||
def parse_index(self):
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user