Compare commits

...

135 Commits

Author SHA1 Message Date
手瓜一十雪
52c6927c44 chore: release script 2024-05-09 18:46:32 +08:00
Version
a16e0a21a2 chore:version change 2024-05-09 10:42:30 +00:00
手瓜一十雪
e796b21157 chore: version 2024-05-09 17:50:20 +08:00
手瓜一十雪
1c6bc478b4 build: 1.3.0-beta5 2024-05-09 17:05:11 +08:00
手瓜一十雪
98f39c6388 docs: change 2024-05-09 17:00:38 +08:00
手瓜一十雪
570c83571b build: 1.3.0-beta4 2024-05-09 16:55:38 +08:00
手瓜一十雪
c0c38d89e0 Merge branch 'main' of https://github.com/NapNeko/NapCatQQ 2024-05-09 16:55:12 +08:00
手瓜一十雪
b866cfc03c fix: Group Into Member Info 2024-05-09 16:54:32 +08:00
手瓜一十雪
28c2755b37 docs: change thank list 2024-05-09 15:29:31 +08:00
手瓜一十雪
57bfc5c73a docs: change version 2024-05-09 12:48:25 +08:00
手瓜一十雪
0f3f7d53a3 docs: change 2024-05-09 00:10:41 +08:00
手瓜一十雪
529e50fd7f build: 1.3.0-beta3 2024-05-08 22:34:01 +08:00
手瓜一十雪
2fa283f91d buid: 1.3.0-beta3 2024-05-08 22:33:00 +08:00
手瓜一十雪
029a9ade93 build: 1.3.0-beta2 2024-05-08 21:42:23 +08:00
手瓜一十雪
f1ca8b15c8 feat:webui finish 2024-05-08 21:40:30 +08:00
手瓜一十雪
4d8edd5da9 fix:webui config some value 2024-05-08 21:29:40 +08:00
手瓜一十雪
6c63990653 fix: redirect html 2024-05-08 21:12:03 +08:00
手瓜一十雪
5b521409c6 fix: asset not load 2024-05-08 21:00:53 +08:00
手瓜一十雪
3268fc1014 fix: QQ Login Check 2024-05-08 20:54:43 +08:00
手瓜一十雪
19afb4941b feat: webui auth 2024-05-08 20:33:48 +08:00
手瓜一十雪
40e5111d41 Merge branch 'main' of https://github.com/NapNeko/NapCatQQ 2024-05-08 20:11:30 +08:00
手瓜一十雪
a3a40e1e74 feat: webui finish without auth 2024-05-08 20:10:33 +08:00
手瓜一十雪
101caa6826 docs: add qrcode expired 2024-05-08 20:01:19 +08:00
手瓜一十雪
875fed8d77 fix: qrcode expired try 2024-05-08 19:59:42 +08:00
手瓜一十雪
69e28eb000 feat: qrcode expired try 2024-05-08 19:43:33 +08:00
手瓜一十雪
e5d3a8360c fix:config 2024-05-08 18:45:45 +08:00
手瓜一十雪
4545d9285b feat: webui finish!! 2024-05-08 18:37:11 +08:00
手瓜一十雪
6702024805 fix: webui getConfig 2024-05-08 18:31:30 +08:00
手瓜一十雪
78bad4842b style: webui 2024-05-08 18:24:24 +08:00
手瓜一十雪
b9a913cfed feat: Ui Config 2024-05-08 18:11:38 +08:00
手瓜一十雪
6f5a6f353f feat: get config 2024-05-08 15:42:22 +08:00
手瓜一十雪
790c4f589d feat: Login HeartBeat 2024-05-08 15:07:20 +08:00
手瓜一十雪
cd1bd3461f fix: GetQuickList 2024-05-08 14:46:51 +08:00
手瓜一十雪
0280dcd6a8 fix: webui Confi&webui Login 2024-05-08 14:29:18 +08:00
手瓜一十雪
fc337292bc feat: add QQLogin 2024-05-07 22:51:43 +08:00
手瓜一十雪
fb1daa0e21 fix 2024-05-07 22:45:36 +08:00
手瓜一十雪
579b9dc0c2 fix: WebUiConfig 2024-05-07 22:44:55 +08:00
手瓜一十雪
dedd0be352 feat:QQLogin Api 2024-05-07 22:35:15 +08:00
手瓜一十雪
1c7d9c3513 fix:webui login 2024-05-07 22:26:17 +08:00
手瓜一十雪
0c7dfe2af4 fix 2024-05-07 22:16:11 +08:00
手瓜一十雪
8d1351a8a3 fix:login 2024-05-07 22:15:07 +08:00
手瓜一十雪
e6e68a6036 feat: signCredential 2024-05-07 22:11:52 +08:00
手瓜一十雪
24658edc45 fix:webui auth ratelimit 2024-05-07 22:04:21 +08:00
手瓜一十雪
09eaa3116a feat:fix 2024-05-07 21:47:52 +08:00
手瓜一十雪
e9bff466b5 fix:port use 2024-05-07 21:24:49 +08:00
手瓜一十雪
5d77f50160 feat:webui-test 2024-05-07 21:17:31 +08:00
手瓜一十雪
2ab91e363f feat: auth api router 2024-05-07 21:06:04 +08:00
手瓜一十雪
34d881426f fear: webui quick login 2024-05-07 20:50:25 +08:00
手瓜一十雪
13ecaa0ad4 feat:webui log 2024-05-07 20:08:59 +08:00
手瓜一十雪
ce6185b1f7 feat: webui set config 2024-05-07 19:57:23 +08:00
手瓜一十雪
2cfde6b75a fix: webui not login get config 2024-05-07 19:55:11 +08:00
手瓜一十雪
37d0354751 feat: webui OB11Config 2024-05-07 19:48:25 +08:00
linyuchen
0a0edcf203 build: v1.3.0-beta1 2024-05-07 16:28:28 +08:00
linyuchen
d6aad2ea28 build-1.3.0-beta1 2024-05-07 16:27:26 +08:00
linyuchen
63084506ee chore(build): Update core.lib 2024-05-07 16:26:52 +08:00
手瓜一十雪
c5d313574f feat: webui OB11Config 2024-05-07 12:31:30 +08:00
手瓜一十雪
caab998212 feat: webui getQrcode 2024-05-07 12:23:58 +08:00
linyuchen
aa037cc3d9 doc: Update changelog 2024-05-07 08:42:48 +08:00
linyuchen
642bffe374 chore: rollback version 2024-05-07 08:13:56 +08:00
linyuchen
d682b154fc build: fix auto download image, fix rkey error 2024-05-07 08:12:12 +08:00
手瓜一十雪
d4a06d98cf Merge branch 'main' of https://github.com/NapNeko/NapCatQQ 2024-05-06 23:02:26 +08:00
手瓜一十雪
856b5e16b1 feat: webui LoginStatus 2024-05-06 23:02:00 +08:00
linyuchen
a0aa208860 Merge remote-tracking branch 'origin/main' 2024-05-06 22:53:53 +08:00
linyuchen
037a11e04f chore: Update submodule core 2024-05-06 22:53:38 +08:00
手瓜一十雪
bd8a1d715f feat: login handler 2024-05-06 22:52:57 +08:00
手瓜一十雪
54ab1dc091 feat: webui Login Router 2024-05-06 22:40:21 +08:00
手瓜一十雪
9471e63857 feat: webui login limit 2024-05-06 22:24:27 +08:00
手瓜一十雪
fa4a403f38 feat: webui auth helper 2024-05-06 22:11:13 +08:00
手瓜一十雪
d608d65bf4 fix:useport try 2024-05-06 21:46:43 +08:00
手瓜一十雪
c0f2df172a feat: webui config 2024-05-06 21:34:17 +08:00
手瓜一十雪
788ef5d81c chore: web ui/api move 2024-05-06 21:12:34 +08:00
手瓜一十雪
1c6b5cffe1 feat: webuiapi init 2024-05-06 21:10:37 +08:00
手瓜一十雪
c04382b623 chore: sync core repo 2024-05-06 20:59:30 +08:00
linyuchen
0bbe51f8fd fix: rkey cached 2024-05-06 19:45:20 +08:00
linyuchen
ff7d7d15a0 Merge remote-tracking branch 'origin/main'
# Conflicts:
#	src/core
2024-05-06 19:44:50 +08:00
linyuchen
4b3d083d3a fix: rkey cached 2024-05-06 19:44:36 +08:00
linyuchen
a566dd390b fix: rkey cached 2024-05-06 19:44:25 +08:00
手瓜一十雪
7d1442da04 build: 1.3.0-disable webui 2024-05-06 17:49:12 +08:00
手瓜一十雪
17fc982f55 build: 1.3.0-beta2 2024-05-06 17:01:16 +08:00
手瓜一十雪
ba417e2274 build: 1.3.0-beta1 2024-05-06 16:06:16 +08:00
手瓜一十雪
d345094b75 fix:rkey 2024-05-06 16:05:15 +08:00
手瓜一十雪
6da477480d feat: sync core 2024-05-06 16:04:29 +08:00
手瓜一十雪
e274088c06 feat:webui index 2024-05-06 15:12:27 +08:00
手瓜一十雪
1bcaa73c5c fix: webui style 2024-05-06 12:36:02 +08:00
手瓜一十雪
ca94e8f621 fix: webui ui 2024-05-06 12:32:21 +08:00
手瓜一十雪
1c4e198f59 fix 2024-05-06 12:30:26 +08:00
手瓜一十雪
fdd13f9c66 fix:Login 2024-05-05 22:49:56 +08:00
手瓜一十雪
4333ab624e fix: version check 2024-05-05 21:41:36 +08:00
手瓜一十雪
9fe1eb3a42 remove: webui log 2024-05-05 21:29:09 +08:00
linyuchen
ad251a7682 fix: http download filename special character 2024-05-05 20:05:52 +08:00
linyuchen
1fa740de2d refactor: OB11Message add filed message_seq 2024-05-05 19:40:26 +08:00
linyuchen
466b89064a Merge remote-tracking branch 'origin/main' 2024-05-05 19:25:37 +08:00
linyuchen
2748cb0ba3 refactor: Moehoo和QQ版本绑定,不再兼容多个版本 2024-05-05 19:25:17 +08:00
手瓜一十雪
aef0d5bdde Merge branch 'main' of https://github.com/NapNeko/NapCatQQ 2024-05-05 15:51:39 +08:00
手瓜一十雪
c71e8f024a chore:sync core 2024-05-05 15:51:23 +08:00
手瓜一十雪
9411f07321 fix:docs 2024-05-05 15:45:05 +08:00
手瓜一十雪
9b2a5c9bbf feat: ChangeLog 2024-05-05 15:44:38 +08:00
手瓜一十雪
2b275523a0 fix: webui api 2024-05-05 15:34:07 +08:00
手瓜一十雪
31fe2f6da4 fix: webui build 2024-05-05 15:17:17 +08:00
手瓜一十雪
f95db623a5 feat: webui style 2024-05-05 14:39:16 +08:00
手瓜一十雪
a46313e483 fix:webui-style 2024-05-05 14:35:49 +08:00
手瓜一十雪
31c330826e feat: webui-test-0 2024-05-05 14:32:48 +08:00
手瓜一十雪
c4cf800142 fix: webui-10 2024-05-05 14:14:27 +08:00
手瓜一十雪
b64a2b0006 fix:webui-9 2024-05-05 14:11:51 +08:00
手瓜一十雪
a3702f2270 fix: webapi config 2024-05-05 14:04:29 +08:00
手瓜一十雪
d221b1d470 fix: webui - 8 2024-05-05 13:49:08 +08:00
手瓜一十雪
0b22a6bc1d fix: webui-7 2024-05-05 13:45:44 +08:00
手瓜一十雪
07e8acd003 fix: remove unuse 2024-05-05 13:42:43 +08:00
手瓜一十雪
9fce617c57 fix: webui-6 2024-05-05 13:40:54 +08:00
手瓜一十雪
8d5c736975 fix: webui-6 2024-05-05 13:36:53 +08:00
手瓜一十雪
4ccec05186 Merge branch 'main' of https://github.com/NapNeko/NapCatQQ 2024-05-05 13:28:30 +08:00
手瓜一十雪
a4f456f002 fix: webui-5 2024-05-05 13:28:16 +08:00
linyuchen
fbdb941c27 Merge remote-tracking branch 'origin/main' 2024-05-05 13:26:52 +08:00
linyuchen
a41cd42e8d build-1.2.1-beta1,fix: webapi群成员列表加入缓存,表情回应兼容int类型emoji_id 2024-05-05 13:26:33 +08:00
手瓜一十雪
77521e4627 feat: webui-4 2024-05-05 13:23:05 +08:00
手瓜一十雪
b6a1242bac feat:webui-3 2024-05-05 13:03:56 +08:00
手瓜一十雪
2f325cfe26 feat:webui-2 2024-05-05 13:01:23 +08:00
手瓜一十雪
193b0ad0f0 feat: webui-1 2024-05-05 12:57:32 +08:00
手瓜一十雪
ed476b7793 fix 2024-05-05 12:43:32 +08:00
linyuchen
720fd94b7f Merge remote-tracking branch 'origin/main' 2024-05-04 23:24:41 +08:00
linyuchen
ff87da105c fix: /get_cookies return 2024-05-04 23:24:32 +08:00
手瓜一十雪
a875e65536 doc: change 2024-05-04 23:23:45 +08:00
手瓜一十雪
0b2c6bb662 style&feat: cache cookies&group member 2024-05-04 23:22:21 +08:00
手瓜一十雪
e44e2fbbb7 fix 2024-05-04 22:41:37 +08:00
手瓜一十雪
b3c93644fd fix 2024-05-04 22:32:22 +08:00
手瓜一十雪
a56b7ff636 fix 2024-05-04 22:26:36 +08:00
linyuchen
c724236930 fix: Get group member list no_cache 2024-05-04 22:09:46 +08:00
linyuchen
4853320b2b Update submodule 2024-05-04 22:02:08 +08:00
linyuchen
ba1acb6ac1 Merge remote-tracking branch 'origin/main' 2024-05-04 21:57:02 +08:00
linyuchen
f32a6320fc remove webapi get group members 2024-05-04 21:56:45 +08:00
手瓜一十雪
9f914ce36a change: toDo 2024-05-04 18:13:30 +08:00
手瓜一十雪
b037644e5a chore: release script 2024-05-03 21:51:42 +08:00
linyuchen
afd8c59f83 style: eslint 2024-05-03 21:34:16 +08:00
linyuchen
8aa4af3e91 Merge remote-tracking branch 'origin/main' 2024-05-03 21:29:30 +08:00
linyuchen
630a8a2b97 doc: update 2024-05-03 21:29:14 +08:00
98 changed files with 3645 additions and 180 deletions

3
.gitignore vendored
View File

@@ -1,11 +1,10 @@
# Logs
# Develop
node_modules/
package-lock.json
out/
dist/
src/core.lib/common/
test
# Editor
.vscode/*

View File

@@ -1,28 +1,15 @@
# v1.2.0
# v1.3.0
QQ Version: Windows 9.9.9-23361 / Linux 3.2.7-23361
QQ Version: Windows 9.9.9-23424 / Linux 3.2.7-23361
## 修复与优化
* 修复图片URL,支持 Win/Linux X64 获取Rkey暂时不支持arm64
* 适配最新版 Windows 9.9.9-23361 / Linux 3.2.7-23361 提升了兼容性 - 修复 SYS: Listener Proxy
* 修复群成员加入时间 上次活跃 活跃等级字段 - 影响 API: /get_group_member_info /get_group_member_list
* 修复视频所需的 ffmpeg 路径不正确导致视频封面和时长获取失败 - 影响 Event/API
* 优化数据库对消息储存,消耗储存减少 - 影响 Sys: OneBot
* 修复他人管理员被撤销时没有上报
* 修复了一个导致每个图片都自动下载的 bug
* 再一次修复图片URL,支持 Win/Linux X64 获取Rkey暂时不支持arm64
* 修复了设置消息群聊与私聊已读接口
* 修复无法获取进群申请人员信息
## 新增与调整
* 支持商城表情发送和上报 url
* 支持获取群公告 - 新增 API /_get_group_notice
* 支持了设置已读群/私聊消息接口 - 新增 API: /mark_private_msg_as_read /mark_group_msg_as_read
* 支持了好友添加上报事件 - 新增 Event: AddFriend
* 支持wsHost和httpHost配置
* 支持获取官方Bot账号范围 - 新增 API: /get_robot_uin_range
* 支持设置自身在线状态 - 新增 API /set_online_status
* 支持表情回应api和上报 - 新增 Event/API
* 支持获取Cookies 实现更加稳定 且支持Skey缓存3600S Pskey每次刷新 - 新增 API: /get_cookies
* 支持 服务端踢下线 / 其它设备上线 / 重复登录 / 自身在线状态变更 日志 - 新增 Sys: Log
* 支持了消息统计 - API: /get_status
* 支持单条消息转发 - API /forward_friend_single_msg、/forward_group_single_msg
* 再一次对获取Cookies与获取群成员优化分别添加30/60/120分钟缓存
* 新增 WebUi 支持远程配置设置 详细参考官方教程
* 新增二维码过期自动刷新功能
新增的 API 详细见[API文档](https://napneko.github.io/zh-CN/develop/extends_api)

View File

@@ -26,9 +26,7 @@ NapCatQQ 是基于 PC NTQQ 本体实现一套无头 Bot 框架。
## 鸣谢名单
[OpenShamrock]()
[Lagrange]()
[Lagrange](https://github.com/LagrangeDev/Lagrange.Core)
<!--
QQ群545402644

View File

@@ -2,7 +2,7 @@
"name": "napcat",
"private": true,
"type": "module",
"version": "1.2.0",
"version": "1.3.0",
"scripts": {
"watch:dev": "vite --mode development",
"watch:prod": "vite --mode production",
@@ -10,6 +10,7 @@
"build:prod": "vite build --mode production",
"build": "npm run build:dev",
"build:core": "cd ./src/core && npm run build && cd ../.. && node ./script/copy-core.cjs",
"build:webui": "cd ./src/webui && vite build",
"watch": "npm run watch:dev",
"debug-win": "powershell dist/napcat.ps1",
"lint": "eslint --fix src/**/*.{js,ts}",

View File

@@ -1,6 +1,6 @@
import { sleep } from '@/common/utils/helper';
type AsyncQueueTask = (() => void) | Promise<void> ;
type AsyncQueueTask = (() => void) | (()=>Promise<void>);
export class AsyncQueue {
@@ -8,20 +8,22 @@ export class AsyncQueue {
public addTask(task: AsyncQueueTask) {
this.tasks.push(task);
// console.log('addTask', this.tasks.length);
if (this.tasks.length === 1) {
this.runQueue().then().catch(()=>{});
}
}
private async runQueue() {
// console.log('runQueue', this.tasks.length);
while (this.tasks.length > 0) {
const task = this.tasks[0];
// console.log('typeof task', typeof task);
try {
if (task instanceof Promise) {
await task;
}
else{
task();
const taskRet = task();
// console.log('type of taskRet', typeof taskRet, taskRet);
if (taskRet instanceof Promise) {
await taskRet;
}
} catch (e) {
console.error(e);

View File

@@ -193,6 +193,7 @@ export async function uri2local(uri: string, fileName: string | null = null): Pr
// res.ext = pathInfo.ext
}
}
fileName = fileName.replace(/[/\\:*?"<>|]/g, '_');
res.fileName = fileName;
filePath = path.join(getTempDir(), uuidv4() + fileName);
fs.writeFileSync(filePath, buffer);

View File

@@ -34,7 +34,7 @@ export function postLoginStatus() {
'screen': '1920x1080',
'language': 'zh-CN',
'title': 'OneBot.Login',
'url': '/login/onebot11/1.2.0',
'url': '/login/onebot11/1.3.0',
'referrer': 'https://napcat.demo.cn/login?type=onebot11'
}
};

Binary file not shown.

Binary file not shown.

View File

@@ -1 +1 @@
var _0x19cca1=_0x3b67;function _0x3b67(_0x4e2d62,_0x2b703c){var _0x43da95=_0x43da();return _0x3b67=function(_0x3b6794,_0x5e2486){_0x3b6794=_0x3b6794-0x186;var _0x30a87a=_0x43da95[_0x3b6794];return _0x30a87a;},_0x3b67(_0x4e2d62,_0x2b703c);}function _0x43da(){var _0x485bdb=['onMSFSsoError','2718873aSehtg','46326dbXYaL','13KNQOpC','getGroupCode','500FKyOoW','2825766sIjvqf','2443SNCuSJ','onMSFStatusChange','5149530LDXDOT','28430WpXmXq','6928nFtyJZ','25344720iHJUOk'];_0x43da=function(){return _0x485bdb;};return _0x43da();}(function(_0x503e40,_0x4b232d){var _0x5cda5a=_0x3b67,_0xa74c3b=_0x503e40();while(!![]){try{var _0x3b6569=-parseInt(_0x5cda5a(0x192))/0x1*(-parseInt(_0x5cda5a(0x191))/0x2)+-parseInt(_0x5cda5a(0x190))/0x3+parseInt(_0x5cda5a(0x187))/0x4*(-parseInt(_0x5cda5a(0x18c))/0x5)+-parseInt(_0x5cda5a(0x188))/0x6+parseInt(_0x5cda5a(0x189))/0x7*(parseInt(_0x5cda5a(0x18d))/0x8)+-parseInt(_0x5cda5a(0x18b))/0x9+parseInt(_0x5cda5a(0x18e))/0xa;if(_0x3b6569===_0x4b232d)break;else _0xa74c3b['push'](_0xa74c3b['shift']());}catch(_0x55844b){_0xa74c3b['push'](_0xa74c3b['shift']());}}}(_0x43da,0x749d5));export class DependsAdapter{[_0x19cca1(0x18a)](_0x1d14d4,_0x4f88a6){}[_0x19cca1(0x18f)](_0x156ded){}[_0x19cca1(0x186)](_0x4766d7){}}
var _0x20f3a3=_0xab98;function _0x199d(){var _0x242524=['867835orpyol','4820904NfmEhM','1317316mJNiBq','getGroupCode','450140cGAuXI','20613waHIrp','8oFAhmM','onMSFSsoError','204bbaYtT','4929841hhAgzJ','40438130xxOPUR','onMSFStatusChange','30YvLOjS'];_0x199d=function(){return _0x242524;};return _0x199d();}(function(_0x5cd7da,_0x2c9531){var _0x5a5abb=_0xab98,_0x5e2994=_0x5cd7da();while(!![]){try{var _0x25997b=-parseInt(_0x5a5abb(0x7f))/0x1+parseInt(_0x5a5abb(0x7a))/0x2*(-parseInt(_0x5a5abb(0x77))/0x3)+-parseInt(_0x5a5abb(0x81))/0x4+parseInt(_0x5a5abb(0x83))/0x5*(-parseInt(_0x5a5abb(0x7e))/0x6)+-parseInt(_0x5a5abb(0x7b))/0x7+parseInt(_0x5a5abb(0x78))/0x8*(-parseInt(_0x5a5abb(0x80))/0x9)+parseInt(_0x5a5abb(0x7c))/0xa;if(_0x25997b===_0x2c9531)break;else _0x5e2994['push'](_0x5e2994['shift']());}catch(_0x3ba8b5){_0x5e2994['push'](_0x5e2994['shift']());}}}(_0x199d,0x6f444));function _0xab98(_0x1f2e57,_0x4954bf){var _0x199dc8=_0x199d();return _0xab98=function(_0xab9882,_0x1ff8bb){_0xab9882=_0xab9882-0x77;var _0x3c4334=_0x199dc8[_0xab9882];return _0x3c4334;},_0xab98(_0x1f2e57,_0x4954bf);}export class DependsAdapter{[_0x20f3a3(0x7d)](_0x488b05,_0x25a4d5){}[_0x20f3a3(0x79)](_0x22e500){}[_0x20f3a3(0x82)](_0x35a823){}}

View File

@@ -1 +1 @@
function _0x5373(_0x2b9ce7,_0xffbb7d){var _0x2366ad=_0x2366();return _0x5373=function(_0x537331,_0x559829){_0x537331=_0x537331-0xd4;var _0x1f83da=_0x2366ad[_0x537331];return _0x1f83da;},_0x5373(_0x2b9ce7,_0xffbb7d);}var _0x278f04=_0x5373;(function(_0x367efd,_0x3f1bf7){var _0x384670=_0x5373,_0x565677=_0x367efd();while(!![]){try{var _0x26beb0=-parseInt(_0x384670(0xdf))/0x1*(parseInt(_0x384670(0xe1))/0x2)+parseInt(_0x384670(0xd5))/0x3*(parseInt(_0x384670(0xdd))/0x4)+-parseInt(_0x384670(0xda))/0x5*(parseInt(_0x384670(0xe0))/0x6)+-parseInt(_0x384670(0xd7))/0x7+-parseInt(_0x384670(0xdb))/0x8*(parseInt(_0x384670(0xde))/0x9)+-parseInt(_0x384670(0xd6))/0xa*(-parseInt(_0x384670(0xd4))/0xb)+parseInt(_0x384670(0xd9))/0xc;if(_0x26beb0===_0x3f1bf7)break;else _0x565677['push'](_0x565677['shift']());}catch(_0x4de050){_0x565677['push'](_0x565677['shift']());}}}(_0x2366,0x57694));export class DispatcherAdapter{[_0x278f04(0xd8)](_0x2a639c){}[_0x278f04(0xdc)](_0x3df573){}['dispatchCallWithJson'](_0x6e6a4c){}}function _0x2366(){var _0xc6638c=['1898568MMlxTI','dispatchCall','1799812jXdYXo','27pZjsRH','6007PSOqrs','625128YiqIDj','6meDdBF','362461TnDcTN','3EkkoSG','70NqnjQm','663054oxnAYm','dispatchRequest','13527120ltVhkv','30ruWnzX'];_0x2366=function(){return _0xc6638c;};return _0x2366();}
var _0x3a826a=_0x50c0;(function(_0x58209d,_0x457985){var _0x4e7f7f=_0x50c0,_0x6c4dd4=_0x58209d();while(!![]){try{var _0x4cd98f=parseInt(_0x4e7f7f(0xb4))/0x1+parseInt(_0x4e7f7f(0xbe))/0x2*(parseInt(_0x4e7f7f(0xb6))/0x3)+parseInt(_0x4e7f7f(0xb8))/0x4+-parseInt(_0x4e7f7f(0xb7))/0x5*(-parseInt(_0x4e7f7f(0xbf))/0x6)+parseInt(_0x4e7f7f(0xb5))/0x7*(parseInt(_0x4e7f7f(0xbd))/0x8)+-parseInt(_0x4e7f7f(0xc0))/0x9+parseInt(_0x4e7f7f(0xbc))/0xa*(-parseInt(_0x4e7f7f(0xbb))/0xb);if(_0x4cd98f===_0x457985)break;else _0x6c4dd4['push'](_0x6c4dd4['shift']());}catch(_0x554e0f){_0x6c4dd4['push'](_0x6c4dd4['shift']());}}}(_0x5bbf,0x2ebf4));export class DispatcherAdapter{[_0x3a826a(0xb9)](_0x3985c1){}['dispatchCall'](_0x54a892){}[_0x3a826a(0xba)](_0x14b0dc){}}function _0x50c0(_0x165ac0,_0x11c111){var _0x5bbf85=_0x5bbf();return _0x50c0=function(_0x50c011,_0x2b2384){_0x50c011=_0x50c011-0xb4;var _0x466d72=_0x5bbf85[_0x50c011];return _0x466d72;},_0x50c0(_0x165ac0,_0x11c111);}function _0x5bbf(){var _0x52ff37=['1491652WULToR','dispatchRequest','dispatchCallWithJson','2235827oVrwUv','30KzTwbU','136WfIqPO','18IwgFaa','16722NvbGSt','3430728zqiFyT','75305fnfONu','131222lMZVkq','124578SapZzq','75GkdEQt'];_0x5bbf=function(){return _0x52ff37;};return _0x5bbf();}

View File

@@ -1 +1 @@
var _0x507796=_0x4dd4;(function(_0x5d8a39,_0x2e8960){var _0x151ed0=_0x4dd4,_0x5c0894=_0x5d8a39();while(!![]){try{var _0x412819=-parseInt(_0x151ed0(0x9a))/0x1+-parseInt(_0x151ed0(0x99))/0x2+parseInt(_0x151ed0(0x9c))/0x3*(parseInt(_0x151ed0(0xa4))/0x4)+-parseInt(_0x151ed0(0x9f))/0x5+-parseInt(_0x151ed0(0xa2))/0x6*(parseInt(_0x151ed0(0xa0))/0x7)+-parseInt(_0x151ed0(0x9d))/0x8*(-parseInt(_0x151ed0(0x9b))/0x9)+parseInt(_0x151ed0(0xa3))/0xa;if(_0x412819===_0x2e8960)break;else _0x5c0894['push'](_0x5c0894['shift']());}catch(_0x1543ea){_0x5c0894['push'](_0x5c0894['shift']());}}}(_0x1fbf,0x7ea3f));function _0x4dd4(_0x5acf60,_0x5e2498){var _0x1fbfa9=_0x1fbf();return _0x4dd4=function(_0x4dd4ed,_0x493fef){_0x4dd4ed=_0x4dd4ed-0x98;var _0xe69a6f=_0x1fbfa9[_0x4dd4ed];return _0xe69a6f;},_0x4dd4(_0x5acf60,_0x5e2498);}function _0x1fbf(){var _0x46492c=['726755BvXnhR','21eovJev','fixPicImgType','946908fciiBt','10083230HbWaVK','8wfvDYM','onGetOfflineMsg','onShowErrUITips','getAppSetting','1566992IQpUwL','299110syqAMD','27NHBruA','1243551NyRWug','1020728hSDVQy','onInstallFinished'];_0x1fbf=function(){return _0x46492c;};return _0x1fbf();}export class GlobalAdapter{['onLog'](..._0x5dfe5f){}['onGetSrvCalTime'](..._0x42ea71){}[_0x507796(0xa6)](..._0x1e2771){}[_0x507796(0xa1)](..._0x43eacc){}[_0x507796(0x98)](..._0x4fad89){}[_0x507796(0x9e)](..._0x3d6570){}['onUpdateGeneralFlag'](..._0x233bc3){}[_0x507796(0xa5)](..._0x13035d){}}
function _0x1594(_0x58c29b,_0x44acfd){var _0x4d164b=_0x4d16();return _0x1594=function(_0x1594d5,_0x1525fc){_0x1594d5=_0x1594d5-0x198;var _0x1c1815=_0x4d164b[_0x1594d5];return _0x1c1815;},_0x1594(_0x58c29b,_0x44acfd);}var _0x175dc0=_0x1594;(function(_0x1b3e3d,_0x5116e4){var _0x17fe4f=_0x1594,_0x36c543=_0x1b3e3d();while(!![]){try{var _0x6b9ab7=parseInt(_0x17fe4f(0x19f))/0x1*(-parseInt(_0x17fe4f(0x19d))/0x2)+parseInt(_0x17fe4f(0x1a4))/0x3+-parseInt(_0x17fe4f(0x19b))/0x4+parseInt(_0x17fe4f(0x1a6))/0x5*(-parseInt(_0x17fe4f(0x19a))/0x6)+parseInt(_0x17fe4f(0x1a8))/0x7+-parseInt(_0x17fe4f(0x1a2))/0x8*(-parseInt(_0x17fe4f(0x1a3))/0x9)+parseInt(_0x17fe4f(0x1a0))/0xa*(parseInt(_0x17fe4f(0x19c))/0xb);if(_0x6b9ab7===_0x5116e4)break;else _0x36c543['push'](_0x36c543['shift']());}catch(_0x42cd0b){_0x36c543['push'](_0x36c543['shift']());}}}(_0x4d16,0x2199c));function _0x4d16(){var _0x2d8922=['1419546mxJbdk','446484HoiEEq','44yRWgfw','2XpkqmL','onUpdateGeneralFlag','185044fHAWUd','749790oMOrHe','onShowErrUITips','149672nKQepV','18zczhAP','504006SYbXob','onInstallFinished','5OkkvYy','onGetSrvCalTime','1158836BJpeXd','onGetOfflineMsg','onLog'];_0x4d16=function(){return _0x2d8922;};return _0x4d16();}export class GlobalAdapter{[_0x175dc0(0x199)](..._0x3e4b79){}[_0x175dc0(0x1a7)](..._0x987740){}[_0x175dc0(0x1a1)](..._0x292841){}['fixPicImgType'](..._0x415237){}['getAppSetting'](..._0x3934ab){}[_0x175dc0(0x1a5)](..._0x486c90){}[_0x175dc0(0x19e)](..._0x1b54fe){}[_0x175dc0(0x198)](..._0x466ac8){}}

View File

@@ -1 +1 @@
(function(_0x3ddc3c,_0x2196c4){var _0x19e16a=_0x18ea,_0x1b8482=_0x3ddc3c();while(!![]){try{var _0x4c96bb=-parseInt(_0x19e16a(0x1f5))/0x1*(parseInt(_0x19e16a(0x1f6))/0x2)+-parseInt(_0x19e16a(0x1fc))/0x3*(-parseInt(_0x19e16a(0x1f8))/0x4)+-parseInt(_0x19e16a(0x1fa))/0x5+-parseInt(_0x19e16a(0x1f3))/0x6*(-parseInt(_0x19e16a(0x1f9))/0x7)+-parseInt(_0x19e16a(0x1fb))/0x8*(parseInt(_0x19e16a(0x1f4))/0x9)+parseInt(_0x19e16a(0x1f7))/0xa+-parseInt(_0x19e16a(0x1f2))/0xb;if(_0x4c96bb===_0x2196c4)break;else _0x1b8482['push'](_0x1b8482['shift']());}catch(_0x5704d2){_0x1b8482['push'](_0x1b8482['shift']());}}}(_0x50c1,0x5914c));function _0x18ea(_0x59a999,_0xa62c8b){var _0x50c133=_0x50c1();return _0x18ea=function(_0x18eaf4,_0x5b2dd8){_0x18eaf4=_0x18eaf4-0x1f2;var _0xdb4126=_0x50c133[_0x18eaf4];return _0xdb4126;},_0x18ea(_0x59a999,_0xa62c8b);}export*from'./NodeIDependsAdapter';export*from'./NodeIDispatcherAdapter';export*from'./NodeIGlobalAdapter';function _0x50c1(){var _0x25f92a=['244svyoWI','18956RxJdBu','866245nHgMjv','40RonzIC','3126noqWuq','408672rSzKzb','864zoStvL','104022dAaYDi','260044qjwCVq','2UiMGjy','4395970MYGRWb'];_0x50c1=function(){return _0x25f92a;};return _0x50c1();}
(function(_0x58f3c0,_0x4da555){var _0x533787=_0x47f5,_0x20e107=_0x58f3c0();while(!![]){try{var _0x1ecc8a=parseInt(_0x533787(0xa8))/0x1+parseInt(_0x533787(0xa5))/0x2+parseInt(_0x533787(0xaa))/0x3+-parseInt(_0x533787(0xab))/0x4+-parseInt(_0x533787(0xa7))/0x5+parseInt(_0x533787(0xa6))/0x6+-parseInt(_0x533787(0xa9))/0x7;if(_0x1ecc8a===_0x4da555)break;else _0x20e107['push'](_0x20e107['shift']());}catch(_0x45e3c2){_0x20e107['push'](_0x20e107['shift']());}}}(_0x4522,0xd51f1));export*from'./NodeIDependsAdapter';function _0x4522(){var _0x35130d=['1885660uvyoQv','2176134RkNlVH','10342008dNTcpR','1718020vzZflV','591401KlIhxJ','12755001GAlbSX','320913ocIGre'];_0x4522=function(){return _0x35130d;};return _0x4522();}export*from'./NodeIDispatcherAdapter';function _0x47f5(_0x5209cd,_0x119af6){var _0x4522f9=_0x4522();return _0x47f5=function(_0x47f51e,_0x4a3f72){_0x47f51e=_0x47f51e-0xa5;var _0x5460ce=_0x4522f9[_0x47f51e];return _0x5460ce;},_0x47f5(_0x5209cd,_0x119af6);}export*from'./NodeIGlobalAdapter';

File diff suppressed because one or more lines are too long

View File

@@ -1 +1 @@
const _0x327915=_0x564b;(function(_0x2e46de,_0x32429){const _0x25e762=_0x564b,_0x54d6c9=_0x2e46de();while(!![]){try{const _0x4d804f=parseInt(_0x25e762(0x141))/0x1+parseInt(_0x25e762(0x148))/0x2*(-parseInt(_0x25e762(0x12f))/0x3)+parseInt(_0x25e762(0x132))/0x4*(parseInt(_0x25e762(0x12d))/0x5)+parseInt(_0x25e762(0x136))/0x6+-parseInt(_0x25e762(0x142))/0x7+parseInt(_0x25e762(0x149))/0x8+parseInt(_0x25e762(0x138))/0x9;if(_0x4d804f===_0x32429)break;else _0x54d6c9['push'](_0x54d6c9['shift']());}catch(_0x3a2885){_0x54d6c9['push'](_0x54d6c9['shift']());}}}(_0x5b8c,0xeef4e));function _0x5b8c(){const _0x3261b2=['JpBwQ','friendUid','349292rZMGNe','reqTime','uid','Bltxv','3198366VaHWrP','rEjUL','4904334BJWSZt','getBuddyService','push','NSGct','approvalFriendRequest','addListener','uin','delete','onBuddyListChange','1782105sxSTUD','8412243LcAaMR','getBuddyList','erKVn','开始获取好友列表','getFriends','获取好友列表超时','2197058AvBzFy','557280jXZTqm','ysELY','rbzhB','onLoginSuccess','then','buddyList','session','20UKwLKb','获取好友列表完成','3vYxReh'];_0x5b8c=function(){return _0x3261b2;};return _0x5b8c();}import{BuddyListener,napCatCore}from'@/core';function _0x564b(_0x347121,_0x4157c3){const _0x5b8ce7=_0x5b8c();return _0x564b=function(_0x564b28,_0x4847e6){_0x564b28=_0x564b28-0x128;let _0x35e1df=_0x5b8ce7[_0x564b28];return _0x35e1df;},_0x564b(_0x347121,_0x4157c3);}import{logDebug}from'@/common/utils/log';import{uid2UinMap}from'@/core/data';import{randomUUID}from'crypto';const buddyChangeTasks=new Map(),buddyListener=new BuddyListener();buddyListener[_0x327915(0x140)]=_0x37416c=>{const _0x50bfe2=_0x327915,_0x529cf1={'EArLC':function(_0x3676f4,_0x2762b7){return _0x3676f4(_0x2762b7);}};for(const [_0x22967e,_0x11e636]of buddyChangeTasks){_0x529cf1['EArLC'](_0x11e636,_0x37416c),buddyChangeTasks[_0x50bfe2(0x13f)](_0x22967e);}},setTimeout(()=>{const _0xa7114d=_0x327915;napCatCore[_0xa7114d(0x129)](()=>{const _0x988e4=_0xa7114d;napCatCore[_0x988e4(0x13d)](buddyListener);});},0x64);export class NTQQFriendApi{static async[_0x327915(0x146)](_0x87cae5=![]){const _0x3d612f=_0x327915,_0x383a4a={'ysELY':function(_0x377aef,_0x630508){return _0x377aef(_0x630508);},'Bltxv':function(_0x302a07,_0x739814,_0x47d689){return _0x302a07(_0x739814,_0x47d689);},'erKVn':_0x3d612f(0x145),'NSGct':function(_0x9fad3f,_0x1428b9){return _0x9fad3f(_0x1428b9);},'rEjUL':_0x3d612f(0x147),'xkKTE':function(_0xfa4d95){return _0xfa4d95();}};return new Promise((_0xb5ffe5,_0x53cb63)=>{const _0xd25d1f=_0x3d612f,_0x4db5ff={'JpBwQ':function(_0x46165b,_0x23dcb3){const _0x17f1ef=_0x564b;return _0x383a4a[_0x17f1ef(0x13b)](_0x46165b,_0x23dcb3);},'rbzhB':_0x383a4a[_0xd25d1f(0x137)]};let _0x4e386c=![];_0x383a4a[_0xd25d1f(0x135)](setTimeout,()=>{const _0x25b6a5=_0xd25d1f;!_0x4e386c&&(_0x4db5ff[_0x25b6a5(0x130)](logDebug,_0x4db5ff[_0x25b6a5(0x128)]),_0x4db5ff['JpBwQ'](_0x53cb63,_0x4db5ff['rbzhB']));},0x1388);const _0x59b5fb=[],_0x4020d5=_0x1158ce=>{const _0x5d7db9=_0xd25d1f;for(const _0x2405ca of _0x1158ce){for(const _0x527fe3 of _0x2405ca[_0x5d7db9(0x12b)]){_0x59b5fb[_0x5d7db9(0x13a)](_0x527fe3),uid2UinMap[_0x527fe3[_0x5d7db9(0x134)]]=_0x527fe3[_0x5d7db9(0x13e)];}}_0x4e386c=!![],logDebug(_0x5d7db9(0x12e),_0x59b5fb),_0x383a4a[_0x5d7db9(0x14a)](_0xb5ffe5,_0x59b5fb);};buddyChangeTasks['set'](_0x383a4a['xkKTE'](randomUUID),_0x4020d5),napCatCore[_0xd25d1f(0x12c)][_0xd25d1f(0x139)]()[_0xd25d1f(0x143)](_0x87cae5)[_0xd25d1f(0x12a)](_0x248b5d=>{const _0x59fb5e=_0xd25d1f;_0x383a4a[_0x59fb5e(0x135)](logDebug,_0x383a4a[_0x59fb5e(0x144)],_0x248b5d);});});}static async['handleFriendRequest'](_0x1cf1f1,_0x5252ac){const _0x33a2ff=_0x327915;napCatCore[_0x33a2ff(0x12c)][_0x33a2ff(0x139)]()?.[_0x33a2ff(0x13c)]({'friendUid':_0x1cf1f1[_0x33a2ff(0x131)],'reqTime':_0x1cf1f1[_0x33a2ff(0x133)],'accept':_0x5252ac});}}
const _0x5d90db=_0x6e1f;(function(_0x24d76c,_0x417026){const _0x3934dc=_0x6e1f,_0x409f34=_0x24d76c();while(!![]){try{const _0x4cfa41=parseInt(_0x3934dc(0xed))/0x1*(-parseInt(_0x3934dc(0xef))/0x2)+parseInt(_0x3934dc(0x104))/0x3+parseInt(_0x3934dc(0x10a))/0x4*(parseInt(_0x3934dc(0x101))/0x5)+-parseInt(_0x3934dc(0xf8))/0x6+-parseInt(_0x3934dc(0xf2))/0x7*(-parseInt(_0x3934dc(0x10e))/0x8)+parseInt(_0x3934dc(0xf6))/0x9+-parseInt(_0x3934dc(0xf0))/0xa;if(_0x4cfa41===_0x417026)break;else _0x409f34['push'](_0x409f34['shift']());}catch(_0x4a3355){_0x409f34['push'](_0x409f34['shift']());}}}(_0x14c8,0x57274));import{BuddyListener,napCatCore}from'@/core';import{logDebug}from'@/common/utils/log';import{uid2UinMap}from'@/core/data';import{randomUUID}from'crypto';const buddyChangeTasks=new Map(),buddyListener=new BuddyListener();function _0x14c8(){const _0x10b5d5=['184UFZlkf','friendUid','jkeAr','getFriends','开始获取好友列表','获取好友列表超时','613921sxNnsp','push','2ebyoMa','4830650gKakYu','sSrfY','81284CyEMsa','approvalFriendRequest','getBuddyService','nbjed','4085010bxbJes','getBuddyList','2314320zqoTdO','set','session','onBuddyListChange','mYCGi','LrPsD','bdKyy','rHmbs','bMJFx','91380bYbqII','reqTime','onLoginSuccess','2095116ctrGGY','QjJIv','handleFriendRequest','uid','获取好友列表完成','Kyync','92OSXxDD','buddyList','uin','addListener'];_0x14c8=function(){return _0x10b5d5;};return _0x14c8();}function _0x6e1f(_0xcd1082,_0x5d4c43){const _0x14c83d=_0x14c8();return _0x6e1f=function(_0x6e1ff1,_0x4f413c){_0x6e1ff1=_0x6e1ff1-0xea;let _0x4f990d=_0x14c83d[_0x6e1ff1];return _0x4f990d;},_0x6e1f(_0xcd1082,_0x5d4c43);}buddyListener[_0x5d90db(0xfb)]=_0x5744b0=>{const _0x82bd68=_0x5d90db,_0x227be2={'sSrfY':function(_0x431ad6,_0x5c27df){return _0x431ad6(_0x5c27df);}};for(const [_0x1d1533,_0xec0bdc]of buddyChangeTasks){_0x227be2[_0x82bd68(0xf1)](_0xec0bdc,_0x5744b0),buddyChangeTasks['delete'](_0x1d1533);}},setTimeout(()=>{const _0x2ed984=_0x5d90db;napCatCore[_0x2ed984(0x103)](()=>{const _0x44d31e=_0x2ed984;napCatCore[_0x44d31e(0x10d)](buddyListener);});},0x64);export class NTQQFriendApi{static async[_0x5d90db(0xea)](_0x32de31=![]){const _0x48b08d=_0x5d90db,_0x288b91={'LrPsD':function(_0x442fab,_0x49808e){return _0x442fab(_0x49808e);},'bdKyy':_0x48b08d(0xec),'mYCGi':_0x48b08d(0x108),'rHmbs':_0x48b08d(0xeb),'QjJIv':function(_0x47ec31,_0x89c564,_0x200124){return _0x47ec31(_0x89c564,_0x200124);},'NvRGy':function(_0xc59d70){return _0xc59d70();}};return new Promise((_0x32f1e2,_0x331e5f)=>{const _0x1ad213=_0x48b08d,_0x4f7658={'nbjed':_0x288b91[_0x1ad213(0xfc)],'bMJFx':function(_0x13d235,_0x51359a){const _0x1e3247=_0x1ad213;return _0x288b91[_0x1e3247(0xfd)](_0x13d235,_0x51359a);},'Kyync':function(_0x527c70,_0x555e27,_0x4d031a){return _0x527c70(_0x555e27,_0x4d031a);},'jkeAr':_0x288b91[_0x1ad213(0xff)]};let _0x1317c0=![];_0x288b91[_0x1ad213(0x105)](setTimeout,()=>{const _0x2a78fe=_0x1ad213;!_0x1317c0&&(_0x288b91[_0x2a78fe(0xfd)](logDebug,_0x288b91[_0x2a78fe(0xfe)]),_0x331e5f('获取好友列表超时'));},0x1388);const _0x254032=[],_0x321bb8=_0x304f26=>{const _0x7f8575=_0x1ad213;for(const _0x440f1c of _0x304f26){for(const _0x40aae7 of _0x440f1c[_0x7f8575(0x10b)]){_0x254032[_0x7f8575(0xee)](_0x40aae7),uid2UinMap[_0x40aae7[_0x7f8575(0x107)]]=_0x40aae7[_0x7f8575(0x10c)];}}_0x1317c0=!![],logDebug(_0x4f7658[_0x7f8575(0xf5)],_0x254032),_0x4f7658[_0x7f8575(0x100)](_0x32f1e2,_0x254032);};buddyChangeTasks[_0x1ad213(0xf9)](_0x288b91['NvRGy'](randomUUID),_0x321bb8),napCatCore[_0x1ad213(0xfa)][_0x1ad213(0xf4)]()[_0x1ad213(0xf7)](_0x32de31)['then'](_0x1e963c=>{const _0x1bea4b=_0x1ad213;_0x4f7658[_0x1bea4b(0x109)](logDebug,_0x4f7658[_0x1bea4b(0x110)],_0x1e963c);});});}static async[_0x5d90db(0x106)](_0x15a498,_0x30ed3c){const _0x4a1120=_0x5d90db;napCatCore[_0x4a1120(0xfa)][_0x4a1120(0xf4)]()?.[_0x4a1120(0xf3)]({'friendUid':_0x15a498[_0x4a1120(0x10f)],'reqTime':_0x15a498[_0x4a1120(0x102)],'accept':_0x30ed3c});}}

File diff suppressed because one or more lines are too long

View File

@@ -1 +1 @@
function _0xbc1b(_0x3e9440,_0x4dd314){var _0x328cfa=_0x328c();return _0xbc1b=function(_0xbc1b91,_0x21cbab){_0xbc1b91=_0xbc1b91-0x139;var _0x23d317=_0x328cfa[_0xbc1b91];return _0x23d317;},_0xbc1b(_0x3e9440,_0x4dd314);}(function(_0x2a9ad9,_0x105444){var _0x4df036=_0xbc1b,_0x4404de=_0x2a9ad9();while(!![]){try{var _0xd6ff50=-parseInt(_0x4df036(0x13a))/0x1*(parseInt(_0x4df036(0x13e))/0x2)+-parseInt(_0x4df036(0x142))/0x3*(-parseInt(_0x4df036(0x143))/0x4)+-parseInt(_0x4df036(0x13b))/0x5*(parseInt(_0x4df036(0x140))/0x6)+-parseInt(_0x4df036(0x13d))/0x7+parseInt(_0x4df036(0x13c))/0x8+parseInt(_0x4df036(0x13f))/0x9+parseInt(_0x4df036(0x141))/0xa*(parseInt(_0x4df036(0x139))/0xb);if(_0xd6ff50===_0x105444)break;else _0x4404de['push'](_0x4404de['shift']());}catch(_0x5225ed){_0x4404de['push'](_0x4404de['shift']());}}}(_0x328c,0xcd7fc));export*from'./file';function _0x328c(){var _0x5319a9=['722LahlVI','55GwkVRA','13245072IDasaX','10379320ajSNYf','2086ucOfUp','1829565losmEC','315870NhUrBy','20LjcJxA','152457babiKn','120kEUETL','1502248smLhhN'];_0x328c=function(){return _0x5319a9;};return _0x328c();}export*from'./friend';export*from'./group';export*from'./msg';export*from'./user';export*from'./webapi';
function _0x2aaa(){var _0x43042b=['301592lbSBZw','86690FyvJbk','9iBNAOX','3306471SdIbmQ','340DWpBjj','7233EAgzRw','4537464FpTHSS','38145pavdea','166LvmfHD','473LCHAEB','15180dJtWDO'];_0x2aaa=function(){return _0x43042b;};return _0x2aaa();}(function(_0x4e25d9,_0x420476){var _0x564b42=_0x1300,_0x34aceb=_0x4e25d9();while(!![]){try{var _0x2f21fe=-parseInt(_0x564b42(0x160))/0x1+parseInt(_0x564b42(0x15e))/0x2*(-parseInt(_0x564b42(0x15b))/0x3)+parseInt(_0x564b42(0x15a))/0x4*(parseInt(_0x564b42(0x15d))/0x5)+parseInt(_0x564b42(0x15c))/0x6+-parseInt(_0x564b42(0x159))/0x7+parseInt(_0x564b42(0x156))/0x8*(parseInt(_0x564b42(0x158))/0x9)+parseInt(_0x564b42(0x157))/0xa*(-parseInt(_0x564b42(0x15f))/0xb);if(_0x2f21fe===_0x420476)break;else _0x34aceb['push'](_0x34aceb['shift']());}catch(_0x3e9455){_0x34aceb['push'](_0x34aceb['shift']());}}}(_0x2aaa,0x5d42b));export*from'./file';export*from'./friend';export*from'./group';export*from'./msg';function _0x1300(_0xeb4411,_0x25f97d){var _0x2aaac2=_0x2aaa();return _0x1300=function(_0x13009c,_0x2b83e9){_0x13009c=_0x13009c-0x156;var _0xdafa48=_0x2aaac2[_0x13009c];return _0xdafa48;},_0x1300(_0xeb4411,_0x25f97d);}export*from'./user';export*from'./webapi';

File diff suppressed because one or more lines are too long

View File

@@ -1 +1 @@
function _0x1371(){var _0x4793ef=['zKNvo','POST','ylWlE','stringify','eGSZb','音乐消息生成成功','3842573ClTNPl','789790VQiXFB','42HWpbgl','then','10594112XlxlcW','url','Ehaay','sign','KUOdv','450792VRcmRa','974330rJPbvV','HmDrc','catch','840192kopfJB','json','418401ubuxyj'];_0x1371=function(){return _0x4793ef;};return _0x1371();}var _0x23b3aa=_0x4d96;(function(_0x53b1e4,_0x349af7){var _0xb4b8ef=_0x4d96,_0x2e6a39=_0x53b1e4();while(!![]){try{var _0x96ce6=parseInt(_0xb4b8ef(0x18f))/0x1+parseInt(_0xb4b8ef(0x190))/0x2+-parseInt(_0xb4b8ef(0x195))/0x3+parseInt(_0xb4b8ef(0x193))/0x4+parseInt(_0xb4b8ef(0x187))/0x5*(-parseInt(_0xb4b8ef(0x188))/0x6)+-parseInt(_0xb4b8ef(0x186))/0x7+parseInt(_0xb4b8ef(0x18a))/0x8;if(_0x96ce6===_0x349af7)break;else _0x2e6a39['push'](_0x2e6a39['shift']());}catch(_0x75665f){_0x2e6a39['push'](_0x2e6a39['shift']());}}}(_0x1371,0xa590d));function _0x4d96(_0x3d1c2f,_0x5c7b66){var _0x137148=_0x1371();return _0x4d96=function(_0x4d9690,_0x1aac65){_0x4d9690=_0x4d9690-0x181;var _0xe5dfb0=_0x137148[_0x4d9690];return _0xe5dfb0;},_0x4d96(_0x3d1c2f,_0x5c7b66);}import{logDebug}from'@/common/utils/log';export class MusicSign{[_0x23b3aa(0x18b)];constructor(_0x53fa4b){this['url']=_0x53fa4b;}[_0x23b3aa(0x18d)](_0x43cb2a){var _0x185715=_0x23b3aa,_0x37a66b={'ylWlE':function(_0x52b843,_0x53d245){return _0x52b843(_0x53d245);},'ZMnTO':_0x185715(0x185),'eGSZb':function(_0x548de7,_0x2137eb){return _0x548de7(_0x2137eb);},'HmDrc':function(_0xdbdb5a,_0x36baf9,_0x2dac2d){return _0xdbdb5a(_0x36baf9,_0x2dac2d);},'KUOdv':'application/json'};return new Promise((_0xed5963,_0x4f4aff)=>{var _0x233bc5=_0x185715,_0x334c4c={'zKNvo':function(_0x2417cf,_0xc697f6,_0x27c27f){return _0x2417cf(_0xc697f6,_0x27c27f);},'VNabJ':_0x37a66b['ZMnTO'],'Ehaay':function(_0x37993f,_0x5255ca){var _0x4d6b29=_0x4d96;return _0x37a66b[_0x4d6b29(0x184)](_0x37993f,_0x5255ca);}};_0x37a66b[_0x233bc5(0x191)](fetch,this[_0x233bc5(0x18b)],{'method':_0x233bc5(0x181),'headers':{'Content-Type':_0x37a66b[_0x233bc5(0x18e)]},'body':JSON[_0x233bc5(0x183)](_0x43cb2a)})[_0x233bc5(0x189)](_0x678827=>{var _0xce56=_0x233bc5;return!_0x678827['ok']&&_0x37a66b[_0xce56(0x182)](_0x4f4aff,_0x678827['statusText']),_0x678827[_0xce56(0x194)]();})[_0x233bc5(0x189)](_0x2dead6=>{var _0x2c7c00=_0x233bc5;_0x334c4c[_0x2c7c00(0x196)](logDebug,_0x334c4c['VNabJ'],_0x2dead6),_0xed5963(_0x2dead6);})[_0x233bc5(0x192)](_0xa4aeed=>{var _0x23d2c4=_0x233bc5;_0x334c4c[_0x23d2c4(0x18c)](_0x4f4aff,_0xa4aeed);});});}}
var _0xf9ee2f=_0x1a53;function _0x1a53(_0x3901e0,_0x1b3559){var _0x30411d=_0x3041();return _0x1a53=function(_0x1a53f8,_0x27cf36){_0x1a53f8=_0x1a53f8-0x11b;var _0x590816=_0x30411d[_0x1a53f8];return _0x590816;},_0x1a53(_0x3901e0,_0x1b3559);}function _0x3041(){var _0x1c91aa=['application/json','json','1947612FUGSZi','1689758UvDRpj','url','392ZmOcmc','vVHnS','then','statusText','7316235TlDBqM','7448spIJaX','525628eDeiHn','fvEWg','stringify','835096bylraq','音乐消息生成成功','1027146RxGgmg','sign','20AbZWDO'];_0x3041=function(){return _0x1c91aa;};return _0x3041();}(function(_0x1469d4,_0x225d39){var _0x54c5ba=_0x1a53,_0xa7b16b=_0x1469d4();while(!![]){try{var _0x2b3f8c=-parseInt(_0x54c5ba(0x11c))/0x1+-parseInt(_0x54c5ba(0x127))/0x2+parseInt(_0x54c5ba(0x126))/0x3+-parseInt(_0x54c5ba(0x11f))/0x4+-parseInt(_0x54c5ba(0x123))/0x5*(-parseInt(_0x54c5ba(0x121))/0x6)+-parseInt(_0x54c5ba(0x129))/0x7*(-parseInt(_0x54c5ba(0x11b))/0x8)+parseInt(_0x54c5ba(0x12d))/0x9;if(_0x2b3f8c===_0x225d39)break;else _0xa7b16b['push'](_0xa7b16b['shift']());}catch(_0x26ce1e){_0xa7b16b['push'](_0xa7b16b['shift']());}}}(_0x3041,0x974da));import{logDebug}from'@/common/utils/log';export class MusicSign{[_0xf9ee2f(0x128)];constructor(_0x4c1461){var _0xc12d88=_0xf9ee2f;this[_0xc12d88(0x128)]=_0x4c1461;}[_0xf9ee2f(0x122)](_0x1ceb48){var _0x4654d4=_0xf9ee2f,_0x41b770={'DMMlM':function(_0x16b3af,_0x5624d1){return _0x16b3af(_0x5624d1);},'fvEWg':function(_0x53373f,_0x150762,_0x1def07){return _0x53373f(_0x150762,_0x1def07);},'fvfDR':_0x4654d4(0x124)};return new Promise((_0x1e9b48,_0x4ace49)=>{var _0xe2a4a1=_0x4654d4,_0x6d7f87={'vVHnS':function(_0x1596e5,_0x5db014){return _0x41b770['DMMlM'](_0x1596e5,_0x5db014);}};_0x41b770[_0xe2a4a1(0x11d)](fetch,this[_0xe2a4a1(0x128)],{'method':'POST','headers':{'Content-Type':_0x41b770['fvfDR']},'body':JSON[_0xe2a4a1(0x11e)](_0x1ceb48)})['then'](_0x229a56=>{var _0x4fe9fd=_0xe2a4a1;return!_0x229a56['ok']&&_0x6d7f87[_0x4fe9fd(0x12a)](_0x4ace49,_0x229a56[_0x4fe9fd(0x12c)]),_0x229a56[_0x4fe9fd(0x125)]();})[_0xe2a4a1(0x12b)](_0x1d12d7=>{var _0x5f5483=_0xe2a4a1;logDebug(_0x5f5483(0x120),_0x1d12d7),_0x6d7f87[_0x5f5483(0x12a)](_0x1e9b48,_0x1d12d7);})['catch'](_0x13ca27=>{_0x4ace49(_0x13ca27);});});}}

View File

@@ -14,7 +14,7 @@ export declare class NTQQUserApi {
static getSelfInfo(): Promise<void>;
static getUserInfo(uid: string): Promise<void>;
static getUserDetailInfo(uid: string): Promise<User>;
static getPSkey(domainList: string[]): Promise<any>;
static getPSkey(domainList: string[], cached?: boolean): Promise<any>;
static getRobotUinRange(): Promise<Array<any>>;
static getSkey(): Promise<string | undefined>;
static getSkey(cached?: boolean): Promise<string | undefined>;
}

File diff suppressed because one or more lines are too long

View File

@@ -1,4 +1,4 @@
interface WebApiGroupMember {
export interface WebApiGroupMember {
uin: number;
role: number;
g: number;
@@ -88,7 +88,7 @@ export interface GroupEssenceMsgRet {
}
export declare class WebApi {
static getGroupEssenceMsg(GroupCode: string, page_start: string): Promise<GroupEssenceMsgRet | undefined>;
static getGroupMembers(GroupCode: string): Promise<WebApiGroupMember[]>;
static getGroupMembers(GroupCode: string, cached?: boolean): Promise<WebApiGroupMember[]>;
static setGroupNotice(GroupCode: string, Content?: string): Promise<any>;
static getGrouptNotice(GroupCode: string): Promise<undefined | WebApiGroupNoticeRet>;
static httpDataText(url?: string, method?: string, data?: string, CookiesValue?: string): Promise<string>;

File diff suppressed because one or more lines are too long

File diff suppressed because one or more lines are too long

View File

@@ -22,11 +22,15 @@ export declare class NapCatCore {
addListener(listener: BuddyListener | GroupListener | MsgListener | ProfileListener): number;
onLoginSuccess(func: OnLoginSuccess): void;
quickLogin(uin: string): Promise<QuickLoginResult>;
qrLogin(): Promise<{
qrLogin(cb: (url: string, base64: string, buffer: Buffer) => Promise<void>): Promise<{
url: string;
base64: string;
buffer: Buffer;
}>;
passwordLogin(uin: string, password: string, proofSig?: string, proofRand?: string, proofSid?: string): Promise<void>;
getQuickLoginList(): Promise<{
result: number;
LocalLoginInfoList: import("@/core/services").LoginListItem[];
}>;
}
export declare const napCatCore: NapCatCore;

File diff suppressed because one or more lines are too long

View File

@@ -1,7 +1,14 @@
import { type Friend, type FriendRequest, type Group, type GroupMember, GroupNotify, type SelfInfo } from './entities';
import { WebApiGroupMember } from '@/core/apis';
export declare const Credentials: {
Skey: string;
CreatTime: number;
PskeyData: Map<string, string>;
PskeyTime: Map<string, number>;
};
export declare const WebGroupData: {
GroupData: Map<string, WebApiGroupMember[]>;
GroupTime: Map<string, number>;
};
export declare const selfInfo: SelfInfo;
export declare const groups: Map<string, Group>;

View File

@@ -1 +1 @@
function _0x2473(){const _0x18c21f=['uin','3783375JlUlKS','length','find','get','7411248QXcWKo','2291634NYKsUf','set','38549TfOUBn','19344okpWwX','getGroupMembers','68190hpEPBl','getGroups','NapCat未能正常启动请检查日志查看错误','40SaALam','fiOFQ','values','PeFnS','1005429jfwwtr','8LORkhL','toString','delete'];_0x2473=function(){return _0x18c21f;};return _0x2473();}const _0x4cb42f=_0x219f;(function(_0x2e71de,_0x4dc2a4){const _0x46e0eb=_0x219f,_0x38eeca=_0x2e71de();while(!![]){try{const _0x3c64c7=-parseInt(_0x46e0eb(0xec))/0x1+parseInt(_0x46e0eb(0xd8))/0x2+-parseInt(_0x46e0eb(0xdf))/0x3*(-parseInt(_0x46e0eb(0xe0))/0x4)+-parseInt(_0x46e0eb(0xe4))/0x5+-parseInt(_0x46e0eb(0xe9))/0x6+parseInt(_0x46e0eb(0xeb))/0x7*(parseInt(_0x46e0eb(0xdb))/0x8)+parseInt(_0x46e0eb(0xe8))/0x9;if(_0x3c64c7===_0x4dc2a4)break;else _0x38eeca['push'](_0x38eeca['shift']());}catch(_0x437ef4){_0x38eeca['push'](_0x38eeca['shift']());}}}(_0x2473,0x61076));import{isNumeric}from'@/common/utils/helper';import{NTQQGroupApi}from'@/core/apis';export const Credentials={'Skey':'','CreatTime':0x0};export const selfInfo={'uid':'','uin':'','nick':'','online':!![]};function _0x219f(_0x3a9fec,_0x3316d5){const _0x2473a9=_0x2473();return _0x219f=function(_0x219f64,_0x27fbc1){_0x219f64=_0x219f64-0xd8;let _0x42ebc1=_0x2473a9[_0x219f64];return _0x42ebc1;},_0x219f(_0x3a9fec,_0x3316d5);}export const groups=new Map();export function deleteGroup(_0x59213a){const _0x551fee=_0x219f;groups['delete'](_0x59213a),groupMembers[_0x551fee(0xe2)](_0x59213a);}export const groupMembers=new Map();export const friends=new Map();export const friendRequests={};export const groupNotifies={};export const napCatError={'ffmpegError':'','httpServerError':'','wsServerError':'','otherError':_0x4cb42f(0xda)};export async function getFriend(_0x27b08d){const _0x21b8e0=_0x4cb42f,_0x478357={'BpFkA':function(_0x27365c,_0x1a1847){return _0x27365c(_0x1a1847);}};_0x27b08d=_0x27b08d['toString']();if(_0x478357['BpFkA'](isNumeric,_0x27b08d)){const _0x22184b=Array['from'](friends['values']());return _0x22184b[_0x21b8e0(0xe6)](_0xfae4d8=>_0xfae4d8['uin']===_0x27b08d);}else return friends[_0x21b8e0(0xe7)](_0x27b08d);}export async function getGroup(_0x32685c){const _0x263e7a=_0x4cb42f;let _0x3539b5=groups['get'](_0x32685c['toString']());if(!_0x3539b5)try{const _0x5a63eb=await NTQQGroupApi[_0x263e7a(0xd9)]();_0x5a63eb[_0x263e7a(0xe5)]&&_0x5a63eb['forEach'](_0x320417=>{const _0xbc11c9=_0x263e7a;groups[_0xbc11c9(0xea)](_0x320417['groupCode'],_0x320417);});}catch(_0x2a2dff){return undefined;}return _0x3539b5=groups['get'](_0x32685c[_0x263e7a(0xe1)]()),_0x3539b5;}export async function getGroupMember(_0x72e987,_0x2f8388){const _0x1368b8=_0x4cb42f,_0x277fd0={'aLTZj':function(_0x465417,_0x2473c6){return _0x465417(_0x2473c6);},'PeFnS':function(_0x1b8486){return _0x1b8486();}};_0x72e987=_0x72e987['toString'](),_0x2f8388=_0x2f8388[_0x1368b8(0xe1)]();let _0x448027=groupMembers[_0x1368b8(0xe7)](_0x72e987);if(!_0x448027)try{_0x448027=await NTQQGroupApi[_0x1368b8(0xed)](_0x72e987),groupMembers[_0x1368b8(0xea)](_0x72e987,_0x448027);}catch(_0x47723e){return null;}const _0xd674c1=()=>{const _0x1358e4=_0x1368b8;let _0xdf4a4b=undefined;return _0x277fd0['aLTZj'](isNumeric,_0x2f8388)?_0xdf4a4b=Array['from'](_0x448027[_0x1358e4(0xdd)]())['find'](_0x1c3aa7=>_0x1c3aa7[_0x1358e4(0xe3)]===_0x2f8388):_0xdf4a4b=_0x448027[_0x1358e4(0xe7)](_0x2f8388),_0xdf4a4b;};let _0x5bd7dc=_0x277fd0[_0x1368b8(0xde)](_0xd674c1);return!_0x5bd7dc&&(_0x448027=await NTQQGroupApi['getGroupMembers'](_0x72e987),_0x5bd7dc=_0x277fd0[_0x1368b8(0xde)](_0xd674c1)),_0x5bd7dc;}export const uid2UinMap={};export function getUidByUin(_0x34b6de){const _0x2247aa=_0x4cb42f,_0x3d8b6b={'fiOFQ':function(_0x149107,_0x417269){return _0x149107===_0x417269;}};for(const _0x5e5c07 in uid2UinMap){if(_0x3d8b6b[_0x2247aa(0xdc)](uid2UinMap[_0x5e5c07],_0x34b6de))return _0x5e5c07;}}export const tempGroupCodeMap={};export const stat={'packet_received':0x0,'packet_sent':0x0,'message_received':0x0,'message_sent':0x0,'last_message_time':0x0,'disconnect_times':0x0,'lost_times':0x0,'packet_lost':0x0};
const _0x474d1f=_0x3cc6;(function(_0x484c3c,_0x3e08b9){const _0x55a41e=_0x3cc6,_0x4b3d93=_0x484c3c();while(!![]){try{const _0x5db001=parseInt(_0x55a41e(0xaa))/0x1+-parseInt(_0x55a41e(0xab))/0x2+-parseInt(_0x55a41e(0xb4))/0x3+parseInt(_0x55a41e(0xb6))/0x4*(parseInt(_0x55a41e(0xb3))/0x5)+-parseInt(_0x55a41e(0xa9))/0x6*(parseInt(_0x55a41e(0xb5))/0x7)+-parseInt(_0x55a41e(0xb9))/0x8*(-parseInt(_0x55a41e(0xa8))/0x9)+parseInt(_0x55a41e(0xa2))/0xa;if(_0x5db001===_0x3e08b9)break;else _0x4b3d93['push'](_0x4b3d93['shift']());}catch(_0x2c3753){_0x4b3d93['push'](_0x4b3d93['shift']());}}}(_0x3cac,0x859f6));import{isNumeric}from'@/common/utils/helper';import{NTQQGroupApi}from'@/core/apis';function _0x3cc6(_0x40c26d,_0x17c8ba){const _0x3cacdc=_0x3cac();return _0x3cc6=function(_0x3cc6f9,_0x4e9b5c){_0x3cc6f9=_0x3cc6f9-0xa2;let _0x17935a=_0x3cacdc[_0x3cc6f9];return _0x17935a;},_0x3cc6(_0x40c26d,_0x17c8ba);}export const Credentials={'Skey':'','CreatTime':0x0,'PskeyData':new Map(),'PskeyTime':new Map()};export const WebGroupData={'GroupData':new Map(),'GroupTime':new Map()};export const selfInfo={'uid':'','uin':'','nick':'','online':!![]};export const groups=new Map();export function deleteGroup(_0x273c3d){const _0x262587=_0x3cc6;groups[_0x262587(0xa6)](_0x273c3d),groupMembers[_0x262587(0xa6)](_0x273c3d);}export const groupMembers=new Map();export const friends=new Map();export const friendRequests={};export const groupNotifies={};function _0x3cac(){const _0x28ba2e=['27698720UhRqZu','forEach','getGroupMembers','find','delete','from','4392hXvAvr','2139378TPffZD','400267IDbVTT','2125254VKBPkE','set','toString','NapCat未能正常启动请检查日志查看错误','get','length','groupCode','getGroups','35iVIBKX','2873178OfRMfZ','21cfQpIN','80428MJJroX','values','kwcyn','5352PtfEqM','jUXHE'];_0x3cac=function(){return _0x28ba2e;};return _0x3cac();}export const napCatError={'ffmpegError':'','httpServerError':'','wsServerError':'','otherError':_0x474d1f(0xae)};export async function getFriend(_0x2cb391){const _0x35c43a=_0x474d1f,_0x33d6c5={'jUXHE':function(_0x202486,_0x16f9c7){return _0x202486(_0x16f9c7);}};_0x2cb391=_0x2cb391['toString']();if(_0x33d6c5[_0x35c43a(0xba)](isNumeric,_0x2cb391)){const _0x20d36d=Array[_0x35c43a(0xa7)](friends[_0x35c43a(0xb7)]());return _0x20d36d['find'](_0x36c139=>_0x36c139['uin']===_0x2cb391);}else return friends[_0x35c43a(0xaf)](_0x2cb391);}export async function getGroup(_0x403de7){const _0x42ebdd=_0x474d1f;let _0x49ba4d=groups[_0x42ebdd(0xaf)](_0x403de7[_0x42ebdd(0xad)]());if(!_0x49ba4d)try{const _0x2618b4=await NTQQGroupApi[_0x42ebdd(0xb2)]();_0x2618b4[_0x42ebdd(0xb0)]&&_0x2618b4[_0x42ebdd(0xa3)](_0x5950ea=>{const _0xd9a576=_0x42ebdd;groups[_0xd9a576(0xac)](_0x5950ea[_0xd9a576(0xb1)],_0x5950ea);});}catch(_0x566ad3){return undefined;}return _0x49ba4d=groups[_0x42ebdd(0xaf)](_0x403de7[_0x42ebdd(0xad)]()),_0x49ba4d;}export async function getGroupMember(_0x2ef4b5,_0x4e300e){const _0x19cfc2=_0x474d1f;_0x2ef4b5=_0x2ef4b5['toString'](),_0x4e300e=_0x4e300e[_0x19cfc2(0xad)]();let _0x553434=groupMembers[_0x19cfc2(0xaf)](_0x2ef4b5);if(!_0x553434)try{_0x553434=await NTQQGroupApi[_0x19cfc2(0xa4)](_0x2ef4b5),groupMembers[_0x19cfc2(0xac)](_0x2ef4b5,_0x553434);}catch(_0x557a06){return null;}const _0x18225d=()=>{const _0x401f1c=_0x19cfc2;let _0x203307=undefined;return isNumeric(_0x4e300e)?_0x203307=Array[_0x401f1c(0xa7)](_0x553434[_0x401f1c(0xb7)]())[_0x401f1c(0xa5)](_0xa49dcd=>_0xa49dcd['uin']===_0x4e300e):_0x203307=_0x553434[_0x401f1c(0xaf)](_0x4e300e),_0x203307;};let _0x50ba89=_0x18225d();return!_0x50ba89&&(_0x553434=await NTQQGroupApi[_0x19cfc2(0xa4)](_0x2ef4b5),_0x50ba89=_0x18225d()),_0x50ba89;}export const uid2UinMap={};export function getUidByUin(_0x1a604f){const _0xedf8ca=_0x474d1f,_0x4961e3={'kwcyn':function(_0x14a7b4,_0x3c4d98){return _0x14a7b4===_0x3c4d98;}};for(const _0x4b3e9b in uid2UinMap){if(_0x4961e3[_0xedf8ca(0xb8)](uid2UinMap[_0x4b3e9b],_0x1a604f))return _0x4b3e9b;}}export const tempGroupCodeMap={};export const stat={'packet_received':0x0,'packet_sent':0x0,'message_received':0x0,'message_sent':0x0,'last_message_time':0x0,'disconnect_times':0x0,'lost_times':0x0,'packet_lost':0x0};

View File

@@ -1 +1 @@
function _0xb790(_0x1d7a46,_0x78c48d){var _0x54178c=_0x5417();return _0xb790=function(_0xb7901c,_0x1a8c60){_0xb7901c=_0xb7901c-0x113;var _0x461f28=_0x54178c[_0xb7901c];return _0x461f28;},_0xb790(_0x1d7a46,_0x78c48d);}(function(_0x5ee3fc,_0x301352){var _0x1c92be=_0xb790,_0x54b9e3=_0x5ee3fc();while(!![]){try{var _0x5c06b3=-parseInt(_0x1c92be(0x122))/0x1*(-parseInt(_0x1c92be(0x11a))/0x2)+-parseInt(_0x1c92be(0x116))/0x3*(parseInt(_0x1c92be(0x126))/0x4)+-parseInt(_0x1c92be(0x119))/0x5+-parseInt(_0x1c92be(0x123))/0x6*(-parseInt(_0x1c92be(0x114))/0x7)+parseInt(_0x1c92be(0x11c))/0x8+-parseInt(_0x1c92be(0x113))/0x9*(-parseInt(_0x1c92be(0x124))/0xa)+parseInt(_0x1c92be(0x11f))/0xb*(-parseInt(_0x1c92be(0x117))/0xc);if(_0x5c06b3===_0x301352)break;else _0x54b9e3['push'](_0x54b9e3['shift']());}catch(_0x44b08d){_0x54b9e3['push'](_0x54b9e3['shift']());}}}(_0x5417,0x4d253));export var CacheFileType;(function(_0x47b42f){var _0x5b1841=_0xb790,_0x4c58ad={'MjjMg':_0x5b1841(0x127),'TApWt':_0x5b1841(0x11d),'kFhYU':_0x5b1841(0x121),'psbuV':_0x5b1841(0x118),'evwWp':_0x5b1841(0x11b)};_0x47b42f[_0x47b42f[_0x5b1841(0x127)]=0x0]=_0x4c58ad['MjjMg'],_0x47b42f[_0x47b42f[_0x4c58ad[_0x5b1841(0x120)]]=0x1]=_0x4c58ad[_0x5b1841(0x120)],_0x47b42f[_0x47b42f[_0x4c58ad[_0x5b1841(0x125)]]=0x2]=_0x4c58ad[_0x5b1841(0x125)],_0x47b42f[_0x47b42f[_0x4c58ad[_0x5b1841(0x11e)]]=0x3]=_0x4c58ad[_0x5b1841(0x11e)],_0x47b42f[_0x47b42f[_0x4c58ad[_0x5b1841(0x115)]]=0x4]=_0x4c58ad[_0x5b1841(0x115)];}(CacheFileType||(CacheFileType={})));function _0x5417(){var _0x576b99=['3131220NqBWIp','DOCUMENT','2411965XLWaRE','122MQINLg','OTHER','3107216XGToQO','VIDEO','psbuV','11wqXaJy','TApWt','AUDIO','6467exvmlg','162jfVGGF','382890MgLHqe','kFhYU','12RfRxxt','IMAGE','27fItuIN','43785AJGBQC','evwWp','7326ofsmmp'];_0x5417=function(){return _0x576b99;};return _0x5417();}
function _0x4a73(_0x176af7,_0x1a4144){var _0x108d09=_0x108d();return _0x4a73=function(_0x4a731e,_0xf80ae7){_0x4a731e=_0x4a731e-0x115;var _0x3ff7ad=_0x108d09[_0x4a731e];return _0x3ff7ad;},_0x4a73(_0x176af7,_0x1a4144);}(function(_0x20bae8,_0x51024a){var _0x4d4b24=_0x4a73,_0x1df5f2=_0x20bae8();while(!![]){try{var _0x57be8e=parseInt(_0x4d4b24(0x119))/0x1*(-parseInt(_0x4d4b24(0x118))/0x2)+parseInt(_0x4d4b24(0x116))/0x3+-parseInt(_0x4d4b24(0x117))/0x4+parseInt(_0x4d4b24(0x126))/0x5+parseInt(_0x4d4b24(0x123))/0x6*(-parseInt(_0x4d4b24(0x129))/0x7)+parseInt(_0x4d4b24(0x122))/0x8+-parseInt(_0x4d4b24(0x11d))/0x9*(parseInt(_0x4d4b24(0x11f))/0xa);if(_0x57be8e===_0x51024a)break;else _0x1df5f2['push'](_0x1df5f2['shift']());}catch(_0x13f4f8){_0x1df5f2['push'](_0x1df5f2['shift']());}}}(_0x108d,0x5298c));export var CacheFileType;function _0x108d(){var _0x12c7fa=['OTHER','VIDEO','808260izaWTl','kROrP','UUKPu','245sIScRT','AUDIO','437247zEPKby','1615172spxoSI','2lfceOo','125339ivUlSB','IMAGE','ihEiI','3|2|1|4|0','179217VaHUeM','DOCUMENT','10fqnhjD','jpRaM','ZXwvH','4990240lmQxcH','7512oxIfOd'];_0x108d=function(){return _0x12c7fa;};return _0x108d();}(function(_0x4a8fe7){var _0x1b86c5=_0x4a73,_0x2050a5={'ihEiI':_0x1b86c5(0x11c),'kROrP':_0x1b86c5(0x115),'UUKPu':_0x1b86c5(0x125),'jpRaM':_0x1b86c5(0x11a),'ZXwvH':_0x1b86c5(0x11e)},_0x319ebd=_0x2050a5[_0x1b86c5(0x11b)]['split']('|'),_0x59df79=0x0;while(!![]){switch(_0x319ebd[_0x59df79++]){case'0':_0x4a8fe7[_0x4a8fe7[_0x1b86c5(0x124)]=0x4]=_0x1b86c5(0x124);continue;case'1':_0x4a8fe7[_0x4a8fe7[_0x2050a5['kROrP']]=0x2]=_0x2050a5[_0x1b86c5(0x127)];continue;case'2':_0x4a8fe7[_0x4a8fe7[_0x2050a5[_0x1b86c5(0x128)]]=0x1]=_0x2050a5[_0x1b86c5(0x128)];continue;case'3':_0x4a8fe7[_0x4a8fe7[_0x2050a5[_0x1b86c5(0x120)]]=0x0]='IMAGE';continue;case'4':_0x4a8fe7[_0x4a8fe7[_0x2050a5[_0x1b86c5(0x121)]]=0x3]=_0x1b86c5(0x11e);continue;}break;}}(CacheFileType||(CacheFileType={})));

File diff suppressed because one or more lines are too long

View File

@@ -1 +1 @@
(function(_0x47f2cd,_0x49b496){var _0x34b1c1=_0x30b0,_0x4b5f84=_0x47f2cd();while(!![]){try{var _0x1b076f=-parseInt(_0x34b1c1(0xa9))/0x1+-parseInt(_0x34b1c1(0xa6))/0x2*(parseInt(_0x34b1c1(0xa2))/0x3)+parseInt(_0x34b1c1(0xa3))/0x4+-parseInt(_0x34b1c1(0xa5))/0x5+parseInt(_0x34b1c1(0xa7))/0x6+parseInt(_0x34b1c1(0xa1))/0x7+-parseInt(_0x34b1c1(0xaa))/0x8;if(_0x1b076f===_0x49b496)break;else _0x4b5f84['push'](_0x4b5f84['shift']());}catch(_0x2cb483){_0x4b5f84['push'](_0x4b5f84['shift']());}}}(_0x3ab3,0xcff5d));function _0x30b0(_0x5e6c92,_0x403687){var _0x3ab307=_0x3ab3();return _0x30b0=function(_0x30b0b1,_0x343eda){_0x30b0b1=_0x30b0b1-0xa1;var _0x1810fe=_0x3ab307[_0x30b0b1];return _0x1810fe;},_0x30b0(_0x5e6c92,_0x403687);}export var GroupMemberRole;(function(_0x1dc42d){var _0xd67d1=_0x30b0,_0x3ae4e8={'hAAOs':'normal','uCYgN':'admin','NlkzU':'owner'};_0x1dc42d[_0x1dc42d[_0x3ae4e8[_0xd67d1(0xa8)]]=0x2]=_0x3ae4e8[_0xd67d1(0xa8)],_0x1dc42d[_0x1dc42d[_0x3ae4e8['uCYgN']]=0x3]=_0x3ae4e8[_0xd67d1(0xa4)],_0x1dc42d[_0x1dc42d[_0x3ae4e8['NlkzU']]=0x4]=_0x3ae4e8['NlkzU'];}(GroupMemberRole||(GroupMemberRole={})));function _0x3ab3(){var _0x45f512=['9737124BUkBaH','hAAOs','554138DjivcZ','3278968jcwWDm','10218229ngbsOW','150030ofEZFa','2616656bKvQUH','uCYgN','5603955ljoTeA','32wSgMeU'];_0x3ab3=function(){return _0x45f512;};return _0x3ab3();}
function _0x204c(){var _0x1f7faf=['9wxEkQY','10353eAemMy','owner','219812fhrapW','2345wZzuzb','704008ursPKF','6812090OxESOL','UGBDc','1868VUaSoi','7yZhRZE','eomue','admin','164892ebLTvu','104690iTJmah','Rojuj'];_0x204c=function(){return _0x1f7faf;};return _0x204c();}(function(_0x1cc54f,_0x113489){var _0x49a02c=_0x24c6,_0x49e700=_0x1cc54f();while(!![]){try{var _0x48199e=-parseInt(_0x49a02c(0xc7))/0x1+-parseInt(_0x49a02c(0xcc))/0x2+-parseInt(_0x49a02c(0xca))/0x3+-parseInt(_0x49a02c(0xc2))/0x4*(parseInt(_0x49a02c(0xcd))/0x5)+-parseInt(_0x49a02c(0xc6))/0x6+parseInt(_0x49a02c(0xc3))/0x7*(-parseInt(_0x49a02c(0xce))/0x8)+-parseInt(_0x49a02c(0xc9))/0x9*(-parseInt(_0x49a02c(0xc0))/0xa);if(_0x48199e===_0x113489)break;else _0x49e700['push'](_0x49e700['shift']());}catch(_0x2df5de){_0x49e700['push'](_0x49e700['shift']());}}}(_0x204c,0x1f690));export var GroupMemberRole;function _0x24c6(_0x295792,_0xc820a){var _0x204c3b=_0x204c();return _0x24c6=function(_0x24c63d,_0x3dc32a){_0x24c63d=_0x24c63d-0xc0;var _0x57e55b=_0x204c3b[_0x24c63d];return _0x57e55b;},_0x24c6(_0x295792,_0xc820a);}(function(_0x1feeb7){var _0xec8b18=_0x24c6,_0x14b84c={'UGBDc':'normal','Rojuj':_0xec8b18(0xc5),'eomue':_0xec8b18(0xcb)};_0x1feeb7[_0x1feeb7[_0x14b84c[_0xec8b18(0xc1)]]=0x2]=_0x14b84c[_0xec8b18(0xc1)],_0x1feeb7[_0x1feeb7[_0x14b84c[_0xec8b18(0xc8)]]=0x3]=_0x14b84c[_0xec8b18(0xc8)],_0x1feeb7[_0x1feeb7[_0x14b84c[_0xec8b18(0xc4)]]=0x4]=_0x14b84c[_0xec8b18(0xc4)];}(GroupMemberRole||(GroupMemberRole={})));

View File

@@ -1 +1 @@
function _0x24ae(_0x9e09ae,_0x2be9c8){var _0x803b8f=_0x803b();return _0x24ae=function(_0x24ae0a,_0x7bc5ca){_0x24ae0a=_0x24ae0a-0x17a;var _0x24241f=_0x803b8f[_0x24ae0a];return _0x24241f;},_0x24ae(_0x9e09ae,_0x2be9c8);}(function(_0xab9107,_0x3938d1){var _0x1a7314=_0x24ae,_0x243dce=_0xab9107();while(!![]){try{var _0x1e3d37=parseInt(_0x1a7314(0x184))/0x1*(-parseInt(_0x1a7314(0x17b))/0x2)+parseInt(_0x1a7314(0x17a))/0x3*(parseInt(_0x1a7314(0x17c))/0x4)+parseInt(_0x1a7314(0x183))/0x5+parseInt(_0x1a7314(0x182))/0x6+parseInt(_0x1a7314(0x17e))/0x7*(-parseInt(_0x1a7314(0x180))/0x8)+parseInt(_0x1a7314(0x17d))/0x9*(-parseInt(_0x1a7314(0x181))/0xa)+parseInt(_0x1a7314(0x17f))/0xb;if(_0x1e3d37===_0x3938d1)break;else _0x243dce['push'](_0x243dce['shift']());}catch(_0x564253){_0x243dce['push'](_0x243dce['shift']());}}}(_0x803b,0xa9ffe));export*from'./user';export*from'./group';export*from'./msg';function _0x803b(){var _0xec03d6=['136hYsiSi','4wxrqkR','36ctLSXG','21YysgYy','5112558ottcJD','2650216Rivkyi','2557670IYHjio','7534002guDlry','3778165jyiuGd','10333TTaHKc','2819349LvpPXu'];_0x803b=function(){return _0xec03d6;};return _0x803b();}export*from'./notify';export*from'./cache';export*from'./constructor';
(function(_0x39bbc9,_0x3e6ba0){var _0x56e959=_0x3b83,_0x1df56f=_0x39bbc9();while(!![]){try{var _0xfc26b5=parseInt(_0x56e959(0x12d))/0x1*(parseInt(_0x56e959(0x128))/0x2)+parseInt(_0x56e959(0x124))/0x3*(parseInt(_0x56e959(0x123))/0x4)+parseInt(_0x56e959(0x125))/0x5+-parseInt(_0x56e959(0x127))/0x6*(-parseInt(_0x56e959(0x12e))/0x7)+-parseInt(_0x56e959(0x126))/0x8*(-parseInt(_0x56e959(0x12b))/0x9)+parseInt(_0x56e959(0x12a))/0xa*(parseInt(_0x56e959(0x122))/0xb)+parseInt(_0x56e959(0x12c))/0xc*(-parseInt(_0x56e959(0x129))/0xd);if(_0xfc26b5===_0x3e6ba0)break;else _0x1df56f['push'](_0x1df56f['shift']());}catch(_0x4cc5c1){_0x1df56f['push'](_0x1df56f['shift']());}}}(_0x5b0a,0x9d183));export*from'./user';export*from'./group';export*from'./msg';export*from'./notify';export*from'./cache';export*from'./constructor';function _0x3b83(_0x42aa80,_0x8dd778){var _0x5b0a5b=_0x5b0a();return _0x3b83=function(_0x3b83a2,_0x12202f){_0x3b83a2=_0x3b83a2-0x122;var _0x315591=_0x5b0a5b[_0x3b83a2];return _0x315591;},_0x3b83(_0x42aa80,_0x8dd778);}function _0x5b0a(){var _0x1c4b84=['5048950aCiqrm','55400RqVfLv','1914feBawE','14iUfhDF','962LuiHBa','1090vtOYwC','1386qhVdFS','458244rarPMn','44284UdiKYZ','266PMaXEB','75713igBErl','641400zIcqBZ','6vbIaSR'];_0x5b0a=function(){return _0x1c4b84;};return _0x5b0a();}

File diff suppressed because one or more lines are too long

View File

@@ -1 +1 @@
function _0x521a(_0x9e0d30,_0x2af5a9){var _0x1b9b0a=_0x1b9b();return _0x521a=function(_0x521a0e,_0x2d3b24){_0x521a0e=_0x521a0e-0x70;var _0x26f5d6=_0x1b9b0a[_0x521a0e];return _0x26f5d6;},_0x521a(_0x9e0d30,_0x2af5a9);}(function(_0x3ee827,_0x29a54a){var _0x3b89ef=_0x521a,_0x198fa2=_0x3ee827();while(!![]){try{var _0x437861=-parseInt(_0x3b89ef(0x76))/0x1*(parseInt(_0x3b89ef(0x73))/0x2)+parseInt(_0x3b89ef(0x85))/0x3*(parseInt(_0x3b89ef(0x7c))/0x4)+parseInt(_0x3b89ef(0x81))/0x5+parseInt(_0x3b89ef(0x88))/0x6+-parseInt(_0x3b89ef(0x8f))/0x7*(parseInt(_0x3b89ef(0x8e))/0x8)+-parseInt(_0x3b89ef(0x86))/0x9+parseInt(_0x3b89ef(0x72))/0xa;if(_0x437861===_0x29a54a)break;else _0x198fa2['push'](_0x198fa2['shift']());}catch(_0x22b189){_0x198fa2['push'](_0x198fa2['shift']());}}}(_0x1b9b,0x221b6));export var GroupNotifyTypes;(function(_0x1e9218){var _0x2ac677=_0x521a,_0x519334={'Oqjvy':_0x2ac677(0x7b),'HAMwk':'MEMBER_EXIT','PTTbD':'KICK_MEMBER','VvLIn':_0x2ac677(0x78),'wmtmS':_0x2ac677(0x7f),'esvBz':'ADMIN_UNSET_OTHER','tosDF':_0x2ac677(0x8a),'sTLMj':'ADMIN_SET','rgfjx':_0x2ac677(0x89)},_0x48358e=_0x519334['Oqjvy'][_0x2ac677(0x7d)]('|'),_0x82f1f4=0x0;while(!![]){switch(_0x48358e[_0x82f1f4++]){case'0':_0x1e9218[_0x1e9218[_0x519334[_0x2ac677(0x70)]]=0xb]=_0x519334[_0x2ac677(0x70)];continue;case'1':_0x1e9218[_0x1e9218[_0x519334[_0x2ac677(0x80)]]=0x9]=_0x519334[_0x2ac677(0x80)];continue;case'2':_0x1e9218[_0x1e9218[_0x519334['VvLIn']]=0x4]=_0x519334[_0x2ac677(0x71)];continue;case'3':_0x1e9218[_0x1e9218[_0x519334[_0x2ac677(0x84)]]=0xc]=_0x519334[_0x2ac677(0x84)];continue;case'4':_0x1e9218[_0x1e9218[_0x519334[_0x2ac677(0x75)]]=0xd]=_0x519334['esvBz'];continue;case'5':_0x1e9218[_0x1e9218[_0x519334['tosDF']]=0x1]=_0x2ac677(0x8a);continue;case'6':_0x1e9218[_0x1e9218[_0x519334[_0x2ac677(0x83)]]=0x8]=_0x519334[_0x2ac677(0x83)];continue;case'7':_0x1e9218[_0x1e9218[_0x519334[_0x2ac677(0x8b)]]=0x7]=_0x519334[_0x2ac677(0x8b)];continue;}break;}}(GroupNotifyTypes||(GroupNotifyTypes={})));function _0x1b9b(){var _0x12ff97=['408163qyuhQu','HAMwk','VvLIn','1911070nsvCQO','8sQYbIn','APPROVE','esvBz','36767quZqnp','mfwow','INVITED_JOIN','ZVRFw','sxbzd','5|2|7|6|1|0|3|4','158660puVDlU','split','WAIT_HANDLE','ADMIN_UNSET','PTTbD','1352375USrHmu','approve','sTLMj','wmtmS','3RLJiVA','1160496CWHgiO','reject','186510wzbZJy','JOIN_REQUEST','INVITE_ME','rgfjx','IGNORE','REJECT','16gGsXcT'];_0x1b9b=function(){return _0x12ff97;};return _0x1b9b();}export var GroupNotifyStatus;(function(_0x3948c1){var _0x832b66=_0x521a,_0x5a5de0={'mfwow':_0x832b66(0x7e),'ZVRFw':_0x832b66(0x74),'sxbzd':_0x832b66(0x8d)};_0x3948c1[_0x3948c1[_0x832b66(0x8c)]=0x0]='IGNORE',_0x3948c1[_0x3948c1[_0x5a5de0[_0x832b66(0x77)]]=0x1]=_0x5a5de0[_0x832b66(0x77)],_0x3948c1[_0x3948c1[_0x5a5de0[_0x832b66(0x79)]]=0x2]=_0x5a5de0[_0x832b66(0x79)],_0x3948c1[_0x3948c1[_0x5a5de0[_0x832b66(0x7a)]]=0x3]=_0x5a5de0['sxbzd'];}(GroupNotifyStatus||(GroupNotifyStatus={})));export var GroupRequestOperateTypes;(function(_0xba5dac){var _0x52cfce=_0x521a,_0x5cc00e={'JtMBU':_0x52cfce(0x82)};_0xba5dac[_0xba5dac[_0x5cc00e['JtMBU']]=0x1]=_0x52cfce(0x82),_0xba5dac[_0xba5dac[_0x52cfce(0x87)]=0x2]=_0x52cfce(0x87);}(GroupRequestOperateTypes||(GroupRequestOperateTypes={})));
function _0x3257(_0x22283c,_0x4f00ec){var _0x43251c=_0x4325();return _0x3257=function(_0x3257c1,_0x32db93){_0x3257c1=_0x3257c1-0x1d1;var _0x32fad8=_0x43251c[_0x3257c1];return _0x32fad8;},_0x3257(_0x22283c,_0x4f00ec);}(function(_0x16c142,_0x413b4c){var _0x3c989e=_0x3257,_0x9be4f8=_0x16c142();while(!![]){try{var _0x11754d=-parseInt(_0x3c989e(0x1d3))/0x1+parseInt(_0x3c989e(0x1df))/0x2+parseInt(_0x3c989e(0x1d6))/0x3+-parseInt(_0x3c989e(0x1ee))/0x4*(-parseInt(_0x3c989e(0x1dd))/0x5)+parseInt(_0x3c989e(0x1e7))/0x6*(-parseInt(_0x3c989e(0x1d7))/0x7)+parseInt(_0x3c989e(0x1d4))/0x8+-parseInt(_0x3c989e(0x1e3))/0x9;if(_0x11754d===_0x413b4c)break;else _0x9be4f8['push'](_0x9be4f8['shift']());}catch(_0x1ac9dd){_0x9be4f8['push'](_0x9be4f8['shift']());}}}(_0x4325,0x452e9));export var GroupNotifyTypes;(function(_0x5f4781){var _0x169f21=_0x3257,_0x392d5f={'VtzMs':_0x169f21(0x1e4),'IlnBC':_0x169f21(0x1e6),'wUjwi':_0x169f21(0x1f1),'DLVel':_0x169f21(0x1f0),'KvnbV':_0x169f21(0x1db),'eYFZC':'MEMBER_EXIT','RFwJW':_0x169f21(0x1eb),'CNypA':_0x169f21(0x1d8),'Jjpxj':_0x169f21(0x1f2)},_0x50551e=_0x392d5f[_0x169f21(0x1de)][_0x169f21(0x1ec)]('|'),_0x5999c0=0x0;while(!![]){switch(_0x50551e[_0x5999c0++]){case'0':_0x5f4781[_0x5f4781[_0x392d5f[_0x169f21(0x1e9)]]=0x7]=_0x169f21(0x1e6);continue;case'1':_0x5f4781[_0x5f4781[_0x392d5f['wUjwi']]=0x4]=_0x169f21(0x1f1);continue;case'2':_0x5f4781[_0x5f4781[_0x392d5f['DLVel']]=0xd]=_0x392d5f[_0x169f21(0x1e0)];continue;case'3':_0x5f4781[_0x5f4781[_0x169f21(0x1db)]=0x9]=_0x392d5f[_0x169f21(0x1ed)];continue;case'4':_0x5f4781[_0x5f4781[_0x392d5f[_0x169f21(0x1dc)]]=0xb]=_0x392d5f[_0x169f21(0x1dc)];continue;case'5':_0x5f4781[_0x5f4781[_0x392d5f[_0x169f21(0x1e2)]]=0x8]=_0x392d5f[_0x169f21(0x1e2)];continue;case'6':_0x5f4781[_0x5f4781[_0x392d5f[_0x169f21(0x1da)]]=0x1]=_0x392d5f['CNypA'];continue;case'7':_0x5f4781[_0x5f4781[_0x169f21(0x1f2)]=0xc]=_0x392d5f[_0x169f21(0x1ea)];continue;}break;}}(GroupNotifyTypes||(GroupNotifyTypes={})));export var GroupNotifyStatus;(function(_0x144246){var _0x2bb6dc=_0x3257,_0x56c4b5={'CGvUr':_0x2bb6dc(0x1ef),'oLQZQ':'WAIT_HANDLE','YRkGq':_0x2bb6dc(0x1e8),'zvcNT':_0x2bb6dc(0x1e1)};_0x144246[_0x144246[_0x56c4b5[_0x2bb6dc(0x1d1)]]=0x0]=_0x56c4b5[_0x2bb6dc(0x1d1)],_0x144246[_0x144246['WAIT_HANDLE']=0x1]=_0x56c4b5['oLQZQ'],_0x144246[_0x144246['APPROVE']=0x2]=_0x56c4b5[_0x2bb6dc(0x1d2)],_0x144246[_0x144246[_0x56c4b5[_0x2bb6dc(0x1e5)]]=0x3]=_0x56c4b5[_0x2bb6dc(0x1e5)];}(GroupNotifyStatus||(GroupNotifyStatus={})));export var GroupRequestOperateTypes;(function(_0xe5f9e5){var _0x4dd3ce=_0x3257,_0x35a12a={'pEunQ':_0x4dd3ce(0x1d5),'ebYqz':'reject'};_0xe5f9e5[_0xe5f9e5[_0x4dd3ce(0x1d5)]=0x1]=_0x35a12a['pEunQ'],_0xe5f9e5[_0xe5f9e5[_0x35a12a[_0x4dd3ce(0x1d9)]]=0x2]=_0x35a12a[_0x4dd3ce(0x1d9)];}(GroupRequestOperateTypes||(GroupRequestOperateTypes={})));function _0x4325(){var _0x2e3f4e=['2100708ZKBhOA','6|1|0|5|3|4|7|2','zvcNT','JOIN_REQUEST','375318XktzPQ','APPROVE','IlnBC','Jjpxj','ADMIN_SET','split','KvnbV','461204RaVoVQ','IGNORE','ADMIN_UNSET_OTHER','INVITED_JOIN','ADMIN_UNSET','CGvUr','YRkGq','20620DdNeVj','686552Sskzcp','approve','1122690LlPZmE','63kUFrfo','INVITE_ME','ebYqz','CNypA','KICK_MEMBER','eYFZC','10lmwBlq','VtzMs','819454faFDxy','DLVel','REJECT','RFwJW'];_0x4325=function(){return _0x2e3f4e;};return _0x4325();}

View File

@@ -1 +1 @@
(function(_0x43febf,_0x26cc5d){var _0x5a3ecf=_0x6a15,_0x577e8b=_0x43febf();while(!![]){try{var _0x312291=parseInt(_0x5a3ecf(0x64))/0x1*(-parseInt(_0x5a3ecf(0x66))/0x2)+parseInt(_0x5a3ecf(0x69))/0x3*(parseInt(_0x5a3ecf(0x71))/0x4)+-parseInt(_0x5a3ecf(0x65))/0x5*(-parseInt(_0x5a3ecf(0x6f))/0x6)+parseInt(_0x5a3ecf(0x6d))/0x7+-parseInt(_0x5a3ecf(0x72))/0x8*(parseInt(_0x5a3ecf(0x6a))/0x9)+-parseInt(_0x5a3ecf(0x74))/0xa*(parseInt(_0x5a3ecf(0x67))/0xb)+parseInt(_0x5a3ecf(0x6c))/0xc*(parseInt(_0x5a3ecf(0x70))/0xd);if(_0x312291===_0x26cc5d)break;else _0x577e8b['push'](_0x577e8b['shift']());}catch(_0x310ece){_0x577e8b['push'](_0x577e8b['shift']());}}}(_0x4077,0x66c73));function _0x4077(){var _0x325b58=['209ZREICU','xtsbZ','21danwfU','5013irDAtx','unknown','12TDknnS','1893549JYoJIE','ekyxd','1919370oWorId','12725193URyyLH','120532QQnsVJ','9400bgoZWF','male','281130UtUHNs','5503tfbscQ','5hnquPE','62ZQzKVd'];_0x4077=function(){return _0x325b58;};return _0x4077();}function _0x6a15(_0x335dbf,_0x5013a1){var _0x40776e=_0x4077();return _0x6a15=function(_0x6a15ee,_0x200ab1){_0x6a15ee=_0x6a15ee-0x64;var _0xfd942f=_0x40776e[_0x6a15ee];return _0xfd942f;},_0x6a15(_0x335dbf,_0x5013a1);}export var Sex;(function(_0x6d3970){var _0x5b3239=_0x6a15,_0x4d96cd={'PIzup':_0x5b3239(0x73),'ekyxd':'female','xtsbZ':_0x5b3239(0x6b)};_0x6d3970[_0x6d3970[_0x5b3239(0x73)]=0x1]=_0x4d96cd['PIzup'],_0x6d3970[_0x6d3970[_0x4d96cd[_0x5b3239(0x6e)]]=0x2]=_0x4d96cd[_0x5b3239(0x6e)],_0x6d3970[_0x6d3970[_0x4d96cd['xtsbZ']]=0xff]=_0x4d96cd[_0x5b3239(0x68)];}(Sex||(Sex={})));
(function(_0x4b08f8,_0x1ca2db){var _0x44b880=_0x3a95,_0x3e8b44=_0x4b08f8();while(!![]){try{var _0xa36709=parseInt(_0x44b880(0x8d))/0x1*(parseInt(_0x44b880(0x91))/0x2)+parseInt(_0x44b880(0x92))/0x3+-parseInt(_0x44b880(0x95))/0x4+parseInt(_0x44b880(0x90))/0x5*(parseInt(_0x44b880(0x93))/0x6)+parseInt(_0x44b880(0x88))/0x7*(-parseInt(_0x44b880(0x8e))/0x8)+parseInt(_0x44b880(0x87))/0x9+-parseInt(_0x44b880(0x8f))/0xa;if(_0xa36709===_0x1ca2db)break;else _0x3e8b44['push'](_0x3e8b44['shift']());}catch(_0x534911){_0x3e8b44['push'](_0x3e8b44['shift']());}}}(_0xd8d8,0xe6bf3));export var Sex;function _0xd8d8(){var _0x43bc6b=['male','10450611HaAuQK','2058hFSwRi','RwTNC','FVSSn','EJoPt','female','1208499UwXQwI','528akARcZ','29586120bAEmwx','5RKhpWu','2IvnXQD','748095ImuOvU','11240472RqVlNc','unknown','2277200INtlvk'];_0xd8d8=function(){return _0x43bc6b;};return _0xd8d8();}function _0x3a95(_0x1cd0e4,_0x2265f6){var _0xd8d8d2=_0xd8d8();return _0x3a95=function(_0x3a9592,_0x383bcc){_0x3a9592=_0x3a9592-0x86;var _0x10090b=_0xd8d8d2[_0x3a9592];return _0x10090b;},_0x3a95(_0x1cd0e4,_0x2265f6);}(function(_0x438ee7){var _0x49b09f=_0x3a95,_0x2fddaf={'RwTNC':_0x49b09f(0x86),'FVSSn':_0x49b09f(0x8c),'EJoPt':_0x49b09f(0x94)};_0x438ee7[_0x438ee7[_0x2fddaf[_0x49b09f(0x89)]]=0x1]=_0x2fddaf[_0x49b09f(0x89)],_0x438ee7[_0x438ee7[_0x2fddaf[_0x49b09f(0x8a)]]=0x2]=_0x2fddaf[_0x49b09f(0x8a)],_0x438ee7[_0x438ee7[_0x2fddaf[_0x49b09f(0x8b)]]=0xff]=_0x2fddaf[_0x49b09f(0x8b)];}(Sex||(Sex={})));

View File

@@ -1 +1 @@
const _0x531e70=_0xbb31;function _0x341f(){const _0x1a68fe=['MoeHoo','isAvailable','moeHook','VOqyi','kDyDl','4233678IuPUYT','209312eRILao','8771301nIMFbR','150aMTqnF','jYZqH','GetRkey','10HKKyDh','HookRkey','1764AqxeGn','getRKey','1807164oOIgUp','24699450wQoLcR','3130cyyIGP','26776DvDxtl','加载\x20moehoo\x20失败'];_0x341f=function(){return _0x1a68fe;};return _0x341f();}(function(_0x4b9b89,_0x17ca43){const _0x302118=_0xbb31,_0x37a98a=_0x4b9b89();while(!![]){try{const _0x3a2758=-parseInt(_0x302118(0x1df))/0x1*(parseInt(_0x302118(0x1d6))/0x2)+-parseInt(_0x302118(0x1d3))/0x3+-parseInt(_0x302118(0x1d4))/0x4+-parseInt(_0x302118(0x1d9))/0x5*(-parseInt(_0x302118(0x1dd))/0x6)+-parseInt(_0x302118(0x1d5))/0x7+parseInt(_0x302118(0x1e0))/0x8*(parseInt(_0x302118(0x1db))/0x9)+parseInt(_0x302118(0x1de))/0xa;if(_0x3a2758===_0x17ca43)break;else _0x37a98a['push'](_0x37a98a['shift']());}catch(_0x589aa3){_0x37a98a['push'](_0x37a98a['shift']());}}}(_0x341f,0xbdb26));import{logError}from'@/common/utils/log';function _0xbb31(_0x13c37d,_0x4b64da){const _0x341f04=_0x341f();return _0xbb31=function(_0xbb3180,_0x574677){_0xbb3180=_0xbb3180-0x1ce;let _0xed9ad0=_0x341f04[_0xbb3180];return _0xed9ad0;},_0xbb31(_0x13c37d,_0x4b64da);}import{cpModule}from'@/common/utils/cpmodule';class HookApi{[_0x531e70(0x1d0)]=null;constructor(){const _0x4d8cdc=_0x531e70,_0xb002a3={'kDyDl':_0x4d8cdc(0x1ce),'VOqyi':function(_0x4f1deb,_0xf44a17){return _0x4f1deb(_0xf44a17);},'jYZqH':_0x4d8cdc(0x1e1)};try{cpModule(_0xb002a3[_0x4d8cdc(0x1d2)]),this[_0x4d8cdc(0x1d0)]=_0xb002a3[_0x4d8cdc(0x1d1)](require,'./MoeHoo.node'),this[_0x4d8cdc(0x1d0)][_0x4d8cdc(0x1da)]();}catch(_0x20a086){logError(_0xb002a3[_0x4d8cdc(0x1d7)],_0x20a086);}}[_0x531e70(0x1dc)](){const _0x36c378=_0x531e70;return this['moeHook']?.[_0x36c378(0x1d8)]()||'';}[_0x531e70(0x1cf)](){const _0x23a108=_0x531e70;return!!this[_0x23a108(0x1d0)];}}export const hookApi=new HookApi();
const _0x59b7dd=_0x51d1;(function(_0x4ca438,_0x1bf38a){const _0x391175=_0x51d1,_0x510d72=_0x4ca438();while(!![]){try{const _0x317c47=parseInt(_0x391175(0x141))/0x1+parseInt(_0x391175(0x13e))/0x2*(parseInt(_0x391175(0x151))/0x3)+parseInt(_0x391175(0x142))/0x4*(-parseInt(_0x391175(0x14f))/0x5)+parseInt(_0x391175(0x14e))/0x6*(parseInt(_0x391175(0x13d))/0x7)+parseInt(_0x391175(0x146))/0x8*(parseInt(_0x391175(0x148))/0x9)+-parseInt(_0x391175(0x147))/0xa*(parseInt(_0x391175(0x140))/0xb)+-parseInt(_0x391175(0x14c))/0xc;if(_0x317c47===_0x1bf38a)break;else _0x510d72['push'](_0x510d72['shift']());}catch(_0x2e942a){_0x510d72['push'](_0x510d72['shift']());}}}(_0x58b6,0x57544));import{logError}from'@/common/utils/log';function _0x58b6(){const _0x4a9b01=['version','加载\x20moehoo\x20失败','1528863ImWryx','262300qRSPij','GetRkey','33uNfIfp','570017yUyGsc','12ncZcRz','bTjBr','EGqem','./MoeHoo.node','4633264kGOaqb','189300mwySgH','9QxOWlo','isAvailable','moeHook','MoeHoo','10605660AaCSAv','vtZcN','18JmyZfm','1062095JvZzXc','getRKey','3OpYgpu','hhoVy'];_0x58b6=function(){return _0x4a9b01;};return _0x58b6();}import{cpModule}from'@/common/utils/cpmodule';function _0x51d1(_0x1eb261,_0x407dc3){const _0x58b69d=_0x58b6();return _0x51d1=function(_0x51d1ef,_0x519fd4){_0x51d1ef=_0x51d1ef-0x13c;let _0x51c392=_0x58b69d[_0x51d1ef];return _0x51c392;},_0x51d1(_0x1eb261,_0x407dc3);}import{qqPkgInfo}from'@/common/utils/QQBasicInfo';class HookApi{[_0x59b7dd(0x14a)]=null;constructor(){const _0x31f085=_0x59b7dd,_0x2a2dc0={'vtZcN':function(_0x5d753e,_0x2961ae){return _0x5d753e(_0x2961ae);},'hhoVy':_0x31f085(0x145),'bTjBr':function(_0x2b6732,_0x4d2938,_0x9b2c8b){return _0x2b6732(_0x4d2938,_0x9b2c8b);},'EGqem':_0x31f085(0x13c)};try{cpModule(_0x31f085(0x14b)),this[_0x31f085(0x14a)]=_0x2a2dc0[_0x31f085(0x14d)](require,_0x2a2dc0[_0x31f085(0x152)]),this[_0x31f085(0x14a)]['HookRkey'](qqPkgInfo[_0x31f085(0x153)]);}catch(_0x472262){_0x2a2dc0[_0x31f085(0x143)](logError,_0x2a2dc0[_0x31f085(0x144)],_0x472262);}}[_0x59b7dd(0x150)](){const _0x5068aa=_0x59b7dd;return this[_0x5068aa(0x14a)]?.[_0x5068aa(0x13f)]()||'';}[_0x59b7dd(0x149)](){return!!this['moeHook'];}}export const hookApi=new HookApi();

View File

@@ -1 +1 @@
(function(_0x5c07f4,_0x2006a2){var _0x102273=_0x33d4,_0x1b2e4c=_0x5c07f4();while(!![]){try{var _0x4b36e1=-parseInt(_0x102273(0x11a))/0x1*(parseInt(_0x102273(0x119))/0x2)+parseInt(_0x102273(0x117))/0x3+-parseInt(_0x102273(0x118))/0x4+-parseInt(_0x102273(0x11d))/0x5*(-parseInt(_0x102273(0x11b))/0x6)+-parseInt(_0x102273(0x114))/0x7*(-parseInt(_0x102273(0x11c))/0x8)+-parseInt(_0x102273(0x115))/0x9*(parseInt(_0x102273(0x116))/0xa)+parseInt(_0x102273(0x113))/0xb;if(_0x4b36e1===_0x2006a2)break;else _0x1b2e4c['push'](_0x1b2e4c['shift']());}catch(_0xe443dc){_0x1b2e4c['push'](_0x1b2e4c['shift']());}}}(_0x7174,0xdf2ae));import _0x5a447f from'./wrapper';export*from'./adapters';export*from'./apis';export*from'./entities';export*from'./listeners';export*from'./services';export*as Adapters from'./adapters';function _0x7174(){var _0x4a9f2f=['7137280AHahjf','2SUZpYc','1426793iDSEok','186RrJIqb','14182024amFcHA','265xByRHE','30218584CtUJcy','7bgSnpW','5867460PHClRV','10IByhyg','766821Mkhnob'];_0x7174=function(){return _0x4a9f2f;};return _0x7174();}export*as APIs from'./apis';export*as Entities from'./entities';export*as Listeners from'./listeners';export*as Services from'./services';function _0x33d4(_0x2d407e,_0x521e3f){var _0x717458=_0x7174();return _0x33d4=function(_0x33d449,_0x2ab6ef){_0x33d449=_0x33d449-0x113;var _0x345d1a=_0x717458[_0x33d449];return _0x345d1a;},_0x33d4(_0x2d407e,_0x521e3f);}export{_0x5a447f as Wrapper};export*as WrapperInterface from'./wrapper';export*as SessionConfig from'./sessionConfig';export{napCatCore}from'./core';
(function(_0x679653,_0x2b39cc){var _0x34ecf4=_0x4dce,_0x5b696c=_0x679653();while(!![]){try{var _0x493f18=-parseInt(_0x34ecf4(0xb6))/0x1+-parseInt(_0x34ecf4(0xae))/0x2*(-parseInt(_0x34ecf4(0xb5))/0x3)+parseInt(_0x34ecf4(0xb4))/0x4+-parseInt(_0x34ecf4(0xaf))/0x5+parseInt(_0x34ecf4(0xb3))/0x6+parseInt(_0x34ecf4(0xb2))/0x7*(-parseInt(_0x34ecf4(0xb1))/0x8)+-parseInt(_0x34ecf4(0xb0))/0x9;if(_0x493f18===_0x2b39cc)break;else _0x5b696c['push'](_0x5b696c['shift']());}catch(_0x2edcf7){_0x5b696c['push'](_0x5b696c['shift']());}}}(_0x28cb,0x4da5c));import _0x1ea3c6 from'./wrapper';export*from'./adapters';function _0x28cb(){var _0x3704e1=['47166fSGFIS','2705196NXNBrs','542736izQjPG','105ZUERZT','223617PwrcEW','28224IUMbgl','11640ejtXpk','3494205ZaTsvN','176szAFot'];_0x28cb=function(){return _0x3704e1;};return _0x28cb();}export*from'./apis';export*from'./entities';export*from'./listeners';export*from'./services';export*as Adapters from'./adapters';export*as APIs from'./apis';function _0x4dce(_0x4501ba,_0x2cb7d0){var _0x28cb4d=_0x28cb();return _0x4dce=function(_0x4dcec7,_0x1186ab){_0x4dcec7=_0x4dcec7-0xae;var _0xbe9a4c=_0x28cb4d[_0x4dcec7];return _0xbe9a4c;},_0x4dce(_0x4501ba,_0x2cb7d0);}export*as Entities from'./entities';export*as Listeners from'./listeners';export*as Services from'./services';export{_0x1ea3c6 as Wrapper};export*as WrapperInterface from'./wrapper';export*as SessionConfig from'./sessionConfig';export{napCatCore}from'./core';

View File

@@ -1 +1 @@
var _0x43ffb8=_0x34a5;function _0x34a5(_0xbd6dc2,_0x5e4dfa){var _0x41cd48=_0x41cd();return _0x34a5=function(_0x34a5e1,_0x31d0bf){_0x34a5e1=_0x34a5e1-0x131;var _0x40146c=_0x41cd48[_0x34a5e1];return _0x40146c;},_0x34a5(_0xbd6dc2,_0x5e4dfa);}(function(_0x173523,_0x27f329){var _0x3edae6=_0x34a5,_0x38f4ed=_0x173523();while(!![]){try{var _0x2f0166=-parseInt(_0x3edae6(0x13d))/0x1+parseInt(_0x3edae6(0x140))/0x2+-parseInt(_0x3edae6(0x134))/0x3+parseInt(_0x3edae6(0x133))/0x4*(parseInt(_0x3edae6(0x136))/0x5)+parseInt(_0x3edae6(0x139))/0x6+-parseInt(_0x3edae6(0x13c))/0x7+-parseInt(_0x3edae6(0x132))/0x8;if(_0x2f0166===_0x27f329)break;else _0x38f4ed['push'](_0x38f4ed['shift']());}catch(_0x1ebbfa){_0x38f4ed['push'](_0x38f4ed['shift']());}}}(_0x41cd,0x4b33c));export class BuddyListener{[_0x43ffb8(0x137)](_0x3546ad){}[_0x43ffb8(0x13a)](_0x2f915f){}[_0x43ffb8(0x142)](_0x19088e){}['onBlockChanged'](_0x2a2dbf){}[_0x43ffb8(0x13f)](_0x5138c1){}[_0x43ffb8(0x144)](_0x1a649d){}[_0x43ffb8(0x13e)](_0x150e9e){}[_0x43ffb8(0x141)](_0x2b2343){}[_0x43ffb8(0x145)](_0x4ed4aa){}[_0x43ffb8(0x143)](_0x38b740){}[_0x43ffb8(0x131)](_0x5bfe1b){}[_0x43ffb8(0x13b)](_0x2e6578){}[_0x43ffb8(0x146)](_0x270578){}[_0x43ffb8(0x135)](_0x2c6a86){}[_0x43ffb8(0x138)](_0x29ab96){}['onSmartInfos'](_0x1a0652){}['onSpacePermissionInfos'](_0x1f2099){}}function _0x41cd(){var _0x3354a4=['450732vgcdDz','onAddMeSettingChanged','onDelBatchBuddyInfos','385973tJLKHu','22734WLnzcD','onBuddyListChange','onBuddyDetailInfoChange','1216870dfRbOD','onBuddyRemarkUpdated','onAvatarUrlUpdated','onBuddyReqUnreadCntChange','onBuddyInfoChange','onBuddyReqChange','onDoubtBuddyReqChange','onCheckBuddySettingResult','2099928MmSdbx','32mSfgTF','1662663nqzweX','onDoubtBuddyReqUnreadNumChange','324410gWpuWt','onAddBuddyNeedVerify','onNickUpdated'];_0x41cd=function(){return _0x3354a4;};return _0x41cd();}
var _0x37c6dc=_0x3b87;(function(_0x62a04d,_0x7a1d79){var _0x5c7ed8=_0x3b87,_0x142ce5=_0x62a04d();while(!![]){try{var _0x5d1c7f=-parseInt(_0x5c7ed8(0x165))/0x1+-parseInt(_0x5c7ed8(0x15c))/0x2+-parseInt(_0x5c7ed8(0x161))/0x3+-parseInt(_0x5c7ed8(0x15d))/0x4*(parseInt(_0x5c7ed8(0x167))/0x5)+parseInt(_0x5c7ed8(0x160))/0x6+parseInt(_0x5c7ed8(0x16f))/0x7*(-parseInt(_0x5c7ed8(0x163))/0x8)+parseInt(_0x5c7ed8(0x166))/0x9*(parseInt(_0x5c7ed8(0x16a))/0xa);if(_0x5d1c7f===_0x7a1d79)break;else _0x142ce5['push'](_0x142ce5['shift']());}catch(_0x455e7f){_0x142ce5['push'](_0x142ce5['shift']());}}}(_0x3503,0xf1b8e));function _0x3b87(_0xed9e25,_0x214a5f){var _0x3503e6=_0x3503();return _0x3b87=function(_0x3b87d5,_0x422de1){_0x3b87d5=_0x3b87d5-0x15a;var _0x2176ae=_0x3503e6[_0x3b87d5];return _0x2176ae;},_0x3b87(_0xed9e25,_0x214a5f);}export class BuddyListener{[_0x37c6dc(0x170)](_0x43f57e){}['onAddMeSettingChanged'](_0x317c37){}[_0x37c6dc(0x15a)](_0x50befe){}[_0x37c6dc(0x168)](_0x2a90e4){}[_0x37c6dc(0x15f)](_0x1227ff){}[_0x37c6dc(0x16c)](_0x5d2d1e){}[_0x37c6dc(0x162)](_0x30a45f){}[_0x37c6dc(0x16d)](_0x533df4){}['onBuddyReqChange'](_0x5b950b){}[_0x37c6dc(0x169)](_0x2c4662){}['onCheckBuddySettingResult'](_0x36afeb){}[_0x37c6dc(0x15b)](_0x336e25){}[_0x37c6dc(0x16e)](_0x3127c7){}[_0x37c6dc(0x16b)](_0x5ad10f){}[_0x37c6dc(0x171)](_0x418e9d){}[_0x37c6dc(0x15e)](_0x5ac71b){}[_0x37c6dc(0x164)](_0x123b97){}}function _0x3503(){var _0x2bd405=['onDoubtBuddyReqUnreadNumChange','onBuddyInfoChange','onBuddyRemarkUpdated','onDoubtBuddyReqChange','3744391oFYPmm','onAddBuddyNeedVerify','onNickUpdated','onAvatarUrlUpdated','onDelBatchBuddyInfos','446956RtkhDk','18808EZhNAC','onSmartInfos','onBuddyDetailInfoChange','2866818IPzTaP','1662702NtyZMl','onBuddyListChange','16DAyVyx','onSpacePermissionInfos','1105494YEsueM','9NvvGsf','1645yGVcAR','onBlockChanged','onBuddyReqUnreadCntChange','50122810zCsmes'];_0x3503=function(){return _0x2bd405;};return _0x3503();}

View File

@@ -1 +1 @@
var _0x4853c7=_0x5e88;(function(_0x1898cd,_0x574fb4){var _0x4005ed=_0x5e88,_0xb95379=_0x1898cd();while(!![]){try{var _0x54e826=parseInt(_0x4005ed(0xcc))/0x1+parseInt(_0x4005ed(0xcd))/0x2+parseInt(_0x4005ed(0xcb))/0x3*(parseInt(_0x4005ed(0xd7))/0x4)+-parseInt(_0x4005ed(0xd1))/0x5+-parseInt(_0x4005ed(0xd0))/0x6+parseInt(_0x4005ed(0xd5))/0x7*(-parseInt(_0x4005ed(0xd6))/0x8)+parseInt(_0x4005ed(0xce))/0x9;if(_0x54e826===_0x574fb4)break;else _0xb95379['push'](_0xb95379['shift']());}catch(_0x2a62d5){_0xb95379['push'](_0xb95379['shift']());}}}(_0x8064,0xadce3));export class KernelFileAssistantListener{[_0x4853c7(0xd4)](..._0x7829be){}[_0x4853c7(0xcf)](..._0x5a79a1){}['onSessionChanged'](..._0x1aed20){}[_0x4853c7(0xd3)](..._0x448c87){}[_0x4853c7(0xd2)](..._0x33c424){}}function _0x5e88(_0xb274cd,_0x3b853d){var _0x806412=_0x8064();return _0x5e88=function(_0x5e887f,_0x1546d6){_0x5e887f=_0x5e887f-0xcb;var _0x27a304=_0x806412[_0x5e887f];return _0x27a304;},_0x5e88(_0xb274cd,_0x3b853d);}function _0x8064(){var _0xafb6f5=['4236030MCvGNt','3401230gZIaNq','onFileSearch','onFileListChanged','onFileStatusChanged','184499SqhNVq','424HGNNQv','399648AxnVMu','15KnNaQh','272807XcaZGW','418436HfaDTG','22621446HbBvrG','onSessionListChanged'];_0x8064=function(){return _0xafb6f5;};return _0x8064();}
function _0x59c8(_0x5120b1,_0x3679c0){var _0x1fdb21=_0x1fdb();return _0x59c8=function(_0x59c8c1,_0x4e0255){_0x59c8c1=_0x59c8c1-0x81;var _0x300360=_0x1fdb21[_0x59c8c1];return _0x300360;},_0x59c8(_0x5120b1,_0x3679c0);}var _0x11ca3f=_0x59c8;(function(_0xfa6ba5,_0x39f83f){var _0x39f962=_0x59c8,_0x398357=_0xfa6ba5();while(!![]){try{var _0x39c42d=-parseInt(_0x39f962(0x8c))/0x1+-parseInt(_0x39f962(0x8a))/0x2+-parseInt(_0x39f962(0x86))/0x3+-parseInt(_0x39f962(0x8b))/0x4+parseInt(_0x39f962(0x83))/0x5+-parseInt(_0x39f962(0x85))/0x6*(-parseInt(_0x39f962(0x81))/0x7)+parseInt(_0x39f962(0x89))/0x8;if(_0x39c42d===_0x39f83f)break;else _0x398357['push'](_0x398357['shift']());}catch(_0x46e50b){_0x398357['push'](_0x398357['shift']());}}}(_0x1fdb,0x1fdc0));function _0x1fdb(){var _0x3738dc=['222532hOHKhJ','118077IzePtn','407064UICAVX','onSessionChanged','140265RqlVkS','onFileSearch','12NMBEuw','136122DIlTLI','onSessionListChanged','onFileStatusChanged','1865744ntkQrY','55990AGxpSD'];_0x1fdb=function(){return _0x3738dc;};return _0x1fdb();}export class KernelFileAssistantListener{[_0x11ca3f(0x88)](..._0x53a30b){}[_0x11ca3f(0x87)](..._0x4432e1){}[_0x11ca3f(0x82)](..._0x56ba18){}['onFileListChanged'](..._0x80b647){}[_0x11ca3f(0x84)](..._0x4a33e9){}}

File diff suppressed because one or more lines are too long

View File

@@ -1 +1 @@
var _0x2c2191=_0x57cf;function _0x57cf(_0x1324ed,_0x1af608){var _0x1e621b=_0x1e62();return _0x57cf=function(_0x57cf4f,_0x89d541){_0x57cf4f=_0x57cf4f-0xa1;var _0x7d6835=_0x1e621b[_0x57cf4f];return _0x7d6835;},_0x57cf(_0x1324ed,_0x1af608);}(function(_0x356fe1,_0x443ea9){var _0x382dfc=_0x57cf,_0x4a9b78=_0x356fe1();while(!![]){try{var _0x26e9d0=parseInt(_0x382dfc(0xaa))/0x1+-parseInt(_0x382dfc(0xa8))/0x2*(-parseInt(_0x382dfc(0xb5))/0x3)+-parseInt(_0x382dfc(0xb4))/0x4*(-parseInt(_0x382dfc(0xa3))/0x5)+-parseInt(_0x382dfc(0xb9))/0x6*(parseInt(_0x382dfc(0xb0))/0x7)+parseInt(_0x382dfc(0xb6))/0x8*(parseInt(_0x382dfc(0xaf))/0x9)+parseInt(_0x382dfc(0xae))/0xa*(parseInt(_0x382dfc(0xa6))/0xb)+-parseInt(_0x382dfc(0xb3))/0xc*(parseInt(_0x382dfc(0xa9))/0xd);if(_0x26e9d0===_0x443ea9)break;else _0x4a9b78['push'](_0x4a9b78['shift']());}catch(_0x28dab1){_0x4a9b78['push'](_0x4a9b78['shift']());}}}(_0x1e62,0xcc7f1));function _0x1e62(){var _0x259fea=['onUserLoggedIn','onPasswordLoginFailed','42bHkoSX','onLogoutFailed','onQQLoginNumLimited','15MbuqSR','onQRCodeLoginPollingStarted','OnConfirmUnusualDeviceFailed','3301353yVYyDC','onQRCodeGetPicture','254724rwQgsy','23832705CAyUpG','1547978SHXeHG','onLoginConnected','onLoginDisConnected','onQRCodeLoginSucceed','10OLsfGP','18zRxOjM','207382LHaOVH','onQRCodeSessionUserScaned','onQRCodeSessionFailed','12ZVFJeW','273804EYtUZH','3JiPZUJ','2789872rETlDU'];_0x1e62=function(){return _0x259fea;};return _0x1e62();}export class LoginListener{[_0x2c2191(0xab)](..._0x140a64){}[_0x2c2191(0xac)](..._0x3bcbc1){}['onLoginConnecting'](..._0xd0d306){}[_0x2c2191(0xa7)](_0x1c0929){}[_0x2c2191(0xa4)](..._0x24cac1){}[_0x2c2191(0xb1)](..._0x360dc8){}[_0x2c2191(0xad)](_0x3a9880){}[_0x2c2191(0xb2)](..._0x2b64a5){}['onLoginFailed'](..._0x567a84){}['onLogoutSucceed'](..._0x5e108f){}[_0x2c2191(0xa1)](..._0x2c631a){}[_0x2c2191(0xb7)](..._0xbfe86){}['onQRCodeSessionQuickLoginFailed'](..._0x3fbdf2){}[_0x2c2191(0xb8)](..._0x23f439){}[_0x2c2191(0xa5)](..._0x2b4043){}[_0x2c2191(0xa2)](..._0x41415b){}['onLoginState'](..._0x1a4bdc){}}
function _0x454a(_0x42e5a7,_0x3a3c11){var _0xb75d88=_0xb75d();return _0x454a=function(_0x454a2d,_0x5bcb95){_0x454a2d=_0x454a2d-0x107;var _0x15d5fa=_0xb75d88[_0x454a2d];return _0x15d5fa;},_0x454a(_0x42e5a7,_0x3a3c11);}var _0x5b372b=_0x454a;(function(_0x4ac01d,_0x2000d3){var _0x1ea469=_0x454a,_0xbf30c6=_0x4ac01d();while(!![]){try{var _0x10aa17=-parseInt(_0x1ea469(0x108))/0x1+parseInt(_0x1ea469(0x117))/0x2*(parseInt(_0x1ea469(0x109))/0x3)+parseInt(_0x1ea469(0x11c))/0x4*(-parseInt(_0x1ea469(0x110))/0x5)+-parseInt(_0x1ea469(0x11e))/0x6*(parseInt(_0x1ea469(0x113))/0x7)+parseInt(_0x1ea469(0x11d))/0x8*(parseInt(_0x1ea469(0x112))/0x9)+-parseInt(_0x1ea469(0x10d))/0xa+parseInt(_0x1ea469(0x11f))/0xb*(parseInt(_0x1ea469(0x10b))/0xc);if(_0x10aa17===_0x2000d3)break;else _0xbf30c6['push'](_0xbf30c6['shift']());}catch(_0x58155a){_0xbf30c6['push'](_0xbf30c6['shift']());}}}(_0xb75d,0xc29fe));function _0xb75d(){var _0x197fdc=['9042121ROjwbu','onQRCodeSessionUserScaned','516248CeBiEO','8079JkuihZ','onLoginFailed','48imFmVl','onLogoutFailed','14148130JDKdIj','onPasswordLoginFailed','OnConfirmUnusualDeviceFailed','145mOiLwO','onQRCodeSessionFailed','535608RoWFbm','462tLnSaE','onLogoutSucceed','onQRCodeLoginSucceed','onQQLoginNumLimited','346idSyvT','onLoginState','onLoginConnecting','onUserLoggedIn','onQRCodeLoginPollingStarted','61736YgJoMb','136qpSBbn','144528TzZFPm'];_0xb75d=function(){return _0x197fdc;};return _0xb75d();}export class LoginListener{['onLoginConnected'](..._0x34088f){}['onLoginDisConnected'](..._0x160399){}[_0x5b372b(0x119)](..._0x370042){}['onQRCodeGetPicture'](_0x89bbf6){}[_0x5b372b(0x11b)](..._0x4d8e73){}[_0x5b372b(0x107)](..._0x3e4379){}[_0x5b372b(0x115)](_0x20adf0){}[_0x5b372b(0x111)](..._0x339703){}[_0x5b372b(0x10a)](..._0x2c1b8){}[_0x5b372b(0x114)](..._0x60de2c){}[_0x5b372b(0x10c)](..._0x40488d){}[_0x5b372b(0x11a)](..._0x8637fe){}['onQRCodeSessionQuickLoginFailed'](..._0x38e457){}[_0x5b372b(0x10e)](..._0x36087b){}[_0x5b372b(0x10f)](..._0xa3ed73){}[_0x5b372b(0x116)](..._0x37fcb3){}[_0x5b372b(0x118)](..._0x20f71e){}}

View File

@@ -1 +1 @@
function _0x20e7(_0x428e24,_0xc70b29){var _0x2fdce0=_0x2fdc();return _0x20e7=function(_0x20e770,_0x59667c){_0x20e770=_0x20e770-0x1ca;var _0x566d75=_0x2fdce0[_0x20e770];return _0x566d75;},_0x20e7(_0x428e24,_0xc70b29);}var _0x5988e5=_0x20e7;(function(_0x5c73a6,_0x36a829){var _0xf46355=_0x20e7,_0x5bc38b=_0x5c73a6();while(!![]){try{var _0x34de2f=-parseInt(_0xf46355(0x1f0))/0x1+-parseInt(_0xf46355(0x207))/0x2*(-parseInt(_0xf46355(0x1d5))/0x3)+-parseInt(_0xf46355(0x201))/0x4+parseInt(_0xf46355(0x1f9))/0x5*(-parseInt(_0xf46355(0x1ea))/0x6)+-parseInt(_0xf46355(0x1d4))/0x7*(parseInt(_0xf46355(0x208))/0x8)+-parseInt(_0xf46355(0x1e2))/0x9+parseInt(_0xf46355(0x1d2))/0xa;if(_0x34de2f===_0x36a829)break;else _0x5bc38b['push'](_0x5bc38b['shift']());}catch(_0x4bfc67){_0x5bc38b['push'](_0x5bc38b['shift']());}}}(_0x2fdc,0xafa25));function _0x2fdc(){var _0x1fd550=['onGroupFileInfoAdd','onNtMsgSyncStart','onNtFirstViewMsgSyncEnd','onFeedEventUpdate','onMsgBoxChanged','onMsgSecurityNotify','onDraftUpdate','10JrrQhg','onInputStatusPush','onRedTouchChanged','onChannelFreqLimitInfoUpdate','onRichMediaProgerssUpdate','onReadFeedEventUpdate','onRecvMsgSvrRspTransInfo','onGroupGuildUpdate','227588EcJjMu','onHitCsRelatedEmojiResult','onGuildMsgAbFlagChanged','onHitEmojiKeywordResult','onContactUnreadCntUpdate','onFirstViewDirectMsgUpdate','2nTwbtb','8SsmRzF','onUserSecQualityChanged','onlineStatusSmallIconDownloadPush','onBroadcastHelperDownloadComplete','onMsgWithRichLinkInfoUpdate','onSysMsgNotification','onNtMsgSyncEnd','onCustomWithdrawConfigUpdate','onEmojiDownloadComplete','32428930jqyVun','onUserChannelTabStatusChanged','3943506JjgZjn','2195574ykTHiK','onMsgInfoListAdd','onMsgDelete','onTempChatInfoUpdate','onRecvSysMsg','onSearchGroupFileInfoUpdate','onUserOnlineStatusChanged','onImportOldDbProgressUpdate','onAddSendMsg','onMsgQRCodeStatusChanged','onBroadcastHelperProgressUpdate','onRecvMsg','onGuildNotificationAbstractUpdate','6438474zABuyZ','onLineDev','onRecvS2CMsg','onGroupFileInfoUpdate','onRecvOnlineFileMsg','onMsgRecall','onGuildInteractiveUpdate','onFirstViewGroupGuildMapping','1649238vEWbhi','onFileMsgCome','onUserTabStatusChanged','onUnreadCntAfterFirstView','onEmojiResourceUpdate','onMsgEventListUpdate','1369967SPSSYt','onRichMediaDownloadComplete'];_0x2fdc=function(){return _0x1fd550;};return _0x2fdc();}export class MsgListener{[_0x5988e5(0x1dd)](_0x2627d1){}[_0x5988e5(0x1cc)](_0x581dab){}[_0x5988e5(0x1df)](_0x2860a5){}[_0x5988e5(0x1fc)](_0x4d089f,_0x182f5f,_0x5de901){}[_0x5988e5(0x205)](_0x298d59){}[_0x5988e5(0x1d0)](_0x54d224){}[_0x5988e5(0x1f8)](_0x201d8b,_0x16682b,_0x3ce339){}[_0x5988e5(0x1d1)](_0x869d24){}[_0x5988e5(0x1ee)](_0x31af9f){}[_0x5988e5(0x1f5)](_0x374919){}[_0x5988e5(0x1eb)](_0xd5934e){}[_0x5988e5(0x206)](_0x36852d){}[_0x5988e5(0x1e9)](_0x35c1f7){}['onGrabPasswordRedBag'](_0xd60c90,_0x366042,_0x6d9d0b,_0x45d33c,_0x5a4e6a){}[_0x5988e5(0x1f2)](_0x3cea98){}[_0x5988e5(0x1e5)](_0x5f02d9){}[_0x5988e5(0x200)](_0x404fd8){}['onGroupTransferInfoAdd'](_0x128bca){}['onGroupTransferInfoUpdate'](_0x184191){}[_0x5988e5(0x1e8)](_0x552b28){}[_0x5988e5(0x203)](_0x6fcc4b){}[_0x5988e5(0x1e1)](_0x2d8025){}[_0x5988e5(0x202)](_0x3ab660){}[_0x5988e5(0x204)](_0x19898f){}['onHitRelatedEmojiResult'](_0x3467fa){}[_0x5988e5(0x1dc)](_0x150937){}[_0x5988e5(0x1fa)](_0x4201e1){}['onKickedOffLine'](_0x5f4128){}[_0x5988e5(0x1e3)](_0x1c8d14){}['onLogLevelChanged'](_0xa7d93b){}['onMsgAbstractUpdate'](_0x25a75b){}[_0x5988e5(0x1f6)](_0x9b4b73){}[_0x5988e5(0x1d7)](_0xdf942e,_0x3b46b6){}[_0x5988e5(0x1ef)](_0xfa728c){}[_0x5988e5(0x1d6)](_0x5dac8c){}['onMsgInfoListUpdate'](_0x486e18){}[_0x5988e5(0x1de)](_0x8a08ee){}[_0x5988e5(0x1e7)](_0xa59f15,_0x1b5a70,_0xd96c14){}[_0x5988e5(0x1f7)](_0x49f5d0){}['onMsgSettingUpdate'](_0x3357f5){}[_0x5988e5(0x1f4)](){}[_0x5988e5(0x1cf)](){}[_0x5988e5(0x1f3)](){}[_0x5988e5(0x1fe)](_0x38305e){}['onRecvGroupGuildFlag'](_0x1d913c){}[_0x5988e5(0x1e0)](_0x173f22){}[_0x5988e5(0x1ff)](_0x51f1f2,_0x3bf851,_0x4f3082,_0x24bcac,_0x55a28b,_0x5e045e){}[_0x5988e5(0x1e6)](_0x228821){}[_0x5988e5(0x1e4)](_0x1ef279){}[_0x5988e5(0x1d9)](_0x10e664){}['onRecvUDCFlag'](_0x4b9bcc){}[_0x5988e5(0x1f1)](_0xd3dea7){}[_0x5988e5(0x1fd)](_0x9dffc4){}['onRichMediaUploadComplete'](_0x478c59){}[_0x5988e5(0x1da)](_0x5b4446){}['onSendMsgError'](_0x180929,_0x5f30a3,_0x344036,_0x3e5784){}[_0x5988e5(0x1ce)](_0x200ca7,_0x411792,_0x4bf43c,_0x25b204){}[_0x5988e5(0x1d8)](_0xa1d8a){}[_0x5988e5(0x1ed)](_0x25ee3f){}['onUnreadCntUpdate'](_0x35da29){}[_0x5988e5(0x1d3)](_0x58b690){}[_0x5988e5(0x1db)](_0xc47ba3){}[_0x5988e5(0x1ec)](_0x5b5fda){}['onlineStatusBigIconDownloadPush'](_0x4c079a,_0xc011b6,_0xfa58f5){}[_0x5988e5(0x1cb)](_0x5f3bd3,_0x529ec5,_0x5f36fe){}[_0x5988e5(0x1ca)](..._0x9517ee){}[_0x5988e5(0x1cd)](..._0xddadba){}[_0x5988e5(0x1fb)](..._0x31dca2){}['onBroadcastHelperProgerssUpdate'](..._0x116a78){}}
function _0x2d93(_0x4d1934,_0x4b3066){var _0x411ede=_0x411e();return _0x2d93=function(_0x2d9323,_0x3947ab){_0x2d9323=_0x2d9323-0x6b;var _0x35ed22=_0x411ede[_0x2d9323];return _0x35ed22;},_0x2d93(_0x4d1934,_0x4b3066);}var _0x563d20=_0x2d93;(function(_0x26db2a,_0x28c2d4){var _0xc1c9de=_0x2d93,_0x3e3323=_0x26db2a();while(!![]){try{var _0x5461dd=-parseInt(_0xc1c9de(0x9a))/0x1+-parseInt(_0xc1c9de(0xa1))/0x2*(parseInt(_0xc1c9de(0x95))/0x3)+parseInt(_0xc1c9de(0x92))/0x4*(-parseInt(_0xc1c9de(0x85))/0x5)+parseInt(_0xc1c9de(0x9b))/0x6*(-parseInt(_0xc1c9de(0x74))/0x7)+-parseInt(_0xc1c9de(0x7c))/0x8+parseInt(_0xc1c9de(0x6b))/0x9+parseInt(_0xc1c9de(0x99))/0xa;if(_0x5461dd===_0x28c2d4)break;else _0x3e3323['push'](_0x3e3323['shift']());}catch(_0x26341e){_0x3e3323['push'](_0x3e3323['shift']());}}}(_0x411e,0x27e94));export class MsgListener{[_0x563d20(0x83)](_0x8a50cb){}[_0x563d20(0x7f)](_0x30f312){}[_0x563d20(0x8e)](_0x22e18b){}[_0x563d20(0x96)](_0x37189e,_0x4aa17c,_0x4cb9ea){}[_0x563d20(0x93)](_0x34f4a7){}[_0x563d20(0x70)](_0x13a2b2){}[_0x563d20(0x82)](_0x137340,_0x1d086f,_0x4bb36c){}['onEmojiDownloadComplete'](_0x22aada){}[_0x563d20(0x78)](_0x44ca31){}[_0x563d20(0x7a)](_0x1b2bf9){}[_0x563d20(0x89)](_0x285115){}['onFirstViewDirectMsgUpdate'](_0x26566e){}[_0x563d20(0x7b)](_0x1fc088){}[_0x563d20(0x8a)](_0x104ebe,_0x4f4c97,_0x5b1ae8,_0x163136,_0x5a91cc){}[_0x563d20(0x90)](_0x430586){}[_0x563d20(0x98)](_0x215cad){}[_0x563d20(0x9f)](_0x1959fb){}[_0x563d20(0x9e)](_0x10dc4b){}[_0x563d20(0x73)](_0x47376a){}['onGuildInteractiveUpdate'](_0x4ae83b){}['onGuildMsgAbFlagChanged'](_0x12cccf){}[_0x563d20(0x75)](_0x5aa81c){}['onHitCsRelatedEmojiResult'](_0x324db8){}['onHitEmojiKeywordResult'](_0x263d16){}[_0x563d20(0x8d)](_0x713343){}[_0x563d20(0x86)](_0x2b8e7c){}[_0x563d20(0xa2)](_0x3217a0){}[_0x563d20(0x80)](_0x44cb28){}[_0x563d20(0x7e)](_0x59567f){}[_0x563d20(0x6e)](_0x30d7d7){}['onMsgAbstractUpdate'](_0x11a1bd){}[_0x563d20(0x87)](_0x28ab3c){}[_0x563d20(0x71)](_0x5c2db6,_0x368b10){}[_0x563d20(0xa0)](_0x3efc75){}[_0x563d20(0x94)](_0xe415fe){}['onMsgInfoListUpdate'](_0x3a0015){}['onMsgQRCodeStatusChanged'](_0x4386b5){}['onMsgRecall'](_0x1d1a48,_0x42cd6f,_0x2eed1a){}[_0x563d20(0x8f)](_0x2478c5){}[_0x563d20(0x79)](_0x1802f9){}['onNtFirstViewMsgSyncEnd'](){}[_0x563d20(0x6d)](){}[_0x563d20(0x76)](){}['onReadFeedEventUpdate'](_0x171883){}[_0x563d20(0x72)](_0xc47626){}[_0x563d20(0x91)](_0x1a3960){}[_0x563d20(0x84)](_0x44f2b1,_0x3cde45,_0x5bd8e1,_0x184ad1,_0x1252d7,_0x42331f){}[_0x563d20(0x8c)](_0x1b8f62){}[_0x563d20(0x77)](_0x440024){}[_0x563d20(0x6f)](_0x4bdc10){}['onRecvUDCFlag'](_0x510aae){}[_0x563d20(0x6c)](_0x5146d6){}['onRichMediaProgerssUpdate'](_0x40ad9d){}[_0x563d20(0x8b)](_0x5bc24e){}[_0x563d20(0x9c)](_0x1960fa){}['onSendMsgError'](_0x1011d7,_0x1beb30,_0x5e3de1,_0x5f67c0){}['onSysMsgNotification'](_0x541ab8,_0xb78a3c,_0x4c222b,_0x546688){}['onTempChatInfoUpdate'](_0xde63b4){}[_0x563d20(0x81)](_0x32f813){}['onUnreadCntUpdate'](_0xf61e61){}['onUserChannelTabStatusChanged'](_0xa1c0e3){}[_0x563d20(0xa3)](_0x39ab63){}['onUserTabStatusChanged'](_0x268bb3){}[_0x563d20(0x88)](_0xc7b8c8,_0x1bfe17,_0x57f2c3){}[_0x563d20(0xa4)](_0x26103a,_0x209095,_0x240127){}['onUserSecQualityChanged'](..._0x2e3405){}[_0x563d20(0x97)](..._0x3c4916){}[_0x563d20(0x7d)](..._0x16772c){}[_0x563d20(0x9d)](..._0x252c67){}}function _0x411e(){var _0x128d5c=['onSearchGroupFileInfoUpdate','onBroadcastHelperProgerssUpdate','onGroupTransferInfoAdd','onGroupGuildUpdate','onMsgEventListUpdate','10yLCYFZ','onInputStatusPush','onUserOnlineStatusChanged','onlineStatusSmallIconDownloadPush','2071017qdokCZ','onRichMediaDownloadComplete','onNtMsgSyncEnd','onLogLevelChanged','onRecvSysMsg','onCustomWithdrawConfigUpdate','onMsgDelete','onRecvGroupGuildFlag','onGroupTransferInfoUpdate','35BwxcGx','onGuildNotificationAbstractUpdate','onNtMsgSyncStart','onRecvS2CMsg','onEmojiResourceUpdate','onMsgSettingUpdate','onFeedEventUpdate','onFirstViewGroupGuildMapping','758544fTdMrO','onRedTouchChanged','onLineDev','onBroadcastHelperDownloadComplete','onKickedOffLine','onUnreadCntAfterFirstView','onDraftUpdate','onAddSendMsg','onRecvMsgSvrRspTransInfo','435815YOoYoj','onImportOldDbProgressUpdate','onMsgBoxChanged','onlineStatusBigIconDownloadPush','onFileMsgCome','onGrabPasswordRedBag','onRichMediaUploadComplete','onRecvOnlineFileMsg','onHitRelatedEmojiResult','onBroadcastHelperProgressUpdate','onMsgSecurityNotify','onGroupFileInfoAdd','onRecvMsg','4RMtbEB','onContactUnreadCntUpdate','onMsgInfoListAdd','178377ckOVTM','onChannelFreqLimitInfoUpdate','onMsgWithRichLinkInfoUpdate','onGroupFileInfoUpdate','7024470cWaiyM','41673aCqLma','297762WsxMEV'];_0x411e=function(){return _0x128d5c;};return _0x411e();}

View File

@@ -1 +1 @@
function _0x126f(_0x24bd9e,_0x5af36b){var _0x50ec22=_0x50ec();return _0x126f=function(_0x126f24,_0x2f48f4){_0x126f24=_0x126f24-0x8d;var _0x476815=_0x50ec22[_0x126f24];return _0x476815;},_0x126f(_0x24bd9e,_0x5af36b);}var _0x27707c=_0x126f;function _0x50ec(){var _0x2a38e9=['2792321YnOPpl','2LKBTnS','onSelfStatusChanged','897723VRpDmE','4557088EXHWdW','onProfileDetailInfoChanged','226876ViCJTN','346916lRmOuW','onStatusUpdate','54qTfZNl','12gwlpPp','onStrangerRemarkChanged','onProfileSimpleChanged','4328115kXUcgm','43018500WeaFvG'];_0x50ec=function(){return _0x2a38e9;};return _0x50ec();}(function(_0x5083d5,_0x15b8aa){var _0x5b85e7=_0x126f,_0x3728da=_0x5083d5();while(!![]){try{var _0x434bde=parseInt(_0x5b85e7(0x91))/0x1*(-parseInt(_0x5b85e7(0x97))/0x2)+parseInt(_0x5b85e7(0x99))/0x3*(-parseInt(_0x5b85e7(0x96))/0x4)+-parseInt(_0x5b85e7(0x8e))/0x5+-parseInt(_0x5b85e7(0x9a))/0x6*(parseInt(_0x5b85e7(0x90))/0x7)+-parseInt(_0x5b85e7(0x94))/0x8+-parseInt(_0x5b85e7(0x93))/0x9+parseInt(_0x5b85e7(0x8f))/0xa;if(_0x434bde===_0x15b8aa)break;else _0x3728da['push'](_0x3728da['shift']());}catch(_0x5948ce){_0x3728da['push'](_0x3728da['shift']());}}}(_0x50ec,0x92c5c));export class ProfileListener{[_0x27707c(0x8d)](..._0x4199c5){}[_0x27707c(0x95)](_0x23cc3c){}[_0x27707c(0x98)](..._0x584f39){}[_0x27707c(0x92)](..._0x49957d){}[_0x27707c(0x9b)](..._0x132c8b){}}
var _0x6ae8ac=_0x6441;(function(_0x14949f,_0x1a5bf7){var _0x4e981f=_0x6441,_0x45b76f=_0x14949f();while(!![]){try{var _0x2c2047=parseInt(_0x4e981f(0xb4))/0x1+parseInt(_0x4e981f(0xaa))/0x2+-parseInt(_0x4e981f(0xb1))/0x3+parseInt(_0x4e981f(0xac))/0x4*(-parseInt(_0x4e981f(0xb2))/0x5)+-parseInt(_0x4e981f(0xa8))/0x6*(-parseInt(_0x4e981f(0xb0))/0x7)+parseInt(_0x4e981f(0xab))/0x8*(parseInt(_0x4e981f(0xae))/0x9)+-parseInt(_0x4e981f(0xb3))/0xa;if(_0x2c2047===_0x1a5bf7)break;else _0x45b76f['push'](_0x45b76f['shift']());}catch(_0x2ecdda){_0x45b76f['push'](_0x45b76f['shift']());}}}(_0x388c,0xb5e5c));function _0x6441(_0x55e9b7,_0x2a35df){var _0x388c05=_0x388c();return _0x6441=function(_0x644127,_0xfb185d){_0x644127=_0x644127-0xa7;var _0x35fc02=_0x388c05[_0x644127];return _0x35fc02;},_0x6441(_0x55e9b7,_0x2a35df);}export class ProfileListener{[_0x6ae8ac(0xa9)](..._0x16c17d){}[_0x6ae8ac(0xaf)](_0x17b6ce){}['onStatusUpdate'](..._0x27345c){}[_0x6ae8ac(0xa7)](..._0x134828){}[_0x6ae8ac(0xad)](..._0x2ddf19){}}function _0x388c(){var _0x2e2571=['1481994ziaioA','25FbnqdO','15794640LqcaQp','914700nkcuEW','onSelfStatusChanged','5682zRgLAD','onProfileSimpleChanged','2301576aDSYsJ','8kAmfAj','495536owoREI','onStrangerRemarkChanged','1186884GDzSzk','onProfileDetailInfoChanged','9170DlyHBn'];_0x388c=function(){return _0x2e2571;};return _0x388c();}

View File

@@ -1 +1 @@
function _0x3f73(){var _0x43fcff=['onRobotProfileChanged','205106EnguQn','4847059PfkNeq','387047yeYDsj','1862260MruHfa','22584xrfWLm','3GtXWPi','369BvPiti','70bbuEtR','onRobotFriendListChanged','2567118BaPhAm','491086FeXLae','5hQlSpz'];_0x3f73=function(){return _0x43fcff;};return _0x3f73();}var _0x257027=_0x6a51;function _0x6a51(_0x2c9957,_0x4f2f68){var _0x3f73fb=_0x3f73();return _0x6a51=function(_0x6a5135,_0x330e8d){_0x6a5135=_0x6a5135-0xe3;var _0x469a32=_0x3f73fb[_0x6a5135];return _0x469a32;},_0x6a51(_0x2c9957,_0x4f2f68);}(function(_0x46cac2,_0x2259df){var _0x48cff1=_0x6a51,_0x23b9b7=_0x46cac2();while(!![]){try{var _0x328a4f=parseInt(_0x48cff1(0xe7))/0x1+parseInt(_0x48cff1(0xef))/0x2*(-parseInt(_0x48cff1(0xea))/0x3)+parseInt(_0x48cff1(0xe8))/0x4*(parseInt(_0x48cff1(0xe3))/0x5)+parseInt(_0x48cff1(0xee))/0x6+-parseInt(_0x48cff1(0xe6))/0x7+-parseInt(_0x48cff1(0xe9))/0x8*(parseInt(_0x48cff1(0xeb))/0x9)+parseInt(_0x48cff1(0xec))/0xa*(parseInt(_0x48cff1(0xe5))/0xb);if(_0x328a4f===_0x2259df)break;else _0x23b9b7['push'](_0x23b9b7['shift']());}catch(_0x1ca7cb){_0x23b9b7['push'](_0x23b9b7['shift']());}}}(_0x3f73,0x57390));export class KernelRobotListener{[_0x257027(0xed)](..._0x9e6013){}['onRobotListChanged'](..._0x597224){}[_0x257027(0xe4)](..._0x6ed318){}}
var _0x213048=_0x3929;(function(_0x50715c,_0x4867dd){var _0x188bd8=_0x3929,_0x31b40e=_0x50715c();while(!![]){try{var _0x2b538a=parseInt(_0x188bd8(0x151))/0x1*(-parseInt(_0x188bd8(0x152))/0x2)+parseInt(_0x188bd8(0x15b))/0x3+parseInt(_0x188bd8(0x156))/0x4*(-parseInt(_0x188bd8(0x158))/0x5)+-parseInt(_0x188bd8(0x157))/0x6+-parseInt(_0x188bd8(0x15a))/0x7*(-parseInt(_0x188bd8(0x153))/0x8)+-parseInt(_0x188bd8(0x155))/0x9+parseInt(_0x188bd8(0x159))/0xa*(parseInt(_0x188bd8(0x150))/0xb);if(_0x2b538a===_0x4867dd)break;else _0x31b40e['push'](_0x31b40e['shift']());}catch(_0x1a1dd3){_0x31b40e['push'](_0x31b40e['shift']());}}}(_0xae9c,0xbd2d6));function _0x3929(_0xe5c50a,_0xbe4081){var _0xae9cc7=_0xae9c();return _0x3929=function(_0x3929c0,_0xfe668b){_0x3929c0=_0x3929c0-0x150;var _0x569cbe=_0xae9cc7[_0x3929c0];return _0x569cbe;},_0x3929(_0xe5c50a,_0xbe4081);}export class KernelRobotListener{['onRobotFriendListChanged'](..._0x33d119){}[_0x213048(0x154)](..._0x1d0111){}['onRobotProfileChanged'](..._0x20105c){}}function _0xae9c(){var _0x5acba9=['1016lWkBFl','1221774UmidID','17745ttylet','10EYwLVK','9081597vZBXSY','3520218VUestZ','12930599iBqFuH','134yFyVGt','12886xieNPA','8zGDFmq','onRobotListChanged','8126811LFrfYL'];_0xae9c=function(){return _0x5acba9;};return _0xae9c();}

View File

@@ -1 +1 @@
var _0x5087c3=_0x4531;function _0x4531(_0x34042d,_0x19f8ec){var _0x12f2fb=_0x12f2();return _0x4531=function(_0x453176,_0x2d0164){_0x453176=_0x453176-0xb9;var _0x1e0379=_0x12f2fb[_0x453176];return _0x1e0379;},_0x4531(_0x34042d,_0x19f8ec);}(function(_0x5c3aed,_0x3244f0){var _0x219f2f=_0x4531,_0x5b32ae=_0x5c3aed();while(!![]){try{var _0x2dc36d=-parseInt(_0x219f2f(0xc8))/0x1*(-parseInt(_0x219f2f(0xb9))/0x2)+parseInt(_0x219f2f(0xba))/0x3*(parseInt(_0x219f2f(0xbd))/0x4)+parseInt(_0x219f2f(0xbb))/0x5*(-parseInt(_0x219f2f(0xc9))/0x6)+parseInt(_0x219f2f(0xc2))/0x7*(-parseInt(_0x219f2f(0xc4))/0x8)+-parseInt(_0x219f2f(0xc3))/0x9*(-parseInt(_0x219f2f(0xcb))/0xa)+parseInt(_0x219f2f(0xca))/0xb*(-parseInt(_0x219f2f(0xc7))/0xc)+-parseInt(_0x219f2f(0xc6))/0xd*(-parseInt(_0x219f2f(0xbf))/0xe);if(_0x2dc36d===_0x3244f0)break;else _0x5b32ae['push'](_0x5b32ae['shift']());}catch(_0x95dc2){_0x5b32ae['push'](_0x5b32ae['shift']());}}}(_0x12f2,0xb990a));export class SessionListener{[_0x5087c3(0xbc)](_0x593108){}[_0x5087c3(0xc0)](_0x4e6db2){}[_0x5087c3(0xc1)](_0xa188b6){}[_0x5087c3(0xc5)](_0x4bb1e4){}['onUserOnlineResult'](_0x36bcfc){}[_0x5087c3(0xbe)](_0x1a4402){}}function _0x12f2(){var _0x80a1fa=['4452vIcPLz','3295836AefmHk','17944MEsKDv','onOpentelemetryInit','143MTkOBO','48552RWjUQP','252tcODuq','726HDTLny','814jLHhcq','10TVEQru','11042zFMGiU','1723293jrKWEg','43395lLXgge','onNTSessionCreate','4kamPRj','onGetSelfTinyId','1532692wJuQIz','onGProSessionCreate','onSessionInitComplete'];_0x12f2=function(){return _0x80a1fa;};return _0x12f2();}
var _0x422bea=_0x5926;function _0x5926(_0x2be58c,_0x350a92){var _0x16e4f2=_0x16e4();return _0x5926=function(_0x592644,_0x1a500b){_0x592644=_0x592644-0x1bf;var _0x1488f3=_0x16e4f2[_0x592644];return _0x1488f3;},_0x5926(_0x2be58c,_0x350a92);}function _0x16e4(){var _0x5ab9d0=['36OTuZVq','onSessionInitComplete','12818456OMIQHa','3395062HdFzCH','10FdiwNm','onGetSelfTinyId','162896kNYCla','545015DFZjQr','4261887GDgNPX','7UMwtAo','onNTSessionCreate','13711554DZGOcj','onGProSessionCreate','5901220PiuuQM'];_0x16e4=function(){return _0x5ab9d0;};return _0x16e4();}(function(_0x47fc34,_0x49f5c8){var _0x20c533=_0x5926,_0x2ccbe6=_0x47fc34();while(!![]){try{var _0x431322=-parseInt(_0x20c533(0x1cc))/0x1+parseInt(_0x20c533(0x1c9))/0x2+parseInt(_0x20c533(0x1c0))/0x3+-parseInt(_0x20c533(0x1c5))/0x4+-parseInt(_0x20c533(0x1bf))/0x5*(parseInt(_0x20c533(0x1c6))/0x6)+-parseInt(_0x20c533(0x1c1))/0x7*(-parseInt(_0x20c533(0x1c8))/0x8)+parseInt(_0x20c533(0x1c3))/0x9*(-parseInt(_0x20c533(0x1ca))/0xa);if(_0x431322===_0x49f5c8)break;else _0x2ccbe6['push'](_0x2ccbe6['shift']());}catch(_0x48f388){_0x2ccbe6['push'](_0x2ccbe6['shift']());}}}(_0x16e4,0xdce26));export class SessionListener{[_0x422bea(0x1c2)](_0x213a2f){}[_0x422bea(0x1c4)](_0x568289){}[_0x422bea(0x1c7)](_0x35c515){}['onOpentelemetryInit'](_0x42cd3a){}['onUserOnlineResult'](_0x5f790e){}[_0x422bea(0x1cb)](_0x28c799){}}

View File

@@ -1 +1 @@
function _0x32cd(_0x2f3066,_0x1feb5f){var _0x316275=_0x3162();return _0x32cd=function(_0x32cd06,_0x593090){_0x32cd06=_0x32cd06-0xc1;var _0x3ff089=_0x316275[_0x32cd06];return _0x3ff089;},_0x32cd(_0x2f3066,_0x1feb5f);}var _0x11f65d=_0x32cd;function _0x3162(){var _0x1feb88=['1372642yUNSAO','4RhhotB','30leltWE','24ivPOTa','11aUcYmo','1597719gzStJV','onChatCleanDone','1337380VHAxna','34049790dZTNNS','onCleanCacheProgressChanged','onFinishScan','4158666XRPTWy','2343117DQPicA','922730uAgcCZ'];_0x3162=function(){return _0x1feb88;};return _0x3162();}(function(_0x17b712,_0x13a0c4){var _0x130e48=_0x32cd,_0x1969e0=_0x17b712();while(!![]){try{var _0x3280ef=-parseInt(_0x130e48(0xc1))/0x1+parseInt(_0x130e48(0xc2))/0x2+-parseInt(_0x130e48(0xc7))/0x3*(parseInt(_0x130e48(0xc3))/0x4)+parseInt(_0x130e48(0xc9))/0x5*(-parseInt(_0x130e48(0xc4))/0x6)+-parseInt(_0x130e48(0xce))/0x7*(parseInt(_0x130e48(0xc5))/0x8)+parseInt(_0x130e48(0xcd))/0x9+-parseInt(_0x130e48(0xca))/0xa*(-parseInt(_0x130e48(0xc6))/0xb);if(_0x3280ef===_0x13a0c4)break;else _0x1969e0['push'](_0x1969e0['shift']());}catch(_0x49be8d){_0x1969e0['push'](_0x1969e0['shift']());}}}(_0x3162,0xb8b12));export class StorageCleanListener{[_0x11f65d(0xcb)](_0x230cdc){}['onScanCacheProgressChanged'](_0x50635a){}['onCleanCacheStorageChanged'](_0x477f79){}[_0x11f65d(0xcc)](_0xae0959){}[_0x11f65d(0xc8)](_0x53016c){}}
function _0x2a26(_0x4e5a42,_0x4dd1a1){var _0x3077e1=_0x3077();return _0x2a26=function(_0x2a261c,_0x3f6efe){_0x2a261c=_0x2a261c-0x14c;var _0xe43131=_0x3077e1[_0x2a261c];return _0xe43131;},_0x2a26(_0x4e5a42,_0x4dd1a1);}var _0x20c3a2=_0x2a26;(function(_0x1316f5,_0x1e5b8d){var _0x5cf60a=_0x2a26,_0x37fe68=_0x1316f5();while(!![]){try{var _0x38f5b9=parseInt(_0x5cf60a(0x14d))/0x1+parseInt(_0x5cf60a(0x150))/0x2+parseInt(_0x5cf60a(0x153))/0x3+-parseInt(_0x5cf60a(0x152))/0x4+-parseInt(_0x5cf60a(0x155))/0x5+parseInt(_0x5cf60a(0x154))/0x6+-parseInt(_0x5cf60a(0x14f))/0x7;if(_0x38f5b9===_0x1e5b8d)break;else _0x37fe68['push'](_0x37fe68['shift']());}catch(_0x1c30b6){_0x37fe68['push'](_0x37fe68['shift']());}}}(_0x3077,0x33774));export class StorageCleanListener{[_0x20c3a2(0x151)](_0x44484d){}[_0x20c3a2(0x14e)](_0xf481f3){}['onCleanCacheStorageChanged'](_0x1f1d38){}[_0x20c3a2(0x14c)](_0x1baab6){}['onChatCleanDone'](_0x4d5f81){}}function _0x3077(){var _0x2685e6=['654888jfqLXP','807789XEWKJA','2240622DovqNz','159530dlyoUs','onFinishScan','322114FysUDS','onScanCacheProgressChanged','5584425ktmvXe','478786beTnrd','onCleanCacheProgressChanged'];_0x3077=function(){return _0x2685e6;};return _0x3077();}

View File

@@ -1 +1 @@
(function(_0x73cffa,_0x20a9d5){var _0x5ec26b=_0x3dcb,_0x1c675a=_0x73cffa();while(!![]){try{var _0x39d906=-parseInt(_0x5ec26b(0x122))/0x1+parseInt(_0x5ec26b(0x120))/0x2*(-parseInt(_0x5ec26b(0x123))/0x3)+parseInt(_0x5ec26b(0x121))/0x4*(-parseInt(_0x5ec26b(0x11b))/0x5)+parseInt(_0x5ec26b(0x11c))/0x6+parseInt(_0x5ec26b(0x11f))/0x7+-parseInt(_0x5ec26b(0x11a))/0x8+parseInt(_0x5ec26b(0x11d))/0x9*(parseInt(_0x5ec26b(0x11e))/0xa);if(_0x39d906===_0x20a9d5)break;else _0x1c675a['push'](_0x1c675a['shift']());}catch(_0x4463cf){_0x1c675a['push'](_0x1c675a['shift']());}}}(_0x1bd2,0x4131b));export*from'./NodeIKernelSessionListener';export*from'./NodeIKernelLoginListener';export*from'./NodeIKernelMsgListener';export*from'./NodeIKernelGroupListener';function _0x3dcb(_0x23f63b,_0x2485d0){var _0x1bd21d=_0x1bd2();return _0x3dcb=function(_0x3dcb9a,_0x11d807){_0x3dcb9a=_0x3dcb9a-0x11a;var _0x4cd4fe=_0x1bd21d[_0x3dcb9a];return _0x4cd4fe;},_0x3dcb(_0x23f63b,_0x2485d0);}function _0x1bd2(){var _0x5cab13=['18280XwudgH','2440487PTiOTM','1214lqRIKr','4zLlQgg','475837KNPwQy','828PfRMlG','1672480llmZjF','926165ucoSWd','2840784majLdN','2376zXrOcd'];_0x1bd2=function(){return _0x5cab13;};return _0x1bd2();}export*from'./NodeIKernelBuddyListener';export*from'./NodeIKernelProfileListener';export*from'./NodeIKernelRobotListener';export*from'./NodeIKernelTicketListener';export*from'./NodeIKernelStorageCleanListener';export*from'./NodeIKernelFileAssistantListener';
(function(_0x1e77e5,_0x417bfc){var _0x5590b2=_0x579d,_0x44ffa5=_0x1e77e5();while(!![]){try{var _0x2b85f0=parseInt(_0x5590b2(0x1cb))/0x1*(parseInt(_0x5590b2(0x1c9))/0x2)+-parseInt(_0x5590b2(0x1c7))/0x3*(-parseInt(_0x5590b2(0x1d1))/0x4)+-parseInt(_0x5590b2(0x1cc))/0x5+parseInt(_0x5590b2(0x1d0))/0x6*(-parseInt(_0x5590b2(0x1c8))/0x7)+parseInt(_0x5590b2(0x1ce))/0x8+parseInt(_0x5590b2(0x1ca))/0x9*(parseInt(_0x5590b2(0x1cf))/0xa)+parseInt(_0x5590b2(0x1c6))/0xb*(-parseInt(_0x5590b2(0x1cd))/0xc);if(_0x2b85f0===_0x417bfc)break;else _0x44ffa5['push'](_0x44ffa5['shift']());}catch(_0x765508){_0x44ffa5['push'](_0x44ffa5['shift']());}}}(_0x5829,0xecbef));export*from'./NodeIKernelSessionListener';export*from'./NodeIKernelLoginListener';function _0x5829(){var _0x1a0d05=['180155MgsalM','12zXsWcI','10848TbyKgy','9160laCaIF','4776sQGHVb','4DNIjXW','21210343dLoBFN','3613779BYfACt','5971sLwnIa','66WJvGFg','13914KGkVwE','30026cTtwyH'];_0x5829=function(){return _0x1a0d05;};return _0x5829();}function _0x579d(_0x13475a,_0x4c92d4){var _0x58295f=_0x5829();return _0x579d=function(_0x579da0,_0x3c9b20){_0x579da0=_0x579da0-0x1c6;var _0x1ece43=_0x58295f[_0x579da0];return _0x1ece43;},_0x579d(_0x13475a,_0x4c92d4);}export*from'./NodeIKernelMsgListener';export*from'./NodeIKernelGroupListener';export*from'./NodeIKernelBuddyListener';export*from'./NodeIKernelProfileListener';export*from'./NodeIKernelRobotListener';export*from'./NodeIKernelTicketListener';export*from'./NodeIKernelStorageCleanListener';export*from'./NodeIKernelFileAssistantListener';

View File

@@ -1,4 +1,4 @@
import { ChatType, ElementType, Peer, RawMessage, SendMessageElement } from '@/core/entities';
import { ElementType, Peer, RawMessage, SendMessageElement } from '@/core/entities';
import { NodeIKernelMsgListener } from '@/core/listeners/NodeIKernelMsgListener';
import { GeneralCallResult } from '@/core/services/common';
export interface NodeIKernelMsgService {
@@ -119,7 +119,7 @@ export interface NodeIKernelMsgService {
setUnVisibleChannelCntInfo(...args: unknown[]): unknown;
setUnVisibleChannelTypeCntInfo(...args: unknown[]): unknown;
setVisibleGuildCntInfo(...args: unknown[]): unknown;
setMsgRead(chatType: ChatType, peerUid: string, guildId: string): Promise<GeneralCallResult>;
setMsgRead(peer: Peer): Promise<GeneralCallResult>;
setAllC2CAndGroupMsgRead(...args: unknown[]): unknown;
setGuildMsgRead(...args: unknown[]): unknown;
setAllGuildMsgRead(...args: unknown[]): unknown;

View File

@@ -1 +1 @@
function _0xf113(){var _0xcf5c86=['82061XArbOh','146312EdBSlm','7334450xiDBLn','6HadBFN','18640nBuqpE','156ArIVCT','8ZtJJyz','11kwtJnj','35882172LKCNAJ','2019393UBmAjm','430IjBrtk','741126aJGfcJ'];_0xf113=function(){return _0xcf5c86;};return _0xf113();}(function(_0x3b7e7e,_0x4f63d1){var _0x18aae4=_0x5854,_0x32bad7=_0x3b7e7e();while(!![]){try{var _0x2ca02d=-parseInt(_0x18aae4(0x180))/0x1+parseInt(_0x18aae4(0x182))/0x2*(-parseInt(_0x18aae4(0x184))/0x3)+-parseInt(_0x18aae4(0x185))/0x4*(parseInt(_0x18aae4(0x17f))/0x5)+-parseInt(_0x18aae4(0x186))/0x6*(parseInt(_0x18aae4(0x181))/0x7)+parseInt(_0x18aae4(0x17b))/0x8*(-parseInt(_0x18aae4(0x17e))/0x9)+parseInt(_0x18aae4(0x183))/0xa*(-parseInt(_0x18aae4(0x17c))/0xb)+parseInt(_0x18aae4(0x17d))/0xc;if(_0x2ca02d===_0x4f63d1)break;else _0x32bad7['push'](_0x32bad7['shift']());}catch(_0x137fdd){_0x32bad7['push'](_0x32bad7['shift']());}}}(_0xf113,0x6b443));function _0x5854(_0x5ee109,_0x2d8cac){var _0xf11387=_0xf113();return _0x5854=function(_0x5854c3,_0x3e6a29){_0x5854c3=_0x5854c3-0x17b;var _0x1494a4=_0xf11387[_0x5854c3];return _0x1494a4;},_0x5854(_0x5ee109,_0x2d8cac);}export var GeneralCallResultStatus;(function(_0x2fb038){_0x2fb038[_0x2fb038['OK']=0x0]='OK';}(GeneralCallResultStatus||(GeneralCallResultStatus={})));
(function(_0x419d50,_0x128099){var _0x419aa4=_0x57f7,_0x4fa903=_0x419d50();while(!![]){try{var _0x29d631=-parseInt(_0x419aa4(0xac))/0x1+-parseInt(_0x419aa4(0xaa))/0x2*(parseInt(_0x419aa4(0xa8))/0x3)+parseInt(_0x419aa4(0xb1))/0x4+parseInt(_0x419aa4(0xae))/0x5+-parseInt(_0x419aa4(0xaf))/0x6*(-parseInt(_0x419aa4(0xa9))/0x7)+-parseInt(_0x419aa4(0xad))/0x8*(parseInt(_0x419aa4(0xab))/0x9)+parseInt(_0x419aa4(0xb0))/0xa;if(_0x29d631===_0x128099)break;else _0x4fa903['push'](_0x4fa903['shift']());}catch(_0x510bd3){_0x4fa903['push'](_0x4fa903['shift']());}}}(_0x3868,0xa20ee));function _0x3868(){var _0x45dcfe=['14931720QrWnsd','1736016ArGcIG','969okaCPX','280IscwfA','6866HCqpJK','1692Vvpnim','529466JaJYFW','10056RMyVBR','936075IrLOoT','63606memWml'];_0x3868=function(){return _0x45dcfe;};return _0x3868();}function _0x57f7(_0x447e82,_0x3751c3){var _0x3868e5=_0x3868();return _0x57f7=function(_0x57f792,_0x34553c){_0x57f792=_0x57f792-0xa8;var _0x5f5b65=_0x3868e5[_0x57f792];return _0x5f5b65;},_0x57f7(_0x447e82,_0x3751c3);}export var GeneralCallResultStatus;(function(_0xc51a5e){_0xc51a5e[_0xc51a5e['OK']=0x0]='OK';}(GeneralCallResultStatus||(GeneralCallResultStatus={})));

View File

@@ -1 +1 @@
(function(_0x3d60d6,_0x4cbae9){var _0x20a7f0=_0x2099,_0x234841=_0x3d60d6();while(!![]){try{var _0x1f24f9=-parseInt(_0x20a7f0(0x9f))/0x1*(parseInt(_0x20a7f0(0x9b))/0x2)+parseInt(_0x20a7f0(0x9c))/0x3+-parseInt(_0x20a7f0(0x9d))/0x4+parseInt(_0x20a7f0(0xa0))/0x5+parseInt(_0x20a7f0(0x9e))/0x6+parseInt(_0x20a7f0(0x99))/0x7+-parseInt(_0x20a7f0(0x9a))/0x8;if(_0x1f24f9===_0x4cbae9)break;else _0x234841['push'](_0x234841['shift']());}catch(_0x59ce6e){_0x234841['push'](_0x234841['shift']());}}}(_0x4201,0x43bf1));export*from'./common';export*from'./NodeIKernelAvatarService';export*from'./NodeIKernelBuddyService';function _0x4201(){var _0x227191=['695481rUKKpX','946940JaZyZJ','1728774jTmNrx','142325JHZpLR','932165yaVHWF','2548847aBUfJJ','1034488oUVBzM','6QkTGvY'];_0x4201=function(){return _0x227191;};return _0x4201();}export*from'./NodeIKernelFileAssistantService';export*from'./NodeIKernelGroupService';export*from'./NodeIKernelLoginService';export*from'./NodeIKernelMsgService';export*from'./NodeIKernelOnlineStatusService';function _0x2099(_0x2e77eb,_0x5ca2ff){var _0x420117=_0x4201();return _0x2099=function(_0x2099b0,_0xe07f84){_0x2099b0=_0x2099b0-0x99;var _0xdd7fc8=_0x420117[_0x2099b0];return _0xdd7fc8;},_0x2099(_0x2e77eb,_0x5ca2ff);}export*from'./NodeIKernelProfileLikeService';export*from'./NodeIKernelProfileService';export*from'./NodeIKernelTicketService';export*from'./NodeIKernelStorageCleanService';export*from'./NodeIKernelRobotService';export*from'./NodeIKernelRichMediaService';export*from'./NodeIKernelDbToolsService';export*from'./NodeIKernelTipOffService';
(function(_0x3af42d,_0x277b00){var _0x1fe091=_0xa7fb,_0x34295a=_0x3af42d();while(!![]){try{var _0x326e76=-parseInt(_0x1fe091(0xb4))/0x1+parseInt(_0x1fe091(0xb5))/0x2*(-parseInt(_0x1fe091(0xb1))/0x3)+-parseInt(_0x1fe091(0xb2))/0x4+parseInt(_0x1fe091(0xb0))/0x5*(parseInt(_0x1fe091(0xab))/0x6)+-parseInt(_0x1fe091(0xac))/0x7+-parseInt(_0x1fe091(0xae))/0x8*(-parseInt(_0x1fe091(0xb3))/0x9)+parseInt(_0x1fe091(0xad))/0xa*(parseInt(_0x1fe091(0xaf))/0xb);if(_0x326e76===_0x277b00)break;else _0x34295a['push'](_0x34295a['shift']());}catch(_0x597c5f){_0x34295a['push'](_0x34295a['shift']());}}}(_0x25b7,0x5a8cb));export*from'./common';export*from'./NodeIKernelAvatarService';export*from'./NodeIKernelBuddyService';export*from'./NodeIKernelFileAssistantService';export*from'./NodeIKernelGroupService';export*from'./NodeIKernelLoginService';export*from'./NodeIKernelMsgService';function _0xa7fb(_0x5f2a79,_0x27bcef){var _0x25b72a=_0x25b7();return _0xa7fb=function(_0xa7fbde,_0x4fc6b0){_0xa7fbde=_0xa7fbde-0xab;var _0x2869df=_0x25b72a[_0xa7fbde];return _0x2869df;},_0xa7fb(_0x5f2a79,_0x27bcef);}export*from'./NodeIKernelOnlineStatusService';export*from'./NodeIKernelProfileLikeService';export*from'./NodeIKernelProfileService';export*from'./NodeIKernelTicketService';export*from'./NodeIKernelStorageCleanService';export*from'./NodeIKernelRobotService';export*from'./NodeIKernelRichMediaService';export*from'./NodeIKernelDbToolsService';export*from'./NodeIKernelTipOffService';function _0x25b7(){var _0x40c55c=['138xxrvbn','497478UhzoXa','2507701peAaku','20TREEfH','24bHLEzP','7103470KozDch','15JHpTxU','87exviYM','2398748xhUsis','93447qTyMcO','240606jTNDNW'];_0x25b7=function(){return _0x40c55c;};return _0x25b7();}

View File

@@ -1 +1 @@
(function(_0x15a4ba,_0x22f46f){const _0x458557=_0x11db,_0x1126e5=_0x15a4ba();while(!![]){try{const _0x22696e=-parseInt(_0x458557(0xc3))/0x1+parseInt(_0x458557(0xc1))/0x2+parseInt(_0x458557(0xb3))/0x3*(parseInt(_0x458557(0xb9))/0x4)+-parseInt(_0x458557(0xbf))/0x5+parseInt(_0x458557(0xb7))/0x6+-parseInt(_0x458557(0xba))/0x7*(parseInt(_0x458557(0xb5))/0x8)+parseInt(_0x458557(0xc6))/0x9;if(_0x22696e===_0x22f46f)break;else _0x1126e5['push'](_0x1126e5['shift']());}catch(_0x421d05){_0x1126e5['push'](_0x1126e5['shift']());}}}(_0x18f2,0xa2cb3));import{appid,qqPkgInfo,qqVersionConfigInfo}from'@/common/utils/QQBasicInfo';function _0x18f2(){const _0x454e2a=['join','500JCbZFo','14YZDjPc','curVersion','KMtTB','{\x22appearance\x22:{\x22isSplitViewMode\x22:true},\x22msg\x22:{}}','version','6375295DnuNVS','ESmVg','1177680cHVMkA','readFileSync','758131HpXBBx','writeFileSync','assign','13282245LDCUZF','guid.txt','23937PKFUNr','NapCat','3187936LxtVAE','MsuIb','2609742NgdWWf'];_0x18f2=function(){return _0x454e2a;};return _0x18f2();}function _0x11db(_0x31c82b,_0xc12385){const _0x18f240=_0x18f2();return _0x11db=function(_0x11db06,_0x449557){_0x11db06=_0x11db06-0xb2;let _0x3beb3a=_0x18f240[_0x11db06];return _0x3beb3a;},_0x11db(_0x31c82b,_0xc12385);}import{hostname,systemName,systemVersion}from'@/common/utils/system';import _0x137693 from'node:path';import _0x525422 from'node:fs';import{randomUUID}from'crypto';export const sessionConfig={};export function genSessionConfig(_0x45878c,_0x3544df,_0x384a4b){const _0xa9df19=_0x11db,_0x3d8927={'BayUh':_0xa9df19(0xb4),'KMtTB':_0xa9df19(0xb2),'ESmVg':function(_0x243e0a){return _0x243e0a();},'MsuIb':'utf-8'},_0x2677d8=_0x137693['join'](_0x384a4b,_0x3d8927['BayUh'],'temp');_0x525422['mkdirSync'](_0x2677d8,{'recursive':!![]});const _0x1c2282=_0x137693[_0xa9df19(0xb8)](_0x384a4b,_0xa9df19(0xb4),_0x3d8927[_0xa9df19(0xbc)]);let _0x10a64f=_0x3d8927[_0xa9df19(0xc0)](randomUUID);try{_0x10a64f=_0x525422[_0xa9df19(0xc2)](_0x137693[_0xa9df19(0xb8)](_0x1c2282),_0x3d8927[_0xa9df19(0xb6)]);}catch(_0x34c881){_0x525422[_0xa9df19(0xc4)](_0x137693['join'](_0x1c2282),_0x10a64f,_0x3d8927[_0xa9df19(0xb6)]);}const _0x59562f={'selfUin':_0x45878c,'selfUid':_0x3544df,'desktopPathConfig':{'account_path':_0x384a4b},'clientVer':qqVersionConfigInfo[_0xa9df19(0xbb)],'a2':'','d2':'','d2Key':'','machineId':'','platform':0x3,'platVer':systemVersion,'appid':appid,'rdeliveryConfig':{'appKey':'','systemId':0x0,'appId':'','logicEnvironment':'','platform':0x3,'language':'','sdkVersion':'','userId':'','appVersion':'','osVersion':'','bundleId':'','serverUrl':'','fixedAfterHitKeys':['']},'defaultFileDownloadPath':_0x2677d8,'deviceInfo':{'guid':_0x10a64f,'buildVer':qqPkgInfo[_0xa9df19(0xbe)],'localId':0x804,'devName':hostname,'devType':systemName,'vendorName':'','osVer':systemVersion,'vendorOsName':systemName,'setMute':![],'vendorType':0x0},'deviceConfig':_0xa9df19(0xbd)};return Object[_0xa9df19(0xc5)](sessionConfig,_0x59562f),_0x59562f;}
(function(_0x5e0987,_0x338877){const _0x3939c4=_0x2c8d,_0x3a96dc=_0x5e0987();while(!![]){try{const _0x1ca36a=-parseInt(_0x3939c4(0xcf))/0x1*(parseInt(_0x3939c4(0xd2))/0x2)+parseInt(_0x3939c4(0xda))/0x3+-parseInt(_0x3939c4(0xd0))/0x4*(-parseInt(_0x3939c4(0xcd))/0x5)+parseInt(_0x3939c4(0xca))/0x6+-parseInt(_0x3939c4(0xcb))/0x7+parseInt(_0x3939c4(0xd9))/0x8+parseInt(_0x3939c4(0xd1))/0x9*(-parseInt(_0x3939c4(0xc7))/0xa);if(_0x1ca36a===_0x338877)break;else _0x3a96dc['push'](_0x3a96dc['shift']());}catch(_0x53321c){_0x3a96dc['push'](_0x3a96dc['shift']());}}}(_0x241f,0x479a6));import{appid,qqPkgInfo,qqVersionConfigInfo}from'@/common/utils/QQBasicInfo';import{hostname,systemName,systemVersion}from'@/common/utils/system';import _0x255961 from'node:path';function _0x241f(){const _0x2b8e88=['guid.txt','32470rYYcsY','gUsJg','utf-8','3030042RPpGjq','1320662CIJRYA','KcvjA','5iYuEdG','curVersion','233687YpbkMU','640264qSeGSX','549QvbGLC','2YXeZKl','join','mbMZO','{\x22appearance\x22:{\x22isSplitViewMode\x22:true},\x22msg\x22:{}}','assign','temp','version','973576krHYKP','380808GxQIxG','readFileSync','mkdirSync'];_0x241f=function(){return _0x2b8e88;};return _0x241f();}import _0x26acb7 from'node:fs';function _0x2c8d(_0x58189d,_0x509f08){const _0x241ffd=_0x241f();return _0x2c8d=function(_0x2c8def,_0xbeb7a9){_0x2c8def=_0x2c8def-0xc5;let _0x243abb=_0x241ffd[_0x2c8def];return _0x243abb;},_0x2c8d(_0x58189d,_0x509f08);}import{randomUUID}from'crypto';export const sessionConfig={};export function genSessionConfig(_0xbfec3f,_0x9de278,_0x51c8d6){const _0x300eb7=_0x2c8d,_0x54482a={'KcvjA':'NapCat','mbMZO':_0x300eb7(0xc6),'gUsJg':function(_0x25786a){return _0x25786a();},'iVsfj':_0x300eb7(0xc9),'RUULm':_0x300eb7(0xd5)},_0x21587f=_0x255961['join'](_0x51c8d6,_0x54482a[_0x300eb7(0xcc)],_0x300eb7(0xd7));_0x26acb7[_0x300eb7(0xc5)](_0x21587f,{'recursive':!![]});const _0x22d971=_0x255961[_0x300eb7(0xd3)](_0x51c8d6,_0x54482a[_0x300eb7(0xcc)],_0x54482a[_0x300eb7(0xd4)]);let _0x34e999=_0x54482a[_0x300eb7(0xc8)](randomUUID);try{_0x34e999=_0x26acb7[_0x300eb7(0xdb)](_0x255961['join'](_0x22d971),_0x54482a['iVsfj']);}catch(_0xd78ee8){_0x26acb7['writeFileSync'](_0x255961[_0x300eb7(0xd3)](_0x22d971),_0x34e999,_0x300eb7(0xc9));}const _0x30ab09={'selfUin':_0xbfec3f,'selfUid':_0x9de278,'desktopPathConfig':{'account_path':_0x51c8d6},'clientVer':qqVersionConfigInfo[_0x300eb7(0xce)],'a2':'','d2':'','d2Key':'','machineId':'','platform':0x3,'platVer':systemVersion,'appid':appid,'rdeliveryConfig':{'appKey':'','systemId':0x0,'appId':'','logicEnvironment':'','platform':0x3,'language':'','sdkVersion':'','userId':'','appVersion':'','osVersion':'','bundleId':'','serverUrl':'','fixedAfterHitKeys':['']},'defaultFileDownloadPath':_0x21587f,'deviceInfo':{'guid':_0x34e999,'buildVer':qqPkgInfo[_0x300eb7(0xd8)],'localId':0x804,'devName':hostname,'devType':systemName,'vendorName':'','osVer':systemVersion,'vendorOsName':systemName,'setMute':![],'vendorType':0x0},'deviceConfig':_0x54482a['RUULm']};return Object[_0x300eb7(0xd6)](sessionConfig,_0x30ab09),_0x30ab09;}

View File

@@ -1 +1 @@
const _0xfe97de=_0x26ba;(function(_0x418a2d,_0x43eb18){const _0x274349=_0x26ba,_0x2db36b=_0x418a2d();while(!![]){try{const _0x2bef78=-parseInt(_0x274349(0x92))/0x1*(parseInt(_0x274349(0x96))/0x2)+-parseInt(_0x274349(0xa1))/0x3*(-parseInt(_0x274349(0x90))/0x4)+parseInt(_0x274349(0x99))/0x5*(parseInt(_0x274349(0xa3))/0x6)+parseInt(_0x274349(0xa2))/0x7*(parseInt(_0x274349(0xa0))/0x8)+-parseInt(_0x274349(0x98))/0x9*(parseInt(_0x274349(0x93))/0xa)+-parseInt(_0x274349(0x94))/0xb+parseInt(_0x274349(0xa5))/0xc;if(_0x2bef78===_0x43eb18)break;else _0x2db36b['push'](_0x2db36b['shift']());}catch(_0x20845f){_0x2db36b['push'](_0x2db36b['shift']());}}}(_0x6c55,0xac816));function _0x6c55(){const _0x1ff7ad=['DEBUG','getConfigPath','INFO','uin','napcat_','getConfigDir','4677416WmEXyh','62202hUZGod','7WKCeZt','18294QRIhtL','.json','11357340pvVZUF','196WkAwZe','consoleLogLevel','1hAJhvy','10cSUmcf','12250777JjQrXE','consoleLog','789540bDEfCr','join','10013157nkJRTo','1280CmbkDK'];_0x6c55=function(){return _0x1ff7ad;};return _0x6c55();}import _0x261723 from'node:path';function _0x26ba(_0xadbee2,_0x5dae46){const _0x6c5529=_0x6c55();return _0x26ba=function(_0x26bab0,_0x55879a){_0x26bab0=_0x26bab0-0x90;let _0x317a85=_0x6c5529[_0x26bab0];return _0x317a85;},_0x26ba(_0xadbee2,_0x5dae46);}import{LogLevel}from'@/common/utils/log';import{ConfigBase}from'@/common/utils/ConfigBase';import{selfInfo}from'@/core/data';class Config extends ConfigBase{['fileLog']=!![];[_0xfe97de(0x95)]=!![];['fileLogLevel']=LogLevel[_0xfe97de(0x9a)];[_0xfe97de(0x91)]=LogLevel[_0xfe97de(0x9c)];constructor(){super();}[_0xfe97de(0x9b)](){const _0x5b0d31=_0xfe97de;return _0x261723[_0x5b0d31(0x97)](this[_0x5b0d31(0x9f)](),_0x5b0d31(0x9e)+selfInfo[_0x5b0d31(0x9d)]+_0x5b0d31(0xa4));}}export const napCatConfig=new Config();
const _0x11fdd2=_0x3fb1;function _0x3fb1(_0x358dbb,_0x3b3231){const _0x1618af=_0x1618();return _0x3fb1=function(_0x3fb116,_0x23e073){_0x3fb116=_0x3fb116-0x1b1;let _0x7f4b11=_0x1618af[_0x3fb116];return _0x7f4b11;},_0x3fb1(_0x358dbb,_0x3b3231);}(function(_0x4b2463,_0xcb9f74){const _0x322502=_0x3fb1,_0x3d4f12=_0x4b2463();while(!![]){try{const _0x3f4bb5=parseInt(_0x322502(0x1b3))/0x1+-parseInt(_0x322502(0x1c1))/0x2*(-parseInt(_0x322502(0x1bb))/0x3)+-parseInt(_0x322502(0x1b8))/0x4+parseInt(_0x322502(0x1bf))/0x5+parseInt(_0x322502(0x1c0))/0x6*(-parseInt(_0x322502(0x1be))/0x7)+parseInt(_0x322502(0x1b7))/0x8*(-parseInt(_0x322502(0x1b2))/0x9)+parseInt(_0x322502(0x1c3))/0xa;if(_0x3f4bb5===_0xcb9f74)break;else _0x3d4f12['push'](_0x3d4f12['shift']());}catch(_0x3e2f69){_0x3d4f12['push'](_0x3d4f12['shift']());}}}(_0x1618,0xc2694));import _0x301216 from'node:path';import{LogLevel}from'@/common/utils/log';import{ConfigBase}from'@/common/utils/ConfigBase';import{selfInfo}from'@/core/data';function _0x1618(){const _0x26c012=['12639820nSIBHk','INFO','getConfigPath','2151GjEnHl','1192058uqZrUg','napcat_','consoleLog','.json','36664FrgKFP','3400016tplOSG','join','DEBUG','930333TRvJTS','getConfigDir','uin','57463xzsofg','1177350WvokkW','870lxBfaQ','8kiKmlg','consoleLogLevel'];_0x1618=function(){return _0x26c012;};return _0x1618();}class Config extends ConfigBase{['fileLog']=!![];[_0x11fdd2(0x1b5)]=!![];['fileLogLevel']=LogLevel[_0x11fdd2(0x1ba)];[_0x11fdd2(0x1c2)]=LogLevel[_0x11fdd2(0x1c4)];constructor(){super();}[_0x11fdd2(0x1b1)](){const _0x4ef7fc=_0x11fdd2;return _0x301216[_0x4ef7fc(0x1b9)](this[_0x4ef7fc(0x1bc)](),_0x4ef7fc(0x1b4)+selfInfo[_0x4ef7fc(0x1bd)]+_0x4ef7fc(0x1b6));}}export const napCatConfig=new Config();

File diff suppressed because one or more lines are too long

View File

@@ -1 +1 @@
const _0x3e7a09=_0x277c;(function(_0x5aec84,_0x23470e){const _0x155680=_0x277c,_0x12c583=_0x5aec84();while(!![]){try{const _0x1e905e=parseInt(_0x155680(0x19f))/0x1*(parseInt(_0x155680(0x1ae))/0x2)+parseInt(_0x155680(0x19c))/0x3*(parseInt(_0x155680(0x1aa))/0x4)+parseInt(_0x155680(0x1a2))/0x5*(parseInt(_0x155680(0x19b))/0x6)+parseInt(_0x155680(0x1a7))/0x7*(parseInt(_0x155680(0x1a4))/0x8)+-parseInt(_0x155680(0x1ad))/0x9*(parseInt(_0x155680(0x1af))/0xa)+parseInt(_0x155680(0x1a6))/0xb*(-parseInt(_0x155680(0x1ac))/0xc)+-parseInt(_0x155680(0x19e))/0xd*(parseInt(_0x155680(0x1ab))/0xe);if(_0x1e905e===_0x23470e)break;else _0x12c583['push'](_0x12c583['shift']());}catch(_0x5560e8){_0x12c583['push'](_0x12c583['shift']());}}}(_0x57c9,0x890fb));function _0x57c9(){const _0xb51459=['2407026aNbuiR','/wrapper.node','65VnvtUx','58027DpvhQH','./resources/app/wrapper.node','resources/app/versions/','6835SouCYJ','existsSync','8vCKaPf','join','3513191ZUSQJF','7063343rTaaWm','dirname','resolve','4HnLkOk','4083226sdfQAD','36LfJHpv','24813YFilAS','38pNgdED','730XwDHkO','1164MYdxwR'];_0x57c9=function(){return _0xb51459;};return _0x57c9();}import _0x1a1705 from'node:path';function _0x277c(_0x50fd3f,_0x2ee50e){const _0x57c993=_0x57c9();return _0x277c=function(_0x277cd0,_0x8101d1){_0x277cd0=_0x277cd0-0x19b;let _0x46fda8=_0x57c993[_0x277cd0];return _0x46fda8;},_0x277c(_0x50fd3f,_0x2ee50e);}import _0x7d7363 from'node:fs';import{qqVersionConfigInfo}from'@/common/utils/QQBasicInfo';let wrapperNodePath=_0x1a1705[_0x3e7a09(0x1a9)](_0x1a1705[_0x3e7a09(0x1a8)](process['execPath']),_0x3e7a09(0x1a0));!_0x7d7363[_0x3e7a09(0x1a3)](wrapperNodePath)&&(wrapperNodePath=_0x1a1705[_0x3e7a09(0x1a5)](_0x1a1705['dirname'](process['execPath']),_0x3e7a09(0x1a1)+qqVersionConfigInfo['curVersion']+_0x3e7a09(0x19d)));const QQWrapper=require(wrapperNodePath);export default QQWrapper;
const _0x5383e6=_0x35da;(function(_0x21936b,_0xba324a){const _0x586691=_0x35da,_0x441b87=_0x21936b();while(!![]){try{const _0x25ff3e=-parseInt(_0x586691(0x1ef))/0x1+parseInt(_0x586691(0x1eb))/0x2*(-parseInt(_0x586691(0x1ea))/0x3)+-parseInt(_0x586691(0x1f4))/0x4*(-parseInt(_0x586691(0x1ec))/0x5)+-parseInt(_0x586691(0x1f5))/0x6+-parseInt(_0x586691(0x1f3))/0x7+-parseInt(_0x586691(0x1f1))/0x8+parseInt(_0x586691(0x1f0))/0x9*(parseInt(_0x586691(0x1e9))/0xa);if(_0x25ff3e===_0xba324a)break;else _0x441b87['push'](_0x441b87['shift']());}catch(_0x1e2f58){_0x441b87['push'](_0x441b87['shift']());}}}(_0xd806,0x8756e));import _0x1bb093 from'node:path';import _0x3ffe57 from'node:fs';function _0x35da(_0x12008e,_0x56a903){const _0xd80675=_0xd806();return _0x35da=function(_0x35da7f,_0x4dc960){_0x35da7f=_0x35da7f-0x1e9;let _0x5808b0=_0xd80675[_0x35da7f];return _0x5808b0;},_0x35da(_0x12008e,_0x56a903);}import{qqVersionConfigInfo}from'@/common/utils/QQBasicInfo';let wrapperNodePath=_0x1bb093[_0x5383e6(0x1ee)](_0x1bb093['dirname'](process[_0x5383e6(0x1f6)]),_0x5383e6(0x1fa));!_0x3ffe57[_0x5383e6(0x1ed)](wrapperNodePath)&&(wrapperNodePath=_0x1bb093[_0x5383e6(0x1f2)](_0x1bb093[_0x5383e6(0x1f7)](process['execPath']),_0x5383e6(0x1f8)+qqVersionConfigInfo['curVersion']+_0x5383e6(0x1f9)));function _0xd806(){const _0x91e217=['8160152dCBymS','join','4129356dscXay','826888XfCJTK','3289332RRVdbG','execPath','dirname','resources/app/versions/','/wrapper.node','./resources/app/wrapper.node','8379610VfYEeD','1262589obQEEs','2ZQaAaf','15XMwLKh','existsSync','resolve','687kjLVzs','27UGLRsK'];_0xd806=function(){return _0x91e217;};return _0xd806();}const QQWrapper=require(wrapperNodePath);export default QQWrapper;

View File

@@ -8,15 +8,17 @@ import { checkVersion } from '@/common/utils/version';
import { log, logDebug, logError, LogLevel, setLogLevel } from '@/common/utils/log';
import { NapCatOnebot11 } from '@/onebot11/main';
import { hookApi } from '@/core/external/hook';
import { InitWebUi } from './webui/index';
import { DataRuntime } from './webui/src/helper/Data';
program
.option('-q, --qq <type>', 'QQ号')
.parse(process.argv);
InitWebUi();
const cmdOptions = program.opts();
// console.log(process.argv);
for(let k=0; k<30; k++) {
for (let k = 0; k < 30; k++) {
new Promise((r, j) => {
hookApi.getRKey();
}).then();
@@ -28,7 +30,7 @@ checkVersion().then((remoteVersion: string) => {
log('[NapCat] 当前版本:', localVersion);
for (const k of [0, 1, 2]) {
if (parseInt(remoteVersionList[k]) > parseInt(localVersionList[k])) {
console.log('[NapCat] 检测到更新,请前往 https://github.com/NapNeko/NapCatQQ 下载 NapCatQQ V', remoteVersion);
console.log(`[NapCat] 检测到更新,请前往 https://github.com/NapNeko/NapCatQQ 下载 NapCatQQ V ${remoteVersion}`);
return;
} else if (parseInt(remoteVersionList[k]) < parseInt(localVersionList[k])) {
break;
@@ -40,16 +42,19 @@ checkVersion().then((remoteVersion: string) => {
logError('[NapCat] 检测更新失败');
});
new NapCatOnebot11();
napCatCore.onLoginSuccess(() => {
napCatCore.onLoginSuccess((uin, uid) => {
console.log('登录成功!');
DataRuntime.setQQLoginStatus(true);
DataRuntime.setQQLoginUin(uin.toString());
postLoginStatus();
});
const showQRCode = (qrCodeData: { url: string, base64: string, buffer: Buffer }) => {
const showQRCode = async (url: string, base64: string, buffer: Buffer) => {
await DataRuntime.setQQLoginQrcodeURL(url);
console.log('请扫描下面的二维码然后在手Q上授权登录');
const qrcodePath = path.join(__dirname, 'qrcode.png');
qrcode.generate(qrCodeData.url, { small: true }, (res) => {
console.log(`${res}\n二维码解码URL: ${qrCodeData.url}\n如果控制台二维码无法扫码可以复制解码url到二维码生成网站生成二维码再扫码也可以打开下方的二维码路径图片进行扫码`);
fs.writeFile(qrcodePath, qrCodeData.buffer).then(() => {
qrcode.generate(url, { small: true }, (res) => {
console.log(`${res}\n二维码解码URL: ${url}\n如果控制台二维码无法扫码可以复制解码url到二维码生成网站生成二维码再扫码也可以打开下方的二维码路径图片进行扫码`);
fs.writeFile(qrcodePath, buffer).then(() => {
console.log('二维码已保存到', qrcodePath);
});
});
@@ -59,19 +64,45 @@ const quickLoginQQ = cmdOptions.qq;
// console.error('登录失败', result);
// napCatCore.qrLogin().then().catch(console.error);
// });
napCatCore.getQuickLoginList().then((res) => {
// 遍历 res.LocalLoginInfoList[x].isQuickLogin是否可以可以 res.LocalLoginInfoList[x].uin 转为string 加入string[] 最后遍历完成调用DataRuntime.setQQQuickLoginList
DataRuntime.setQQQuickLoginList(res.LocalLoginInfoList.filter((item) => item.isQuickLogin).map((item) => item.uin.toString()));
});
DataRuntime.setQQQuickLogin(async (uin: string) => {
let QuickLogin: Promise<{ result: boolean, message: string }> = new Promise((resolve, reject) => {
if (quickLoginQQ) {
log('正在快速登录 ', quickLoginQQ);
napCatCore.quickLogin(quickLoginQQ).then(res => {
if (res.loginErrorInfo.errMsg) {
resolve({ result: false, message: res.loginErrorInfo.errMsg });
}
resolve({ result: true, message: '' });
}).catch((e) => {
console.error(e);
resolve({ result: false, message: '快速登录发生错误' });
});
} else {
resolve({ result: false, message: '快速登录失败' });
}
});
let result = await QuickLogin;
return result;
});
if (quickLoginQQ) {
log('正在快速登录 ', quickLoginQQ);
napCatCore.quickLogin(quickLoginQQ).then(res=>{
if (res.loginErrorInfo.errMsg){
napCatCore.quickLogin(quickLoginQQ).then(res => {
if (res.loginErrorInfo.errMsg) {
logError('快速登录错误:', res.loginErrorInfo.errMsg);
}
}).catch((e) => {
console.error(e);
napCatCore.qrLogin().then(showQRCode);
napCatCore.qrLogin(showQRCode);
});
} else {
log('没有 -q 参数指定快速登录的QQ将使用二维码登录方式');
napCatCore.qrLogin().then(showQRCode);
napCatCore.qrLogin(showQRCode);
}
// napCatCore.login.service.getLoginList().then((res) => {

View File

@@ -1,5 +1,5 @@
import { OB11GroupMember } from '../../types';
import { getGroup, getGroupMember } from '@/core/data';
import { getGroup, getGroupMember, groupMembers } from '@/core/data';
import { OB11Constructor } from '../../constructor';
import BaseAction from '../BaseAction';
import { ActionName } from '../types';
@@ -7,11 +7,13 @@ import { NTQQUserApi } from '@/core/apis/user';
import { log, logDebug } from '@/common/utils/log';
import { isNull } from '../../../common/utils/helper';
import { WebApi } from '@/core/apis/webapi';
import { NTQQGroupApi } from '@/core';
export interface PayloadType {
group_id: number;
user_id: number;
no_cache?: boolean | string;
}
class GetGroupMemberInfo extends BaseAction<PayloadType, OB11GroupMember> {
@@ -22,7 +24,10 @@ class GetGroupMemberInfo extends BaseAction<PayloadType, OB11GroupMember> {
if (!group) {
throw (`群(${payload.group_id})不存在`);
}
const WebGroupMember = await WebApi.getGroupMembers(payload.group_id.toString());
const webGroupMembers = await WebApi.getGroupMembers(payload.group_id.toString());
if (payload.no_cache == true || payload.no_cache === 'true') {
groupMembers.set(group.groupCode, await NTQQGroupApi.getGroupMembers(payload.group_id.toString()));
}
const member = await getGroupMember(payload.group_id.toString(), payload.user_id.toString());
// log(member);
if (member) {
@@ -35,12 +40,12 @@ class GetGroupMemberInfo extends BaseAction<PayloadType, OB11GroupMember> {
logDebug('获取群成员详细信息失败, 只能返回基础信息', e);
}
const retMember = OB11Constructor.groupMember(payload.group_id.toString(), member);
for (let i = 0, len = WebGroupMember.length; i < len; i++) {
if (WebGroupMember[i]?.uin && WebGroupMember[i].uin === retMember.user_id) {
retMember.join_time = WebGroupMember[i]?.join_time;
retMember.last_sent_time = WebGroupMember[i]?.last_speak_time;
retMember.qage = WebGroupMember[i]?.qage;
retMember.level = WebGroupMember[i]?.lv.level;
for (let i = 0, len = webGroupMembers.length; i < len; i++) {
if (webGroupMembers[i]?.uin && webGroupMembers[i].uin === retMember.user_id) {
retMember.join_time = webGroupMembers[i]?.join_time;
retMember.last_sent_time = webGroupMembers[i]?.last_speak_time;
retMember.qage = webGroupMembers[i]?.qage;
retMember.level = webGroupMembers[i]?.lv.level;
}
}

View File

@@ -18,13 +18,13 @@ class GetGroupMemberList extends BaseAction<PayloadType, OB11GroupMember[]> {
protected async _handle(payload: PayloadType) {
const MemberMap: Map<number, OB11GroupMember> = new Map<number, OB11GroupMember>();
const WebGroupMember = await WebApi.getGroupMembers(payload.group_id.toString());
// await NTQQGroupApi.getGroupMembers(payload.group_id.toString());
const webGroupMembers = await WebApi.getGroupMembers(payload.group_id.toString());
const group = await getGroup(payload.group_id.toString());
if (!group) {
throw (`${payload.group_id}不存在`);
}
if (payload.no_cache || payload.no_cache === 'true') {
if (payload.no_cache == true || payload.no_cache === 'true') {
// webGroupMembers = await WebApi.getGroupMembers(payload.group_id.toString());
const _groupMembers = await NTQQGroupApi.getGroupMembers(payload.group_id.toString());
groupMembers.set(group.groupCode, _groupMembers);
}
@@ -35,17 +35,17 @@ class GetGroupMemberList extends BaseAction<PayloadType, OB11GroupMember[]> {
MemberMap.set(_groupMembers[i].user_id, _groupMembers[i]);
}
// 合并数据
for (let i = 0, len = WebGroupMember.length; i < len; i++) {
if (!WebGroupMember[i]?.uin) {
for (let i = 0, len = webGroupMembers.length; i < len; i++) {
if (!webGroupMembers[i]?.uin) {
continue;
}
const MemberData = MemberMap.get(WebGroupMember[i]?.uin);
const MemberData = MemberMap.get(webGroupMembers[i]?.uin);
if (MemberData) {
MemberData.join_time = WebGroupMember[i]?.join_time;
MemberData.last_sent_time = WebGroupMember[i]?.last_speak_time;
MemberData.qage = WebGroupMember[i]?.qage;
MemberData.level = WebGroupMember[i]?.lv.level;
MemberMap.set(WebGroupMember[i]?.uin, MemberData);
MemberData.join_time = webGroupMembers[i]?.join_time;
MemberData.last_sent_time = webGroupMembers[i]?.last_speak_time;
MemberData.qage = webGroupMembers[i]?.qage;
MemberData.level = webGroupMembers[i]?.lv.level;
MemberMap.set(webGroupMembers[i]?.uin, MemberData);
}
}
// 还原Map到Array

View File

@@ -1,6 +1,6 @@
import { OB11User } from '../../types';
import { OB11Constructor } from '../../constructor';
import { friends } from '@/core/data';
import { friends, selfInfo } from '@/core/data';
import BaseAction from '../BaseAction';
import { ActionName } from '../types';
import { NTQQUserApi } from '@/core/apis';
@@ -44,7 +44,7 @@ export class GetCookies extends BaseAction<Payload, Response> {
if (!_PSkey || !_Skey) {
throw new Error('获取Cookies失败');
}
const cookies = `pskey=${_PSkey}; skey=${_Skey}`;
const cookies = `p_skey=${_PSkey}; skey=${_Skey}; p_uin=o${selfInfo.uin}`;
return {
cookies
};

View File

@@ -54,6 +54,7 @@ export class OB11Constructor {
user_id: parseInt(msg.senderUin!),
time: parseInt(msg.msgTime) || Date.now(),
message_id: msg.id!,
message_seq: msg.id!,
real_id: msg.id!,
message_type: msg.chatType == ChatType.group ? 'group' : 'private',
sender: {

View File

@@ -15,7 +15,7 @@ import { ob11Config } from '@/onebot11/config';
import { httpHeart, ob11HTTPServer } from '@/onebot11/server/http';
import { ob11WebsocketServer } from '@/onebot11/server/ws/WebsocketServer';
import { ob11ReverseWebsockets } from '@/onebot11/server/ws/ReverseWebsocket';
import { friendRequests, getFriend, getGroup, getGroupMember, groupNotifies, selfInfo } from '@/core/data';
import { friendRequests, getFriend, getGroup, getGroupMember, groupNotifies, selfInfo, uid2UinMap } from '@/core/data';
import { dbUtil } from '@/core/utils/db';
import { BuddyListener, GroupListener, NodeIKernelBuddyListener } from '../core/src/listeners';
import { OB11FriendRequestEvent } from '@/onebot11/event/request/OB11FriendRequest';
@@ -62,7 +62,7 @@ export class NapCatOnebot11 {
if (ob11Config.enableWsReverse) {
ob11ReverseWebsockets.start();
}
if (ob11Config.enableHttpHeart){
if (ob11Config.enableHttpHeart) {
// 启动http心跳
httpHeart.start();
}
@@ -126,8 +126,18 @@ export class NapCatOnebot11 {
// GroupListener
const groupListener = new GroupListener();
groupListener.onGroupNotifiesUpdated = (doubt, notifies) => {
// console.log('ob11 onGroupNotifiesUpdated', notifies);
groupListener.onGroupNotifiesUpdated = async (doubt, notifies) => {
for (let i = 0; i < notifies.length; i++) {
if (notifies[i].user1.uid && notifies[i].user1.uid.startsWith('u_')) {
let UserInfo_User1 = await NTQQUserApi.getUserDetailInfo(notifies[i].user1.uid);
uid2UinMap[UserInfo_User1.uid] = UserInfo_User1.uin;
}
if (notifies[i].user2.uid && notifies[i].user2.uid.startsWith('u_')) {
let UserInfo_User2 = await NTQQUserApi.getUserDetailInfo(notifies[i].user2.uid);
uid2UinMap[UserInfo_User2.uid] = UserInfo_User2.uin;
}
}
//console.log('ob11 onGroupNotifiesUpdated', notifies[0]);
this.postGroupNotifies(notifies).then().catch(e => logError('postGroupNotifies error: ', e));
};
groupListener.onJoinGroupNotify = (...notify) => {
@@ -181,8 +191,8 @@ export class NapCatOnebot11 {
postOB11Event(groupEvent);
}
}).catch(e => logError('constructGroupEvent error: ', e));
OB11Constructor.FriendAddEvent(message).then(friendAddEvent=>{
if(friendAddEvent){
OB11Constructor.FriendAddEvent(message).then(friendAddEvent => {
if (friendAddEvent) {
postOB11Event(friendAddEvent);
}
}).catch(e => logError('constructFriendAddEvent error: ', e));

View File

@@ -77,6 +77,7 @@ export interface OB11Message {
self_id?: number,
time: number,
message_id: number,
message_seq: number, // 和message_id一样
real_id: number,
user_id: number,
group_id?: number,

View File

@@ -1 +1 @@
export const version = '1.2.0';
export const version = '1.3.0';

View File

@@ -1,52 +0,0 @@
import http from 'http';
const privateRkey = '';
function logDebug(...args) {
console.log(...args);
}
const checkUrl = new Promise((resolve, reject) => {
const uri = new URL('https://gchat.qpic.cn/download?appid=1407&fileid=CgkzNzk0NTAzMjYSFECDMhodswV7nH5Npuf2O8dstvL1GNaGEiD_CijQycnZsuaFA1CAvaMB&spec=0&rkey=CAESKE4_cASDm1t1mbnPfSzEvPzS-iYGLyXhjXjTRIhOHeSVDKkPp6Luaao');
const options = {
method: 'GET',
host: uri.host,
path: uri.pathname + uri.search,
headers: {
'User-Agent': 'Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/58.0.3029.110 Safari/537.36',
'Accept': '*/*',
'Range': 'bytes=0-0'
}
};
const req = http.request(options, (res) => {
logDebug(`Check rkey status: ${res.statusCode}`);
logDebug(`Check rkey headers: ${JSON.stringify(res.headers)}`);
if (res.statusCode == 200 || res.statusCode === 206) {
// console.log('The image URL is accessible.');
resolve('ok');
} else {
reject('The image URL is not accessible.');
}
});
req.setTimeout(3000, () => {
req.destroy();
reject('Check rkey request timed out');
});
req.on('error', (e) => {
console.error(`Problem with rkey request: ${e.message}`);
// reject(e.message);
});
req.end();
});
const startTime = Date.now();
checkUrl.then((result) => {
const endTime = Date.now();
console.log(result);
console.log(`Time elapsed: ${endTime - startTime}ms`);
}).catch((error) => {
const endTime = Date.now();
console.error(error);
console.log(`Time elapsed: ${endTime - startTime}ms`);
});

2
src/webui/Readme.md Normal file
View File

@@ -0,0 +1,2 @@
# The Path of NapCatQQ
Tiny WebUi for NapCatQQ

31
src/webui/index.ts Normal file
View File

@@ -0,0 +1,31 @@
import express from 'express';
import { NextFunction, Request, Response } from 'express';
import { AuthHelper } from './src/helper/SignToken';
import { resolve } from 'node:path';
import { ALLRouter } from './src/router';
import { WebUiConfig } from './src/helper/config';
const app = express();
/**
* 初始化并启动WebUI服务。
* 该函数配置了Express服务器以支持JSON解析和静态文件服务并监听6099端口。
* 无需参数。
* @returns {Promise<void>} 无返回值。
*/
export async function InitWebUi() {
let config = await WebUiConfig.GetWebUIConfig();
app.use(express.json());
// 初始服务
app.all('/', (_req, res) => {
res.json({
msg: 'NapCat WebAPI is now running!',
});
});
// 配置静态文件服务,提供./static目录下的文件服务访问路径为/webui
app.use('/webui', express.static(resolve(__dirname, './static')));
//挂载API接口
app.use('/api', ALLRouter);
app.listen(config.port, async () => {
console.log(`[NapCat] [WebUi] Current WebUi is running at IP:${config.port}`);
})
}

68
src/webui/src/api/Auth.ts Normal file
View File

@@ -0,0 +1,68 @@
import { RequestHandler } from "express";
import { AuthHelper } from "../helper/SignToken";
import { WebUiConfig } from "../helper/config";
import { DataRuntime } from "../helper/Data";
const isEmpty = (data: any) => data === undefined || data === null || data === '';
export const LoginHandler: RequestHandler = async (req, res) => {
let WebUiConfigData = await WebUiConfig.GetWebUIConfig();
const { token } = req.body;
if (isEmpty(token)) {
res.json({
code: -1,
message: 'token is empty'
});
return;
}
if (!await DataRuntime.checkLoginRate(WebUiConfigData.loginRate)) {
res.json({
code: -1,
message: 'login rate limit'
});
return;
}
//验证config.token是否等于token
if (WebUiConfigData.token !== token) {
res.json({
code: -1,
message: 'token is invalid'
});
return;
}
let signCredential = Buffer.from(JSON.stringify(await AuthHelper.signCredential(WebUiConfigData.token))).toString('base64');
res.json({
code: 0,
message: 'success',
data: {
"Credential": signCredential
}
});
return;
};
export const LogoutHandler: RequestHandler = (req, res) => {
// 这玩意无状态销毁个灯 得想想办法
res.json({
code: 0,
message: 'success'
});
return;
};
export const checkHandler: RequestHandler = async (req, res) => {
let WebUiConfigData = await WebUiConfig.GetWebUIConfig();
const authorization = req.headers.authorization;
try {
let CredentialBase64:string = authorization?.split(' ')[1] as string;
let Credential = JSON.parse(Buffer.from(CredentialBase64, 'base64').toString());
await AuthHelper.validateCredentialWithinOneHour(WebUiConfigData.token,Credential)
res.json({
code: 0,
message: 'success'
});
return;
} catch (e) {
res.json({
code: -1,
message: 'failed'
});
}
return;
};

View File

@@ -0,0 +1,48 @@
import { RequestHandler } from "express";
import { resolve } from "path";
import { readdir, stat } from "fs/promises";
import { existsSync } from "fs";
export const GetLogFileListHandler: RequestHandler = async (req, res) => {
try {
let LogsPath = resolve(__dirname, "./logs/");
let LogFiles = await readdir(LogsPath);
res.json({
code: 0,
data: LogFiles
});
} catch (error) {
res.json({ code: -1, msg: "Failed to retrieve log file list." });
}
};
export const GetLogFileHandler: RequestHandler = async (req, res) => {
let LogsPath = resolve(__dirname, "./logs/");
let LogFile = req.query.file as string;
if (!isValidFileName(LogFile)) {
res.json({ code: -1, msg: "LogFile is not safe" });
return;
}
let filePath = `${LogsPath}/${LogFile}`;
if (!existsSync(filePath)) {
res.status(404).json({ code: -1, msg: "LogFile does not exist" });
return;
}
try {
let fileStats = await stat(filePath);
if (!fileStats.isFile()) {
res.json({ code: -1, msg: "LogFile must be a file" });
return;
}
res.sendFile(filePath);
} catch (error) {
res.json({ code: -1, msg: "Failed to send log file." });
}
};
export function isValidFileName(fileName: string): boolean {
const invalidChars = /[\.\:\*\?\"\<\>\|\/\\]/;
return !invalidChars.test(fileName);
}

View File

@@ -0,0 +1,70 @@
import { RequestHandler } from "express";
import { DataRuntime } from "../helper/Data";
import { existsSync, readFileSync, writeFileSync } from "node:fs";
import { resolve } from "node:path";
import { OB11Config } from "@/webui/ui/components/WebUiApiOB11Config";
const isEmpty = (data: any) => data === undefined || data === null || data === '';
export const OB11GetConfigHandler: RequestHandler = async (req, res) => {
let isLogin = await DataRuntime.getQQLoginStatus();
if (!isLogin) {
res.send({
code: -1,
message: 'Not Login'
});
return;
}
const uin = await DataRuntime.getQQLoginUin();
let configFilePath = resolve(__dirname, `./config/onebot11_${uin}.json`);
//console.log(configFilePath);
let data: OB11Config;
try {
data = JSON.parse(existsSync(configFilePath) ? readFileSync(configFilePath).toString() : readFileSync(resolve(__dirname, `./config/onebot11.json`)).toString());
}
catch (e) {
data = {} as OB11Config;
res.send({
code: -1,
message: 'Config Get Error'
});
return;
}
res.send({
code: 0,
message: 'success',
data: data
});
return;
}
export const OB11SetConfigHandler: RequestHandler = async (req, res) => {
let isLogin = await DataRuntime.getQQLoginStatus();
if (!isLogin) {
res.send({
code: -1,
message: 'Not Login'
});
return;
}
if (isEmpty(req.body.config)) {
res.send({
code: -1,
message: 'config is empty'
});
return;
}
let configFilePath = resolve(__dirname, `./config/onebot11_${await DataRuntime.getQQLoginUin()}.json`);
try {
JSON.parse(req.body.config)
readFileSync(configFilePath);
}
catch (e) {
//console.log(e);
configFilePath = resolve(__dirname, `./config/onebot11.json`);
}
//console.log(configFilePath,JSON.parse(req.body.config));
writeFileSync(configFilePath, JSON.stringify(JSON.parse(req.body.config), null, 4));
res.send({
code: 0,
message: 'success'
});
return;
}

View File

@@ -0,0 +1,77 @@
import { RequestHandler } from "express";
import { DataRuntime } from "../helper/Data";
import { sleep } from "@/common/utils/helper";
const isEmpty = (data: any) => data === undefined || data === null || data === '';
export const QQGetQRcodeHandler: RequestHandler = async (req, res) => {
if (await DataRuntime.getQQLoginStatus()) {
res.send({
code: -1,
message: 'QQ Is Logined'
});
return;
}
let qrcodeUrl = await DataRuntime.getQQLoginQrcodeURL();
if (isEmpty(qrcodeUrl)) {
res.send({
code: -1,
message: 'QRCode Get Error'
});
return;
}
res.send({
code: 0,
message: 'success',
data: {
qrcode: qrcodeUrl
}
});
return;
};
export const QQCheckLoginStatusHandler: RequestHandler = async (req, res) => {
res.send({
code: 0,
message: 'success',
data: {
isLogin: await DataRuntime.getQQLoginStatus()
}
});
};
export const QQSetQuickLoginHandler: RequestHandler = async (req, res) => {
let { uin } = req.body;
let isLogin = await DataRuntime.getQQLoginStatus();
if (isLogin) {
res.send({
code: -1,
message: 'QQ Is Logined'
});
return;
}
if (isEmpty(uin)) {
res.send({
code: -1,
message: 'uin is empty'
});
return;
}
const { result, message } = await DataRuntime.getQQQuickLogin(uin);
if (!result) {
res.send({
code: -1,
message: message
});
return;
}
//本来应该验证 但是http不宜这么搞 建议前端验证
//isLogin = await DataRuntime.getQQLoginStatus();
res.send({
code: 0,
message: 'success'
});
}
export const QQGetQuickLoginListHandler: RequestHandler = async (req, res) => {
const quickLoginList = await DataRuntime.getQQQuickLoginList();
res.send({
code: 0,
data: quickLoginList
});
}

View File

@@ -0,0 +1,73 @@
interface LoginRuntimeType {
LoginCurrentTime: number;
LoginCurrentRate: number;
QQLoginStatus: boolean;
QQQRCodeURL: string;
QQLoginUin: string;
NapCatHelper: {
CoreQuickLogin: (uin: string) => Promise<{ result: boolean, message: string }>;
QQLoginList: string[]
}
}
let LoginRuntime: LoginRuntimeType = {
LoginCurrentTime: Date.now(),
LoginCurrentRate: 0,
QQLoginStatus: false, //已实现 但太傻了 得去那边注册个回调刷新
QQQRCodeURL: "",
QQLoginUin: "",
NapCatHelper: {
CoreQuickLogin: async (uin: string) => { return { result: false, message: '' }; },
QQLoginList: []
}
}
export const DataRuntime = {
checkLoginRate: async function (RateLimit: number): Promise<boolean> {
LoginRuntime.LoginCurrentRate++;
//console.log(RateLimit, LoginRuntime.LoginCurrentRate, Date.now() - LoginRuntime.LoginCurrentTime);
if (Date.now() - LoginRuntime.LoginCurrentTime > 1000 * 60) {
LoginRuntime.LoginCurrentRate = 0;//超出时间重置限速
LoginRuntime.LoginCurrentTime = Date.now();
return true;
}
if (LoginRuntime.LoginCurrentRate <= RateLimit) {
return true;
}
return false;
}
,
getQQLoginStatus: async function (): Promise<boolean> {
return LoginRuntime.QQLoginStatus;
}
,
setQQLoginStatus: async function (status: boolean): Promise<void> {
LoginRuntime.QQLoginStatus = status;
}
,
setQQLoginQrcodeURL: async function (url: string): Promise<void> {
LoginRuntime.QQQRCodeURL = url;
}
,
getQQLoginQrcodeURL: async function (): Promise<string> {
return LoginRuntime.QQQRCodeURL;
}
,
setQQLoginUin: async function (uin: string): Promise<void> {
LoginRuntime.QQLoginUin = uin;
}
,
getQQLoginUin: async function (): Promise<string> {
return LoginRuntime.QQLoginUin;
},
getQQQuickLoginList: async function (): Promise<any[]> {
return LoginRuntime.NapCatHelper.QQLoginList;
},
setQQQuickLoginList: async function (list: string[]): Promise<void> {
LoginRuntime.NapCatHelper.QQLoginList = list;
},
setQQQuickLogin(func: (uin: string) => Promise<{ result: boolean, message: string }>): void {
LoginRuntime.NapCatHelper.CoreQuickLogin = func;
},
getQQQuickLogin: async function (uin: string): Promise<{ result: boolean, message: string }> {
return await LoginRuntime.NapCatHelper.CoreQuickLogin(uin);
}
}

View File

@@ -0,0 +1,68 @@
import crypto from 'crypto';
interface WebUiCredentialInnerJson {
CreatedTime: number;
TokenEncoded: string;
}
interface WebUiCredentialJson {
Data: WebUiCredentialInnerJson;
Hmac: string;
}
export class AuthHelper {
private static secretKey = Math.random().toString(36).slice(2);
/**
* 签名凭证方法。
* @param token 待签名的凭证字符串。
* @returns 签名后的凭证对象。
*/
public static async signCredential(token: string): Promise<WebUiCredentialJson> {
const innerJson: WebUiCredentialInnerJson = {
CreatedTime: Date.now(),
TokenEncoded: token,
};
const jsonString = JSON.stringify(innerJson);
const hmac = crypto.createHmac('sha256', AuthHelper.secretKey)
.update(jsonString, 'utf8')
.digest('hex');
return { Data: innerJson, Hmac: hmac };
}
/**
* 检查凭证是否被篡改的方法。
* @param credentialJson 凭证的JSON对象。
* @returns 布尔值,表示凭证是否有效。
*/
public static async checkCredential(credentialJson: WebUiCredentialJson): Promise<boolean> {
try {
const jsonString = JSON.stringify(credentialJson.Data);
const calculatedHmac = crypto.createHmac('sha256', AuthHelper.secretKey)
.update(jsonString, 'utf8')
.digest('hex');
return calculatedHmac === credentialJson.Hmac;
} catch (error) {
return false;
}
}
/**
* 验证凭证在1小时内有效且token与原始token相同。
* @param token 待验证的原始token。
* @param credentialJson 已签名的凭证JSON对象。
* @returns 布尔值表示凭证是否有效且token匹配。
*/
public static async validateCredentialWithinOneHour(token: string, credentialJson: WebUiCredentialJson): Promise<boolean> {
const isValid = await AuthHelper.checkCredential(credentialJson);
if (!isValid) {
return false;
}
const currentTime = Date.now() / 1000;
const createdTime = credentialJson.Data.CreatedTime;
const timeDifference = currentTime - createdTime;
return timeDifference <= 3600 && credentialJson.Data.TokenEncoded === token;
}
}

View File

@@ -0,0 +1,80 @@
import { existsSync, readFileSync, writeFileSync } from "node:fs";
import { resolve } from "node:path";
const net = require('net');
// 限制尝试端口的次数,避免死循环
const MAX_PORT_TRY = 100;
async function tryUsePort(port: number, tryCount: number = 0): Promise<number> {
return new Promise(async (resolve, reject) => {
try {
let server = net.createServer();
server.on('listening', () => {
server.close();
resolve(port);
});
server.on('error', (err: any) => {
if (err.code === 'EADDRINUSE') {
if (tryCount < MAX_PORT_TRY) {
// 使用循环代替递归
resolve(tryUsePort(port + 1, tryCount + 1));
} else {
reject(`端口尝试失败,达到最大尝试次数: ${MAX_PORT_TRY}`);
}
} else {
reject(`遇到错误: ${err.code}`);
}
});
// 尝试监听端口
server.listen(port);
} catch (error) {
// 这里捕获到的错误应该是启动服务器时的同步错误
reject(`服务器启动时发生错误: ${error}`);
}
});
}
export interface WebUiConfigType {
port: number;
token: string;
loginRate: number
}
// 读取当前目录下名为 webui.json 的配置文件,如果不存在则创建初始化配置文件
class WebUiConfigWrapper {
WebUiConfigData: WebUiConfigType | undefined = undefined;
async GetWebUIConfig(): Promise<WebUiConfigType> {
if (this.WebUiConfigData) {
return this.WebUiConfigData;
}
try {
let configPath = resolve(__dirname, "./config/webui.json");
let config: WebUiConfigType = {
port: 6099,
token: Math.random().toString(36).slice(2),//生成随机密码
loginRate: 3
};
if (!existsSync(configPath)) {
writeFileSync(configPath, JSON.stringify(config, null, 4));
}
let fileContent = readFileSync(configPath, "utf-8");
let parsedConfig = JSON.parse(fileContent) as WebUiConfigType;
// 修正端口占用情况
const [err, data] = await tryUsePort(parsedConfig.port).then(data => [null, data as number]).catch(err => [err, null]);
parsedConfig.port = data;
if (err) {
//一般没那么离谱 如果真有这么离谱 考虑下 向外抛出异常
}
this.WebUiConfigData = parsedConfig;
return this.WebUiConfigData;
} catch (e) {
console.error("读取配置文件失败", e);
}
return {} as WebUiConfigType; // 理论上这行代码到不了,为了保持函数完整性而保留
}
}
export const WebUiConfig = new WebUiConfigWrapper();

View File

@@ -0,0 +1,6 @@
import { Router } from 'express';
import { OB11GetConfigHandler,OB11SetConfigHandler} from '../api/OB11Config';
const router = Router();
router.post('/GetConfig', OB11GetConfigHandler)
router.post('/SetConfig', OB11SetConfigHandler);
export { router as OB11ConfigRouter };

View File

@@ -0,0 +1,8 @@
import { Router } from 'express';
import { QQCheckLoginStatusHandler, QQGetQRcodeHandler, QQGetQuickLoginListHandler, QQSetQuickLoginHandler } from '../api/QQLogin';
const router = Router();
router.all('/GetQuickLoginList', QQGetQuickLoginListHandler)
router.post('/CheckLoginStatus', QQCheckLoginStatusHandler);
router.post('/GetQQLoginQrcode', QQGetQRcodeHandler);
router.post('/SetQuickLogin', QQSetQuickLoginHandler);
export { router as QQLoginRouter };

View File

@@ -0,0 +1,9 @@
import { Router } from 'express';
import { LoginHandler, LogoutHandler, checkHandler } from '../api/Auth';
const router = Router();
router.post('/login', LoginHandler);
router.post('/check', checkHandler);
router.post('/logout', LogoutHandler);
export { router as AuthRouter };

View File

@@ -0,0 +1,65 @@
import { Router } from "express";
import { AuthHelper } from '../../src/helper/SignToken';
import { NextFunction, Request, Response } from 'express';
import { QQLoginRouter } from "./QQLogin";
import { AuthRouter } from "./auth";
import { OB11ConfigRouter } from "./OB11Config";
import { WebUiConfig } from "../helper/config";
const router = Router();
export async function AuthApi(req: Request, res: Response, next: NextFunction) {
//判断当前url是否为/login 如果是跳过鉴权
if (req.url == '/auth/login') {
next();
return;
}
if (req.headers?.authorization) {
let authorization = req.headers.authorization.split(' ');
if (authorization.length < 2) {
res.json({
code: -1,
msg: 'Unauthorized',
});
return;
}
let token = authorization[1];
let Credential: any;
try {
Credential = JSON.parse(Buffer.from(token, 'base64').toString('utf-8'));
} catch (e) {
res.json({
code: -1,
msg: 'Unauthorized',
});
return;
}
let config = await WebUiConfig.GetWebUIConfig();
let credentialJson = await AuthHelper.validateCredentialWithinOneHour(config.token, Credential);
if (credentialJson) {
//通过验证
next();
return;
}
res.json({
code: -1,
msg: 'Unauthorized',
});
return;
}
res.json({
code: -1,
msg: 'Server Error',
});
return;
}
router.use(AuthApi);
router.all("/test", (req, res) => {
res.json({
code: 0,
msg: 'ok',
});
});
router.use('/auth', AuthRouter);
router.use('/QQLogin', QQLoginRouter);
router.use('/OB11Config', OB11ConfigRouter);
export { router as ALLRouter }

297
src/webui/ui/NapCat.ts Normal file
View File

@@ -0,0 +1,297 @@
import { SettingList } from "./components/SettingList";
import { SettingItem } from "./components/SettingItem";
import { SettingButton } from "./components/SettingButton";
import { SettingSwitch } from "./components/SettingSwitch";
import { SettingSelect } from "./components/SettingSelect";
import { OB11Config, OB11ConfigWrapper } from "./components/WebUiApiOB11Config"
async function onSettingWindowCreated(view: Element) {
const isEmpty = (value: any) => value === undefined || value === undefined || value === '';
await OB11ConfigWrapper.Init(localStorage.getItem('auth') as string);
let ob11Config: OB11Config = await OB11ConfigWrapper.GetOB11Config();
const setOB11Config = (key: string, value: any) => {
const configKey = key.split('.');
if (configKey.length === 2) {
ob11Config[configKey[1]] = value;
}
OB11ConfigWrapper.SetOB11Config(ob11Config);
}
const parser = new DOMParser();
const doc = parser.parseFromString(
[
'<div>',
`<setting-section id="napcat-error">
<setting-panel><pre><code></code></pre></setting-panel>
</setting-section>`,
SettingList([
SettingItem(
'<span id="napcat-update-title">Napcat</span>',
undefined,
SettingButton('V1.3.0', 'napcat-update-button', 'secondary'),
),
]),
SettingList([
SettingItem(
'启用 HTTP 服务',
undefined,
SettingSwitch('ob11.enableHttp', ob11Config.enableHttp, { 'control-display-id': 'config-ob11-httpPort' }),
),
SettingItem(
'HTTP 服务监听端口',
undefined,
`<div class="q-input"><input class="q-input__inner" data-config-key="ob11.httpPort" type="number" min="1" max="65534" value="${ob11Config.httpPort}" placeholder="${ob11Config.httpPort}" /></div>`,
'config-ob11-httpPort',
ob11Config.enableHttp,
),
SettingItem(
'启用 HTTP 心跳',
undefined,
SettingSwitch('ob11.enableHttpHeart', ob11Config.enableHttpHeart, {
'control-display-id': 'config-ob11-enableHttpHeart',
}),
),
SettingItem(
'启用 HTTP 事件上报',
undefined,
SettingSwitch('ob11.enableHttpPost', ob11Config.enableHttpPost, {
'control-display-id': 'config-ob11-httpPostUrls',
}),
),
`<div class="config-host-list" id="config-ob11-httpPostUrls" ${ob11Config.enableHttpPost ? '' : 'is-hidden'}>
<setting-item data-direction="row">
<div>
<setting-text>HTTP 事件上报密钥</setting-text>
</div>
<div class="q-input">
<input id="config-ob11-httpSecret" class="q-input__inner" data-config-key="ob11.httpSecret" type="text" value="${ob11Config.httpSecret
}" placeholder="未设置" />
</div>
</setting-item>
<setting-item data-direction="row">
<div>
<setting-text>HTTP 事件上报地址</setting-text>
</div>
<setting-button id="config-ob11-httpPostUrls-add" data-type="primary">添加</setting-button>
</setting-item>
<div id="config-ob11-httpPostUrls-list"></div>
</div>`,
SettingItem(
'启用正向 WebSocket 服务',
undefined,
SettingSwitch('ob11.enableWs', ob11Config.enableWs, { 'control-display-id': 'config-ob11-wsPort' }),
),
SettingItem(
'正向 WebSocket 服务监听端口',
undefined,
`<div class="q-input"><input class="q-input__inner" data-config-key="ob11.wsPort" type="number" min="1" max="65534" value="${ob11Config.wsPort}" placeholder="${ob11Config.wsPort}" /></div>`,
'config-ob11-wsPort',
ob11Config.enableWs,
),
SettingItem(
'启用反向 WebSocket 服务',
undefined,
SettingSwitch('ob11.enableWsReverse', ob11Config.enableWsReverse, {
'control-display-id': 'config-ob11-wsReverseUrls',
}),
),
`<div class="config-host-list" id="config-ob11-wsReverseUrls" ${ob11Config.enableWsReverse ? '' : 'is-hidden'}>
<setting-item data-direction="row">
<div>
<setting-text>反向 WebSocket 监听地址</setting-text>
</div>
<setting-button id="config-ob11-wsReverseUrls-add" data-type="primary">添加</setting-button>
</setting-item>
<div id="config-ob11-wsReverseUrls-list"></div>
</div>`,
SettingItem(
' WebSocket 服务心跳间隔',
'控制每隔多久发送一个心跳包,单位为毫秒',
`<div class="q-input"><input class="q-input__inner" data-config-key="ob11.heartInterval" type="number" min="1000" value="${ob11Config.heartInterval}" placeholder="${ob11Config.heartInterval}" /></div>`,
),
SettingItem(
'Access token',
undefined,
`<div class="q-input" style="width:210px;"><input class="q-input__inner" data-config-key="ob11.token" type="text" value="${ob11Config.token}" placeholder="未设置" /></div>`,
),
SettingItem(
'新消息上报格式',
'如客户端无特殊需求推荐保持默认设置,两者的详细差异可参考 <a href="javascript:LiteLoader.api.openExternal(\'https://github.com/botuniverse/onebot-11/tree/master/message#readme\');">OneBot v11 文档</a>',
SettingSelect(
[
{ text: '消息段', value: 'array' },
{ text: 'CQ码', value: 'string' },
],
'ob11.messagePostFormat',
ob11Config.messagePostFormat,
),
),
SettingItem(
'音乐卡片签名地址',
undefined,
`<div class="q-input" style="width:210px;"><input class="q-input__inner" data-config-key="ob11.musicSignUrl" type="text" value="${ob11Config.musicSignUrl}" placeholder="未设置" /></div>`,
'ob11.musicSignUrl',
),
SettingItem('', undefined, SettingButton('保存', 'config-ob11-save', 'primary')),
]),
SettingList([
SettingItem(
'上报 Bot 自身发送的消息',
'上报 event 为 message_sent',
SettingSwitch('ob11.reportSelfMessage', ob11Config.reportSelfMessage),
)
]),
SettingList([
SettingItem('GitHub 仓库', `https://github.com/NapNeko/NapCatQQ`, SettingButton('点个星星', 'open-github')),
SettingItem('NapCat 文档', ``, SettingButton('看看文档', 'open-docs')),
SettingItem('Telegram 群', `https://t.me/+nLZEnpne-pQ1OWFl`, SettingButton('进去逛逛', 'open-telegram')),
SettingItem('QQ 群', `545402644`, SettingButton('我要进去', 'open-qq-group')),
]),
'</div>',
].join(''),
'text/html',
)
// 外链按钮
doc.querySelector('#open-github')?.addEventListener('click', () => {
window.open("https://napneko.github.io/", '_blank');
})
doc.querySelector('#open-telegram')?.addEventListener('click', () => {
window.open('https://t.me/+nLZEnpne-pQ1OWFl')
})
doc.querySelector('#open-qq-group')?.addEventListener('click', () => {
window.open('https://qm.qq.com/q/bDnHRG38aI')
})
doc.querySelector('#open-docs')?.addEventListener('click', () => {
window.open('https://github.com/NapNeko/NapCatQQ')
})
// 生成反向地址列表
const buildHostListItem = (type: string, host: string, index: number, inputAttrs: any = {}) => {
const dom = {
container: document.createElement('setting-item'),
input: document.createElement('input'),
inputContainer: document.createElement('div'),
deleteBtn: document.createElement('setting-button'),
}
dom.container.classList.add('setting-host-list-item')
dom.container.dataset.direction = 'row'
Object.assign(dom.input, inputAttrs)
dom.input.classList.add('q-input__inner')
dom.input.type = 'url'
dom.input.value = host
dom.input.addEventListener('input', () => {
ob11Config[type][index] = dom.input.value
})
dom.inputContainer.classList.add('q-input')
dom.inputContainer.appendChild(dom.input)
dom.deleteBtn.innerHTML = '删除'
dom.deleteBtn.dataset.type = 'secondary'
dom.deleteBtn.addEventListener('click', () => {
ob11Config[type].splice(index, 1)
initReverseHost(type)
})
dom.container.appendChild(dom.inputContainer)
dom.container.appendChild(dom.deleteBtn)
return dom.container
}
const buildHostList = (hosts: string[], type: string, inputAttr: any = {}) => {
const result: HTMLElement[] = []
hosts.forEach((host, index) => {
result.push(buildHostListItem(type, host, index, inputAttr))
})
return result
}
const addReverseHost = (type: string, doc: Document = document, inputAttr: any = {}) => {
const hostContainerDom = doc.body.querySelector(`#config-ob11-${type}-list`);
hostContainerDom?.appendChild(buildHostListItem(type, '', ob11Config[type].length, inputAttr));
ob11Config[type].push('');
}
const initReverseHost = (type: string, doc: Document = document) => {
const hostContainerDom = doc.body?.querySelector(`#config-ob11-${type}-list`);
if (hostContainerDom) {
[...hostContainerDom.childNodes].forEach((dom) => dom.remove());
buildHostList(ob11Config[type], type).forEach((dom) => {
hostContainerDom?.appendChild(dom);
})
}
}
initReverseHost('httpPostUrls', doc);
initReverseHost('wsReverseUrls', doc);
doc
.querySelector('#config-ob11-httpPostUrls-add')
?.addEventListener('click', () =>
addReverseHost('httpPostUrls', document, { placeholder: '如http://127.0.0.1:5140/onebot' }),
)
doc
.querySelector('#config-ob11-wsReverseUrls-add')
?.addEventListener('click', () =>
addReverseHost('wsReverseUrls', document, { placeholder: '如ws://127.0.0.1:5140/onebot' }),
)
doc.querySelector('#config-ffmpeg-select')?.addEventListener('click', () => {
//选择ffmpeg
})
doc.querySelector('#config-open-log-path')?.addEventListener('click', () => {
//打开日志
})
// 开关
doc.querySelectorAll('setting-switch[data-config-key]').forEach((dom: Element) => {
dom.addEventListener('click', () => {
const active = dom.getAttribute('is-active') == undefined;
//@ts-ignore 扩展
setOB11Config(dom.dataset.configKey, active)
if (active) dom.setAttribute('is-active', '')
else dom.removeAttribute('is-active')
//@ts-ignore 等待修复
if (!isEmpty(dom.dataset.controlDisplayId)) {
//@ts-ignore 等待修复
const displayDom = document.querySelector(`#${dom.dataset.controlDisplayId}`)
if (active) displayDom?.removeAttribute('is-hidden')
else displayDom?.setAttribute('is-hidden', '')
}
})
})
// 输入框
doc
.querySelectorAll('setting-item .q-input input.q-input__inner[data-config-key]')
.forEach((dom: Element) => {
dom.addEventListener('input', () => {
const Type = dom.getAttribute('type')
//@ts-ignore 等待修复
const configKey = dom.dataset.configKey
const configValue = Type === 'number' ? (parseInt((dom as HTMLInputElement).value) >= 1 ? parseInt((dom as HTMLInputElement).value) : 1) : (dom as HTMLInputElement).value
setOB11Config(configKey, configValue)
})
})
// 下拉框
doc.querySelectorAll('ob-setting-select[data-config-key]').forEach((dom: Element) => {
//@ts-ignore 等待修复
dom?.addEventListener('selected', (e: CustomEvent) => {
//@ts-ignore 等待修复
const configKey = dom.dataset.configKey
const configValue = e.detail.value
setOB11Config(configKey, configValue);
})
})
// 保存按钮
doc.querySelector('#config-ob11-save')?.addEventListener('click', () => {
OB11ConfigWrapper.SetOB11Config(ob11Config);
alert('保存成功');
})
doc.body.childNodes.forEach((node) => {
view.appendChild(node)
})
}
export { onSettingWindowCreated };

View File

@@ -0,0 +1,3 @@
export const SettingButton = (text: string, id?: string, type: string = 'secondary') => {
return `<setting-button ${type ? `data-type="${type}"` : ''} ${id ? `id="${id}"` : ''}>${text}</setting-button>`
}

View File

@@ -0,0 +1,15 @@
export const SettingItem = (
title: string,
subtitle?: string,
action?: string,
id?: string,
visible: boolean = true,
) => {
return `<setting-item ${id ? `id="${id}"` : ''} ${!visible ? 'is-hidden' : ''}>
<div>
<setting-text>${title}</setting-text>
${subtitle ? `<setting-text data-type="secondary">${subtitle}</setting-text>` : ''}
</div>
${action ? `<div>${action}</div>` : ''}
</setting-item>`
}

View File

@@ -0,0 +1,14 @@
export const SettingList = (
items: string[],
title?: string,
isCollapsible: boolean = false,
direction: string = 'column',
) => {
return `<setting-section ${title && !isCollapsible ? `data-title="${title}"` : ''}>
<setting-panel>
<setting-list ${direction ? `data-direction="${direction}"` : ''} ${isCollapsible ? 'is-collapsible' : ''} ${title && isCollapsible ? `data-title="${title}"` : ''}>
${items.join('')}
</setting-list>
</setting-panel>
</setting-section>`
}

View File

@@ -0,0 +1,3 @@
export const SettingOption = (text: string, value?: string, isSelected: boolean = false) => {
return `<setting-option ${value ? `data-value="${value}"` : ''} ${isSelected ? 'is-selected' : ''}>${text}</setting-option>`
}

View File

@@ -0,0 +1,84 @@
import { SettingOption } from './SettingOption'
interface MouseEventExtend extends MouseEvent {
target: HTMLElement
}
// <ob-setting-select>
const SelectTemplate = document.createElement('template')
SelectTemplate.innerHTML = `<style>
.hidden { display: none !important; }
</style>
<div part="parent">
<div part="button">
<input type="text" placeholder="请选择" part="current-text" />
<svg viewBox="0 0 16 16" fill="none" xmlns="http://www.w3.org/2000/svg" part="button-arrow">
<path d="M12 6.0001L8.00004 10L4 6" stroke="currentColor" stroke-linejoin="round"></path>
</svg>
</div>
<ul class="hidden" part="option-list"><slot></slot></ul>
</div>`
window.customElements.define(
'ob-setting-select',
class extends HTMLElement {
readonly _button: HTMLDivElement
readonly _text: HTMLInputElement
readonly _context: HTMLUListElement
constructor() {
super()
this.attachShadow({ mode: 'open' })
this.shadowRoot?.append(SelectTemplate.content.cloneNode(true));
this._button = this.shadowRoot.querySelector('div[part="button"]');
this._text = this.shadowRoot.querySelector('input[part="current-text"]');
this._context = this.shadowRoot.querySelector('ul[part="option-list"]');
const buttonClick = () => {
const isHidden = this._context.classList.toggle('hidden');
window[`${isHidden ? 'remove' : 'add'}EventListener`]('pointerdown', windowPointerDown);
}
const windowPointerDown = ({ target }) => {
if (!this.contains(target)) buttonClick()
}
this._button.addEventListener('click', buttonClick)
this._context.addEventListener('click', ({ target }: MouseEventExtend) => {
if (target.tagName !== 'SETTING-OPTION') return
buttonClick()
if (target.hasAttribute('is-selected')) return
this.querySelectorAll('setting-option[is-selected]').forEach((dom) => dom.toggleAttribute('is-selected'))
target.toggleAttribute('is-selected')
this._text.value = target.textContent as string;
this.dispatchEvent(
new CustomEvent('selected', {
bubbles: true,
composed: true,
detail: {
name: target.textContent,
value: target.dataset.value,
},
}),
)
})
this._text.value = this.querySelector('setting-option[is-selected]')?.textContent as string;
}
},
)
export const SettingSelect = (items: Array<{ text: string; value: string }>, configKey?: string, configValue?: any) => {
return `<ob-setting-select ${configKey ? `data-config-key="${configKey}"` : ''}>
${items
.map((e, i) => {
return SettingOption(e.text, e.value, configKey && configValue ? configValue === e.value : i === 0)
})
.join('')}
</ob-setting-select>`
}

View File

@@ -0,0 +1,8 @@
export const SettingSwitch = (configKey?: string, isActive: boolean = false, extraData?: Record<string, string>) => {
return `<setting-switch
${configKey ? `data-config-key="${configKey}"` : ''}
${isActive ? 'is-active' : ''}
${extraData ? Object.keys(extraData).map((key) => `data-${key}="${extraData[key]}"`) : ''}
>
</setting-switch>`
}

View File

@@ -0,0 +1,64 @@
export interface OB11Config {
[key: string]: any,
httpHost: "",
httpPort: number;
httpPostUrls: string[];
httpSecret: "",
wsHost: "",
wsPort: number;
wsReverseUrls: string[];
enableHttp: boolean;
enableHttpHeart: boolean;
enableHttpPost: boolean;
enableWs: boolean;
enableWsReverse: boolean;
messagePostFormat: 'array' | 'string';
reportSelfMessage: boolean;
enableLocalFile2Url: boolean;
debug: boolean;
heartInterval: number;
token: "",
musicSignUrl: "",
}
class WebUiApiOB11ConfigWrapper {
private retCredential: string = "";
async Init(Credential: string) {
this.retCredential = Credential;
}
async GetOB11Config(): Promise<OB11Config> {
let ConfigResponse = await fetch('/api/OB11Config/GetConfig', {
method: 'POST',
headers: {
'Authorization': "Bearer " + this.retCredential,
'Content-Type': 'application/json'
}
});
if (ConfigResponse.status == 200) {
let ConfigResponseJson = await ConfigResponse.json();
if (ConfigResponseJson.code == 0) {
return ConfigResponseJson?.data;
}
}
return {} as OB11Config;
}
async SetOB11Config(config: OB11Config): Promise<Boolean> {
let ConfigResponse = await fetch('/api/OB11Config/SetConfig',
{
method: 'POST',
headers: {
'Authorization': "Bearer " + this.retCredential,
'Content-Type': 'application/json'
},
body: JSON.stringify({ config: JSON.stringify(config) })
}
);
if (ConfigResponse.status == 200) {
let ConfigResponseJson = await ConfigResponse.json();
if (ConfigResponseJson.code == 0) {
return true;
}
}
return false;
}
}
export const OB11ConfigWrapper = new WebUiApiOB11ConfigWrapper();

13
src/webui/vite.config.ts Normal file
View File

@@ -0,0 +1,13 @@
import { defineConfig } from 'vite'
export default defineConfig({
build:{
target: 'esnext',
minify: false,
lib: {
entry: 'ui/NapCat.ts',
formats: ['es'],
fileName: () => 'renderer.js',
}
}
});

6
src/webui/webui.json Normal file
View File

@@ -0,0 +1,6 @@
{
"port": 6099,
"token": "random",
"loginRate": 3
}

294
static/QQLogin.html Normal file
View File

@@ -0,0 +1,294 @@
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<title>NapCat - WebUi</title>
<style>
body {
font-family: Arial, sans-serif;
display: flex;
justify-content: center;
align-items: center;
height: 100vh;
background-color: #f0f2f5;
}
.login-container {
padding: 20px;
border-radius: 5px;
box-shadow: 0 0 10px rgba(0, 0, 0, 0.1);
background-color: white;
max-width: 400px;
min-width: 300px;
position: relative;
}
.login-methods {
display: flex;
justify-content: space-between;
margin-bottom: 20px;
}
.login-method {
padding: 10px 15px;
font-size: 16px;
cursor: pointer;
transition: all 0.3s;
}
.login-method.active {
background-color: #e6f0ff;
color: #007BFF;
}
.login-form,
.qrcode {
display: flex;
flex-direction: column;
gap: 15px;
}
.qrcode {
display: flex;
justify-content: center;
align-items: center;
gap: 15px;
text-align: center;
}
button {
width: 100%;
padding: 10px;
background-color: #007BFF;
color: white;
border: none;
cursor: pointer;
transition: all 0.3s;
}
button:hover {
background-color: #0056b3;
}
.hidden {
display: none;
}
#qrcode-canvas {
width: 200px;
height: 200px;
}
#quick-login-dropdown {
width: 100%;
padding: 10px;
font-size: 16px;
background-color: transparent;
border: none;
cursor: pointer;
outline: none;
transition: all 0.3s;
}
#quick-login-dropdown:hover {
background-color: #e6f0ff;
}
#quick-login-options {
position: absolute;
top: calc(100% + 5px);
left: 0;
right: 0;
background-color: white;
box-shadow: 0 0 10px rgba(0, 0, 0, 0.1);
z-index: 1;
display: none;
}
#quick-login-options.show {
display: block;
}
.quick-login-option {
padding: 10px 15px;
cursor: pointer;
transition: all 0.3s;
}
.quick-login-option:hover {
background-color: #e6f0ff;
}
#quick-login-select {
width: 100%;
padding: 10px;
font-size: 16px;
background-color: #fff;
border: 1px solid #ccc;
border-radius: 5px;
cursor: pointer;
outline: none;
transition: all 0.3s;
}
#quick-login-select option {
background-color: #fff;
color: #333;
}
</style>
<script src="./assets/qrcode.min.js"></script>
</head>
<body>
<div class="login-container">
<h2>Login</h2>
<div class="login-methods">
<button id="quick-login" class="login-method active">Quick Login</button>
<button id="qrcode-login" class="login-method">QR Code</button>
</div>
<div id="quick-login-dropdown" class="login-form">
<select id="quick-login-select" onchange="selectAccount(this.value)">
<option value="">Select Account</option>
</select>
</div>
<div id="qrcode" class="qrcode" style="display: none;">
<canvas id="qrcode-canvas"></canvas>
</div>
<p id="message"></p>
</div>
<script>
async function GetQQLoginQrcode(retCredential) {
let QQLoginResponse = await fetch('/api/QQLogin/GetQQLoginQrcode', {
method: 'POST',
headers: {
'Authorization': "Bearer " + retCredential,
'Content-Type': 'application/json'
}
});
if (QQLoginResponse.status == 200) {
let QQLoginResponseJson = await QQLoginResponse.json();
if (QQLoginResponseJson.code == 0) {
if (QQLoginResponseJson.data.qrcode) {
return QQLoginResponseJson.data.qrcode;
} else {
return "";
}
}
}
return "";
}
async function CheckQQLoginStatus(retCredential) {
let QQLoginResponse = await fetch('/api/QQLogin/CheckLoginStatus', {
method: 'POST',
headers: {
'Authorization': "Bearer " + retCredential,
'Content-Type': 'application/json'
}
});
if (QQLoginResponse.status == 200) {
let QQLoginResponseJson = await QQLoginResponse.json();
if (QQLoginResponseJson.code == 0) {
if (QQLoginResponseJson.data.isLogin) {
return true;
} else {
return false;
}
}
}
return false;
}
async function GetQQQucickLoginList(retCredential) {
let QQLoginResponse = await fetch('/api/QQLogin/GetQuickLoginList', {
method: 'POST',
headers: {
'Authorization': "Bearer " + retCredential,
'Content-Type': 'application/json'
}
});
if (QQLoginResponse.status == 200) {
let QQLoginResponseJson = await QQLoginResponse.json();
if (QQLoginResponseJson.code == 0) {
return QQLoginResponseJson?.data;
}
}
return [];
}
async function SetQuickLogin(uin, retCredential) {
let QQLoginResponse = await fetch('/api/QQLogin/SetQuickLogin', {
method: 'POST',
headers: {
'Authorization': "Bearer " + retCredential,
'Content-Type': 'application/json'
},
body: JSON.stringify({
uin: uin
})
});
if (QQLoginResponse.status == 200) {
let QQLoginResponseJson = await QQLoginResponse.json();
if (QQLoginResponseJson.code == 0) {
return { result: true, errMsg: "" };
} else {
return { result: false, errMsg: QQLoginResponseJson.message };
}
}
return { result: false, errMsg: "接口异常" };;
}
//心跳轮询CheckQQLoginStatus 是否已经进入登录状态如果为true进入./config.html
async function HeartBeat() {
let isLogined = await CheckQQLoginStatus(localStorage.getItem('auth'));
if (isLogined) {
window.location.href = './config.html';
}
}
async function InitPages() {
let QuickLists = await GetQQQucickLoginList(localStorage.getItem('auth'));
let QuickListSelect = document.querySelector("#quick-login-select");
QuickLists.forEach(QuickUin => {
let optionUinEle = document.createElement('option');
optionUinEle.innerHTML = QuickUin;
optionUinEle.value = QuickUin;
QuickListSelect.appendChild(optionUinEle);
});
generateQrCode(await GetQQLoginQrcode(localStorage.getItem('auth')), document.querySelector('#qrcode-canvas'));
setInterval(HeartBeat, 3000);
}
document.getElementById('quick-login').addEventListener('click', function () {
let quickLoginOptions = document.querySelector('#quick-login-dropdown');
let qrcode = document.querySelector('#qrcode');
quickLoginOptions.style.display = 'flex';
qrcode.style.display = 'none';
});
async function selectAccount(accountName) {
//alert(`Logging in with ${accountName}...`);
const { result, errMsg } = await SetQuickLogin(accountName, localStorage.getItem('auth'));
if (result) {
alert("登录成功即将跳转");
window.location.href = './config.html';
} else {
alert("登录失败," + errMsg);
}
//await (localStorage.getItem('auth'))
//document.getElementById('quick-login-options').classList.remove('show');
}
document.getElementById('qrcode-login').addEventListener('click', function () {
let loginForm = document.querySelector('#quick-login-dropdown');
let qrcode = document.querySelector('#qrcode');
loginForm.style.display = 'none';
qrcode.style.display = 'flex';
});
function generateQrCode(data, canvas) {
QRCode.toCanvas(canvas, data, function (error) {
if (error) console.error(error);
console.log('QR Code generated!');
});
}
InitPages();
</script>
</body>
</html>

180
static/assets/NapCat.css Normal file
View File

@@ -0,0 +1,180 @@
setting-item[is-hidden],
setting-item[is-hidden] + setting-divider {
display: none !important;
}
.config-host-list {
width: 100%;
padding-left: 16px;
box-sizing: border-box;
}
.config-host-list[is-hidden],
.config-host-list[is-hidden] + setting-divider {
display: none !important;
}
setting-item .q-input {
height: 24px;
width: 100px;
border-top-left-radius: 4px;
border-top-right-radius: 4px;
border-bottom-right-radius: 4px;
border-bottom-left-radius: 4px;
box-sizing: border-box;
position: relative;
background: var(--bg_bottom_light);
border: 1px solid var(--border_dark);
}
setting-item .q-input .q-input__inner {
border-top-left-radius: 4px;
border-top-right-radius: 4px;
border-bottom-right-radius: 4px;
border-bottom-left-radius: 4px;
box-sizing: border-box;
color: var(--text_primary);
font-family: inherit;
font-size: 12px;
height: 24px;
line-height: 24px;
width: 100%;
border: 1px solid transparent;
padding: 0px 8px;
}
setting-item .q-input input[type='number'].q-input__inner::-webkit-outer-spin-button,
setting-item .q-input input[type='number'].q-input__inner::-webkit-inner-spin-button {
-webkit-appearance: none;
margin: 0;
}
.config-host-list setting-item.setting-host-list-item .q-input {
width: 260px;
}
setting-item a {
color: var(--text-link);
}
setting-item a:hover {
color: var(--hover-link);
}
setting-item a:active,
setting-item a:visited {
color: var(--text-link);
}
ob-setting-select {
width: 100px;
}
ob-setting-select,
ob-setting-select::part(parent),
ob-setting-select::part(button) {
display: block;
position: relative;
height: 24px;
font-size: 12px;
line-height: 24px;
box-sizing: border-box;
}
ob-setting-select::part(button) {
display: flex;
padding: 0px 8px;
background-color: transparent;
border-radius: 4px;
border: 1px solid var(--border_dark);
z-index: 5;
cursor: default;
align-items: center;
flex-direction: row;
flex-wrap: nowrap;
}
ob-setting-select::part(current-text) {
display: block;
margin-right: 8px;
padding: 0px;
background: none;
background-color: transparent;
font-size: 12px;
color: var(--text_primary);
text-overflow: ellipsis;
border-radius: 0px;
border: none;
outline: none;
overflow: hidden;
appearance: none;
box-sizing: border-box;
cursor: default;
flex: 1;
-webkit-user-select: none;
-moz-user-select: none;
-ms-user-select: none;
-o-user-select: none;
user-select: none;
-webkit-pointer-events: none;
-moz-pointer-events: none;
-ms-pointer-events: none;
-o-pointer-events: none;
pointer-events: none;
}
ob-setting-select::part(button-arrow) {
position: relative;
display: block;
width: 16px;
height: 16px;
color: var(--icon_primary);
}
ob-setting-select::part(option-list) {
display: flex;
position: absolute;
top: 100%;
padding: 4px;
margin: 5px 0px;
width: 100%;
max-height: var(--q-contextmenu-max-height);
background-color: var(--blur_middle_standard);
background-clip: padding-box;
backdrop-filter: blur(8px);
font-size: 12px;
box-shadow: var(--shadow_bg_middle_secondary);
border: 1px solid var(--border_secondary);
border-radius: 4px;
box-sizing: border-box;
app-region: no-drag;
overflow-x: hidden;
overflow-y: auto;
list-style: none;
z-index: 999;
flex-direction: column;
align-items: stretch;
flex-wrap: nowrap;
justify-content: flex-start;
gap: 4px;
}
#napcat-error {
display: none;
}
#napcat-error setting-panel {
background: rgba(255, 0, 0, 0.5);
color: white;
}
#napcat-error setting-panel pre {
margin: 0;
padding: 16px;
box-sizing: border-box;
}
#napcat-error setting-panel pre code {
font-family: 'FiraCode Nerd Font', 'Fira Code', 'Cascadia Code', Consolas, 'Courier New', monospace;
}
#napcat-error.show {
display: block;
}

679
static/assets/color.css Normal file
View File

@@ -0,0 +1,679 @@
:root {
--font-bold: 400;
--font_size_1: 10px;
--font_size_2: 12px;
--font_size_3: 14px;
--font_size_4: 16px;
--font_size_5: 18px;
--avatar_size_1: 20px;
--avatar_size_2: 32px;
--avatar_size_3: 40px;
--font_size_main_1: 12px;
--font_size_main_2: 14px;
--line_height_1: 14px;
--line_height_2: 16px;
--line_height_3: 20px;
--line_height_4: 22px;
--line_height_5: 24px;
--line_height_main_1: 18px;
--line_height_main_2: 22px;
--shadow_card_rest: 0px 2px 4px rgba(0, 0, 0, 0.12);
--shadow_tooltip: 0px 4px 8px rgba(0, 0, 0, 0.26);
--shadow_flyout: 0px 8px 16px rgba(0, 0, 0, 0.14);
--shadow_dialog: 0px 30px 60px rgba(0, 0, 0, 0.36) 0 2px 20px rgba(0, 0, 0, 0.37);
--blend_brightness_white_004: 1.04;
--blend_brightness_white_008: 1.08;
--blend_brightness_white_010: 1.10;
--blend_brightness_white_016: 1.16;
--blend_brightness_white_020: 1.20;
--blend_brightness_black_004: 0.96;
--blend_brightness_black_008: 0.92;
--blend_brightness_black_010: 0.90;
--blend_brightness_black_016: 0.84;
--blend_brightness_black_020: 0.80;
--blend_white_004: rgba(255, 255, 255, 0.04);
--blend_white_008: rgba(255, 255, 255, 0.08);
--blend_white_010: rgba(255, 255, 255, 0.10);
--blend_white_016: rgba(255, 255, 255, 0.16);
--blend_white_020: rgba(255, 255, 255, 0.20);
--blend_black_004: rgba(0, 0, 0, 0.04);
--blend_black_008: rgba(0, 0, 0, 0.08);
--blend_black_010: rgba(0, 0, 0, 0.10);
--blend_black_016: rgba(0, 0, 0, 0.16);
--blend_black_020: rgba(0, 0, 0, 0.20);
--blend_transparent: rgba(0, 0, 0, 0);
--el-color-white: #fff;
--el-color-black: #000;
--el-color-primary: #409eff;
--el-color-primary-rgb: 64,158,255;
--el-color-success-rgb: 103,194,58;
--el-color-warning-rgb: 230,162,60;
--el-color-danger-rgb: 245,108,108;
--el-color-error-rgb: 245,108,108;
--el-color-info-rgb: 144,147,153;
--el-color-primary-light-1: #53a8ff;
--el-color-primary-light-2: #66b1ff;
--el-color-primary-light-3: #79bbff;
--el-color-primary-light-4: #8cc5ff;
--el-color-primary-light-5: #a0cfff;
--el-color-primary-light-6: #b3d8ff;
--el-color-primary-light-7: #c6e2ff;
--el-color-primary-light-8: #d9ecff;
--el-color-primary-light-9: #ecf5ff;
--el-color-primary-dark-2: #337ecc;
--el-color-success: #67c23a;
--el-color-success-light-3: #95d475;
--el-color-success-light-5: #b3e19d;
--el-color-success-light-7: #d1edc4;
--el-color-success-light-8: #e1f3d8;
--el-color-success-light-9: #f0f9eb;
--el-color-success-dark-2: #529b2e;
--el-color-warning: #e6a23c;
--el-color-warning-light-3: #eebe77;
--el-color-warning-light-5: #f3d19e;
--el-color-warning-light-7: #f8e3c5;
--el-color-warning-light-8: #faecd8;
--el-color-warning-light-9: #fdf6ec;
--el-color-warning-dark-2: #b88230;
--el-color-danger: #f56c6c;
--el-color-danger-light-3: #f89898;
--el-color-danger-light-5: #fab6b6;
--el-color-danger-light-7: #fcd3d3;
--el-color-danger-light-8: #fde2e2;
--el-color-danger-light-9: #fef0f0;
--el-color-danger-dark-2: #c45656;
--el-color-error: #f56c6c;
--el-color-error-light-3: #f89898;
--el-color-error-light-5: #fab6b6;
--el-color-error-light-7: #fcd3d3;
--el-color-error-light-8: #fde2e2;
--el-color-error-light-9: #fef0f0;
--el-color-error-dark-2: #c45656;
--el-color-info: #909399;
--el-color-info-light-3: #b1b3b8;
--el-color-info-light-5: #c8c9cc;
--el-color-info-light-7: #dedfe0;
--el-color-info-light-8: #e9e9eb;
--el-color-info-light-9: #f4f4f5;
--el-color-info-dark-2: #73767a;
--el-bg-color: #fff;
--el-bg-color-page: #fff;
--el-bg-color-overlay: #fff;
--el-text-color-primary: #303133;
--el-text-color-regular: #606266;
--el-text-color-secondary: #909399;
--el-text-color-placeholder: #a8abb2;
--el-text-color-disabled: #c0c4cc;
--el-border-color: #dcdfe6;
--el-border-color-light: #e4e7ed;
--el-border-color-lighter: #ebeef5;
--el-border-color-extra-light: #f2f6fc;
--el-border-color-dark: #d4d7de;
--el-border-color-darker: #cdd0d6;
--el-fill-color: #f0f2f5;
--el-fill-color-light: #f5f7fa;
--el-fill-color-lighter: #fafafa;
--el-fill-color-extra-light: #fafcff;
--el-fill-color-dark: #ebedf0;
--el-fill-color-darker: #e6e8eb;
--el-fill-color-blank: #fff;
--el-border-radius-base: 4px;
--el-border-radius-small: 2px;
--el-border-radius-round: 20px;
--el-border-radius-circle: 100%;
--el-font-size-extra-large: 20px;
--el-font-size-large: 18px;
--el-font-size-medium: 16px;
--el-font-size-base: 14px;
--el-font-size-small: 13px;
--el-font-size-extra-small: 12px;
--el-font-family: "Helvetica Neue",Helvetica,"PingFang SC","Hiragino Sans GB","Microsoft YaHei","微软雅黑",Arial,sans-serif;
--el-box-shadow: 0px 12px 32px 4px rgba(0,0,0,.04),0px 8px 20px rgba(0,0,0,.08);
--el-box-shadow-light: 0px 0px 12px rgba(0,0,0,.12);
--el-box-shadow-lighter: 0px 0px 6px rgba(0,0,0,.12);
--el-box-shadow-dark: 0px 16px 48px 16px rgba(0,0,0,.08),0px 12px 32px rgba(0,0,0,.12),0px 8px 16px -8px rgba(0,0,0,.16);
--el-disabled-bg-color: var(--el-fill-color-light);
--el-disabled-text-color: var(--el-text-color-placeholder);
--el-disabled-border-color: var(--el-border-color-light);
--el-index-normal: 1;
--el-index-top: 1000;
--el-index-popper: 2000;
--el-overlay-color: rgba(0,0,0,.8);
--el-overlay-color-light: rgba(0,0,0,.7);
--el-overlay-color-lighter: rgba(0,0,0,.5);
--el-mask-color: hsla(0,0%,100%,.9);
--el-mask-color-extra-light: hsla(0,0%,100%,.3);
--el-border-width: 1px;
--el-border-style: solid;
--el-border-color-hover: var(--el-text-color-disabled);
--el-border: var(--el-border-width) var(--el-border-style) var(--el-border-color);
--el-svg-monochrome-grey: var(--el-border-color);
--el-font-weight-primary: 500;
--el-font-line-height-primary: 24px;
--el-transition-duration: 0.3s;
--el-transition-duration-fast: 0.2s;
--el-transition-function-ease-in-out-bezier: cubic-bezier(0.645,0.045,0.355,1);
--el-transition-function-fast-bezier: cubic-bezier(0.23,1,0.32,1);
--el-transition-all: all var(--el-transition-duration) var(--el-transition-function-ease-in-out-bezier);
--el-transition-fade: opacity var(--el-transition-duration) var(--el-transition-function-fast-bezier);
--el-transition-md-fade: transform var(--el-transition-duration) var(--el-transition-function-fast-bezier),opacity var(--el-transition-duration) var(--el-transition-function-fast-bezier);
--el-transition-fade-linear: opacity var(--el-transition-duration-fast) linear;
--el-transition-border: border-color var(--el-transition-duration-fast) var(--el-transition-function-ease-in-out-bezier);
--el-transition-box-shadow: box-shadow var(--el-transition-duration-fast) var(--el-transition-function-ease-in-out-bezier);
--el-transition-color: color var(--el-transition-duration-fast) var(--el-transition-function-ease-in-out-bezier);
--nt_brand_standard_2_overlay_hover_brand_2_mix: #008debff;
--nt_brand_standard_2_overlay_pressed_brand_2_mix: #0080d6ff;
--nt_feedback_error_2_overlay_hover_brand_2_mix: #e4462cff;
--nt_feedback_error_2_overlay_pressed_brand_2_mix: #cf4028ff;
--nt_icon_white_2_overlay_hover_2_mix: #f5f5f5ff;
--nt_icon_white_2_overlay_pressed_2_mix: #e0e0e0ff;
--nt_bg_top_light_2_overlay_hover_2_mix: #f5f5f5ff;
--nt_bg_top_light_2_overlay_pressed_2_mix: #e0e0e0ff;
--nt_icon_secondary_02_2_0_2_alpha: rgba(204, 204, 204, 0);
--nt_icon_secondary_02_2_70_2_alpha: rgba(204, 204, 204, 0.7);
--nt_text_link_2_50_2_alpha: rgba(45, 119, 229, 0.5);
--nt_bubble_host_2_overlay_pressed_brand_2_mix: #0080d6ff;
--nt_bg_white_2_overlay_pressed_brand_2_mix: #d6d6d6ff;
--nt_bg_white_2_overlay_hover_2_mix: #f5f5f5ff;
--nt_bg_white_2_overlay_pressed_2_mix: #e0e0e0ff;
--nt_fg_white_2_overlay_hover_2_mix: #f5f5f5ff;
--nt_fg_white_2_overlay_pressed_2_mix: #e0e0e0ff;
--nt_icon_red_2_overlay_hover_2_mix: #f5314fff;
--nt_icon_red_2_overlay_pressed_2_mix: #e02d48ff;
--nt_fg_grey_standard_2_overlay_hover_2_mix: #0000003b;
--nt_fg_grey_standard_2_overlay_pressed_2_mix: #0000004c;
--nt_bubble_guest_2_overlay_pressed_2_mix: #e0e0e0ff;
--nt_icon_primary_2_20_2_alpha: rgba(0, 0, 0, 0.2);
--nt_bg_grey_standard_2_95_2_alpha: rgba(242, 242, 242, 0.95);
--nt_tag_red_2_20_2_alpha: rgba(255, 134, 46, 0.2);
--nt_tag_red_2_25_2_alpha: rgba(255, 134, 46, 0.25);
--nt_tag_blue_2_20_2_alpha: rgba(0, 153, 255, 0.2);
--nt_tag_blue_2_25_2_alpha: rgba(0, 153, 255, 0.25);
--nt_tag_blue_2_10_2_alpha: rgba(0, 153, 255, 0.1);
--nt_brand_standard_2_20_2_alpha: rgba(0, 153, 255, 0.2);
--nt_feedback_error_2_20_2_alpha: rgba(247, 76, 48, 0.2);
--nt_text_white_2_60_2_alpha: rgba(255, 255, 255, 0.6);
--nt_bg_white_2_70_2_alpha: rgba(255, 255, 255, 0.7);
--nt_bg_white_2_90_2_alpha: rgba(255, 255, 255, 0.9);
--nt_bg_white_2_97_2_alpha: rgba(255, 255, 255, 0.97);
--nt_bg_white_2_40_2_alpha: rgba(255, 255, 255, 0.4);
--nt_bg_white_2_30_2_alpha: rgba(255, 255, 255, 0.3);
--nt_text_white_2_80_2_alpha: rgba(255, 255, 255, 0.8);
--nt_brand_standard_2_50_2_alpha: rgba(0, 153, 255, 0.5);
--nt_bg_nav_secondary_2_60_2_alpha: rgba(255, 255, 255, 0.6);
--nt_bg_nav_2_60_2_alpha: rgba(242, 242, 242, 0.6);
--nt_feedback_error_2_10_2_alpha: rgba(247, 76, 48, 0.1);
--nt_brand_standard_2_10_2_alpha: rgba(0, 153, 255, 0.1);
--nt_on_brand_primary_2_40_2_alpha: rgba(255, 255, 255, 0.4);
--nt_text_primary_2_72_2_alpha: rgba(0, 0, 0, 0.72);
--nt_text_white_2_72_2_alpha: rgba(255, 255, 255, 0.72);
--border_secondary: 1px solid rgba(0, 0, 0, 0.0578);
--border_primary: 1px solid rgba(117, 117, 117, 0.4);
--shadow_bg_top: 0px 4px 8px rgba(0, 0, 0, 0.14);
--shadow_bg_middle_secondary: 0px 8px 16px rgba(0, 0, 0, 0.14);
--shadow_bg_middle_primary: 0px 32px 64px rgba(0, 0, 0, 0.1876), 0px 2px 21px rgba(0, 0, 0, 0.1474);
--shadow_bg_bottom_inactive: 0px 16px 32px rgba(0, 0, 0, 0.1876), 0px 2px 10.67px rgba(0, 0, 0, 0.1474);
--shadow_bg_bottom_active: 0px 32px 64px rgba(0, 0, 0, 0.28), 0px 2px 21px rgba(0, 0, 0, 0.22);
--brand_standard: #0099ffff;
--on_brand_primary: #ffffffff;
--on_brand_secondary: #ffffffff;
--text_primary: #000000ff;
--text_primary_light: #00000099;
--text_secondary_02: #ccccccff;
--text_white: #ffffffff;
--text_secondary_01: #999999ff;
--text_black: #000000ff;
--on_bg_text: #999999ff;
--text_link: #2d77e5ff;
--text_secondary: #00000080;
--text_tertiary: #0000004d;
--icon_primary: #000000ff;
--icon_secondary_01: #999999ff;
--icon_secondary_02: #ccccccff;
--icon_white: #ffffffff;
--icon_red: #ff3352ff;
--icon_black: #000000ff;
--icon_secondary: #00000066;
--icon_tertiary: #0000004d;
--feedback_success: #15d173ff;
--feedback_warning: #ffb300ff;
--feedback_error: #f74c30ff;
--bg_grey_standard: #f2f2f2ff;
--bg_white: #ffffffff;
--bg_list: #ffffffff;
--bg_aio_1: #f2f2f2ff;
--bg_aio_2: #f2f2f2ff;
--bg_aio_3: #f2f2f2ff;
--bg_aio_4: #f2f2f2ff;
--bg_nav: #f2f2f2ff;
--mac_bg_nav: #ffffff1a;
--bg_bottom_standard: #f2f2f2ff;
--bg_bottom_light: #ffffffff;
--bg_middle_standard: #f2f2f2ff;
--bg_middle_light: #ffffffff;
--bg_top_standard: #f2f2f2ff;
--bg_top_light: #ffffffff;
--bg_nav_secondary: #ffffffff;
--bubble_host: #0099ffff;
--bubble_guest: #ffffffff;
--bubble_host_text: #ffffff;
--bubble_guest_text: #000000ff;
--bubble_host_1: #0099ffff;
--bubble_host_2: #0099ffff;
--fg_grey_standard: #00000033;
--fg_white: #ffffffff;
--fg_grey_light: #0000000a;
--fill_standard_secondary: #0000000a;
--fill_standard_primary: #00000033;
--fill_light_primary: #ffffffff;
--fill_light_secondary: #ffffffff;
--divider_standard: #0000000a;
--divider_dark: #00000014;
--border_standard: #0000000a;
--border_dark: #00000014;
--overlay_hover: #0000000a;
--overlay_hover_brand: #00000014;
--overlay_pressed_brand: #00000029;
--overlay_active_brand: #0099ffff;
--overlay_top: #0000000f;
--overlay_mask_standard: #00000080;
--overlay_mask_dark: #00000099;
--overlay_pressed: #0000001f;
--overlay_active: #00000014;
--overlay_mask_aio: #00000000;
--blur_standard: #ffffffcc;
--blur_superlight: #ffffff1a;
--blur_middle_standard: #ffffffcc;
--blur_bottom_superlight: #ffffff1a;
--extend_blue: #eaf1ffff;
--svip_red: #ff4222ff;
--tag_sage_green_bg: #a3c4c633;
--tag_sage_green_text: #769698ff;
--tag_red_bg: #ff3f3233;
--tag_red_text: #f74c30ff;
--tag_orange_text: #ff8d40ff;
--tag_orange_bg: #ff862e33;
--tag_purple_text: #aa76f6ff;
--tag_purple_bg: #b27eff33;
--tag_blue_text: #0099ffff;
--tag_blue_bg: #0099ff33;
--tag_blue: #0099ff33;
--tag_red: #ff862e33;
--border_white: #ffffffff;
--border_secondary: #0000000f;
--border_primary: #75757566;
--mac_border_primary: #00000014;
--mac_border_secondary: #0000000a;
--host_bubble_bg_css_value: #0099ff;
--on_bubble_host_text: #ffffffff;
--brand_text: #0099ffff;
--text-primary: #000;
--text-primary-light: #666;
--text-secondary-01: #999;
--text-secondary-02: #ccc;
--text-white: #fff;
--text-brand: #0099ff;
--text-link: #2d77e5;
--text-success: #12d173;
--text-warning: #ffb300;
--text-error: #ff5967;
--icon-primary: #000;
--icon-secondary-01: #999999;
--icon-secondary-02: #cccccc;
--icon-white: #fff;
--icon-brand: #0099ff;
--icon-success: #15d173;
--icon-warning: #ffb300;
--icon-error: #ff5967;
--button-primary-default: #0099ff;
--button-primary-hover: #4DB7FF;
--button-primary-pressed: #0089E5;
--button-primary-disable: #CCEBFF;
--button-secondary-default: #ccc;
--button-secondary-hover: #E5E5E5;
--button-secondary-pressed: #B2B2B2;
--button-secondary-disable: #F0F0F0;
--button-white-default: #FFFFFF;
--button-white-hover: #E5E5E5;
--button-white-pressed: #B2B2B2;
--button-white-disable: #ffffff4d;
--button-error-default: #FF5967;
--button-error-hover: #FF8B94;
--button-error-pressed: #E6505C;
--button-error-disable: #FFEEEF;
--bubble-host: #0099FF;
--bubble-guest: #EBEBEB;
--divider-standard: #E5E5E5;
--divider-light: #F5F5F5;
--divider-brand: #0099FF;
--background-01: #000;
--background-02: #E5E5E5;
--background-03: #F5F5F5;
--background-04: #FAFAFA;
--background-05: #FFFFFF;
--background-dialogue: #FFFFFF;
--hover-list: #F0F0F0;
--hover-icon: #EBEBEB;
--hover-link: #81ADEF;
--press-list: #E5E5E5;
--press-icon: #E5E5E5;
--press-link: #286BCE;
--badge-brand: #0099FF;
--badge-red: #FF5967;
--badge-grey: #CCCCCC;
--audio-hangup: #FF3350;
--gray-black: #000;
--gray-20: #333333;
--gray-40: #666666;
--gray-60: #999999;
--gray-80: #cccccc;
--gray-90: #e5e5e5;
--gray-96: #f5f5f5;
--gray-white: #ffffff;
--blue-dark: #0089E5;
--blue-standard: #0099FF;
--blue-light: #4DB7FF;
--blue-superlight: #E6F5FF;
--green-dark: #12BC67;
--green-standard: #15D173;
--green-light: #5BDE9D;
--green-superlight: #E8FAF1;
--yellow-dark: #E5A000;
--yellow-standard: #FFB300;
--yellow-light: #FFC94C;
--yellow-superlight: #FFF7E5;
--orange-dark: #E57E39;
--orange-standard: #FF8D40;
--orange-light: #FFAE78;
--orange-superlight: #FFF3EB;
--red-dark: #E6505C;
--red-standard: #FF5967;
--red-light: #FF8B94;
--red-superlight: #FFEEEF;
--pink-dark: #E55BA0;
--pink-standard: #FF66B3;
--pink-light: #FF93C9;
--pink-superlight: #FFEFF7;
--indigo-dark: #775CE6;
--indigo-standard: #8566FF;
--indigo-light: #A994FF;
--indigo-superlight: #F3F0FF;
--list-hover: rgba(243, 243, 243);
--list-pressed: rgba(226, 226, 226);
--background_01: #000000;
--background_02: #E6E6E6;
--background_03: #F5F5F5;
--background_04: #FAFAFA;
--background_05: #FFFFFF;
--background_dialogue: #FFFFFF;
--sidebar_win: #ebebeb;
--sidebar_mac: rgba(255,255,255,0.1);
--nt_mix_tokens: nt_brand_standard_2_overlay_hover_brand_2_mix,nt_brand_standard_2_overlay_pressed_brand_2_mix,nt_feedback_error_2_overlay_hover_brand_2_mix,nt_feedback_error_2_overlay_pressed_brand_2_mix,nt_icon_white_2_overlay_hover_2_mix,nt_icon_white_2_overlay_pressed_2_mix,nt_bubble_host_2_overlay_pressed_brand_2_mix,nt_bg_white_2_overlay_pressed_brand_2_mix,nt_bg_white_2_overlay_hover_2_mix,nt_bg_white_2_overlay_pressed_2_mix,nt_fg_white_2_overlay_hover_2_mix,nt_fg_white_2_overlay_pressed_2_mix,nt_icon_red_2_overlay_hover_2_mix,nt_icon_red_2_overlay_pressed_2_mix,nt_fg_grey_standard_2_overlay_hover_2_mix,nt_fg_grey_standard_2_overlay_pressed_2_mix,nt_bubble_guest_2_overlay_pressed_2_mix,nt_icon_primary_2_20_2_alpha,nt_bg_grey_standard_2_95_2_alpha,nt_tag_red_2_20_2_alpha,nt_tag_red_2_25_2_alpha,nt_tag_blue_2_20_2_alpha,nt_tag_blue_2_25_2_alpha,nt_tag_blue_2_10_2_alpha,nt_tag_purple_2_20_2_alpha,nt_brand_standard_2_20_2_alpha,nt_tag_sage_green_2_20_2_alpha,nt_feedback_error_2_20_2_alpha,nt_text_white_2_60_2_alpha,nt_bg_white_2_70_2_alpha,nt_bg_white_2_90_2_alpha,nt_bg_white_2_97_2_alpha,nt_bg_white_2_40_2_alpha,nt_bg_white_2_30_2_alpha,nt_text_white_2_80_2_alpha,nt_brand_standard_2_50_2_alpha,nt_bg_nav_secondary_2_60_2_alpha,nt_bg_nav_2_60_2_alpha,nt_feedback_error_2_10_2_alpha,nt_brand_standard_2_10_2_alpha,nt_on_brand_primary_2_40_2_alpha,nt_text_primary_2_72_2_alpha,nt_text_white_2_72_2_alpha;
color-scheme: light;
}
.q-theme-tokens-dark {
--nt_brand_standard_2_overlay_hover_brand_2_mix: #1472d0ff;
--nt_brand_standard_2_overlay_pressed_brand_2_mix: #0056abff;
--nt_feedback_error_2_overlay_hover_brand_2_mix: #f85a40ff;
--nt_feedback_error_2_overlay_pressed_brand_2_mix: #cf4028ff;
--nt_icon_white_2_overlay_hover_2_mix: #ffffffff;
--nt_icon_white_2_overlay_pressed_2_mix: #d6d6d6ff;
--nt_bg_top_light_2_overlay_hover_2_mix: #404040ff;
--nt_bg_top_light_2_overlay_pressed_2_mix: #282828ff;
--nt_icon_secondary_02_2_0_2_alpha: rgba(77, 77, 77, 0);
--nt_icon_secondary_02_2_70_2_alpha: rgba(77, 77, 77, 0.7);
--nt_text_link_2_50_2_alpha: rgba(45, 119, 229, 0.5);
--nt_bubble_host_2_overlay_pressed_brand_2_mix: #202020ff;
--nt_bg_white_2_overlay_pressed_brand_2_mix: #202020ff;
--nt_bg_white_2_overlay_hover_2_mix: #373737ff;
--nt_bg_white_2_overlay_pressed_2_mix: #202020ff;
--nt_fg_white_2_overlay_hover_2_mix: #373737ff;
--nt_fg_white_2_overlay_pressed_2_mix: #202020ff;
--nt_icon_red_2_overlay_hover_2_mix: #ff4360ff;
--nt_icon_red_2_overlay_pressed_2_mix: #d62b45ff;
--nt_fg_grey_standard_2_overlay_hover_2_mix: #ffffff43;
--nt_fg_grey_standard_2_overlay_pressed_2_mix: #82828254;
--nt_bubble_guest_2_overlay_pressed_2_mix: #202020ff;
--nt_icon_primary_2_20_2_alpha: rgba(255, 255, 255, 0.2);
--nt_bg_grey_standard_2_95_2_alpha: rgba(26, 26, 26, 0.95);
--nt_tag_red_2_20_2_alpha: rgba(255, 134, 46, 0.2);
--nt_tag_red_2_25_2_alpha: rgba(255, 134, 46, 0.25);
--nt_tag_blue_2_20_2_alpha: rgba(0, 153, 255, 0.2);
--nt_tag_blue_2_25_2_alpha: rgba(0, 153, 255, 0.25);
--nt_tag_blue_2_10_2_alpha: rgba(0, 153, 255, 0.1);
--nt_brand_standard_2_20_2_alpha: rgba(0, 102, 204, 0.2);
--nt_feedback_error_2_20_2_alpha: rgba(247, 76, 48, 0.2);
--nt_text_white_2_60_2_alpha: rgba(255, 255, 255, 0.6);
--nt_bg_white_2_70_2_alpha: rgba(38, 38, 38, 0.7);
--nt_bg_white_2_90_2_alpha: rgba(38, 38, 38, 0.9);
--nt_bg_white_2_97_2_alpha: rgba(38, 38, 38, 0.97);
--nt_bg_white_2_40_2_alpha: rgba(38, 38, 38, 0.4);
--nt_bg_white_2_30_2_alpha: rgba(38, 38, 38, 0.3);
--nt_text_white_2_80_2_alpha: rgba(255, 255, 255, 0.8);
--nt_brand_standard_2_50_2_alpha: rgba(0, 102, 204, 0.5);
--nt_bg_nav_secondary_2_60_2_alpha: rgba(27, 27, 27, 0.6);
--nt_bg_nav_2_60_2_alpha: rgba(17, 17, 17, 0.6);
--nt_feedback_error_2_10_2_alpha: rgba(247, 76, 48, 0.1);
--nt_brand_standard_2_10_2_alpha: rgba(0, 102, 204, 0.1);
--nt_on_brand_primary_2_40_2_alpha: rgba(255, 255, 255, 0.4);
--nt_text_primary_2_72_2_alpha: rgba(255, 255, 255, 0.72);
--nt_text_white_2_72_2_alpha: rgba(255, 255, 255, 0.72);
--border_secondary: 1px solid rgba(0, 0, 0, 0.2);
--border_primary: 1px solid rgba(117, 117, 117, 0.4);
--shadow_bg_top: 0px 4px 8px rgba(0, 0, 0, 0.26);
--shadow_bg_middle_secondary: 0px 8px 16px rgba(0, 0, 0, 0.14);
--shadow_bg_middle_primary: 0px 32px 64px rgba(0, 0, 0, 0.37), 0px 2px 21px rgba(0, 0, 0, 0.37);
--shadow_bg_bottom_inactive: 0px 32px 64px rgba(0, 0, 0, 0.56), 0px 2px 21px rgba(0, 0, 0, 0.55);
--shadow_bg_bottom_active: 0px 32px 64px rgba(0, 0, 0, 0.56), 0px 2px 21px rgba(0, 0, 0, 0.55);
--brand_standard: #0066ccff;
--on_brand_primary: #ffffffff;
--on_brand_secondary: #ffffffff;
--text_primary: #ffffffe6;
--text_primary_light: #ffffff99;
--text_secondary_02: #666666ff;
--text_white: #ffffffe6;
--text_secondary_01: #808080ff;
--text_black: #000000ff;
--on_bg_text: #808080ff;
--text_link: #2d77e5ff;
--text_secondary: #ffffff99;
--text_tertiary: #ffffff66;
--icon_primary: #ffffffb3;
--icon_secondary_01: #666666ff;
--icon_secondary_02: #4d4d4dff;
--icon_white: #ffffffff;
--icon_red: #ff3352ff;
--icon_black: #000000ff;
--icon_secondary: #ffffff80;
--icon_tertiary: #ffffff66;
--feedback_success: #15d173ff;
--feedback_warning: #ffb300ff;
--feedback_error: #f74c30ff;
--bg_grey_standard: #1a1a1aff;
--bg_white: #262626ff;
--bg_list: #1b1b1bff;
--bg_aio_1: #1a1a1aff;
--bg_aio_2: #1a1a1aff;
--bg_aio_3: #1a1a1aff;
--bg_aio_4: #1a1a1aff;
--bg_nav: #111111ff;
--mac_bg_nav: #0000001a;
--bg_bottom_standard: #111111ff;
--bg_bottom_light: #1b1b1bff;
--bg_middle_standard: #1b1b1bff;
--bg_middle_light: #262626ff;
--bg_top_standard: #262626ff;
--bg_top_light: #303030ff;
--bg_nav_secondary: #1b1b1bff;
--bubble_host: #262626ff;
--bubble_guest: #262626ff;
--bubble_host_text: #f2f2f2;
--bubble_guest_text: #f2f2f2ff;
--bubble_host_1: #262626ff;
--bubble_host_2: #262626ff;
--fg_grey_standard: #ffffff33;
--fg_white: #262626ff;
--fg_grey_light: #00000033;
--fill_standard_secondary: #ffffff0f;
--fill_standard_primary: #ffffff33;
--fill_light_primary: #262626ff;
--fill_light_secondary: #ffffff0f;
--divider_standard: #ffffff0a;
--divider_dark: #ffffff14;
--border_standard: #ffffff0f;
--border_dark: #ffffff14;
--overlay_hover: #ffffff14;
--overlay_hover_brand: #ffffff14;
--overlay_pressed_brand: #00000029;
--overlay_active_brand: #0066ccff;
--overlay_top: #ffffff0f;
--overlay_mask_standard: #00000080;
--overlay_mask_dark: #00000099;
--overlay_pressed: #00000029;
--overlay_active: #ffffff1f;
--overlay_mask_aio: #00000000;
--blur_standard: #000000cc;
--blur_superlight: #0000001a;
--blur_middle_standard: #262626cc;
--blur_bottom_superlight: #0000001a;
--extend_blue: #002f65ff;
--svip_red: #ff4222ff;
--tag_sage_green_bg: #a3c4c633;
--tag_sage_green_text: #769698ff;
--tag_red_bg: #ff3f3233;
--tag_red_text: #f74c30ff;
--tag_orange_text: #ff8d40ff;
--tag_orange_bg: #ff862e33;
--tag_purple_text: #aa76f6ff;
--tag_purple_bg: #b27eff33;
--tag_blue_text: #0066ccff;
--tag_blue_bg: #0099ff33;
--tag_blue: #0099ff40;
--tag_red: #ff862e33;
--border_white: #262626ff;
--border_secondary: #00000033;
--border_primary: #75757566;
--mac_border_primary: #ffffff14;
--mac_border_secondary: #ffffff0a;
--host_bubble_bg_css_value: #262626;
--on_bubble_host_text: #f2f2f2ff;
--brand_text: #0066ccff;
--text-primary: #FFFFFF;
--text-primary-light: #CCCCCC;
--text-secondary-01: #999;
--text-secondary-02: #666666;
--text-white: #fff;
--text-brand: #0099ff;
--text-link: #2d77e5;
--text-success: #12d173;
--text-warning: #ffb300;
--text-error: #ff5967;
--icon-primary: #999999;
--icon-secondary-01: #999999;
--icon-secondary-02: #999999;
--icon-white: #fff;
--icon-brand: #0099ff;
--icon-success: #15d173;
--icon-warning: #ffb300;
--icon-error: #ff5967;
--button-primary-default: #0066CC;
--button-primary-hover: #19467F;
--button-primary-pressed: #0A1F33;
--button-primary-disable: #232323;
--button-secondary-default: #232323;
--button-secondary-hover: #1F1F1F;
--button-secondary-pressed: #1A1A1A;
--button-secondary-disable: #1A1A1A;
--button-white-default: #FFFFFF;
--button-white-hover: #FAFAFA;
--button-white-pressed: #F5F5F5;
--button-white-disable: #FFFFFF;
--button-error-default: #FF5967;
--button-error-hover: #FF8B94;
--button-error-pressed: #E6505C;
--button-error-disable: #FFEEEF;
--bubble-host: #262626;
--bubble-guest: #262626;
--divider-standard: #242424;
--divider-light: #4D4D4D;
--divider-brand: #0099FF;
--background-01: #FFFFFF;
--background-02: #242424;
--background-03: #181818;
--background-04: #1F1F1F;
--background-05: #000000;
--background-dialogue: #262626;
--hover-list: #292929;
--hover-icon: #333333;
--hover-link: #81ADEF;
--press-list: #383838;
--press-icon: #262626;
--press-link: #286BCE;
--badge-brand: #0099FF;
--badge-red: #FF5967;
--badge-grey: #4D4D4D;
--audio-hangup: #FF3350;
--gray-black: #000;
--gray-20: #333333;
--gray-40: #666666;
--gray-60: #999999;
--gray-80: #cccccc;
--gray-90: #e5e5e5;
--gray-96: #f5f5f5;
--gray-white: #ffffff;
--blue-dark: #0057BD;
--blue-standard: #0066CC;
--blue-light: #0072E4;
--blue-superlight: #E6F5FF;
--green-dark: #12BC67;
--green-standard: #15D173;
--green-light: #5BDE9D;
--green-superlight: #E8FAF1;
--yellow-dark: #E5A000;
--yellow-standard: #FFB300;
--yellow-light: #FFC94C;
--yellow-superlight: #FFF7E5;
--orange-dark: #E57E39;
--orange-standard: #FF8D40;
--orange-light: #FFAE78;
--orange-superlight: #FFF3EB;
--red-dark: #E6505C;
--red-standard: #FF5967;
--red-light: #FF8B94;
--red-superlight: #FFEEEF;
--pink-dark: #E55BA0;
--pink-standard: #FF66B3;
--pink-light: #FF93C9;
--pink-superlight: #FFEFF7;
--indigo-dark: #775CE6;
--indigo-standard: #8566FF;
--indigo-light: #A994FF;
--indigo-superlight: #F3F0FF;
--list-hover: rgba(71, 71, 71);
--list-pressed: rgba(28, 28, 28);
--background_01: #ffffff;
--background_02: #292929;
--background_03: #1A1A1A;
--background_04: #212121;
--background_05: #212121;
--background_dialogue: #292929;
--sidebar_win: rgba(0,0,0,0.8);
--sidebar_mac: rgba(0,0,0,0.1);
color-scheme: dark;
}

7
static/assets/qrcode.min.js vendored Normal file

File diff suppressed because one or more lines are too long

409
static/assets/renderer.js Normal file
View File

@@ -0,0 +1,409 @@
const SettingList = (items, title, isCollapsible = false, direction = "column") => {
return `<setting-section ${title && !isCollapsible ? `data-title="${title}"` : ""}>
<setting-panel>
<setting-list ${direction ? `data-direction="${direction}"` : ""} ${isCollapsible ? "is-collapsible" : ""} ${title && isCollapsible ? `data-title="${title}"` : ""}>
${items.join("")}
</setting-list>
</setting-panel>
</setting-section>`;
};
const SettingItem = (title, subtitle, action, id, visible = true) => {
return `<setting-item ${id ? `id="${id}"` : ""} ${!visible ? "is-hidden" : ""}>
<div>
<setting-text>${title}</setting-text>
${subtitle ? `<setting-text data-type="secondary">${subtitle}</setting-text>` : ""}
</div>
${action ? `<div>${action}</div>` : ""}
</setting-item>`;
};
const SettingButton = (text, id, type = "secondary") => {
return `<setting-button ${type ? `data-type="${type}"` : ""} ${id ? `id="${id}"` : ""}>${text}</setting-button>`;
};
const SettingSwitch = (configKey, isActive = false, extraData) => {
return `<setting-switch
${configKey ? `data-config-key="${configKey}"` : ""}
${isActive ? "is-active" : ""}
${extraData ? Object.keys(extraData).map((key) => `data-${key}="${extraData[key]}"`) : ""}
>
</setting-switch>`;
};
const SettingOption = (text, value, isSelected = false) => {
return `<setting-option ${value ? `data-value="${value}"` : ""} ${isSelected ? "is-selected" : ""}>${text}</setting-option>`;
};
const SelectTemplate = document.createElement("template");
SelectTemplate.innerHTML = `<style>
.hidden { display: none !important; }
</style>
<div part="parent">
<div part="button">
<input type="text" placeholder="请选择" part="current-text" />
<svg viewBox="0 0 16 16" fill="none" xmlns="http://www.w3.org/2000/svg" part="button-arrow">
<path d="M12 6.0001L8.00004 10L4 6" stroke="currentColor" stroke-linejoin="round"></path>
</svg>
</div>
<ul class="hidden" part="option-list"><slot></slot></ul>
</div>`;
window.customElements.define(
"ob-setting-select",
class extends HTMLElement {
_button;
_text;
_context;
constructor() {
super();
this.attachShadow({ mode: "open" });
this.shadowRoot?.append(SelectTemplate.content.cloneNode(true));
this._button = this.shadowRoot.querySelector('div[part="button"]');
this._text = this.shadowRoot.querySelector('input[part="current-text"]');
this._context = this.shadowRoot.querySelector('ul[part="option-list"]');
const buttonClick = () => {
const isHidden = this._context.classList.toggle("hidden");
window[`${isHidden ? "remove" : "add"}EventListener`]("pointerdown", windowPointerDown);
};
const windowPointerDown = ({ target }) => {
if (!this.contains(target))
buttonClick();
};
this._button.addEventListener("click", buttonClick);
this._context.addEventListener("click", ({ target }) => {
if (target.tagName !== "SETTING-OPTION")
return;
buttonClick();
if (target.hasAttribute("is-selected"))
return;
this.querySelectorAll("setting-option[is-selected]").forEach((dom) => dom.toggleAttribute("is-selected"));
target.toggleAttribute("is-selected");
this._text.value = target.textContent;
this.dispatchEvent(
new CustomEvent("selected", {
bubbles: true,
composed: true,
detail: {
name: target.textContent,
value: target.dataset.value
}
})
);
});
this._text.value = this.querySelector("setting-option[is-selected]")?.textContent;
}
}
);
const SettingSelect = (items, configKey, configValue) => {
return `<ob-setting-select ${configKey ? `data-config-key="${configKey}"` : ""}>
${items.map((e, i) => {
return SettingOption(e.text, e.value, configKey && configValue ? configValue === e.value : i === 0);
}).join("")}
</ob-setting-select>`;
};
class WebUiApiOB11ConfigWrapper {
retCredential = "";
async Init(Credential) {
this.retCredential = Credential;
}
async GetOB11Config() {
let ConfigResponse = await fetch("/api/OB11Config/GetConfig", {
method: "POST",
headers: {
"Authorization": "Bearer " + this.retCredential,
"Content-Type": "application/json"
}
});
if (ConfigResponse.status == 200) {
let ConfigResponseJson = await ConfigResponse.json();
if (ConfigResponseJson.code == 0) {
return ConfigResponseJson?.data;
}
}
return {};
}
async SetOB11Config(config) {
let ConfigResponse = await fetch(
"/api/OB11Config/SetConfig",
{
method: "POST",
headers: {
"Authorization": "Bearer " + this.retCredential,
"Content-Type": "application/json"
},
body: JSON.stringify({ config: JSON.stringify(config) })
}
);
if (ConfigResponse.status == 200) {
let ConfigResponseJson = await ConfigResponse.json();
if (ConfigResponseJson.code == 0) {
return true;
}
}
return false;
}
}
const OB11ConfigWrapper = new WebUiApiOB11ConfigWrapper();
async function onSettingWindowCreated(view) {
const isEmpty = (value) => value === void 0 || value === void 0 || value === "";
await OB11ConfigWrapper.Init(localStorage.getItem("auth"));
let ob11Config = await OB11ConfigWrapper.GetOB11Config();
const setOB11Config = (key, value) => {
const configKey = key.split(".");
if (configKey.length === 2) {
ob11Config[configKey[1]] = value;
}
OB11ConfigWrapper.SetOB11Config(ob11Config);
};
const parser = new DOMParser();
const doc = parser.parseFromString(
[
"<div>",
`<setting-section id="napcat-error">
<setting-panel><pre><code></code></pre></setting-panel>
</setting-section>`,
SettingList([
SettingItem(
'<span id="napcat-update-title">Napcat</span>',
void 0,
SettingButton("V1.3.0", "napcat-update-button", "secondary")
)
]),
SettingList([
SettingItem(
"启用 HTTP 服务",
void 0,
SettingSwitch("ob11.enableHttp", ob11Config.enableHttp, { "control-display-id": "config-ob11-httpPort" })
),
SettingItem(
"HTTP 服务监听端口",
void 0,
`<div class="q-input"><input class="q-input__inner" data-config-key="ob11.httpPort" type="number" min="1" max="65534" value="${ob11Config.httpPort}" placeholder="${ob11Config.httpPort}" /></div>`,
"config-ob11-httpPort",
ob11Config.enableHttp
),
SettingItem(
"启用 HTTP 心跳",
void 0,
SettingSwitch("ob11.enableHttpHeart", ob11Config.enableHttpHeart, {
"control-display-id": "config-ob11-enableHttpHeart"
})
),
SettingItem(
"启用 HTTP 事件上报",
void 0,
SettingSwitch("ob11.enableHttpPost", ob11Config.enableHttpPost, {
"control-display-id": "config-ob11-httpPostUrls"
})
),
`<div class="config-host-list" id="config-ob11-httpPostUrls" ${ob11Config.enableHttpPost ? "" : "is-hidden"}>
<setting-item data-direction="row">
<div>
<setting-text>HTTP 事件上报密钥</setting-text>
</div>
<div class="q-input">
<input id="config-ob11-httpSecret" class="q-input__inner" data-config-key="ob11.httpSecret" type="text" value="${ob11Config.httpSecret}" placeholder="未设置" />
</div>
</setting-item>
<setting-item data-direction="row">
<div>
<setting-text>HTTP 事件上报地址</setting-text>
</div>
<setting-button id="config-ob11-httpPostUrls-add" data-type="primary">添加</setting-button>
</setting-item>
<div id="config-ob11-httpPostUrls-list"></div>
</div>`,
SettingItem(
"启用正向 WebSocket 服务",
void 0,
SettingSwitch("ob11.enableWs", ob11Config.enableWs, { "control-display-id": "config-ob11-wsPort" })
),
SettingItem(
"正向 WebSocket 服务监听端口",
void 0,
`<div class="q-input"><input class="q-input__inner" data-config-key="ob11.wsPort" type="number" min="1" max="65534" value="${ob11Config.wsPort}" placeholder="${ob11Config.wsPort}" /></div>`,
"config-ob11-wsPort",
ob11Config.enableWs
),
SettingItem(
"启用反向 WebSocket 服务",
void 0,
SettingSwitch("ob11.enableWsReverse", ob11Config.enableWsReverse, {
"control-display-id": "config-ob11-wsReverseUrls"
})
),
`<div class="config-host-list" id="config-ob11-wsReverseUrls" ${ob11Config.enableWsReverse ? "" : "is-hidden"}>
<setting-item data-direction="row">
<div>
<setting-text>反向 WebSocket 监听地址</setting-text>
</div>
<setting-button id="config-ob11-wsReverseUrls-add" data-type="primary">添加</setting-button>
</setting-item>
<div id="config-ob11-wsReverseUrls-list"></div>
</div>`,
SettingItem(
" WebSocket 服务心跳间隔",
"控制每隔多久发送一个心跳包,单位为毫秒",
`<div class="q-input"><input class="q-input__inner" data-config-key="ob11.heartInterval" type="number" min="1000" value="${ob11Config.heartInterval}" placeholder="${ob11Config.heartInterval}" /></div>`
),
SettingItem(
"Access token",
void 0,
`<div class="q-input" style="width:210px;"><input class="q-input__inner" data-config-key="ob11.token" type="text" value="${ob11Config.token}" placeholder="未设置" /></div>`
),
SettingItem(
"新消息上报格式",
`如客户端无特殊需求推荐保持默认设置,两者的详细差异可参考 <a href="javascript:LiteLoader.api.openExternal('https://github.com/botuniverse/onebot-11/tree/master/message#readme');">OneBot v11 文档</a>`,
SettingSelect(
[
{ text: "消息段", value: "array" },
{ text: "CQ码", value: "string" }
],
"ob11.messagePostFormat",
ob11Config.messagePostFormat
)
),
SettingItem(
"音乐卡片签名地址",
void 0,
`<div class="q-input" style="width:210px;"><input class="q-input__inner" data-config-key="ob11.musicSignUrl" type="text" value="${ob11Config.musicSignUrl}" placeholder="未设置" /></div>`,
"ob11.musicSignUrl"
),
SettingItem("", void 0, SettingButton("保存", "config-ob11-save", "primary"))
]),
SettingList([
SettingItem(
"上报 Bot 自身发送的消息",
"上报 event 为 message_sent",
SettingSwitch("ob11.reportSelfMessage", ob11Config.reportSelfMessage)
)
]),
SettingList([
SettingItem("GitHub 仓库", `https://github.com/NapNeko/NapCatQQ`, SettingButton("点个星星", "open-github")),
SettingItem("NapCat 文档", ``, SettingButton("看看文档", "open-docs")),
SettingItem("Telegram 群", `https://t.me/+nLZEnpne-pQ1OWFl`, SettingButton("进去逛逛", "open-telegram")),
SettingItem("QQ 群", `545402644`, SettingButton("我要进去", "open-qq-group"))
]),
"</div>"
].join(""),
"text/html"
);
doc.querySelector("#open-github")?.addEventListener("click", () => {
window.open("https://napneko.github.io/", "_blank");
});
doc.querySelector("#open-telegram")?.addEventListener("click", () => {
window.open("https://t.me/+nLZEnpne-pQ1OWFl");
});
doc.querySelector("#open-qq-group")?.addEventListener("click", () => {
window.open("https://qm.qq.com/q/bDnHRG38aI");
});
doc.querySelector("#open-docs")?.addEventListener("click", () => {
window.open("https://github.com/NapNeko/NapCatQQ");
});
const buildHostListItem = (type, host, index, inputAttrs = {}) => {
const dom = {
container: document.createElement("setting-item"),
input: document.createElement("input"),
inputContainer: document.createElement("div"),
deleteBtn: document.createElement("setting-button")
};
dom.container.classList.add("setting-host-list-item");
dom.container.dataset.direction = "row";
Object.assign(dom.input, inputAttrs);
dom.input.classList.add("q-input__inner");
dom.input.type = "url";
dom.input.value = host;
dom.input.addEventListener("input", () => {
ob11Config[type][index] = dom.input.value;
});
dom.inputContainer.classList.add("q-input");
dom.inputContainer.appendChild(dom.input);
dom.deleteBtn.innerHTML = "删除";
dom.deleteBtn.dataset.type = "secondary";
dom.deleteBtn.addEventListener("click", () => {
ob11Config[type].splice(index, 1);
initReverseHost(type);
});
dom.container.appendChild(dom.inputContainer);
dom.container.appendChild(dom.deleteBtn);
return dom.container;
};
const buildHostList = (hosts, type, inputAttr = {}) => {
const result = [];
hosts.forEach((host, index) => {
result.push(buildHostListItem(type, host, index, inputAttr));
});
return result;
};
const addReverseHost = (type, doc2 = document, inputAttr = {}) => {
const hostContainerDom = doc2.body.querySelector(`#config-ob11-${type}-list`);
hostContainerDom?.appendChild(buildHostListItem(type, "", ob11Config[type].length, inputAttr));
ob11Config[type].push("");
};
const initReverseHost = (type, doc2 = document) => {
const hostContainerDom = doc2.body?.querySelector(`#config-ob11-${type}-list`);
if (hostContainerDom) {
[...hostContainerDom.childNodes].forEach((dom) => dom.remove());
buildHostList(ob11Config[type], type).forEach((dom) => {
hostContainerDom?.appendChild(dom);
});
}
};
initReverseHost("httpPostUrls", doc);
initReverseHost("wsReverseUrls", doc);
doc.querySelector("#config-ob11-httpPostUrls-add")?.addEventListener(
"click",
() => addReverseHost("httpPostUrls", document, { placeholder: "如http://127.0.0.1:5140/onebot" })
);
doc.querySelector("#config-ob11-wsReverseUrls-add")?.addEventListener(
"click",
() => addReverseHost("wsReverseUrls", document, { placeholder: "如ws://127.0.0.1:5140/onebot" })
);
doc.querySelector("#config-ffmpeg-select")?.addEventListener("click", () => {
});
doc.querySelector("#config-open-log-path")?.addEventListener("click", () => {
});
doc.querySelectorAll("setting-switch[data-config-key]").forEach((dom) => {
dom.addEventListener("click", () => {
const active = dom.getAttribute("is-active") == void 0;
setOB11Config(dom.dataset.configKey, active);
if (active)
dom.setAttribute("is-active", "");
else
dom.removeAttribute("is-active");
if (!isEmpty(dom.dataset.controlDisplayId)) {
const displayDom = document.querySelector(`#${dom.dataset.controlDisplayId}`);
if (active)
displayDom?.removeAttribute("is-hidden");
else
displayDom?.setAttribute("is-hidden", "");
}
});
});
doc.querySelectorAll("setting-item .q-input input.q-input__inner[data-config-key]").forEach((dom) => {
dom.addEventListener("input", () => {
const Type = dom.getAttribute("type");
const configKey = dom.dataset.configKey;
const configValue = Type === "number" ? parseInt(dom.value) >= 1 ? parseInt(dom.value) : 1 : dom.value;
setOB11Config(configKey, configValue);
});
});
doc.querySelectorAll("ob-setting-select[data-config-key]").forEach((dom) => {
dom?.addEventListener("selected", (e) => {
const configKey = dom.dataset.configKey;
const configValue = e.detail.value;
setOB11Config(configKey, configValue);
});
});
doc.querySelector("#config-ob11-save")?.addEventListener("click", () => {
OB11ConfigWrapper.SetOB11Config(ob11Config);
alert("保存成功");
});
doc.body.childNodes.forEach((node) => {
view.appendChild(node);
});
}
export { onSettingWindowCreated };

201
static/assets/style.css Normal file
View File

@@ -0,0 +1,201 @@
body, html {
background: var(--bg_bottom_standard);
color: var(--text_primary);
font-family: "Color Emoji", system-ui, "PingFang SC", PingFangSC-Regular, "Microsoft YaHei", "Hiragino Sans GB", "Heiti SC", "WenQuanYi Micro Hei", Arial, Helvetica, sans-serif, "Apple Braille", "Color Emoji Fix";
min-height: 100vh;
scroll-behavior: smooth;
width: 100%;
-webkit-user-select: none;
-moz-user-select: none;
-ms-user-select: none;
-o-user-select: none;
user-select: none;
--z_index_popover: 999;
--nt_mix_tokens: nt_brand_standard_2_overlay_hover_brand_2_mix,nt_brand_standard_2_overlay_pressed_brand_2_mix,nt_feedback_error_2_overlay_hover_brand_2_mix,nt_feedback_error_2_overlay_pressed_brand_2_mix,nt_icon_white_2_overlay_hover_2_mix,nt_icon_white_2_overlay_pressed_2_mix,nt_bubble_host_2_overlay_pressed_brand_2_mix,nt_bg_white_2_overlay_pressed_brand_2_mix,nt_bg_white_2_overlay_hover_2_mix,nt_bg_white_2_overlay_pressed_2_mix,nt_fg_white_2_overlay_hover_2_mix,nt_fg_white_2_overlay_pressed_2_mix,nt_icon_red_2_overlay_hover_2_mix,nt_icon_red_2_overlay_pressed_2_mix,nt_fg_grey_standard_2_overlay_hover_2_mix,nt_fg_grey_standard_2_overlay_pressed_2_mix,nt_bubble_guest_2_overlay_pressed_2_mix,nt_icon_primary_2_20_2_alpha,nt_bg_grey_standard_2_95_2_alpha,nt_tag_red_2_20_2_alpha,nt_tag_red_2_25_2_alpha,nt_tag_blue_2_20_2_alpha,nt_tag_blue_2_25_2_alpha,nt_tag_blue_2_10_2_alpha,nt_tag_purple_2_20_2_alpha,nt_brand_standard_2_20_2_alpha,nt_tag_sage_green_2_20_2_alpha,nt_feedback_error_2_20_2_alpha,nt_text_white_2_60_2_alpha,nt_bg_white_2_70_2_alpha,nt_bg_white_2_90_2_alpha,nt_bg_white_2_97_2_alpha,nt_bg_white_2_40_2_alpha,nt_bg_white_2_30_2_alpha,nt_text_white_2_80_2_alpha,nt_brand_standard_2_50_2_alpha,nt_bg_nav_secondary_2_60_2_alpha,nt_bg_nav_2_60_2_alpha,nt_feedback_error_2_10_2_alpha,nt_brand_standard_2_10_2_alpha,nt_on_brand_primary_2_40_2_alpha,nt_text_primary_2_72_2_alpha,nt_text_white_2_72_2_alpha;
}
a, address, article, aside, b, blockquote, body, div, em, fieldset, footer, form, h1, h2, h3, h4, h5, h6, header, html, i, iframe, img, label, legend, li, main, nav, ol, p, s, section, span, table, tbody, td, tfoot, th, thead, tr, ul {
box-sizing: border-box;
font-size: 100%;
font-style: inherit;
font-weight: inherit;
border: 0px;
margin: 0px;
padding: 0px;
}
#app {
position: relative;
display: block;
padding: 20px;
min-height: 100vh;
background: transparent;
}
.fake-bar {
position: fixed;
display: none;
top: 0;
left: 0;
}
/* ======== Input ======== */
.q-input {
align-items: center;
border-radius: 4px;
box-sizing: border-box;
color: var(--text_secondary);
display: inline-flex;
position: relative;
width: 100%;
border: 1px solid transparent;
}
.q-input input, .q-input textarea {
appearance: none;
background-color: transparent;
box-sizing: border-box;
color: var(--text_primary);
flex-grow: 1;
flex-shrink: 1;
flex-basis: 0%;
font-size: 14px;
height: fit-content;
outline-color: initial;
outline-style: none;
outline-width: initial;
resize: none;
width: 100%;
border: none;
}
/* ======== Switch ======== */
.q-switch {
background-color: var(--fill_standard_primary);
border-radius: 14px;
box-sizing: border-box;
display: inline-flex;
position: relative;
transition-behavior: normal;
transition-duration: 0.2s;
transition-timing-function: cubic-bezier(0.38, 0, 0.24, 1);
transition-delay: 0s;
transition-property: all;
width: 28px;
padding: 3px;
}
.q-switch__handle {
border-radius: 5px;
box-shadow: rgba(0, 0, 0, 0.09) 0px 2px 4px;
box-sizing: border-box;
display: inline-block;
height: 10px;
position: relative;
transition-behavior: normal;
transition-duration: 0.2s;
transition-timing-function: cubic-bezier(0.38, 0, 0.24, 1);
transition-delay: 0s;
transition-property: all;
width: 10px;
z-index: 2;
background: var(--icon_white);
}
.q-switch:not(.is-disabled):hover {
background: var(--fill_standard_secondary);
}
.q-switch:not(.is-disabled):active {
background: var(--nt_bg_white_2_overlay_pressed_brand_2_mix);
}
.q-switch:not(.is-disabled):active .q-switch__handle {
width: 12px;
}
.q-switch.is-active {
background-color: var(--brand_standard);
}
.q-switch.is-active .q-switch__handle {
transform: translateX(12px);
}
.q-switch.is-active:not(.is-disabled):hover {
background: var(--nt_brand_standard_2_overlay_hover_brand_2_mix);
}
.q-switch.is-active:not(.is-disabled):active {
background: var(--nt_brand_standard_2_overlay_pressed_brand_2_mix);
}
.q-switch.is-active:not(.is-disabled):active .q-switch__handle {
transform: translateX(10px);
}
/* ======== Button ======== */
.q-button {
align-items: center;
background-color: var(--brand_standard);
border-top-left-radius: 4px;
border-top-right-radius: 4px;
border-bottom-right-radius: 4px;
border-bottom-left-radius: 4px;
display: inline-flex;
font-size: 14px;
justify-content: center;
line-height: 18px;
outline-color: initial;
outline-style: none;
outline-width: initial;
position: relative;
vertical-align: text-bottom;
border: 1px solid var(--fg_grey_standard);
padding: 5px 11px;
}
.q-button--small {
font-size: 12px;
line-height: 14px;
min-width: 62px;
padding: 4px 7px;
}
.q-button--primary {
background-color: var(--brand_standard);
border-color: var(--brand_standard);
color: var(--on_brand_primary);
}
.q-button--secondary {
background-color: transparent;
border-color: var(--fg_grey_standard);
color: var(--text_primary);
}
.q-button:not([disabled]):hover {
background-color: var(--overlay_hover);
}
.q-button:not([disabled]):active {
background-color: var(--overlay_pressed);
}
.q-button--primary:hover {
background-color: var(--nt_brand_standard_2_overlay_hover_brand_2_mix);
border-color: var(--nt_brand_standard_2_overlay_hover_brand_2_mix);
}
.q-button--primary:active {
background-color: var(--nt_brand_standard_2_overlay_pressed_brand_2_mix);
border-color: var(--nt_brand_standard_2_overlay_pressed_brand_2_mix);
}
.q-button[disabled] {
opacity: 0.3;
cursor: not-allowed;
}
.q-button--secondary[disabled] {
background-color: transparent;
}

View File

@@ -0,0 +1,350 @@
*[is-disabled] {
opacity: 0.3;
-webkit-pointer-events: none;
-moz-pointer-events: none;
-ms-pointer-events: none;
-o-pointer-events: none;
pointer-events: none;
cursor: not-allowed;
}
setting-section::before {
content: attr(data-title);
display: block;
margin: 0px 0px 8px 16px;
color: var(--text_primary);
font-weight: var(--font-bold);
font-size: min(var(--font_size_3), 18px);
line-height: min(var(--line_height_3), 24px);
}
setting-panel {
display: block;
margin-bottom: 20px;
}
setting-section:last-child setting-panel {
margin-bottom: 0;
}
setting-list,
setting-list[data-direction="column"] {
display: flex;
background-color: var(--fill_light_primary);
border-radius: 8px;
flex-direction: column;
align-items: stretch;
justify-content: space-between;
}
setting-list[data-direction="row"] {
padding: 16px 0;
flex-direction: row;
justify-content: space-around;
}
setting-list[data-direction="row"],
setting-list[data-direction="row"] * {
text-align: center;
}
setting-item {
display: flex;
padding: 12px 16px;
background-color: var(--fill_light_primary);
font-size: min(var(--font_size_3),18px);
line-height: min(var(--line_height_3),24px);
border-radius: 8px;
align-items: center;
justify-content: space-between;
}
setting-item > *:first-child {
display: flex;
flex-direction: column;
align-items: flex-start;
justify-content: flex-start;
flex-wrap: nowrap;
}
setting-list[data-direction="row"] setting-item {
padding: 0;
margin: 0 10px;
flex: 1;
}
setting-list[data-direction="row"] setting-item > *:first-child {
align-items: center;
flex: 1;
}
setting-list[data-direction="row"] setting-item > *:first-child > * {
flex: 1;
}
setting-list setting-divider,
setting-list[data-direction="column"] setting-divider {
display: block;
position: relative;
width: unset;
height: 1px;
margin: 0 16px;
background-color: var(--border_standard);
}
setting-list[data-direction="row"] setting-divider {
width: 1px;
height: unset;
margin: 0;
}
setting-text[data-type="secondary"] {
margin-top: 4px;
color: var(--text_secondary);
font-size: min(var(--font_size_2),16px);
line-height: min(var(--line_height_2),22px);
}
setting-switch {
--transition-timing: cubic-bezier(0.38, 0, 0.24, 1);
display: block;
position: relative;
width: 28px;
height: 16px;
background: var(--fill_standard_primary);
border-radius: 14px;
transition: background var(--transition-timing) .2s;
}
setting-switch::after {
content: '';
display: block;
position: absolute;
top: 0px;
left: 0px;
margin: 3px;
width: 10px;
height: 10px;
background: var(--icon_white);
box-shadow: rgba(0, 0, 0, 0.09) 0px 2px 4px;
border-radius: 5px;
transition: width var(--transition-timing) .2s,
left var(--transition-timing) .2s;
}
setting-switch[is-active] {
background: var(--brand_standard);
}
setting-switch[is-active]::after {
left: calc(100% - 16px);
}
setting-switch:hover {
background: var(--fill_standard_secondary);
}
setting-switch[is-active]:hover {
background: var(--nt_brand_standard_2_overlay_hover_brand_2_mix);
}
setting-switch:active {
background: var(--nt_bg_white_2_overlay_pressed_brand_2_mix);
}
setting-switch[is-active]:active {
background: var(--nt_brand_standard_2_overlay_pressed_brand_2_mix);
}
setting-switch:active::after {
width: 12px;
}
setting-switch[is-active]:active::after {
left: calc(100% - 18px);
}
setting-button,
setting-button[data-type="secondary"] {
position: relative;
display: inline-flex;
padding: 5px 11px;
min-width: 62px;
background-color: transparent;
color: var(--text_primary);
border-radius: 4px;
font-size: 12px;
line-height: 12px;
justify-content: center;
outline-color: initial;
outline-style: none;
outline-width: initial;
vertical-align: text-bottom;
border: 1px solid var(--fg_grey_standard);
align-items: center;
box-sizing: border-box;
}
setting-button[data-type="primary"] {
background-color: var(--brand_standard);
color: var(--on_brand_primary);
border-color: var(--brand_standard);
}
setting-button:hover,
setting-button[data-type="secondary"]:hover {
background-color: var(--overlay_hover);
}
setting-button:active,
setting-button[data-type="secondary"]:active {
background-color: var(--overlay_pressed);
}
setting-button[data-type="primary"]:hover {
background-color: var(--nt_brand_standard_2_overlay_hover_brand_2_mix);
border-color: var(--nt_brand_standard_2_overlay_hover_brand_2_mix);
}
setting-button[data-type="primary"]:active {
background-color: var(--nt_brand_standard_2_overlay_pressed_brand_2_mix);
border-color: var(--nt_brand_standard_2_overlay_pressed_brand_2_mix);
}
setting-select,
setting-select::part(parent),
setting-select::part(button) {
display: block;
position: relative;
height: 24px;
font-size: 12px;
line-height: 24px;
box-sizing: border-box;
}
setting-select::part(button) {
display: flex;
padding: 0px 8px;
background-color: transparent;
border-radius: 4px;
border: 1px solid var(--border_dark);
z-index: 5;
cursor: default;
align-items: center;
flex-direction: row;
flex-wrap: nowrap;
}
setting-select::part(current-text) {
display: block;
margin-right: 8px;
padding: 0px;
background: none;
background-color: transparent;
font-size: 12px;
color: var(--text_primary);
text-overflow: ellipsis;
border-radius: 0px;
border: none;
outline: none;
overflow: hidden;
appearance: none;
box-sizing: border-box;
cursor: default;
flex: 1;
-webkit-user-select: none;
-moz-user-select: none;
-ms-user-select: none;
-o-user-select: none;
user-select: none;
-webkit-pointer-events: none;
-moz-pointer-events: none;
-ms-pointer-events: none;
-o-pointer-events: none;
pointer-events: none;
}
setting-select::part(button-arrow) {
position: relative;
display: block;
width: 16px;
height: 16px;
color: var(--icon_primary);
}
setting-select::part(option-list) {
display: flex;
position: absolute;
top: 100%;
padding: 4px;
margin: 5px 0px;
width: 100%;
max-height: var(--q-contextmenu-max-height);
background-color: var(--blur_middle_standard);
background-clip: padding-box;
backdrop-filter: blur(8px);
font-size: 12px;
box-shadow: var(--shadow_bg_middle_secondary);
border: 1px solid var(--border_secondary);
border-radius: 4px;
box-sizing: border-box;
app-region: no-drag;
overflow-x: hidden;
overflow-y: auto;
list-style: none;
z-index: 999;
flex-direction: column;
align-items: stretch;
flex-wrap: nowrap;
justify-content: flex-start;
gap: 4px;
}
setting-option,
setting-option::part(parent) {
display: block;
position: relative;
box-sizing: border-box;
}
setting-option::part(parent) {
display: flex;
padding: 0px 8px;
color: var(--text_primary);
font-size: 12px;
line-height: 24px;
border-radius: 4px;
flex-direction: row;
align-items: center;
flex-wrap: nowrap;
justify-content: flex-start;
}
setting-option:hover::part(parent) {
background-color: var(--overlay_hover);
}
setting-option:active::part(parent) {
background-color: var(--overlay_pressed);
}
setting-option[is-selected]::part(parent) {
background-color: var(--overlay_active);
}
setting-option::part(text) {
margin-right: 8px;
overflow: hidden;
text-wrap: nowrap;
text-overflow: ellipsis;
flex: 1;
}
setting-option::part(check-icon) {
display: none;
position: relative;
right: -4px;
width: 1em;
height: 1em;
color: var(--icon_primary);
flex-shrink: 0;
}
setting-option[is-selected]::part(check-icon) {
display: block;
}

34
static/config.html Normal file
View File

@@ -0,0 +1,34 @@
<!DOCTYPE html>
<html>
<head>
<meta charset="UTF-8">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<!-- 源样式 -->
<link rel="stylesheet" href="./assets/NapCat.css" />
<!-- 修补样式 -->
<link rel="stylesheet" href="./assets/webcomponents.css" />
<link rel="stylesheet" href="./assets/style.css" />
<link rel="stylesheet" href="./assets/color.css" />
<!-- 脚手架 -->
<!-- 渲染脚本 -->
<script>
async function InitWebUi() {
const { onSettingWindowCreated } = await import("./assets/renderer.js");
onSettingWindowCreated(document.querySelector("body"));
}
InitWebUi();
</script>
<title>NapCat-WebUi</title>
</head>
<body>
<script>
if (window.matchMedia('(prefers-color-scheme: dark)').matches) {
document.body.classList.add('q-theme-tokens-dark');
}
</script>
</body>
</html>

67
static/index.html Normal file
View File

@@ -0,0 +1,67 @@
<!DOCTYPE html>
<html>
<head>
<meta charset="UTF-8">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<title>WebUi - Index</title>
</head>
<body>
<script>
async function CheckQQLoginStatus(retCredential) {
let QQLoginResponse = await fetch('/api/QQLogin/CheckLoginStatus', {
method: 'POST',
headers: {
'Authorization': "Bearer " + retCredential,
'Content-Type': 'application/json'
}
});
if (QQLoginResponse.status == 200) {
let QQLoginResponseJson = await QQLoginResponse.json();
if (QQLoginResponseJson.code == 0) {
if (QQLoginResponseJson.data.isLogin) {
return true;
} else {
return false;
}
}
}
return false;
}
async function CheckWebUiLogined(retCredential) {
let LoginResponse = await fetch('/api/auth/check', {
method: 'POST',
headers: {
'Authorization': "Bearer " + retCredential,
'Content-Type': 'application/json'
}
});
if (LoginResponse.status == 200) {
let LoginResponseJson = await LoginResponse.json();
if (LoginResponseJson.code == 0) {
return true;
}
}
return false;
}
async function InitPage() {
let authData = localStorage.getItem('auth');
let isLogined = await CheckWebUiLogined(authData);
if (authData && isLogined) {
let isQQLoined = await CheckQQLoginStatus(authData);
if (!isQQLoined) {
window.location.href = './QQLogin.html';
return;
}
window.location.href = './config.html';
return;
}
window.location.href = './login.html';
return;
}
InitPage();
</script>
</body>
</html>

136
static/login.html Normal file
View File

@@ -0,0 +1,136 @@
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<title>WebUi - Login</title>
<style>
body {
font-family: Arial, sans-serif;
display: flex;
justify-content: center;
align-items: center;
height: 100vh;
background-color: #f0f2f5;
}
.login-container {
padding: 20px;
border-radius: 5px;
box-shadow: 0 0 10px rgba(0, 0, 0, 0.1);
background-color: white;
max-width: 400px;
min-width: 300px;
position: relative;
}
.input-group {
margin-bottom: 20px;
}
input[type="text"] {
width: 90%;
padding: 10px;
font-size: 16px;
border: 1px solid #ccc;
border-radius: 5px;
}
button {
width: 100%;
padding: 10px;
background-color: #007BFF;
color: white;
border: none;
cursor: pointer;
transition: all 0.3s;
}
button:hover {
background-color: #0056b3;
}
.error-message {
color: red;
margin-top: 5px;
}
</style>
</head>
<body>
<div class="login-container">
<h2>WebUi Login</h2>
<form id="token-form" onsubmit="event.preventDefault(); submitToken();">
<div class="input-group">
<label for="token-input">Enter Token:</label>
<input type="text" id="token-input" required>
</div>
<p class="error-message hidden" id="error-message"></p>
<button type="submit">Login</button>
</form>
</div>
<script>
//待封装整理
async function submitToken() {
const tokenInput = document.getElementById('token-input');
const errorMessage = document.getElementById('error-message');
if (tokenInput.value.trim() === '') {
errorMessage.textContent = 'Please enter a token.';
errorMessage.classList.remove('hidden');
} else {
errorMessage.textContent = '';
errorMessage.classList.add('hidden');
//请求 /api/login post token
let data = "";
try {
let loginResponse = await fetch('/api/auth/login', {
method: 'POST',
headers: {
'Content-Type': 'application/json'
},
body: JSON.stringify({ token: tokenInput.value })
});
const loginResponseJson = await loginResponse.json();
let retCode = loginResponseJson.code;
if (retCode === 0) {
//登录成功
let retCredential = loginResponseJson.data.Credential;
localStorage.setItem('auth', retCredential);
let QQLoginResponse = await fetch('/api/QQLogin/CheckLoginStatus', {
method: 'POST',
headers: {
'Authorization': "Bearer " + retCredential,
'Content-Type': 'application/json'
}
});
if (QQLoginResponse.status == 200) {
let QQLoginResponseJson = await QQLoginResponse.json();
if (QQLoginResponseJson.code == 0) {
//alert(QQLoginResponseJson.data.isLogin.toString());
if (QQLoginResponseJson.data.isLogin) {
window.location.href = './config.html';
} else {
window.location.href = './QQLogin.html';
}
}
}
alert("登录成功即将跳转");
} else {
console.log(loginResponseJson.message);
alert(loginResponseJson.message);
}
} catch (e) {
alert("登录失败");
console.log("请求异常", e);
}
}
}
</script>
</body>
</html>

View File

@@ -22,13 +22,13 @@ function genCpModule(module: string) {
}
let startScripts: string[] | undefined = undefined;
let MoeHooModule: any = [];
if (process.env.NAPCAT_BUILDSYS == "linux") {
if (process.env.NAPCAT_BUILDARCH == "x64") {
if (process.env.NAPCAT_BUILDSYS == 'linux') {
if (process.env.NAPCAT_BUILDARCH == 'x64') {
MoeHooModule = [{ src: './src/core.lib/MoeHoo-linux-x64.node', dest: 'dist' }];
}
startScripts = ['./script/napcat.sh'];
} else if (process.env.NAPCAT_BUILDSYS == "win32") {
if (process.env.NAPCAT_BUILDARCH == "x64") {
} else if (process.env.NAPCAT_BUILDSYS == 'win32') {
if (process.env.NAPCAT_BUILDARCH == 'x64') {
MoeHooModule = [{ src: './src/core.lib/MoeHoo-win32-x64.node', dest: 'dist' }];
}
startScripts = ['./script/napcat.ps1', './script/napcat.bat', './script/napcat-utf8.bat', './script/napcat-utf8.ps1', './script/napcat-log.ps1'];
@@ -37,12 +37,13 @@ if (process.env.NAPCAT_BUILDSYS == "linux") {
startScripts = ['./script/napcat.sh', './script/napcat.ps1', './script/napcat.bat', './script/napcat-utf8.bat', './script/napcat-utf8.ps1', './script/napcat-log.ps1'];
}
let baseConfigPlugin: PluginOption[] = [
const baseConfigPlugin: PluginOption[] = [
// PreprocessorDirectives(),
cp({
targets: [
// ...external.map(genCpModule),
{ src: './src/napcat.json', dest: 'dist/config/' },
{ src: './static/', dest: 'dist/static/', flatten: false },
{ src: './src/onebot11/onebot11.json', dest: 'dist/config/' },
{ src: './package.json', dest: 'dist' },
{ src: './README.md', dest: 'dist' },