@atri-bot/plugin-the-cake-is-a-lie 2.0.2 → 2.3.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/dist/index.d.mts CHANGED
@@ -1,14 +1,11 @@
1
- import * as _atri_bot_core0 from "@atri-bot/core";
2
- import { MessageContext } from "@atri-bot/core";
1
+ import * as _$_atri_bot_core0 from "@atri-bot/core";
2
+ import { Plugin } from "@atri-bot/core";
3
+ import * as _$node_napcat_ts0 from "node-napcat-ts";
4
+ import { SendMessageSegment } from "node-napcat-ts";
3
5
 
4
6
  //#region src/index.d.ts
5
- declare const Plugin: _atri_bot_core0.definePluginReturnType<{
6
- pluginName: string;
7
- install(): void;
8
- uninstall(): void;
9
- cakeIsALie({
10
- context
11
- }: MessageContext<"message">): Promise<void>;
12
- }, object>;
7
+ declare const plugin: Plugin<object>;
8
+ declare const messages: SendMessageSegment[];
9
+ declare const theCakeIsALie: _$_atri_bot_core0.ATRIMessage<keyof _$node_napcat_ts0.MessageHandler>;
13
10
  //#endregion
14
- export { Plugin };
11
+ export { messages, plugin, theCakeIsALie };
package/dist/index.mjs CHANGED
@@ -1 +1 @@
1
- import{definePlugin as e}from"@atri-bot/core";import{Structs as t}from"node-napcat-ts";var n=`@atri-bot/plugin-the-cake-is-a-lie`;const r=/^(the cake is a lie|蛋糕是个谎言)$/i,i=[t.text(`You Will Be Baked, And Then There Will Be Cake`),t.music(`163`,2005125394),t.text(`But The Cake Is A Lie`)],a=e(()=>({pluginName:n,install(){this.regMessageEvent({trigger:r,callback:this.cakeIsALie.bind(this)})},uninstall(){},async cakeIsALie({context:e}){i.forEach(async(t,n)=>{setTimeout(()=>this.bot.sendMsg(e,[t],{reply:!1,at:!1}),n*1e3)})}}));export{a as Plugin};
1
+ import{Plugin as e}from"@atri-bot/core";import{Structs as t}from"node-napcat-ts";const n=new e(`@atri-bot/plugin-the-cake-is-a-lie`),r=[t.text(`You Will Be Baked, And Then There Will Be Cake`),t.music(`163`,2005125394),t.text(`But The Cake Is A Lie`)],i=n.message(/the cake is a lie|蛋糕是个谎言/).callback(({context:e,bot:t},n)=>{n(),r.forEach((n,r)=>{setTimeout(()=>t.sendMsg(e,[n],{reply:!1,at:!1}),r*1e3)})});export{r as messages,n as plugin,i as theCakeIsALie};
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "@atri-bot/plugin-the-cake-is-a-lie",
3
3
  "type": "module",
4
- "version": "2.0.2",
4
+ "version": "2.3.0",
5
5
  "description": "the cake is a lie plugin for atri framework",
6
6
  "author": "huan_kong",
7
7
  "license": "MIT",
@@ -16,8 +16,8 @@
16
16
  "typecheck": "tsc --noEmit -p tsconfig.json --composite false"
17
17
  },
18
18
  "dependencies": {
19
- "@atri-bot/core": "^2.1.0",
20
- "node-napcat-ts": "^0.4.23",
19
+ "@atri-bot/core": "^2.3.4",
20
+ "node-napcat-ts": "^0.4.24",
21
21
  "yargs": "^18.0.0"
22
22
  },
23
23
  "devDependencies": {