Skip to content

Commit

Permalink
release: new group
Browse files Browse the repository at this point in the history
  • Loading branch information
MliKiowa committed Aug 12, 2024
1 parent 5f536fd commit cf3f488
Show file tree
Hide file tree
Showing 2 changed files with 17 additions and 0 deletions.
1 change: 1 addition & 0 deletions src/onebot/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -481,6 +481,7 @@ export class NapCatOneBot11Adapter {
let operatorId = message.senderUin;
for (const element of message.elements) {
const operatorUid = element.grayTipElement?.revokeElement.operatorUid;
if(!operatorUid) return;
const operator = await this.core.apis.GroupApi.getGroupMember(message.peerUin, operatorUid);
operatorId = operator?.uin || message.senderUin;
}
Expand Down
16 changes: 16 additions & 0 deletions src/webui/ui/NapCat.ts
Original file line number Diff line number Diff line change
Expand Up @@ -176,6 +176,16 @@ async function onSettingWindowCreated(view: Element) {
),
SettingItem('NapCat 文档', '', SettingButton('看看文档', 'open-docs'))
]),
SettingItem(
'Telegram 群',
'https://t.me/+nLZEnpne-pQ1OWFl',
SettingButton('进去逛逛', 'open-telegram')
),
SettingItem(
'QQ 群',
'518662028',
SettingButton('我要进去', 'open-qq-group')
),
'</div>',
].join(''),
'text/html',
Expand All @@ -188,6 +198,12 @@ async function onSettingWindowCreated(view: Element) {
doc.querySelector('#open-docs')?.addEventListener('click', () => {
window.open('https://napneko.github.io/', '_blank');
});
doc.querySelector('#open-telegram')?.addEventListener('click', () => {
window.open('https://t.me/+nLZEnpne-pQ1OWFl', '_blank');
});
doc.querySelector('#open-qq-group')?.addEventListener('click', () => {
window.open('https://qm.qq.com/q/VfjAq5HIMS', '_blank');
});
// 生成反向地址列表
const buildHostListItem = (
type: string,
Expand Down

0 comments on commit cf3f488

Please sign in to comment.