koishi-plugin-bilibili-notify 3.2.5-alpha.1 → 3.2.5-alpha.11
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.js +94890 -28
- package/lib/index.mjs +94886 -21
- package/package.json +6 -6
- package/readme.md +10 -0
- package/lib/assets/HYZhengYuan-75W-CAgMN3FH.ttf +0 -0
- package/lib/biliAPI-BB6Ih4EM.mjs +0 -659
- package/lib/biliAPI-GF2e2-2V.js +0 -664
- package/lib/biliAPI.d.mts +0 -82
- package/lib/biliAPI.d.ts +0 -82
- package/lib/biliAPI.js +0 -5
- package/lib/biliAPI.mjs +0 -4
- package/lib/blive-BBVUYbxX.js +0 -43
- package/lib/blive-CyC_0-9A.mjs +0 -37
- package/lib/blive.d.mts +0 -19
- package/lib/blive.d.ts +0 -19
- package/lib/blive.js +0 -4
- package/lib/blive.mjs +0 -3
- package/lib/chunk-CrFLpmCJ.js +0 -67
- package/lib/chunk-DBmNgn_A.mjs +0 -40
- package/lib/comRegister-CcqOpkwB.mjs +0 -1421
- package/lib/comRegister-t7UnYFig.js +0 -1426
- package/lib/comRegister.d.mts +0 -109
- package/lib/comRegister.d.ts +0 -109
- package/lib/comRegister.js +0 -6
- package/lib/comRegister.mjs +0 -5
- package/lib/database-4f9U--Ji.mjs +0 -20
- package/lib/database-Ct2yIdxk.js +0 -37
- package/lib/database-Do3O9MDA.d.mts +0 -18
- package/lib/database-KWDs372o.d.ts +0 -18
- package/lib/database.d.mts +0 -2
- package/lib/database.d.ts +0 -2
- package/lib/database.js +0 -5
- package/lib/database.mjs +0 -3
- package/lib/font/HYZhengYuan-75W.js +0 -5
- package/lib/font/HYZhengYuan-75W.mjs +0 -5
- package/lib/generateImg-E9JeFpQX.js +0 -92628
- package/lib/generateImg-zwzMYjw6.mjs +0 -92623
- package/lib/generateImg.d.mts +0 -65
- package/lib/generateImg.d.ts +0 -65
- package/lib/generateImg.js +0 -5
- package/lib/generateImg.mjs +0 -4
- package/lib/img/arrow.js +0 -5
- package/lib/img/arrow.mjs +0 -5
- package/lib/index-DeGUe4jM.d.mts +0 -265
- package/lib/index-MJKYbMf7.d.ts +0 -265
- package/lib/page/0.mjs +0 -0
- package/lib/type/index.d.mts +0 -2
- package/lib/type/index.d.ts +0 -2
- package/lib/type/index.js +0 -5
- package/lib/type/index.mjs +0 -3
- package/lib/type-C5ZxPrgY.mjs +0 -19
- package/lib/type-WjCy4YMc.js +0 -31
- package/lib/utils/index.d.mts +0 -15
- package/lib/utils/index.d.ts +0 -15
- package/lib/utils/index.js +0 -6
- package/lib/utils/index.mjs +0 -3
- package/lib/utils-BoaYrSvG.js +0 -79
- package/lib/utils-C95cnBJG.mjs +0 -61
- /package/lib/page/{0.js → 0.html} +0 -0
package/lib/comRegister.d.mts
DELETED
|
@@ -1,109 +0,0 @@
|
|
|
1
|
-
import { LoginBili } from "./database-Do3O9MDA.mjs";
|
|
2
|
-
import { LiveStatus, LiveType, MasterInfo, PushType, Result, SubItem, SubManager, Target } from "./index-DeGUe4jM.mjs";
|
|
3
|
-
import { Bot, Context, FlatPick, Logger, Schema } from "koishi";
|
|
4
|
-
import { CronJob } from "cron";
|
|
5
|
-
import { Notifier } from "@koishijs/plugin-notifier";
|
|
6
|
-
|
|
7
|
-
//#region src/comRegister.d.ts
|
|
8
|
-
declare class ComRegister {
|
|
9
|
-
static inject: string[];
|
|
10
|
-
qqRelatedBotList: Array<string>;
|
|
11
|
-
logger: Logger;
|
|
12
|
-
config: ComRegister.Config;
|
|
13
|
-
loginTimer: () => void;
|
|
14
|
-
num: number;
|
|
15
|
-
rebootCount: number;
|
|
16
|
-
subNotifier: Notifier;
|
|
17
|
-
ctx: Context;
|
|
18
|
-
subManager: SubManager;
|
|
19
|
-
dynamicTimelineManager: Map<string, number>;
|
|
20
|
-
liveStatusManager: Map<string, LiveStatus>;
|
|
21
|
-
loginDBData: FlatPick<LoginBili, "dynamic_group_id">;
|
|
22
|
-
privateBot: Bot<Context>;
|
|
23
|
-
dynamicJob: CronJob;
|
|
24
|
-
liveJob: CronJob;
|
|
25
|
-
constructor(ctx: Context, config: ComRegister.Config);
|
|
26
|
-
init(config: ComRegister.Config): Promise<void>;
|
|
27
|
-
initManager(): void;
|
|
28
|
-
getBot(pf: string, selfId?: string): Bot<Context, any>;
|
|
29
|
-
sendPrivateMsg(content: string): Promise<void>;
|
|
30
|
-
sendPrivateMsgAndRebootService(): Promise<void>;
|
|
31
|
-
sendPrivateMsgAndStopService(): Promise<void>;
|
|
32
|
-
sendMessageWithRetry(bot: Bot<Context>, channelId: string, content: any): Promise<void>;
|
|
33
|
-
getGroupsThatMeetCriteria(targets: Target, type: PushType): string[];
|
|
34
|
-
broadcastToTargets(targets: Target, content: any, type: PushType): Promise<void>;
|
|
35
|
-
dynamicDetect(): (...args: any[]) => void;
|
|
36
|
-
debug_dynamicDetect(): (...args: any[]) => void;
|
|
37
|
-
useMasterInfo(uid: string, masterInfo: MasterInfo, liveType: LiveType): Promise<MasterInfo>;
|
|
38
|
-
useLiveRoomInfo(roomId: string): Promise<any>;
|
|
39
|
-
sendLiveNotifyCard(liveType: LiveType, followerDisplay: string, liveInfo: {
|
|
40
|
-
liveRoomInfo: any;
|
|
41
|
-
masterInfo: MasterInfo;
|
|
42
|
-
cardStyle: SubItem["card"];
|
|
43
|
-
}, target: Target, liveNotifyMsg: string): Promise<void>;
|
|
44
|
-
liveDetectWithListener(roomId: string, target: Target, cardStyle: SubItem["card"]): Promise<void>;
|
|
45
|
-
liveDetectWithAPI(): Promise<(...args: any[]) => void>;
|
|
46
|
-
subShow(): string;
|
|
47
|
-
updateSubNotifier(): void;
|
|
48
|
-
checkIfLoginInfoIsLoaded(): Promise<unknown>;
|
|
49
|
-
subUserInBili(mid: string): Promise<Result>;
|
|
50
|
-
loadSubFromConfig(subs: ComRegister.Config["sub"]): Promise<Result>;
|
|
51
|
-
checkIfDynamicDetectIsNeeded(): void;
|
|
52
|
-
checkIfLiveDetectIsNeeded(): void;
|
|
53
|
-
enableDynamicDetect(): void;
|
|
54
|
-
enableLiveDetect(): Promise<void>;
|
|
55
|
-
checkIfIsLogin(): Promise<boolean>;
|
|
56
|
-
}
|
|
57
|
-
declare namespace ComRegister {
|
|
58
|
-
interface Config {
|
|
59
|
-
sub: Array<{
|
|
60
|
-
uid: string;
|
|
61
|
-
dynamic: boolean;
|
|
62
|
-
live: boolean;
|
|
63
|
-
target: Array<{
|
|
64
|
-
channelArr: Array<{
|
|
65
|
-
channelId: string;
|
|
66
|
-
dynamic: boolean;
|
|
67
|
-
live: boolean;
|
|
68
|
-
liveGuardBuy: boolean;
|
|
69
|
-
atAll: boolean;
|
|
70
|
-
bot: string;
|
|
71
|
-
}>;
|
|
72
|
-
platform: string;
|
|
73
|
-
}>;
|
|
74
|
-
card: {
|
|
75
|
-
enable: boolean;
|
|
76
|
-
cardColorStart: string;
|
|
77
|
-
cardColorEnd: string;
|
|
78
|
-
cardBasePlateColor: string;
|
|
79
|
-
cardBasePlateBorder: string;
|
|
80
|
-
};
|
|
81
|
-
}>;
|
|
82
|
-
master: {
|
|
83
|
-
enable: boolean;
|
|
84
|
-
platform: string;
|
|
85
|
-
masterAccount: string;
|
|
86
|
-
masterAccountGuildId: string;
|
|
87
|
-
};
|
|
88
|
-
liveDetectType: string;
|
|
89
|
-
restartPush: boolean;
|
|
90
|
-
pushTime: number;
|
|
91
|
-
pushImgsInDynamic: boolean;
|
|
92
|
-
liveLoopTime: number;
|
|
93
|
-
customLiveStart: string;
|
|
94
|
-
customLive: string;
|
|
95
|
-
customLiveEnd: string;
|
|
96
|
-
dynamicUrl: boolean;
|
|
97
|
-
dynamicVideoUrlToBV: boolean;
|
|
98
|
-
filter: {
|
|
99
|
-
enable: boolean;
|
|
100
|
-
notify: boolean;
|
|
101
|
-
regex: string;
|
|
102
|
-
keywords: Array<string>;
|
|
103
|
-
};
|
|
104
|
-
dynamicDebugMode: boolean;
|
|
105
|
-
}
|
|
106
|
-
const Config: Schema<Config>;
|
|
107
|
-
}
|
|
108
|
-
//#endregion
|
|
109
|
-
export { ComRegister as default };
|
package/lib/comRegister.d.ts
DELETED
|
@@ -1,109 +0,0 @@
|
|
|
1
|
-
import { LoginBili } from "./database-KWDs372o.js";
|
|
2
|
-
import { LiveStatus, LiveType, MasterInfo, PushType, Result, SubItem, SubManager, Target } from "./index-MJKYbMf7.js";
|
|
3
|
-
import { Bot, Context, FlatPick, Logger, Schema } from "koishi";
|
|
4
|
-
import { Notifier } from "@koishijs/plugin-notifier";
|
|
5
|
-
import { CronJob } from "cron";
|
|
6
|
-
|
|
7
|
-
//#region src/comRegister.d.ts
|
|
8
|
-
declare class ComRegister {
|
|
9
|
-
static inject: string[];
|
|
10
|
-
qqRelatedBotList: Array<string>;
|
|
11
|
-
logger: Logger;
|
|
12
|
-
config: ComRegister.Config;
|
|
13
|
-
loginTimer: () => void;
|
|
14
|
-
num: number;
|
|
15
|
-
rebootCount: number;
|
|
16
|
-
subNotifier: Notifier;
|
|
17
|
-
ctx: Context;
|
|
18
|
-
subManager: SubManager;
|
|
19
|
-
dynamicTimelineManager: Map<string, number>;
|
|
20
|
-
liveStatusManager: Map<string, LiveStatus>;
|
|
21
|
-
loginDBData: FlatPick<LoginBili, "dynamic_group_id">;
|
|
22
|
-
privateBot: Bot<Context>;
|
|
23
|
-
dynamicJob: CronJob;
|
|
24
|
-
liveJob: CronJob;
|
|
25
|
-
constructor(ctx: Context, config: ComRegister.Config);
|
|
26
|
-
init(config: ComRegister.Config): Promise<void>;
|
|
27
|
-
initManager(): void;
|
|
28
|
-
getBot(pf: string, selfId?: string): Bot<Context, any>;
|
|
29
|
-
sendPrivateMsg(content: string): Promise<void>;
|
|
30
|
-
sendPrivateMsgAndRebootService(): Promise<void>;
|
|
31
|
-
sendPrivateMsgAndStopService(): Promise<void>;
|
|
32
|
-
sendMessageWithRetry(bot: Bot<Context>, channelId: string, content: any): Promise<void>;
|
|
33
|
-
getGroupsThatMeetCriteria(targets: Target, type: PushType): string[];
|
|
34
|
-
broadcastToTargets(targets: Target, content: any, type: PushType): Promise<void>;
|
|
35
|
-
dynamicDetect(): (...args: any[]) => void;
|
|
36
|
-
debug_dynamicDetect(): (...args: any[]) => void;
|
|
37
|
-
useMasterInfo(uid: string, masterInfo: MasterInfo, liveType: LiveType): Promise<MasterInfo>;
|
|
38
|
-
useLiveRoomInfo(roomId: string): Promise<any>;
|
|
39
|
-
sendLiveNotifyCard(liveType: LiveType, followerDisplay: string, liveInfo: {
|
|
40
|
-
liveRoomInfo: any;
|
|
41
|
-
masterInfo: MasterInfo;
|
|
42
|
-
cardStyle: SubItem["card"];
|
|
43
|
-
}, target: Target, liveNotifyMsg: string): Promise<void>;
|
|
44
|
-
liveDetectWithListener(roomId: string, target: Target, cardStyle: SubItem["card"]): Promise<void>;
|
|
45
|
-
liveDetectWithAPI(): Promise<(...args: any[]) => void>;
|
|
46
|
-
subShow(): string;
|
|
47
|
-
updateSubNotifier(): void;
|
|
48
|
-
checkIfLoginInfoIsLoaded(): Promise<unknown>;
|
|
49
|
-
subUserInBili(mid: string): Promise<Result>;
|
|
50
|
-
loadSubFromConfig(subs: ComRegister.Config["sub"]): Promise<Result>;
|
|
51
|
-
checkIfDynamicDetectIsNeeded(): void;
|
|
52
|
-
checkIfLiveDetectIsNeeded(): void;
|
|
53
|
-
enableDynamicDetect(): void;
|
|
54
|
-
enableLiveDetect(): Promise<void>;
|
|
55
|
-
checkIfIsLogin(): Promise<boolean>;
|
|
56
|
-
}
|
|
57
|
-
declare namespace ComRegister {
|
|
58
|
-
interface Config {
|
|
59
|
-
sub: Array<{
|
|
60
|
-
uid: string;
|
|
61
|
-
dynamic: boolean;
|
|
62
|
-
live: boolean;
|
|
63
|
-
target: Array<{
|
|
64
|
-
channelArr: Array<{
|
|
65
|
-
channelId: string;
|
|
66
|
-
dynamic: boolean;
|
|
67
|
-
live: boolean;
|
|
68
|
-
liveGuardBuy: boolean;
|
|
69
|
-
atAll: boolean;
|
|
70
|
-
bot: string;
|
|
71
|
-
}>;
|
|
72
|
-
platform: string;
|
|
73
|
-
}>;
|
|
74
|
-
card: {
|
|
75
|
-
enable: boolean;
|
|
76
|
-
cardColorStart: string;
|
|
77
|
-
cardColorEnd: string;
|
|
78
|
-
cardBasePlateColor: string;
|
|
79
|
-
cardBasePlateBorder: string;
|
|
80
|
-
};
|
|
81
|
-
}>;
|
|
82
|
-
master: {
|
|
83
|
-
enable: boolean;
|
|
84
|
-
platform: string;
|
|
85
|
-
masterAccount: string;
|
|
86
|
-
masterAccountGuildId: string;
|
|
87
|
-
};
|
|
88
|
-
liveDetectType: string;
|
|
89
|
-
restartPush: boolean;
|
|
90
|
-
pushTime: number;
|
|
91
|
-
pushImgsInDynamic: boolean;
|
|
92
|
-
liveLoopTime: number;
|
|
93
|
-
customLiveStart: string;
|
|
94
|
-
customLive: string;
|
|
95
|
-
customLiveEnd: string;
|
|
96
|
-
dynamicUrl: boolean;
|
|
97
|
-
dynamicVideoUrlToBV: boolean;
|
|
98
|
-
filter: {
|
|
99
|
-
enable: boolean;
|
|
100
|
-
notify: boolean;
|
|
101
|
-
regex: string;
|
|
102
|
-
keywords: Array<string>;
|
|
103
|
-
};
|
|
104
|
-
dynamicDebugMode: boolean;
|
|
105
|
-
}
|
|
106
|
-
const Config: Schema<Config>;
|
|
107
|
-
}
|
|
108
|
-
//#endregion
|
|
109
|
-
export { ComRegister as default };
|
package/lib/comRegister.js
DELETED
package/lib/comRegister.mjs
DELETED
|
@@ -1,20 +0,0 @@
|
|
|
1
|
-
import { __export } from "./chunk-DBmNgn_A.mjs";
|
|
2
|
-
|
|
3
|
-
//#region src/database.ts
|
|
4
|
-
var database_exports = {};
|
|
5
|
-
__export(database_exports, {
|
|
6
|
-
apply: () => apply,
|
|
7
|
-
name: () => name
|
|
8
|
-
});
|
|
9
|
-
const name = "Database";
|
|
10
|
-
function apply(ctx) {
|
|
11
|
-
ctx.model.extend("loginBili", {
|
|
12
|
-
id: "unsigned",
|
|
13
|
-
bili_cookies: "text",
|
|
14
|
-
bili_refresh_token: "text",
|
|
15
|
-
dynamic_group_id: "string"
|
|
16
|
-
});
|
|
17
|
-
}
|
|
18
|
-
|
|
19
|
-
//#endregion
|
|
20
|
-
export { apply, database_exports, name };
|
package/lib/database-Ct2yIdxk.js
DELETED
|
@@ -1,37 +0,0 @@
|
|
|
1
|
-
const require_chunk = require('./chunk-CrFLpmCJ.js');
|
|
2
|
-
|
|
3
|
-
//#region src/database.ts
|
|
4
|
-
var database_exports = {};
|
|
5
|
-
require_chunk.__export(database_exports, {
|
|
6
|
-
apply: () => apply,
|
|
7
|
-
name: () => name
|
|
8
|
-
});
|
|
9
|
-
const name = "Database";
|
|
10
|
-
function apply(ctx) {
|
|
11
|
-
ctx.model.extend("loginBili", {
|
|
12
|
-
id: "unsigned",
|
|
13
|
-
bili_cookies: "text",
|
|
14
|
-
bili_refresh_token: "text",
|
|
15
|
-
dynamic_group_id: "string"
|
|
16
|
-
});
|
|
17
|
-
}
|
|
18
|
-
|
|
19
|
-
//#endregion
|
|
20
|
-
Object.defineProperty(exports, 'apply', {
|
|
21
|
-
enumerable: true,
|
|
22
|
-
get: function () {
|
|
23
|
-
return apply;
|
|
24
|
-
}
|
|
25
|
-
});
|
|
26
|
-
Object.defineProperty(exports, 'database_exports', {
|
|
27
|
-
enumerable: true,
|
|
28
|
-
get: function () {
|
|
29
|
-
return database_exports;
|
|
30
|
-
}
|
|
31
|
-
});
|
|
32
|
-
Object.defineProperty(exports, 'name', {
|
|
33
|
-
enumerable: true,
|
|
34
|
-
get: function () {
|
|
35
|
-
return name;
|
|
36
|
-
}
|
|
37
|
-
});
|
|
@@ -1,18 +0,0 @@
|
|
|
1
|
-
import { Context } from "koishi";
|
|
2
|
-
|
|
3
|
-
//#region src/database.d.ts
|
|
4
|
-
declare module "koishi" {
|
|
5
|
-
interface Tables {
|
|
6
|
-
loginBili: LoginBili;
|
|
7
|
-
}
|
|
8
|
-
}
|
|
9
|
-
interface LoginBili {
|
|
10
|
-
id: number;
|
|
11
|
-
bili_cookies: string;
|
|
12
|
-
bili_refresh_token: string;
|
|
13
|
-
dynamic_group_id: string;
|
|
14
|
-
}
|
|
15
|
-
declare const name = "Database";
|
|
16
|
-
declare function apply(ctx: Context): void;
|
|
17
|
-
//#endregion
|
|
18
|
-
export { LoginBili, apply, name };
|
|
@@ -1,18 +0,0 @@
|
|
|
1
|
-
import { Context } from "koishi";
|
|
2
|
-
|
|
3
|
-
//#region src/database.d.ts
|
|
4
|
-
declare module "koishi" {
|
|
5
|
-
interface Tables {
|
|
6
|
-
loginBili: LoginBili;
|
|
7
|
-
}
|
|
8
|
-
}
|
|
9
|
-
interface LoginBili {
|
|
10
|
-
id: number;
|
|
11
|
-
bili_cookies: string;
|
|
12
|
-
bili_refresh_token: string;
|
|
13
|
-
dynamic_group_id: string;
|
|
14
|
-
}
|
|
15
|
-
declare const name = "Database";
|
|
16
|
-
declare function apply(ctx: Context): void;
|
|
17
|
-
//#endregion
|
|
18
|
-
export { LoginBili, apply, name };
|
package/lib/database.d.mts
DELETED
package/lib/database.d.ts
DELETED
package/lib/database.js
DELETED
package/lib/database.mjs
DELETED