mirror of
https://github.com/kodjodevf/mangayomi-extensions.git
synced 2026-02-14 10:51:17 +00:00
Add New sources: BeastScan (AR), Lelmanga (FR) & remove unused code
This commit is contained in:
@@ -22,9 +22,7 @@ class ZoroTheme extends MProvider {
|
||||
|
||||
@override
|
||||
Future<MPages> search(MSource source, String query, int page) async {
|
||||
final data = {
|
||||
"url": "${source.baseUrl}/search?keyword=$query&page=$page"
|
||||
};
|
||||
final data = {"url": "${source.baseUrl}/search?keyword=$query&page=$page"};
|
||||
final res = await http('GET', json.encode(data));
|
||||
|
||||
return animeElementM(res);
|
||||
@@ -44,7 +42,7 @@ class ZoroTheme extends MProvider {
|
||||
final status = xpath(res,
|
||||
'//*[@class="anisc-info"]/div[contains(text(),"Status:")]/span[2]/text()')
|
||||
.first;
|
||||
|
||||
|
||||
anime.status = parseStatus(status, statusList);
|
||||
anime.author = xpath(res,
|
||||
'//*[@class="anisc-info"]/div[contains(text(),"Studios:")]/span/text()')
|
||||
@@ -150,8 +148,7 @@ class ZoroTheme extends MProvider {
|
||||
};
|
||||
|
||||
final resE = await http('GET', json.encode(datasE));
|
||||
String epUrl = substringBefore(
|
||||
substringAfter(resE, "\"link\":\""), "\"");
|
||||
String epUrl = substringBefore(substringAfter(resE, "\"link\":\""), "\"");
|
||||
print(epUrl);
|
||||
List<MVideo> a = [];
|
||||
if (name.contains("Vidstreaming")) {
|
||||
@@ -167,11 +164,6 @@ class ZoroTheme extends MProvider {
|
||||
return videos;
|
||||
}
|
||||
|
||||
@override
|
||||
Future<List<String>> getPageList(MSource source, String url) async {
|
||||
return [];
|
||||
}
|
||||
|
||||
MPages animeElementM(String res) {
|
||||
List<MManga> animeList = [];
|
||||
|
||||
@@ -190,8 +182,8 @@ class ZoroTheme extends MProvider {
|
||||
anime.link = urls[i];
|
||||
animeList.add(anime);
|
||||
}
|
||||
final nextPage = xpath(
|
||||
res, '//li[@class="page-item"]/a[@title="Next"]/@href', "");
|
||||
final nextPage =
|
||||
xpath(res, '//li[@class="page-item"]/a[@title="Next"]/@href', "");
|
||||
return MPages(animeList, !nextPage.isEmpty);
|
||||
}
|
||||
|
||||
@@ -206,4 +198,3 @@ class ZoroTheme extends MProvider {
|
||||
ZoroTheme main() {
|
||||
return ZoroTheme();
|
||||
}
|
||||
|
||||
|
||||
@@ -94,11 +94,9 @@ class OkAnime extends MProvider {
|
||||
if (status.isNotEmpty) {
|
||||
anime.status = parseStatus(status.first, statusList);
|
||||
}
|
||||
anime.description =
|
||||
xpath(res, '//*[@class="review-content"]/text()').first;
|
||||
anime.description = xpath(res, '//*[@class="review-content"]/text()').first;
|
||||
|
||||
anime.genre =
|
||||
xpath(res, '//*[@class="review-author-info"]/a/text()');
|
||||
anime.genre = xpath(res, '//*[@class="review-author-info"]/a/text()');
|
||||
final epUrls = xpath(res,
|
||||
'//*[contains(@class,"anime-card")]/div[@class="anime-title")]/h5/a/@href')
|
||||
.reversed
|
||||
@@ -125,8 +123,7 @@ class OkAnime extends MProvider {
|
||||
final res = await http('GET', json.encode({"url": url}));
|
||||
|
||||
final urls = xpath(res, '//*[@id="streamlinks"]/a/@data-src');
|
||||
final qualities =
|
||||
xpath(res, '//*[@id="streamlinks"]/a/span/text()');
|
||||
final qualities = xpath(res, '//*[@id="streamlinks"]/a/span/text()');
|
||||
|
||||
List<MVideo> videos = [];
|
||||
for (var i = 0; i < urls.length; i++) {
|
||||
@@ -172,11 +169,6 @@ class OkAnime extends MProvider {
|
||||
}
|
||||
return false;
|
||||
}
|
||||
|
||||
@override
|
||||
Future<List<String>> getPageList(MSource source, String url) async {
|
||||
return [];
|
||||
}
|
||||
}
|
||||
|
||||
OkAnime main() {
|
||||
|
||||
@@ -34,8 +34,8 @@ class GogoAnime extends MProvider {
|
||||
final res = await http('GET', json.encode(data));
|
||||
|
||||
List<MManga> animeList = [];
|
||||
final urls = xpath(
|
||||
res, '//*[@class="added_series_body popular"]/ul/li/a[1]/@href');
|
||||
final urls =
|
||||
xpath(res, '//*[@class="added_series_body popular"]/ul/li/a[1]/@href');
|
||||
final names = xpath(
|
||||
res, '//*[//*[@class="added_series_body popular"]/ul/li/a[1]/@title');
|
||||
List<String> images = [];
|
||||
@@ -111,8 +111,7 @@ class GogoAnime extends MProvider {
|
||||
final dataEp = {"url": urlEp};
|
||||
final resEp = await http('GET', json.encode(dataEp));
|
||||
|
||||
final epUrls =
|
||||
xpath(resEp, '//*[@id="episode_related"]/li/a/@href');
|
||||
final epUrls = xpath(resEp, '//*[@id="episode_related"]/li/a/@href');
|
||||
final names = xpath(
|
||||
resEp, '//*[@id="episode_related"]/li/a/div[@class="name"]/text()');
|
||||
List<String> episodes = [];
|
||||
@@ -139,8 +138,7 @@ class GogoAnime extends MProvider {
|
||||
final res = await http('GET', json.encode(datas));
|
||||
final serverUrls =
|
||||
xpath(res, '//*[@class="anime_muti_link"]/ul/li/a/@data-video');
|
||||
final classNames =
|
||||
xpath(res, '//*[@class="anime_muti_link"]/ul/li/@class');
|
||||
final classNames = xpath(res, '//*[@class="anime_muti_link"]/ul/li/@class');
|
||||
List<MVideo> videos = [];
|
||||
for (var i = 0; i < classNames.length; i++) {
|
||||
final name = classNames[i];
|
||||
@@ -160,11 +158,6 @@ class GogoAnime extends MProvider {
|
||||
|
||||
return videos;
|
||||
}
|
||||
|
||||
@override
|
||||
Future<List<String>> getPageList(MSource source, String url) async {
|
||||
return [];
|
||||
}
|
||||
}
|
||||
|
||||
GogoAnime main() {
|
||||
|
||||
@@ -126,8 +126,7 @@ class KissKh extends MProvider {
|
||||
final datas = {"url": url};
|
||||
|
||||
final res = await http('GET', json.encode(datas));
|
||||
final id = substringAfter(
|
||||
substringBefore(url, ".png"), "Episode/");
|
||||
final id = substringAfter(substringBefore(url, ".png"), "Episode/");
|
||||
final jsonRes = json.decode(res);
|
||||
|
||||
final subRes = await http(
|
||||
@@ -160,11 +159,6 @@ class KissKh extends MProvider {
|
||||
};
|
||||
return [video];
|
||||
}
|
||||
|
||||
@override
|
||||
Future<List<String>> getPageList(MSource source, String url) async {
|
||||
return [];
|
||||
}
|
||||
}
|
||||
|
||||
KissKh main() {
|
||||
|
||||
@@ -60,8 +60,7 @@ class AnimesUltra extends MProvider {
|
||||
List<MManga> animeList = [];
|
||||
final urls = xpath(res, '//*[@class="film-poster"]/a/@href');
|
||||
final names = xpath(res, '//*[@class="film-poster"]/a/@title');
|
||||
final images =
|
||||
xpath(res, '//*[@class="film-poster"]/img/@data-src');
|
||||
final images = xpath(res, '//*[@class="film-poster"]/img/@data-src');
|
||||
|
||||
for (var i = 0; i < names.length; i++) {
|
||||
MManga anime = MManga();
|
||||
@@ -86,8 +85,7 @@ class AnimesUltra extends MProvider {
|
||||
final res = await http('GET', json.encode(data));
|
||||
MManga anime = MManga();
|
||||
anime.description =
|
||||
xpath(res, '//*[@class="film-description m-hide"]/text()')
|
||||
.first;
|
||||
xpath(res, '//*[@class="film-description m-hide"]/text()').first;
|
||||
|
||||
final status = xpath(res,
|
||||
'//*[@class="item item-title" and contains(text(),"Status:")]/span[2]/text()')
|
||||
@@ -101,9 +99,8 @@ class AnimesUltra extends MProvider {
|
||||
final urlEp = url.replaceAll('.html', '/episode-1.html');
|
||||
final resEpWebview =
|
||||
await getHtmlViaWebview(urlEp, '//*[@class="ss-list"]/a/@href');
|
||||
final epUrls = xpath(resEpWebview, '//*[@class="ss-list"]/a/@href')
|
||||
.reversed
|
||||
.toList();
|
||||
final epUrls =
|
||||
xpath(resEpWebview, '//*[@class="ss-list"]/a/@href').reversed.toList();
|
||||
final names = xpath(resEpWebview,
|
||||
'//*[@class="ss-list"]/a/div[@class="ssli-detail"]/div/text()')
|
||||
.reversed
|
||||
@@ -126,15 +123,14 @@ class AnimesUltra extends MProvider {
|
||||
final resWebview = await getHtmlViaWebview(
|
||||
url, '//*[@class="ps__-list"]/div/@data-server-id');
|
||||
|
||||
final serverIds = xpath(
|
||||
resWebview, '//*[@class="ps__-list"]/div/@data-server-id');
|
||||
final serverIds =
|
||||
xpath(resWebview, '//*[@class="ps__-list"]/div/@data-server-id');
|
||||
final serverNames =
|
||||
xpath(resWebview, '//*[@class="ps__-list"]/div/a/text()');
|
||||
List<String> serverUrls = [];
|
||||
for (var id in serverIds) {
|
||||
final serversUrls =
|
||||
xpath(resWebview, '//*[@id="content_player_${id}"]/text()')
|
||||
.first;
|
||||
xpath(resWebview, '//*[@id="content_player_${id}"]/text()').first;
|
||||
serverUrls.add(serversUrls);
|
||||
}
|
||||
List<MVideo> videos = [];
|
||||
@@ -144,10 +140,8 @@ class AnimesUltra extends MProvider {
|
||||
|
||||
List<MVideo> a = [];
|
||||
if (name.contains("Sendvid")) {
|
||||
a = await sendVidExtractor(
|
||||
url.replaceAll("https:////", "https://"),
|
||||
json.encode({"Referer": "${source.baseUrl}/"}),
|
||||
"");
|
||||
a = await sendVidExtractor(url.replaceAll("https:////", "https://"),
|
||||
json.encode({"Referer": "${source.baseUrl}/"}), "");
|
||||
} else if (name.contains("Sibnet")) {
|
||||
a = await sibnetExtractor(
|
||||
"https://video.sibnet.ru/shell.php?videoid=$url");
|
||||
@@ -159,11 +153,6 @@ class AnimesUltra extends MProvider {
|
||||
|
||||
return videos;
|
||||
}
|
||||
|
||||
@override
|
||||
Future<List<String>> getPageList(MSource source, String url) async {
|
||||
return [];
|
||||
}
|
||||
}
|
||||
|
||||
AnimesUltra main() {
|
||||
|
||||
@@ -168,11 +168,6 @@ class FrAnime extends MProvider {
|
||||
return videos;
|
||||
}
|
||||
|
||||
@override
|
||||
Future<List<String>> getPageList(MSource source, String url) async {
|
||||
return [];
|
||||
}
|
||||
|
||||
MPages animeResList(String res) {
|
||||
final statusList = [
|
||||
{"EN COURS": 0, "TERMINÉ": 1}
|
||||
|
||||
@@ -14,10 +14,10 @@ class OtakuFr extends MProvider {
|
||||
List<MManga> animeList = [];
|
||||
final urls =
|
||||
xpath(res, '//*[@class="list"]/article/div/div/figure/a/@href');
|
||||
final names = xpath(
|
||||
res, '//*[@class="list"]/article/div/div/figure/a/img/@title');
|
||||
final images = xpath(
|
||||
res, '//*[@class="list"]/article/div/div/figure/a/img/@src');
|
||||
final names =
|
||||
xpath(res, '//*[@class="list"]/article/div/div/figure/a/img/@title');
|
||||
final images =
|
||||
xpath(res, '//*[@class="list"]/article/div/div/figure/a/img/@src');
|
||||
|
||||
for (var i = 0; i < names.length; i++) {
|
||||
MManga anime = MManga();
|
||||
@@ -57,8 +57,7 @@ class OtakuFr extends MProvider {
|
||||
.replaceAll(' (Vf)', '')
|
||||
.replaceAll(' (Vostfr)', ''));
|
||||
}
|
||||
final images =
|
||||
xpath(res, '//*[@class="episode"]/div/figure/a/img/@src');
|
||||
final images = xpath(res, '//*[@class="episode"]/div/figure/a/img/@src');
|
||||
|
||||
for (var i = 0; i < names.length; i++) {
|
||||
MManga anime = MManga();
|
||||
@@ -74,18 +73,17 @@ class OtakuFr extends MProvider {
|
||||
@override
|
||||
Future<MPages> search(MSource source, String query, int page) async {
|
||||
final data = {
|
||||
"url":
|
||||
"${source.baseUrl}/toute-la-liste-affiches/page/$page/?q=$query"
|
||||
"url": "${source.baseUrl}/toute-la-liste-affiches/page/$page/?q=$query"
|
||||
};
|
||||
final res = await http('GET', json.encode(data));
|
||||
|
||||
List<MManga> animeList = [];
|
||||
final urls =
|
||||
xpath(res, '//*[@class="list"]/article/div/div/figure/a/@href');
|
||||
final names = xpath(
|
||||
res, '//*[@class="list"]/article/div/div/figure/a/img/@title');
|
||||
final images = xpath(
|
||||
res, '//*[@class="list"]/article/div/div/figure/a/img/@src');
|
||||
final names =
|
||||
xpath(res, '//*[@class="list"]/article/div/div/figure/a/img/@title');
|
||||
final images =
|
||||
xpath(res, '//*[@class="list"]/article/div/div/figure/a/img/@src');
|
||||
|
||||
for (var i = 0; i < names.length; i++) {
|
||||
MManga anime = MManga();
|
||||
@@ -117,10 +115,9 @@ class OtakuFr extends MProvider {
|
||||
res = await http('GET', json.encode(newData));
|
||||
}
|
||||
|
||||
anime.description =
|
||||
xpath(res, '//*[@class="episode fz-sm synop"]/p/text()')
|
||||
.first
|
||||
.replaceAll("Synopsis:", "");
|
||||
anime.description = xpath(res, '//*[@class="episode fz-sm synop"]/p/text()')
|
||||
.first
|
||||
.replaceAll("Synopsis:", "");
|
||||
final status = xpath(res,
|
||||
'//*[@class="list-unstyled"]/li[contains(text(),"Statut")]/text()')
|
||||
.first
|
||||
@@ -129,12 +126,10 @@ class OtakuFr extends MProvider {
|
||||
anime.genre = xpath(res,
|
||||
'//*[@class="list-unstyled"]/li[contains(text(),"Genre")]/ul/li/a/text()');
|
||||
|
||||
final epUrls =
|
||||
xpath(res, '//*[@class="list-episodes list-group"]/a/@href');
|
||||
final dates = xpath(
|
||||
res, '//*[@class="list-episodes list-group"]/a/span/text()');
|
||||
final names =
|
||||
xpath(res, '//*[@class="list-episodes list-group"]/a/text()');
|
||||
final epUrls = xpath(res, '//*[@class="list-episodes list-group"]/a/@href');
|
||||
final dates =
|
||||
xpath(res, '//*[@class="list-episodes list-group"]/a/span/text()');
|
||||
final names = xpath(res, '//*[@class="list-episodes list-group"]/a/text()');
|
||||
List<String> episodes = [];
|
||||
|
||||
for (var i = 0; i < names.length; i++) {
|
||||
@@ -162,8 +157,7 @@ class OtakuFr extends MProvider {
|
||||
Future<List<MVideo>> getVideoList(MSource source, String url) async {
|
||||
final res = await http('GET', json.encode({"url": url}));
|
||||
|
||||
final servers =
|
||||
xpath(res, '//*[@id="nav-tabContent"]/div/iframe/@src');
|
||||
final servers = xpath(res, '//*[@id="nav-tabContent"]/div/iframe/@src');
|
||||
List<MVideo> videos = [];
|
||||
for (var url in servers) {
|
||||
final datasServer = {
|
||||
@@ -195,11 +189,6 @@ class OtakuFr extends MProvider {
|
||||
String fixUrl(String url) {
|
||||
return regExp(url, r"^(?:(?:https?:)?//|www\.)", 'https://', 0, 0);
|
||||
}
|
||||
|
||||
@override
|
||||
Future<List<String>> getPageList(MSource source, String url) async {
|
||||
return [];
|
||||
}
|
||||
}
|
||||
|
||||
OtakuFr main() {
|
||||
|
||||
BIN
icons/mangayomi-ar-beastscans.png
Normal file
BIN
icons/mangayomi-ar-beastscans.png
Normal file
Binary file not shown.
|
After Width: | Height: | Size: 8.6 KiB |
BIN
icons/mangayomi-fr-lelmanga.png
Normal file
BIN
icons/mangayomi-fr-lelmanga.png
Normal file
Binary file not shown.
|
After Width: | Height: | Size: 4.0 KiB |
File diff suppressed because one or more lines are too long
@@ -224,11 +224,6 @@ class HeanCms extends MProvider {
|
||||
List<String> sources = ["YugenMangas", "Reaper Scans", "Perf Scan"];
|
||||
return sources.contains(sourceName);
|
||||
}
|
||||
|
||||
@override
|
||||
Future<List<MVideo>> getVideoList(MSource source, String url) async {
|
||||
return [];
|
||||
}
|
||||
}
|
||||
|
||||
Map<String, String> getHeader(String url) {
|
||||
|
||||
@@ -15,8 +15,7 @@ class Madara extends MProvider {
|
||||
final names = xpath(res, '//*[@id^="manga-item"]/a/@title');
|
||||
var images = xpath(res, '//*[@id^="manga-item"]/a/img/@data-src');
|
||||
if (images.isEmpty) {
|
||||
images =
|
||||
xpath(res, '//*[@id^="manga-item"]/a/img/@data-lazy-src');
|
||||
images = xpath(res, '//*[@id^="manga-item"]/a/img/@data-lazy-src');
|
||||
if (images.isEmpty) {
|
||||
images = xpath(res, '//*[@id^="manga-item"]/a/img/@srcset');
|
||||
if (images.isEmpty) {
|
||||
@@ -47,8 +46,7 @@ class Madara extends MProvider {
|
||||
final names = xpath(res, '//*[@id^="manga-item"]/a/@title');
|
||||
var images = xpath(res, '//*[@id^="manga-item"]/a/img/@data-src');
|
||||
if (images.isEmpty) {
|
||||
images =
|
||||
xpath(res, '//*[@id^="manga-item"]/a/img/@data-lazy-src');
|
||||
images = xpath(res, '//*[@id^="manga-item"]/a/img/@data-lazy-src');
|
||||
if (images.isEmpty) {
|
||||
images = xpath(res, '//*[@id^="manga-item"]/a/img/@srcset');
|
||||
if (images.isEmpty) {
|
||||
@@ -77,21 +75,19 @@ class Madara extends MProvider {
|
||||
final res = await http('GET', json.encode(data));
|
||||
|
||||
List<MManga> mangaList = [];
|
||||
final urls =
|
||||
xpath(res, '//*[@class^="tab-thumb c-image-hover"]/a/@href');
|
||||
final names =
|
||||
xpath(res, '//*[@class^="tab-thumb c-image-hover"]/a/@title');
|
||||
var images = xpath(
|
||||
res, '//*[@class^="tab-thumb c-image-hover"]/a/img/@data-src');
|
||||
final urls = xpath(res, '//*[@class^="tab-thumb c-image-hover"]/a/@href');
|
||||
final names = xpath(res, '//*[@class^="tab-thumb c-image-hover"]/a/@title');
|
||||
var images =
|
||||
xpath(res, '//*[@class^="tab-thumb c-image-hover"]/a/img/@data-src');
|
||||
if (images.isEmpty) {
|
||||
images = xpath(
|
||||
res, '//*[@class^="tab-thumb c-image-hover"]/a/img/@data-lazy-src');
|
||||
if (images.isEmpty) {
|
||||
images = xpath(
|
||||
res, '//*[@class^="tab-thumb c-image-hover"]/a/img/@srcset');
|
||||
images =
|
||||
xpath(res, '//*[@class^="tab-thumb c-image-hover"]/a/img/@srcset');
|
||||
if (images.isEmpty) {
|
||||
images = xpath(
|
||||
res, '//*[@class^="tab-thumb c-image-hover"]/a/img/@src');
|
||||
images =
|
||||
xpath(res, '//*[@class^="tab-thumb c-image-hover"]/a/img/@src');
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -158,39 +154,45 @@ class Madara extends MProvider {
|
||||
final datas = {"url": url, "sourceId": source.id};
|
||||
res = await http('GET', json.encode(datas));
|
||||
|
||||
manga.author = querySelectorAll(res,
|
||||
selector: "div.author-content > a",
|
||||
typeElement: 0,
|
||||
attributes: "",
|
||||
typeRegExp: 0)
|
||||
.first;
|
||||
manga.description = querySelectorAll(res,
|
||||
selector:
|
||||
"div.description-summary div.summary__content, div.summary_content div.post-content_item > h5 + div, div.summary_content div.manga-excerpt, div.sinopsis div.contenedor, .description-summary > p",
|
||||
typeElement: 0,
|
||||
attributes: "",
|
||||
typeRegExp: 0)
|
||||
.first;
|
||||
manga.imageUrl = querySelectorAll(res,
|
||||
selector: "div.summary_image img",
|
||||
typeElement: 2,
|
||||
attributes: "",
|
||||
typeRegExp: 2)
|
||||
.first;
|
||||
final author = querySelectorAll(res,
|
||||
selector: "div.author-content > a",
|
||||
typeElement: 0,
|
||||
attributes: "",
|
||||
typeRegExp: 0);
|
||||
if (author.isNotEmpty) {
|
||||
manga.author = author.first;
|
||||
}
|
||||
final description = querySelectorAll(res,
|
||||
selector:
|
||||
"div.description-summary div.summary__content, div.summary_content div.post-content_item > h5 + div, div.summary_content div.manga-excerpt, div.sinopsis div.contenedor, .description-summary > p",
|
||||
typeElement: 0,
|
||||
attributes: "",
|
||||
typeRegExp: 0);
|
||||
if (description.isNotEmpty) {
|
||||
manga.description = description.first;
|
||||
}
|
||||
final imageUrl = querySelectorAll(res,
|
||||
selector: "div.summary_image img",
|
||||
typeElement: 2,
|
||||
attributes: "",
|
||||
typeRegExp: 2);
|
||||
if (imageUrl.isNotEmpty) {
|
||||
manga.imageUrl = imageUrl.first;
|
||||
}
|
||||
final mangaId = querySelectorAll(res,
|
||||
selector: "div[id^=manga-chapters-holder]",
|
||||
typeElement: 3,
|
||||
attributes: "data-id",
|
||||
typeRegExp: 0)
|
||||
.first;
|
||||
manga.status = parseStatus(
|
||||
querySelectorAll(res,
|
||||
selector: "div.summary-content",
|
||||
typeElement: 0,
|
||||
attributes: "",
|
||||
typeRegExp: 0)
|
||||
.last,
|
||||
statusList);
|
||||
final status = querySelectorAll(res,
|
||||
selector: "div.summary-content",
|
||||
typeElement: 0,
|
||||
attributes: "",
|
||||
typeRegExp: 0);
|
||||
if (status.isNotEmpty) {
|
||||
manga.status = parseStatus(status.last, statusList);
|
||||
}
|
||||
|
||||
manga.genre = querySelectorAll(res,
|
||||
selector: "div.genres-content a",
|
||||
@@ -208,13 +210,9 @@ class Madara extends MProvider {
|
||||
"${baseUrl}wp-admin/admin-ajax.php?action=manga_get_chapters&manga=$mangaId";
|
||||
final datasP = {"url": urll, "headers": headers, "sourceId": source.id};
|
||||
res = await http('POST', json.encode(datasP));
|
||||
if (res == "400") {
|
||||
if (res == "error") {
|
||||
final urlP = "${url}ajax/chapters";
|
||||
final datasP = {
|
||||
"url": urlP,
|
||||
"headers": headers,
|
||||
"sourceId": source.id
|
||||
};
|
||||
final datasP = {"url": urlP, "headers": headers, "sourceId": source.id};
|
||||
res = await http('POST', json.encode(datasP));
|
||||
}
|
||||
|
||||
@@ -231,8 +229,8 @@ class Madara extends MProvider {
|
||||
dateF = xpath(resWebview,
|
||||
"//*[@id='manga-chapters-holder']/div[2]/div/ul/li/span/i/text()");
|
||||
}
|
||||
var dateUploads = parseDates(
|
||||
dateF, source.dateFormat, source.dateFormatLocale);
|
||||
var dateUploads =
|
||||
parseDates(dateF, source.dateFormat, source.dateFormatLocale);
|
||||
if (dateF.length < chaptersNames.length) {
|
||||
final length = chaptersNames.length - dateF.length;
|
||||
String date = "${DateTime.now().millisecondsSinceEpoch}";
|
||||
@@ -240,8 +238,8 @@ class Madara extends MProvider {
|
||||
date += "--..${DateTime.now().millisecondsSinceEpoch}";
|
||||
}
|
||||
|
||||
final dateFF = parseDates(
|
||||
dateF, source.dateFormat, source.dateFormatLocale);
|
||||
final dateFF =
|
||||
parseDates(dateF, source.dateFormat, source.dateFormatLocale);
|
||||
List<String> chapterDate = date.split('--..');
|
||||
|
||||
for (var date in dateFF) {
|
||||
@@ -314,11 +312,6 @@ class Madara extends MProvider {
|
||||
}
|
||||
return pageUrls;
|
||||
}
|
||||
|
||||
@override
|
||||
Future<List<MVideo>> getVideoList(MSource source, String url) async {
|
||||
return [];
|
||||
}
|
||||
}
|
||||
|
||||
Madara main() {
|
||||
|
||||
@@ -92,33 +92,41 @@ class MangaReader extends MProvider {
|
||||
final datas = {"url": url, "sourceId": source.id};
|
||||
final res = await http('GET', json.encode(datas));
|
||||
|
||||
manga.author = xpath(
|
||||
res,
|
||||
'//*[@class="imptdt" and contains(text(), "Author") or @class="infotable" and contains(text(), "Author") or @class="infotable" and contains(text(), "Auteur") or @class="fmed" and contains(text(), "Auteur") or @class="infotable" and contains(text(), "Autor")]/text()',
|
||||
'')
|
||||
.first
|
||||
.replaceAll("Autor", "")
|
||||
.replaceAll("Author", "")
|
||||
.replaceAll("Auteur", "")
|
||||
.replaceAll("[Add, ]", "");
|
||||
final author = xpath(
|
||||
res,
|
||||
'//*[@class="imptdt" and contains(text(), "Author") or @class="infotable" and contains(text(), "Author") or @class="infotable" and contains(text(), "Auteur") or @class="fmed" and contains(text(), "Auteur") or @class="infotable" and contains(text(), "Autor")]/text()',
|
||||
'');
|
||||
|
||||
manga.description = querySelectorAll(res,
|
||||
selector: ".desc, .entry-content[itemprop=description]",
|
||||
typeElement: 0,
|
||||
attributes: "",
|
||||
typeRegExp: 0)
|
||||
.first;
|
||||
if (author.isNotEmpty) {
|
||||
manga.author = author.first
|
||||
.replaceAll("Autor", "")
|
||||
.replaceAll("Author", "")
|
||||
.replaceAll("Auteur", "")
|
||||
.replaceAll("[Add, ]", "");
|
||||
}
|
||||
|
||||
final description = querySelectorAll(res,
|
||||
selector: ".desc, .entry-content[itemprop=description]",
|
||||
typeElement: 0,
|
||||
attributes: "",
|
||||
typeRegExp: 0);
|
||||
if (description.isNotEmpty) {
|
||||
manga.description = description.first;
|
||||
}
|
||||
|
||||
final status = xpath(
|
||||
res,
|
||||
'//*[@class="imptdt" and contains(text(), "Status") or @class="imptdt" and contains(text(), "Estado") or @class="infotable" and contains(text(), "Status") or @class="infotable" and contains(text(), "Statut") or @class="imptdt" and contains(text(), "Statut")]/text()',
|
||||
'')
|
||||
.first
|
||||
.replaceAll("Status", "")
|
||||
.replaceAll("Estado", "")
|
||||
.replaceAll("Statut", "");
|
||||
res,
|
||||
'//*[@class="imptdt" and contains(text(), "Status") or @class="imptdt" and contains(text(), "Estado") or @class="infotable" and contains(text(), "Status") or @class="infotable" and contains(text(), "Statut") or @class="imptdt" and contains(text(), "Statut")]/text()',
|
||||
'');
|
||||
|
||||
manga.status = parseStatus(status, statusList);
|
||||
if (status.isNotEmpty) {
|
||||
manga.status = parseStatus(
|
||||
status.first
|
||||
.replaceAll("Status", "")
|
||||
.replaceAll("Estado", "")
|
||||
.replaceAll("Statut", ""),
|
||||
statusList);
|
||||
}
|
||||
|
||||
manga.genre = xpath(res,
|
||||
'//*[@class="gnr" or @class="mgen" or @class="seriestugenre" ]/a/text()');
|
||||
@@ -130,8 +138,8 @@ class MangaReader extends MProvider {
|
||||
var chapterDates = xpath(res,
|
||||
'//*[@class="bxcl" or @class="cl" or @class="chbox" or @class="eph-num" or @id="chapterlist"]/div/a/span[@class="chapterdate" and not(text()="{{date}}")]/text()');
|
||||
|
||||
var dateUploads = parseDates(
|
||||
chapterDates, source.dateFormat, source.dateFormatLocale);
|
||||
var dateUploads =
|
||||
parseDates(chapterDates, source.dateFormat, source.dateFormatLocale);
|
||||
|
||||
List<MChapter>? chaptersList = [];
|
||||
for (var i = 0; i < chaptersNames.length; i++) {
|
||||
@@ -157,8 +165,7 @@ class MangaReader extends MProvider {
|
||||
pages = xpath(res, '//*[@id="readerarea"]/img/@src');
|
||||
}
|
||||
if (pages.isEmpty || pages.length == 1) {
|
||||
final images =
|
||||
regExp(res, "\"images\"\\s*:\\s*(\\[.*?])", "", 1, 1);
|
||||
final images = regExp(res, "\"images\"\\s*:\\s*(\\[.*?])", "", 1, 1);
|
||||
final pages = json.decode(images) as List;
|
||||
for (var page in pages) {
|
||||
pagesUrl.add(page);
|
||||
@@ -172,12 +179,10 @@ class MangaReader extends MProvider {
|
||||
|
||||
MPages mangaRes(String res) {
|
||||
List<MManga> mangaList = [];
|
||||
final urls =
|
||||
xpath(res, '//*[ @class="imgu" or @class="bsx"]/a/@href');
|
||||
final names =
|
||||
xpath(res, '//*[ @class="imgu" or @class="bsx"]/a/@title');
|
||||
final images = xpath(
|
||||
res, '//*[ @class="imgu" or @class="bsx"]/a/div[1]/img/@src');
|
||||
final urls = xpath(res, '//*[ @class="imgu" or @class="bsx"]/a/@href');
|
||||
final names = xpath(res, '//*[ @class="imgu" or @class="bsx"]/a/@title');
|
||||
final images =
|
||||
xpath(res, '//*[ @class="imgu" or @class="bsx"]/a/div[1]/img/@src');
|
||||
|
||||
for (var i = 0; i < names.length; i++) {
|
||||
MManga manga = MManga();
|
||||
@@ -196,11 +201,6 @@ class MangaReader extends MProvider {
|
||||
}
|
||||
return "/manga";
|
||||
}
|
||||
|
||||
@override
|
||||
Future<List<MVideo>> getVideoList(MSource source, String url) async {
|
||||
return [];
|
||||
}
|
||||
}
|
||||
|
||||
MangaReader main() {
|
||||
|
||||
@@ -9,6 +9,24 @@ const defaultDateFormatLocale = "en_US";
|
||||
|
||||
List<Source> get mangareaderSourcesList => _mangareaderSourcesList;
|
||||
List<Source> _mangareaderSourcesList = [
|
||||
Source(
|
||||
name: "Beast Scans",
|
||||
baseUrl: "https://beast-scans.com",
|
||||
lang: "ar",
|
||||
iconUrl: getIconUrl("asurascans", "en"),
|
||||
dateFormat: "MMMM dd, yyyy",
|
||||
dateFormatLocale: "ar",
|
||||
version: mangareaderVersion,
|
||||
sourceCodeUrl: mangareaderSourceCodeUrl),
|
||||
Source(
|
||||
name: "Lelmanga",
|
||||
baseUrl: "https://www.lelmanga.com",
|
||||
lang: "fr",
|
||||
iconUrl: getIconUrl("lelmanga", "fr"),
|
||||
dateFormat: "MMMM d, yyyy",
|
||||
dateFormatLocale: "en",
|
||||
version: mangareaderVersion,
|
||||
sourceCodeUrl: mangareaderSourceCodeUrl),
|
||||
Source(
|
||||
name: "Asura Scans",
|
||||
baseUrl: "https://asuratoon.com/",
|
||||
|
||||
@@ -1,8 +1,8 @@
|
||||
import 'package:mangayomi/bridge_lib.dart';
|
||||
import 'dart:convert';
|
||||
|
||||
class MMCRCms extends MProvider {
|
||||
MMCRCms();
|
||||
class MMRCMS extends MProvider {
|
||||
MMRCMS();
|
||||
|
||||
@override
|
||||
Future<MPages> getPopular(MSource source, int page) async {
|
||||
@@ -131,35 +131,33 @@ class MMCRCms extends MProvider {
|
||||
final datas = {"url": url, "sourceId": source.id};
|
||||
final res = await http('GET', json.encode(datas));
|
||||
|
||||
manga.author = xpath(res,
|
||||
'//*[@class="dl-horizontal"]/dt[contains(text(), "Auteur(s)") or contains(text(), "Author(s)") or contains(text(), "Autor(es)") or contains(text(), "Yazar(lar) or contains(text(), "Mangaka(lar)")]//following-sibling::dd[1]/text()')
|
||||
.first;
|
||||
final author = xpath(res,
|
||||
'//*[@class="dl-horizontal"]/dt[contains(text(), "Auteur(s)") or contains(text(), "Author(s)") or contains(text(), "Autor(es)") or contains(text(), "Yazar(lar) or contains(text(), "Mangaka(lar)")]//following-sibling::dd[1]/text()');
|
||||
if (author.isNotEmpty) {
|
||||
manga.author = author.first;
|
||||
}
|
||||
final status = xpath(res,
|
||||
'//*[@class="dl-horizontal"]/dt[contains(text(), "Statut") or contains(text(), "Status") or contains(text(), "Estado") or contains(text(), "Durum")]/following-sibling::dd[1]/text()')
|
||||
.first;
|
||||
manga.status = parseStatus(status, statusList);
|
||||
manga.description =
|
||||
xpath(res, '//*[@class="well" or @class="manga well"]/p/text()')
|
||||
.first;
|
||||
'//*[@class="dl-horizontal"]/dt[contains(text(), "Statut") or contains(text(), "Status") or contains(text(), "Estado") or contains(text(), "Durum")]/following-sibling::dd[1]/text()');
|
||||
if (status.isNotEmpty) {
|
||||
manga.status = parseStatus(status.first, statusList);
|
||||
}
|
||||
|
||||
final description =
|
||||
xpath(res, '//*[@class="well" or @class="manga well"]/p/text()');
|
||||
if (description.isNotEmpty) {
|
||||
manga.description = description.first;
|
||||
}
|
||||
|
||||
manga.genre = xpath(res,
|
||||
'//*[@class="dl-horizontal"]/dt[contains(text(), "Categories") or contains(text(), "Categorias") or contains(text(), "Categorías") or contains(text(), "Catégories") or contains(text(), "Kategoriler" or contains(text(), "Kategorie") or contains(text(), "Kategori") or contains(text(), "Tagi"))]/following-sibling::dd[1]/text()');
|
||||
|
||||
final baseUrl = "${source.baseUrl}/";
|
||||
final headers = {
|
||||
"Referer": baseUrl,
|
||||
"Content-Type": "application/x-www-form-urlencoded",
|
||||
"X-Requested-With": "XMLHttpRequest"
|
||||
};
|
||||
|
||||
var chapUrls =
|
||||
xpath(res, '//*[@class="chapter-title-rtl"]/a/@href');
|
||||
var chaptersNames =
|
||||
xpath(res, '//*[@class="chapter-title-rtl"]/a/text()');
|
||||
var chapUrls = xpath(res, '//*[@class="chapter-title-rtl"]/a/@href');
|
||||
var chaptersNames = xpath(res, '//*[@class="chapter-title-rtl"]/a/text()');
|
||||
var chaptersDates =
|
||||
xpath(res, '//*[@class="date-chapter-title-rtl"]/text()');
|
||||
|
||||
var dateUploads = parseDates(
|
||||
chaptersDates, source.dateFormat, source.dateFormatLocale);
|
||||
var dateUploads =
|
||||
parseDates(chaptersDates, source.dateFormat, source.dateFormatLocale);
|
||||
|
||||
List<MChapter>? chaptersList = [];
|
||||
for (var i = 0; i < chaptersNames.length; i++) {
|
||||
@@ -179,8 +177,8 @@ class MMCRCms extends MProvider {
|
||||
final res = await http('GET', json.encode(datas));
|
||||
|
||||
List<String> pagesUrl = [];
|
||||
final pages = xpath(
|
||||
res, '//*[@id="all"]/img[@class="img-responsive"]/@data-src');
|
||||
final pages =
|
||||
xpath(res, '//*[@id="all"]/img[@class="img-responsive"]/@data-src');
|
||||
for (var page in pages) {
|
||||
if (page.startsWith('//')) {
|
||||
pagesUrl.add(page.replaceAll('//', 'https://'));
|
||||
@@ -191,13 +189,8 @@ class MMCRCms extends MProvider {
|
||||
|
||||
return pagesUrl;
|
||||
}
|
||||
|
||||
@override
|
||||
Future<List<MVideo>> getVideoList(MSource source, String url) async {
|
||||
return [];
|
||||
}
|
||||
}
|
||||
|
||||
MMCRCms main() {
|
||||
return MMCRCms();
|
||||
MMRCMS main() {
|
||||
return MMRCMS();
|
||||
}
|
||||
|
||||
@@ -70,22 +70,7 @@ class NepNep extends MProvider {
|
||||
final vmChapters =
|
||||
substringBefore(substringAfter(script, "vm.Chapters = "), ";");
|
||||
final chapters = json.decode(vmChapters) as List;
|
||||
var chapUrls = chapters
|
||||
.map((ch) =>
|
||||
'/read-online/${substringAfter(url, "/manga/")}${chapterURLEncode(ch['Chapter'])}')
|
||||
.toList();
|
||||
|
||||
var chaptersNames = chapters.map((ch) {
|
||||
String name = ch['ChapterName'] ?? "";
|
||||
String indexChapter = ch['Chapter'];
|
||||
if (name.isEmpty) {
|
||||
name = '${ch['Type']} ${chapterImage(indexChapter, true)}';
|
||||
}
|
||||
return name;
|
||||
}).toList();
|
||||
var chaptersDates = chapters.map((ch) => ch['Date']).toList();
|
||||
var dateUploads =
|
||||
parseDates(chaptersDates, source.dateFormat, source.dateFormatLocale);
|
||||
List<MChapter> chaptersList = [];
|
||||
|
||||
for (var ch in chapters) {
|
||||
@@ -219,11 +204,6 @@ class NepNep extends MProvider {
|
||||
|
||||
return '-chapter-$n$suffix$index.html';
|
||||
}
|
||||
|
||||
@override
|
||||
Future<List<MVideo>> getVideoList(MSource source, String url) async {
|
||||
return [];
|
||||
}
|
||||
}
|
||||
|
||||
Map<String, String> getHeader(String url) {
|
||||
|
||||
@@ -15,6 +15,7 @@ List<Source> _nepnepSourcesList = [
|
||||
lang: "en",
|
||||
typeSource: "nepnep",
|
||||
iconUrl: getIconUrl("mangasee", "en"),
|
||||
isFullData: true,
|
||||
dateFormat: defaultDateFormat,
|
||||
dateFormatLocale: defaultDateFormatLocale,
|
||||
version: nepnepVersion,
|
||||
@@ -26,6 +27,7 @@ List<Source> _nepnepSourcesList = [
|
||||
lang: "en",
|
||||
typeSource: "nepnep",
|
||||
iconUrl: getIconUrl("mangalife", "en"),
|
||||
isFullData: true,
|
||||
dateFormat: defaultDateFormat,
|
||||
dateFormatLocale: defaultDateFormatLocale,
|
||||
version: nepnepVersion,
|
||||
|
||||
@@ -189,11 +189,6 @@ class Batoto extends MProvider {
|
||||
}
|
||||
return "langs=$lang";
|
||||
}
|
||||
|
||||
@override
|
||||
Future<List<MVideo>> getVideoList(MSource source, String url) async {
|
||||
return [];
|
||||
}
|
||||
}
|
||||
|
||||
Map<String, String> getMirrorPref() {
|
||||
|
||||
@@ -166,11 +166,6 @@ class ComickFun extends MProvider {
|
||||
|
||||
return result;
|
||||
}
|
||||
|
||||
@override
|
||||
Future<List<MVideo>> getVideoList(MSource source, String url) async {
|
||||
return [];
|
||||
}
|
||||
}
|
||||
|
||||
Map<String, String> getHeader(String url) {
|
||||
|
||||
@@ -57,15 +57,10 @@ class MangaDex extends MProvider {
|
||||
res, r'$..data.relationships[*].attributes.name', ', ');
|
||||
|
||||
String expressionDescriptionA = r'$..data.attributes.description.en';
|
||||
String expressionDescription = regExp(
|
||||
r'$..data.attributes.description[a]',
|
||||
r'\[a\]',
|
||||
".${source.lang}",
|
||||
0,
|
||||
1);
|
||||
String expressionDescription = regExp(r'$..data.attributes.description[a]',
|
||||
r'\[a\]', ".${source.lang}", 0, 1);
|
||||
|
||||
String description =
|
||||
jsonPathToString(res, expressionDescription, '');
|
||||
String description = jsonPathToString(res, expressionDescription, '');
|
||||
if (description.isEmpty) {
|
||||
description = jsonPathToString(res, expressionDescriptionA, '');
|
||||
}
|
||||
@@ -81,29 +76,27 @@ class MangaDex extends MProvider {
|
||||
if (contentRating != "safe") {
|
||||
genres.add(contentRating);
|
||||
}
|
||||
String publicationDemographic = jsonPathToString(
|
||||
res, r'$..data.attributes.publicationDemographic', '');
|
||||
String publicationDemographic =
|
||||
jsonPathToString(res, r'$..data.attributes.publicationDemographic', '');
|
||||
if (publicationDemographic == "null") {
|
||||
} else {
|
||||
genres.add(publicationDemographic);
|
||||
}
|
||||
manga.genre = genres;
|
||||
String statusRes =
|
||||
jsonPathToString(res, r'$..data.attributes.status', '');
|
||||
String statusRes = jsonPathToString(res, r'$..data.attributes.status', '');
|
||||
manga.status = parseStatus(statusRes, statusList);
|
||||
final mangaId = url.split('/').last;
|
||||
|
||||
final paginatedChapterList =
|
||||
await paginatedChapterListRequest(mangaId, 0, source.lang);
|
||||
final chapterList =
|
||||
jsonPathToString(paginatedChapterList, r'$.data[*]', '_.')
|
||||
.split('_.');
|
||||
int limit = int.parse(
|
||||
jsonPathToString(paginatedChapterList, r'$.limit', ''));
|
||||
int offset = int.parse(
|
||||
jsonPathToString(paginatedChapterList, r'$.offset', ''));
|
||||
int total = int.parse(
|
||||
jsonPathToString(paginatedChapterList, r'$.total', ''));
|
||||
jsonPathToString(paginatedChapterList, r'$.data[*]', '_.').split('_.');
|
||||
int limit =
|
||||
int.parse(jsonPathToString(paginatedChapterList, r'$.limit', ''));
|
||||
int offset =
|
||||
int.parse(jsonPathToString(paginatedChapterList, r'$.offset', ''));
|
||||
int total =
|
||||
int.parse(jsonPathToString(paginatedChapterList, r'$.total', ''));
|
||||
List<MChapter> chapterListA = [];
|
||||
|
||||
final list =
|
||||
@@ -115,8 +108,7 @@ class MangaDex extends MProvider {
|
||||
offset += limit;
|
||||
var newRequest =
|
||||
await paginatedChapterListRequest(mangaId, offset, source.lang);
|
||||
int total =
|
||||
int.parse(jsonPathToString(newRequest, r'$.total', ''));
|
||||
int total = int.parse(jsonPathToString(newRequest, r'$.total', ''));
|
||||
final chapterList =
|
||||
jsonPathToString(paginatedChapterList, r'$.data[*]', '_.')
|
||||
.split('_.');
|
||||
@@ -159,8 +151,7 @@ class MangaDex extends MProvider {
|
||||
List<MChapter> getChapters(int length, String paginatedChapterListA) {
|
||||
List<MChapter> chaptersList = [];
|
||||
String paginatedChapterList = paginatedChapterListA.toString();
|
||||
final dataList =
|
||||
jsonPathToList(paginatedChapterList, r'$.data[*]', 0);
|
||||
final dataList = jsonPathToList(paginatedChapterList, r'$.data[*]', 0);
|
||||
for (var res in dataList) {
|
||||
String scan = "".toString();
|
||||
final groups = jsonPathToList(res,
|
||||
@@ -215,9 +206,8 @@ class MangaDex extends MProvider {
|
||||
chapterr.name = chapName;
|
||||
chapterr.url = id;
|
||||
chapterr.scanlator = scan;
|
||||
chapterr.dateUpload = parseDates(
|
||||
[date], "yyyy-MM-dd'T'HH:mm:ss+SSS", "en_US")
|
||||
.first;
|
||||
chapterr.dateUpload =
|
||||
parseDates([date], "yyyy-MM-dd'T'HH:mm:ss+SSS", "en_US").first;
|
||||
chaptersList.add(chapterr);
|
||||
}
|
||||
}
|
||||
@@ -268,11 +258,6 @@ class MangaDex extends MProvider {
|
||||
}
|
||||
return coverFileName;
|
||||
}
|
||||
|
||||
@override
|
||||
Future<List<MVideo>> getVideoList(MSource source, String url) async {
|
||||
return [];
|
||||
}
|
||||
}
|
||||
|
||||
MangaDex main() {
|
||||
|
||||
@@ -13,12 +13,12 @@ class MangaHere extends MProvider {
|
||||
final res = await http('POST', json.encode(data));
|
||||
|
||||
List<MManga> mangaList = [];
|
||||
final names = xpath(
|
||||
res, '//*[ contains(@class, "manga-list-1-list")]/li/a/@title');
|
||||
final names =
|
||||
xpath(res, '//*[ contains(@class, "manga-list-1-list")]/li/a/@title');
|
||||
final images = xpath(res,
|
||||
'//*[ contains(@class, "manga-list-1-list")]/li/a/img[@class="manga-list-1-cover"]/@src');
|
||||
final urls = xpath(
|
||||
res, '//*[ contains(@class, "manga-list-1-list")]/li/a/@href');
|
||||
final urls =
|
||||
xpath(res, '//*[ contains(@class, "manga-list-1-list")]/li/a/@href');
|
||||
|
||||
for (var i = 0; i < names.length; i++) {
|
||||
MManga manga = MManga();
|
||||
@@ -40,12 +40,12 @@ class MangaHere extends MProvider {
|
||||
final res = await http('POST', json.encode(data));
|
||||
|
||||
List<MManga> mangaList = [];
|
||||
final names = xpath(
|
||||
res, '//*[ contains(@class, "manga-list-1-list")]/li/a/@title');
|
||||
final names =
|
||||
xpath(res, '//*[ contains(@class, "manga-list-1-list")]/li/a/@title');
|
||||
final images = xpath(res,
|
||||
'//*[ contains(@class, "manga-list-1-list")]/li/a/img[@class="manga-list-1-cover"]/@src');
|
||||
final urls = xpath(
|
||||
res, '//*[ contains(@class, "manga-list-1-list")]/li/a/@href');
|
||||
final urls =
|
||||
xpath(res, '//*[ contains(@class, "manga-list-1-list")]/li/a/@href');
|
||||
|
||||
for (var i = 0; i < names.length; i++) {
|
||||
MManga manga = MManga();
|
||||
@@ -67,12 +67,12 @@ class MangaHere extends MProvider {
|
||||
final res = await http('POST', json.encode(data));
|
||||
|
||||
List<MManga> mangaList = [];
|
||||
final names = xpath(
|
||||
res, '//*[contains(@class, "manga-list-4-list")]/li/a/@title');
|
||||
final names =
|
||||
xpath(res, '//*[contains(@class, "manga-list-4-list")]/li/a/@title');
|
||||
final images = xpath(res,
|
||||
'//*[contains(@class, "manga-list-4-list")]/li/a/img[@class="manga-list-4-cover"]/@src');
|
||||
final urls = xpath(
|
||||
res, '//*[contains(@class, "manga-list-4-list")]/li/a/@href');
|
||||
final urls =
|
||||
xpath(res, '//*[contains(@class, "manga-list-4-list")]/li/a/@href');
|
||||
|
||||
for (var i = 0; i < names.length; i++) {
|
||||
MManga manga = MManga();
|
||||
@@ -95,25 +95,21 @@ class MangaHere extends MProvider {
|
||||
final res = await http('GET', json.encode(data));
|
||||
MManga manga = MManga();
|
||||
manga.author =
|
||||
xpath(res, '//*[@class="detail-info-right-say"]/a/text()')
|
||||
.first;
|
||||
manga.description =
|
||||
xpath(res, '//*[@class="fullcontent"]/text()').first;
|
||||
xpath(res, '//*[@class="detail-info-right-say"]/a/text()').first;
|
||||
manga.description = xpath(res, '//*[@class="fullcontent"]/text()').first;
|
||||
final status =
|
||||
xpath(res, '//*[@class="detail-info-right-title-tip"]/text()')
|
||||
.first;
|
||||
xpath(res, '//*[@class="detail-info-right-title-tip"]/text()').first;
|
||||
manga.status = parseStatus(status, statusList);
|
||||
manga.genre =
|
||||
xpath(res, '//*[@class="detail-info-right-tag-list"]/a/text()');
|
||||
|
||||
var chapUrls =
|
||||
xpath(res, '//*[@class="detail-main-list"]/li/a/@href');
|
||||
var chapUrls = xpath(res, '//*[@class="detail-main-list"]/li/a/@href');
|
||||
var chaptersNames = xpath(res,
|
||||
'//*[@class="detail-main-list"]/li/a/div/p[@class="title3"]/text()');
|
||||
final chapterDates = xpath(res,
|
||||
'//*[@class="detail-main-list"]/li/a/div/p[@class="title2"]/text()');
|
||||
var dateUploads = parseDates(
|
||||
chapterDates, source.dateFormat, source.dateFormatLocale);
|
||||
var dateUploads =
|
||||
parseDates(chapterDates, source.dateFormat, source.dateFormatLocale);
|
||||
|
||||
List<MChapter>? chaptersList = [];
|
||||
for (var i = 0; i < chaptersNames.length; i++) {
|
||||
@@ -190,8 +186,7 @@ class MangaHere extends MProvider {
|
||||
}
|
||||
}
|
||||
}
|
||||
String deobfuscatedScript =
|
||||
evalJs(responseText.replaceAll("eval", ""));
|
||||
String deobfuscatedScript = evalJs(responseText.replaceAll("eval", ""));
|
||||
|
||||
int baseLinkStartPos = deobfuscatedScript.indexOf("pix=") + 5;
|
||||
int baseLinkEndPos =
|
||||
@@ -210,11 +205,6 @@ class MangaHere extends MProvider {
|
||||
|
||||
return pageUrls;
|
||||
}
|
||||
|
||||
@override
|
||||
Future<List<MVideo>> getVideoList(MSource source, String url) async {
|
||||
return [];
|
||||
}
|
||||
}
|
||||
|
||||
Map<String, String> getHeader(String url) {
|
||||
|
||||
Reference in New Issue
Block a user