mirror of
https://github.com/NapNeko/NapCatQQ.git
synced 2024-11-21 09:36:35 +00:00
Merge branch 'main' into laana
This commit is contained in:
commit
dfb88d8a1f
10
README.md
10
README.md
@ -44,12 +44,4 @@ NapCatQQ (aka 猫猫框架) 是现代化的基于 NTQQ 的 Bot 协议端实现
|
|||||||
> [!CAUTION]\
|
> [!CAUTION]\
|
||||||
> **请不要在 QQ 官方群聊和任何影响力较大的简中互联网平台(包括但不限于: 哔哩哔哩,微博,知乎,抖音等)发布和讨论*任何*与本项目存在相关性的信息**
|
> **请不要在 QQ 官方群聊和任何影响力较大的简中互联网平台(包括但不限于: 哔哩哔哩,微博,知乎,抖音等)发布和讨论*任何*与本项目存在相关性的信息**
|
||||||
|
|
||||||
任何使用本仓库代码的地方,都应当严格遵守[本仓库开源许可](./LICENSE)。**此外,禁止任何项目未经授权二次分发或基于 NapCat 代码开发。**
|
任何使用本仓库代码的地方,都应当严格遵守[本仓库开源许可](./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 特性。
|
|
@ -4,7 +4,7 @@
|
|||||||
"name": "NapCatQQ",
|
"name": "NapCatQQ",
|
||||||
"slug": "NapCat.Framework",
|
"slug": "NapCat.Framework",
|
||||||
"description": "高性能的 OneBot 11 协议实现",
|
"description": "高性能的 OneBot 11 协议实现",
|
||||||
"version": "2.3.4",
|
"version": "2.3.5",
|
||||||
"icon": "./logo.png",
|
"icon": "./logo.png",
|
||||||
"authors": [
|
"authors": [
|
||||||
{
|
{
|
||||||
|
@ -2,7 +2,7 @@
|
|||||||
"name": "napcat",
|
"name": "napcat",
|
||||||
"private": true,
|
"private": true,
|
||||||
"type": "module",
|
"type": "module",
|
||||||
"version": "2.3.4",
|
"version": "2.3.5",
|
||||||
"scripts": {
|
"scripts": {
|
||||||
"build:framework": "vite build --mode framework",
|
"build:framework": "vite build --mode framework",
|
||||||
"build:shell": "vite build --mode shell",
|
"build:shell": "vite build --mode shell",
|
||||||
|
@ -1 +1 @@
|
|||||||
export const napCatVersion = '2.3.4';
|
export const napCatVersion = '2.3.5';
|
||||||
|
@ -66,10 +66,7 @@ export function encodeCQCode(data: OB11MessageData) {
|
|||||||
|
|
||||||
let result = '[CQ:' + data.type;
|
let result = '[CQ:' + data.type;
|
||||||
for (const name in data.data) {
|
for (const name in data.data) {
|
||||||
const value =
|
const value = (data.data as any)[name];
|
||||||
// eslint-disable-next-line
|
|
||||||
// @ts-ignore
|
|
||||||
data.data[name];
|
|
||||||
if (value === undefined) {
|
if (value === undefined) {
|
||||||
continue;
|
continue;
|
||||||
}
|
}
|
||||||
|
@ -98,7 +98,7 @@ export class NapCatOneBot11Adapter {
|
|||||||
if (ob11Config.http.enablePost) {
|
if (ob11Config.http.enablePost) {
|
||||||
ob11Config.http.postUrls.forEach(url => {
|
ob11Config.http.postUrls.forEach(url => {
|
||||||
this.networkManager.registerAdapter(new OB11ActiveHttpAdapter(
|
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) {
|
if (now.http.enablePost) {
|
||||||
now.http.postUrls.forEach(url => {
|
now.http.postUrls.forEach(url => {
|
||||||
this.networkManager.registerAdapterAndOpen(new OB11ActiveHttpAdapter(
|
this.networkManager.registerAdapterAndOpen(new OB11ActiveHttpAdapter(
|
||||||
url, now.token, this.core, this,
|
url, now.http.secret, this.core, this,
|
||||||
));
|
));
|
||||||
});
|
});
|
||||||
} else {
|
} else {
|
||||||
@ -182,7 +182,7 @@ export class NapCatOneBot11Adapter {
|
|||||||
);
|
);
|
||||||
for (const url of added) {
|
for (const url of added) {
|
||||||
await this.networkManager.registerAdapterAndOpen(new OB11ActiveHttpAdapter(
|
await this.networkManager.registerAdapterAndOpen(new OB11ActiveHttpAdapter(
|
||||||
url, now.token, this.core, this,
|
url, now.http.secret, this.core, this,
|
||||||
));
|
));
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -30,7 +30,7 @@ async function onSettingWindowCreated(view: Element) {
|
|||||||
SettingItem(
|
SettingItem(
|
||||||
'<span id="napcat-update-title">Napcat</span>',
|
'<span id="napcat-update-title">Napcat</span>',
|
||||||
undefined,
|
undefined,
|
||||||
SettingButton('V2.3.4', 'napcat-update-button', 'secondary'),
|
SettingButton('V2.3.5', 'napcat-update-button', 'secondary'),
|
||||||
),
|
),
|
||||||
]),
|
]),
|
||||||
SettingList([
|
SettingList([
|
||||||
|
@ -164,7 +164,7 @@ async function onSettingWindowCreated(view) {
|
|||||||
SettingItem(
|
SettingItem(
|
||||||
'<span id="napcat-update-title">Napcat</span>',
|
'<span id="napcat-update-title">Napcat</span>',
|
||||||
void 0,
|
void 0,
|
||||||
SettingButton("V2.3.4", "napcat-update-button", "secondary")
|
SettingButton("V2.3.5", "napcat-update-button", "secondary")
|
||||||
)
|
)
|
||||||
]),
|
]),
|
||||||
SettingList([
|
SettingList([
|
||||||
|
Loading…
x
Reference in New Issue
Block a user