Merge branch 'main' into laana

This commit is contained in:
Wesley F. Young 2024-09-06 23:13:05 +08:00
commit dfb88d8a1f
8 changed files with 10 additions and 21 deletions

View File

@ -44,12 +44,4 @@ NapCatQQ (aka 猫猫框架) 是现代化的基于 NTQQ 的 Bot 协议端实现
> [!CAUTION]\
> **请不要在 QQ 官方群聊和任何影响力较大的简中互联网平台(包括但不限于: 哔哩哔哩,微博,知乎,抖音等)发布和讨论*任何*与本项目存在相关性的信息**
任何使用本仓库代码的地方,都应当严格遵守[本仓库开源许可](./LICENSE)。**此外,禁止任何项目未经授权二次分发或基于 NapCat 代码开发。**
## 挥别昨日
下列特性因过于陈旧或不再适用于现代化的 QQNT 特性,已经停止维护。已有的代码将会保留,但不会对新的 QQNT 特性进行适配,也不再接受新的 PR 或 Issue。
### CQCode
[CQCode](https://github.com/botuniverse/onebot-11/blob/master/message/string.md) 原本是作为 CoolQ 的消息格式而设计的,它不支持嵌套消息,并且在解析上的实现没有统一标准。随着 QQNT 的发展CQCode 已经逐渐被 array 消息格式所取代。因此,我们建议您尽快迁移至新的消息格式 array以便更好地适配新的 QQNT 特性。
任何使用本仓库代码的地方,都应当严格遵守[本仓库开源许可](./LICENSE)。**此外,禁止任何项目未经授权二次分发或基于 NapCat 代码开发。**

View File

@ -4,7 +4,7 @@
"name": "NapCatQQ",
"slug": "NapCat.Framework",
"description": "高性能的 OneBot 11 协议实现",
"version": "2.3.4",
"version": "2.3.5",
"icon": "./logo.png",
"authors": [
{

View File

@ -2,7 +2,7 @@
"name": "napcat",
"private": true,
"type": "module",
"version": "2.3.4",
"version": "2.3.5",
"scripts": {
"build:framework": "vite build --mode framework",
"build:shell": "vite build --mode shell",

View File

@ -1 +1 @@
export const napCatVersion = '2.3.4';
export const napCatVersion = '2.3.5';

View File

@ -66,10 +66,7 @@ export function encodeCQCode(data: OB11MessageData) {
let result = '[CQ:' + data.type;
for (const name in data.data) {
const value =
// eslint-disable-next-line
// @ts-ignore
data.data[name];
const value = (data.data as any)[name];
if (value === undefined) {
continue;
}

View File

@ -98,7 +98,7 @@ export class NapCatOneBot11Adapter {
if (ob11Config.http.enablePost) {
ob11Config.http.postUrls.forEach(url => {
this.networkManager.registerAdapter(new OB11ActiveHttpAdapter(
url, ob11Config.token, this.core, this,
url, ob11Config.http.secret, this.core, this,
));
});
}
@ -168,7 +168,7 @@ export class NapCatOneBot11Adapter {
if (now.http.enablePost) {
now.http.postUrls.forEach(url => {
this.networkManager.registerAdapterAndOpen(new OB11ActiveHttpAdapter(
url, now.token, this.core, this,
url, now.http.secret, this.core, this,
));
});
} else {
@ -182,7 +182,7 @@ export class NapCatOneBot11Adapter {
);
for (const url of added) {
await this.networkManager.registerAdapterAndOpen(new OB11ActiveHttpAdapter(
url, now.token, this.core, this,
url, now.http.secret, this.core, this,
));
}
}

View File

@ -30,7 +30,7 @@ async function onSettingWindowCreated(view: Element) {
SettingItem(
'<span id="napcat-update-title">Napcat</span>',
undefined,
SettingButton('V2.3.4', 'napcat-update-button', 'secondary'),
SettingButton('V2.3.5', 'napcat-update-button', 'secondary'),
),
]),
SettingList([

View File

@ -164,7 +164,7 @@ async function onSettingWindowCreated(view) {
SettingItem(
'<span id="napcat-update-title">Napcat</span>',
void 0,
SettingButton("V2.3.4", "napcat-update-button", "secondary")
SettingButton("V2.3.5", "napcat-update-button", "secondary")
)
]),
SettingList([