Skip to content

Commit 3066e1f

Browse files
authored
Merge pull request #65 from EylinSir/main
新增漫画源,影视源
2 parents c24e27d + b161307 commit 3066e1f

File tree

11 files changed

+492
-4
lines changed

11 files changed

+492
-4
lines changed

json/App模板配置.json

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -162,8 +162,8 @@
162162
},
163163
"顾我": {
164164
"muban": "AppQiji",
165-
"host": "",
166-
"hosturl": "https://guwozj-1319364746.cos.ap-guangzhou.myqcloud.com/guwo.txt",
165+
"host": "http://117.50.204.35:520",
166+
"hosturl": "",
167167
"key": "ca94b06ca3c7d80e",
168168
"iv": "ca94b06ca3c7d80e",
169169
"verify": "true"

public/sub/order_common.example.html

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -12,6 +12,7 @@
1212
[官]
1313
[听]
1414
[书]
15+
[画]
1516
[搜]
1617
DS
1718
cat

spider/js/人人影视.js

Lines changed: 13 additions & 0 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

spider/js/光社漫画[画].js

Lines changed: 89 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,89 @@
1+
/*
2+
@header({
3+
searchable: 2,
4+
filterable: 0,
5+
quickSearch: 0,
6+
title: '光社漫画',
7+
author: 'EylinSir',
8+
'类型': '漫画',
9+
logo: 'https://m.g-mh.org/favicon.ico',
10+
lang: 'ds'
11+
})
12+
*/
13+
14+
var rule = {
15+
类型: '漫画',
16+
author: 'EylinSir',
17+
title: '光社漫画',
18+
host: 'https://m.g-mh.org',
19+
url: '/manga-genre/fyclass/page/fypage',
20+
searchUrl: '/s/**?page=fypage',
21+
logo: 'https://m.g-mh.org/favicon.ico',
22+
searchable: 2,
23+
quickSearch: 0,
24+
timeout: 5000,
25+
play_parse: true,
26+
class_name: '热门&国漫&韩漫&日漫&欧美&其他',
27+
class_url: 'hots&cn&kr&jp&ou-mei&qita',
28+
headers: {
29+
'User-Agent': 'PC_UA',
30+
'Referer': 'https://m.g-mh.org/'
31+
},
32+
33+
_parse: function(html) {
34+
return (html.match(/<a href=["']\/manga\/[^"']+["'][\s\S]+?<h3[\s\S]+?<\/h3>/g) || []).map(it => {
35+
let img = it.match(/src=["']([^"']+)["']/)[1];
36+
let descMatch = it.match(/<p class=["']slicardtitlep["'][\s\S]*?>([\s\S]*?)<\/p>/);
37+
let originalImgUrl = img.startsWith('http') ? img : this.host + img;
38+
let jpgImgUrl = 'https://wsrv.nl/?url=' + encodeURIComponent(originalImgUrl) + '&output=jpg';
39+
return {
40+
title: it.match(/<h3[^>]*>([\s\S]*?)<\/h3>/)[1].trim(),
41+
img: jpgImgUrl,
42+
url: it.match(/href=["']([^"']+)["']/)[1],
43+
desc: descMatch ? descMatch[1].trim() : ''
44+
};
45+
});
46+
},
47+
48+
一级: async function(tid, pg, filter, extend) {
49+
return setResult(this._parse(await request(this.input, { headers: this.headers })));
50+
},
51+
52+
推荐: async function(tid, pg, filter, extend) {
53+
return setResult(this._parse(await request(this.input, { headers: this.headers })));
54+
},
55+
56+
二级: async function(ids) {
57+
let html = await request(this.input, { headers: this.headers });
58+
let mid = (html.match(/data-mid=["'](\d+)["']/) || html.match(/mid\s*:\s*["']?(\d+)["']?/))[1];
59+
let json = JSON.parse(await request(`https://api-get-v3.mgsearcher.com/api/manga/get?mid=${mid}&mode=all`, { headers: this.headers }));
60+
let chapters = json.data.chapters || json.data.data.chapters;
61+
return {
62+
vod_id: ids[0],
63+
vod_name: pdfh(html, 'h1&&Text'),
64+
vod_pic: pdfh(html, '.rounded-lg img&&src'),
65+
vod_content: pdfh(html, '.text-medium&&Text'),
66+
type_name: "漫画",
67+
vod_play_from: "光社漫画",
68+
vod_play_url: chapters.map(ch => {
69+
return `${ch.attributes?.title || 'Chapter ' + ch.id}$https://api-get-v3.mgsearcher.com/api/chapter/getinfo?m=${mid}&c=${ch.id}`;
70+
}).join("#")
71+
};
72+
},
73+
74+
搜索: async function(wd, quick, pg) {
75+
return setResult(this._parse(await request(this.input, { headers: this.headers })));
76+
},
77+
78+
lazy: async function(flag, id, flags) {
79+
let data = JSON.parse(await request(id, { headers: this.headers }));
80+
let images = data.data.info.images.images.map(img =>
81+
img.url.startsWith('http') ? img.url : "https://f40-1-4.g-mh.online" + img.url
82+
);
83+
return {
84+
parse: 0,
85+
url: "pics://" + images.join("&&"),
86+
header: this.headers
87+
};
88+
}
89+
};

0 commit comments

Comments
 (0)