novel-updates: update blogspot (#1167)

This commit is contained in:
Batorian
2024-08-27 16:09:49 +02:00
committed by GitHub
parent d1a4a91c49
commit 3bcd931a48
+9 -2
View File
@@ -6,7 +6,7 @@ import { Plugin } from '@typings/plugin';
class NovelUpdates implements Plugin.PluginBase {
id = 'novelupdates';
name = 'Novel Updates';
version = '0.7.4';
version = '0.7.5';
icon = 'src/en/novelupdates/icon.png';
customCSS = 'src/en/novelupdates/customCSS.css';
site = 'https://www.novelupdates.com/';
@@ -726,6 +726,7 @@ class NovelUpdates implements Plugin.PluginBase {
* - FictionRead (Outlier)
* - Novel World Translations (Outlier)
* - SacredText TL (Outlier)
* - Toasteful
*
* WordPress sites:
* - Anomlaously Creative (Outlier)
@@ -755,13 +756,19 @@ class NovelUpdates implements Plugin.PluginBase {
if (!isWordPress && !isBlogspot) {
chapterText = await this.getChapterBody(loadedCheerio, domain, url);
} else if (isBlogspot) {
bloatClasses = ['.button-container', '.separator'];
bloatClasses = [
'.button-container',
'.ChapterNav',
'.ch-bottom',
'.separator',
];
bloatClasses.map(tag => loadedCheerio(tag).remove());
chapterTitle =
loadedCheerio('.entry-title').first().text() ||
loadedCheerio('.post-title').first().text() ||
'Title not found';
chapterContent =
loadedCheerio('.content-post').html() ||
loadedCheerio('.entry-content').html() ||
loadedCheerio('.post-body').html() ||
'Content not found';