mgbuild 2.1.10 → 2.1.12
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/lib/index.d.ts +2 -0
- package/lib/index.js +1 -1
- package/lib/mgs/lt/api.d.ts +36 -0
- package/lib/mgs/lt/config.d.ts +6 -0
- package/lib/mgs/lt/headers.d.ts +57 -0
- package/lib/mgs/lt/index.d.ts +42 -0
- package/package.json +1 -1
|
@@ -0,0 +1,36 @@
|
|
|
1
|
+
type ResponseProps<T> = T & {
|
|
2
|
+
errors: any;
|
|
3
|
+
settings: {
|
|
4
|
+
url_cdn: string;
|
|
5
|
+
comic_slug: string;
|
|
6
|
+
};
|
|
7
|
+
};
|
|
8
|
+
export declare class LerToonsAPI {
|
|
9
|
+
static request<T>(version: string, endpoint: string): Promise<{
|
|
10
|
+
props: ResponseProps<T>;
|
|
11
|
+
}>;
|
|
12
|
+
static recents(version: string): Promise<{
|
|
13
|
+
code: string;
|
|
14
|
+
title: string;
|
|
15
|
+
cover: string;
|
|
16
|
+
chapters: number[];
|
|
17
|
+
}[]>;
|
|
18
|
+
static manga(version: string, manga_code: string): Promise<{
|
|
19
|
+
cover: string;
|
|
20
|
+
title: string;
|
|
21
|
+
al: string;
|
|
22
|
+
geek: string;
|
|
23
|
+
slug: string;
|
|
24
|
+
description: string;
|
|
25
|
+
tags: string[];
|
|
26
|
+
available: boolean;
|
|
27
|
+
chapters: {
|
|
28
|
+
title: string;
|
|
29
|
+
number: 26;
|
|
30
|
+
id: string;
|
|
31
|
+
geek: string;
|
|
32
|
+
}[];
|
|
33
|
+
}>;
|
|
34
|
+
static pages(version: string, chapter_id: string): Promise<string[]>;
|
|
35
|
+
}
|
|
36
|
+
export {};
|
|
@@ -0,0 +1,57 @@
|
|
|
1
|
+
declare const _default: {
|
|
2
|
+
default: {
|
|
3
|
+
accept: string;
|
|
4
|
+
"accept-language": string;
|
|
5
|
+
"cache-control": string;
|
|
6
|
+
priority: string;
|
|
7
|
+
pragma: string;
|
|
8
|
+
"sec-ch-ua": string;
|
|
9
|
+
"sec-ch-ua-mobile": string;
|
|
10
|
+
"sec-ch-ua-platform": string;
|
|
11
|
+
"sec-fetch-dest": string;
|
|
12
|
+
"sec-fetch-mode": string;
|
|
13
|
+
"sec-fetch-site": string;
|
|
14
|
+
"sec-fetch-user": string;
|
|
15
|
+
"sec-gpc": string;
|
|
16
|
+
"upgrade-insecure-requests": string;
|
|
17
|
+
"user-agent": string;
|
|
18
|
+
};
|
|
19
|
+
home: {
|
|
20
|
+
accept: string;
|
|
21
|
+
"accept-language": string;
|
|
22
|
+
"cache-control": string;
|
|
23
|
+
priority: string;
|
|
24
|
+
pragma: string;
|
|
25
|
+
"sec-ch-ua": string;
|
|
26
|
+
"sec-ch-ua-mobile": string;
|
|
27
|
+
"sec-ch-ua-platform": string;
|
|
28
|
+
"sec-fetch-dest": string;
|
|
29
|
+
"sec-fetch-mode": string;
|
|
30
|
+
"sec-fetch-site": string;
|
|
31
|
+
"sec-fetch-user": string;
|
|
32
|
+
"sec-gpc": string;
|
|
33
|
+
"upgrade-insecure-requests": string;
|
|
34
|
+
"user-agent": string;
|
|
35
|
+
};
|
|
36
|
+
XMLHttpRequest: {
|
|
37
|
+
accept: string;
|
|
38
|
+
"accept-language": string;
|
|
39
|
+
"cache-control": string;
|
|
40
|
+
"content-type": string;
|
|
41
|
+
pragma: string;
|
|
42
|
+
priority: string;
|
|
43
|
+
"sec-ch-ua": string;
|
|
44
|
+
"sec-ch-ua-mobile": string;
|
|
45
|
+
"sec-ch-ua-platform": string;
|
|
46
|
+
"sec-fetch-dest": string;
|
|
47
|
+
"sec-fetch-mode": string;
|
|
48
|
+
"sec-fetch-site": string;
|
|
49
|
+
"sec-fetch-user": string;
|
|
50
|
+
"sec-gpc": string;
|
|
51
|
+
"upgrade-insecure-requests": string;
|
|
52
|
+
"user-agent": string;
|
|
53
|
+
"x-requested-with": string;
|
|
54
|
+
"x-inertia": string;
|
|
55
|
+
};
|
|
56
|
+
};
|
|
57
|
+
export default _default;
|
|
@@ -0,0 +1,42 @@
|
|
|
1
|
+
type Log = {
|
|
2
|
+
type: "ping" | "error";
|
|
3
|
+
method: string;
|
|
4
|
+
url: string;
|
|
5
|
+
time: string;
|
|
6
|
+
};
|
|
7
|
+
type Logger = (log: Log) => any;
|
|
8
|
+
export declare class Scraper {
|
|
9
|
+
private logger?;
|
|
10
|
+
private state;
|
|
11
|
+
constructor(logger?: Logger);
|
|
12
|
+
manga: (manga_code: string) => Promise<{
|
|
13
|
+
cover: string;
|
|
14
|
+
title: string;
|
|
15
|
+
al: string;
|
|
16
|
+
geek: string;
|
|
17
|
+
slug: string;
|
|
18
|
+
description: string;
|
|
19
|
+
tags: string[];
|
|
20
|
+
available: boolean;
|
|
21
|
+
chapters: {
|
|
22
|
+
title: string;
|
|
23
|
+
number: 26;
|
|
24
|
+
id: string;
|
|
25
|
+
geek: string;
|
|
26
|
+
}[];
|
|
27
|
+
}>;
|
|
28
|
+
chapterById: (chapter_id: string | number) => Promise<{
|
|
29
|
+
pages: string[];
|
|
30
|
+
}>;
|
|
31
|
+
chapter: (manga_code: string, chapter_number: number) => Promise<{
|
|
32
|
+
pages: string[];
|
|
33
|
+
} | undefined>;
|
|
34
|
+
recents: () => Promise<{
|
|
35
|
+
code: string;
|
|
36
|
+
title: string;
|
|
37
|
+
cover: string;
|
|
38
|
+
chapters: number[];
|
|
39
|
+
}[]>;
|
|
40
|
+
private getVersion;
|
|
41
|
+
}
|
|
42
|
+
export {};
|