fix: Plugins (#578)

* test

* test

* fix

* any

* update

* update

* fix LightNovelReader

* Why did I do that

* typo

* fix

* type

* unused icons have been removed

* madara...

* ops

* fix

* close #563

* update

* LitSpace

* fix jaomix

* fix renovels

* fix ficbook

* update ficbook
This commit is contained in:
Rider21
2023-10-30 09:45:33 +03:00
committed by GitHub
parent 5258464743
commit ac96c62066
244 changed files with 45894 additions and 18184 deletions
+5 -5
View File
@@ -1,6 +1,6 @@
import { fetchApi, fetchFile } from "@libs/fetch";
import { Chapter, Novel, Plugin } from "@typings/plugin";
import cheerio from "cheerio";
import { load as parseHTML } from "cheerio";
import { defaultCover } from "@libs/defaultCover";
const pluginId = "awuxia.com";
@@ -24,7 +24,7 @@ export const popularNovels: Plugin.popularNovels = async function (page) {
});
const body = await result.text();
let loadedCheerio = cheerio.load(body);
let loadedCheerio = parseHTML(body);
let novels: Novel.Item[] = [];
@@ -62,7 +62,7 @@ export const parseNovelAndChapters: Plugin.parseNovelAndChapters =
const result = await fetchApi(url);
const body = await result.text();
let loadedCheerio = cheerio.load(body);
let loadedCheerio = parseHTML(body);
let novel: Novel.instance = { url };
@@ -152,7 +152,7 @@ export const parseChapter: Plugin.parseChapter = async function (chapterUrl) {
const result = await fetchApi(url);
const body = await result.text();
let loadedCheerio = cheerio.load(body);
let loadedCheerio = parseHTML(body);
let chapterText = loadedCheerio(".post-body.entry-content").html();
@@ -165,7 +165,7 @@ export const searchNovels: Plugin.searchNovels = async (searchTerm) => {
const result = await fetchApi(url);
const body = await result.text();
let loadedCheerio = cheerio.load(body);
let loadedCheerio = parseHTML(body);
let novels: Novel.Item[] = [];