Commit f1f20e6a authored by nanahira's avatar nanahira

catchup

parent f1b1c6ae
......@@ -17,7 +17,7 @@
"typed-reflector": "^1.0.10"
},
"devDependencies": {
"@koishijs/plugin-adapter-onebot": "^4.1.5",
"@koishijs/plugin-adapter-onebot": "^4.2.4",
"@types/jest": "^27.4.0",
"@types/lodash": "^4.14.178",
"@types/mustache": "^4.1.2",
......@@ -33,10 +33,10 @@
"rimraf": "^3.0.2",
"supertest": "^6.2.2",
"ts-jest": "^27.1.3",
"typescript": "^4.5.5"
"typescript": "^4.6.4"
},
"peerDependencies": {
"koishi": "^4.7.0"
"koishi": "^4.7.1"
}
},
"node_modules/@babel/code-frame": {
......@@ -999,37 +999,37 @@
}
},
"node_modules/@koishijs/core": {
"version": "4.7.0",
"resolved": "https://registry.npmjs.org/@koishijs/core/-/core-4.7.0.tgz",
"integrity": "sha512-MCF8eJaDV8Bw74N3GesFMaxBmRfrUCvez4SwAPkODjRk2uuQpmnxKCAOJu/AFxyyLLg/vQNTGUMG4mPW8RDIyA==",
"version": "4.7.1",
"resolved": "https://registry.npmjs.org/@koishijs/core/-/core-4.7.1.tgz",
"integrity": "sha512-vSd2BgyhDrTW/C7Ju1wDr5Z3vp7Qdyk7LgSpGI/b3QtDEfEkhdYKQ9J9LdHIVdUOFL0L0WeRgImW4ZMBtdVlfg==",
"peer": true,
"dependencies": {
"@koishijs/utils": "^5.4.3",
"@koishijs/utils": "^5.4.5",
"cordis": "^1.1.1",
"fastest-levenshtein": "^1.0.12",
"minato": "^1.0.10",
"ns-require": "^1.1.2"
"minato": "^1.1.0"
},
"engines": {
"node": ">=12.0.0"
}
},
"node_modules/@koishijs/plugin-adapter-onebot": {
"version": "4.1.5",
"resolved": "https://registry.npmjs.org/@koishijs/plugin-adapter-onebot/-/plugin-adapter-onebot-4.1.5.tgz",
"integrity": "sha512-6Lb2ifqbY/hTxnbaSLopDHyVbPUBBfnxdDS7FWDapJ7Z0UeXHCNeIyLSSreuEG93UCn3GDzl43ZCVvOhGQUCHg==",
"version": "4.2.4",
"resolved": "https://registry.npmjs.org/@koishijs/plugin-adapter-onebot/-/plugin-adapter-onebot-4.2.4.tgz",
"integrity": "sha512-T1RAzZDAFtdKig/IRAPSM9pa1hIYQ+ANXp34Ko8eqU7l+MzSaUB7esPpct8PbZSztETIWwxH3ly2rFnRP0pu8Q==",
"dev": true,
"dependencies": {
"qface": "^1.2.0",
"ws": "^8.5.0"
"ws": "^8.6.0"
},
"peerDependencies": {
"koishi": "^4.4.2"
"koishi": "^4.7.1"
}
},
"node_modules/@koishijs/plugin-adapter-onebot/node_modules/ws": {
"version": "8.5.0",
"resolved": "https://registry.npmjs.org/ws/-/ws-8.5.0.tgz",
"integrity": "sha512-BWX0SWVgLPzYwF8lTzEy1egjhS4S4OEAHfsO8o65WOVsrnSRGaSiUaa9e0ggGlkMTtBlmOpEXiie9RUcBO86qg==",
"version": "8.6.0",
"resolved": "https://registry.npmjs.org/ws/-/ws-8.6.0.tgz",
"integrity": "sha512-AzmM3aH3gk0aX7/rZLYvjdvZooofDu3fFOzGqcSnQ1tOcTWwhM/o+q++E8mAyVVIyUdajrkzWUGftaVSDLn1bw==",
"dev": true,
"engines": {
"node": ">=10.0.0"
......@@ -1047,6 +1047,24 @@
}
}
},
"node_modules/@koishijs/plugin-help": {
"version": "1.0.0",
"resolved": "https://registry.npmjs.org/@koishijs/plugin-help/-/plugin-help-1.0.0.tgz",
"integrity": "sha512-SvOZiSmtysQxnhOUG0He+/Ftxr+IuIbTApsK6KypRpQ4a1q7OuJWmKb2e+f62zS3GhMYBJ8qT0wRMU+TFPP3AQ==",
"peer": true,
"peerDependencies": {
"koishi": "^4.7.1"
}
},
"node_modules/@koishijs/plugin-suggest": {
"version": "1.0.0",
"resolved": "https://registry.npmjs.org/@koishijs/plugin-suggest/-/plugin-suggest-1.0.0.tgz",
"integrity": "sha512-6jmhymcygID59Z3UblAARGXflJoH0+Tj/qi20GNQO0bxrKkoW4qjxJhlmZe2uv+D1hvTO0q2Yv98iEMDhKyXxw==",
"peer": true,
"peerDependencies": {
"koishi": "^4.7.1"
}
},
"node_modules/@koishijs/segment": {
"version": "1.1.1",
"resolved": "https://registry.npmjs.org/@koishijs/segment/-/segment-1.1.1.tgz",
......@@ -1054,15 +1072,15 @@
"peer": true
},
"node_modules/@koishijs/utils": {
"version": "5.4.4",
"resolved": "https://registry.npmjs.org/@koishijs/utils/-/utils-5.4.4.tgz",
"integrity": "sha512-afPJs9aiwOjcSXZgGaOqmuEqlhIASxhUKdSBoB0msrw9RVz2HmegmyqHm0reRmftFWoeOvGh8Tv/3BKettzklw==",
"version": "5.4.5",
"resolved": "https://registry.npmjs.org/@koishijs/utils/-/utils-5.4.5.tgz",
"integrity": "sha512-tOmhFFcnuhFAudRcG9Bq7OeVmX1yxGvlSsJMbaSBHvb/hUrFzpXjEd2onqnJw4fyx/QLgYYFBeiFcKXDSujoLg==",
"peer": true,
"dependencies": {
"@koishijs/segment": "^1.1.1",
"cosmokit": "^1.1.2",
"reggol": "^1.0.3",
"schemastery": "^3.4.0",
"schemastery": "^3.4.3",
"supports-color": "^8.1.1"
}
},
......@@ -1815,6 +1833,15 @@
"node": ">=8"
}
},
"node_modules/async": {
"version": "2.6.4",
"resolved": "https://registry.npmjs.org/async/-/async-2.6.4.tgz",
"integrity": "sha512-mzo5dfJYwAn29PeiJ0zvwTo04zj8HDJj0Mn8TD7sno7q12prdbnasKJHhkm2c1LgrhlJ0teaea8860oxi51mGA==",
"peer": true,
"dependencies": {
"lodash": "^4.17.14"
}
},
"node_modules/asynckit": {
"version": "0.4.0",
"resolved": "https://registry.npmjs.org/asynckit/-/asynckit-0.4.0.tgz",
......@@ -2269,6 +2296,15 @@
"integrity": "sha1-JoD7uAaKSNCGVrYJgJK9r8kG9KU=",
"peer": true
},
"node_modules/cordis": {
"version": "1.1.1",
"resolved": "https://registry.npmjs.org/cordis/-/cordis-1.1.1.tgz",
"integrity": "sha512-l1tYxBqy+oEb3EKEvQAlH1g5BICDdnTdcIre1MuCY/qWO4bsrh97qd7jQe2Rq/+tg5HRqs7K6RgP5N/85c57xw==",
"peer": true,
"dependencies": {
"cosmokit": "^1.1.2"
}
},
"node_modules/core-util-is": {
"version": "1.0.3",
"resolved": "https://registry.npmjs.org/core-util-is/-/core-util-is-1.0.3.tgz",
......@@ -4745,14 +4781,16 @@
}
},
"node_modules/koishi": {
"version": "4.7.0",
"resolved": "https://registry.npmjs.org/koishi/-/koishi-4.7.0.tgz",
"integrity": "sha512-aCtfE+QydqbcpoOspOp/QCY1CAXieqnPIR101eKtODgrPBHUVc8XbXbkqGAzx6c2kr6wC7mE4ZLBgECqGBn7tw==",
"version": "4.7.1",
"resolved": "https://registry.npmjs.org/koishi/-/koishi-4.7.1.tgz",
"integrity": "sha512-WtY2ZujFMP4/ySKCc08oXLe2dYlZsdZP7f2eUck1w3cdvOh3eAgndckBP7xpkICAL0l6BYxrbzurIYh32Qck6g==",
"peer": true,
"dependencies": {
"@koa/router": "^10.1.1",
"@koishijs/core": "^4.7.0",
"@koishijs/utils": "^5.4.3",
"@koishijs/core": "^4.7.1",
"@koishijs/plugin-help": "^1.0.0",
"@koishijs/plugin-suggest": "^1.0.0",
"@koishijs/utils": "^5.4.5",
"@types/koa": "*",
"@types/koa__router": "*",
"@types/ws": "^8.5.3",
......@@ -4760,8 +4798,10 @@
"file-type": "^16.5.3",
"koa": "^2.13.4",
"koa-bodyparser": "^4.3.0",
"ns-require": "^1.1.2",
"parseurl": "^1.3.3",
"path-to-regexp": "^6.2.0",
"portfinder": "^1.0.28",
"proxy-agent": "^5.0.0",
"ws": "^8.6.0"
},
......@@ -5006,10 +5046,21 @@
}
},
"node_modules/minimist": {
"version": "1.2.5",
"resolved": "https://registry.npmjs.org/minimist/-/minimist-1.2.5.tgz",
"integrity": "sha512-FM9nNUYrRBAELZQT3xeZQ7fmMOBg6nWNmJKTcgsJeaLstP/UODVpGsr5OhXhhXg6f+qtJ8uiZ+PUxkDWcgIXLw==",
"dev": true
"version": "1.2.6",
"resolved": "https://registry.npmjs.org/minimist/-/minimist-1.2.6.tgz",
"integrity": "sha512-Jsjnk4bw3YJqYzbdyBiNsPWHPfO++UGG749Cxs6peCu5Xg4nrena6OVxOYxrQTqww0Jmwt+Ref8rggumkTLz9Q=="
},
"node_modules/mkdirp": {
"version": "0.5.6",
"resolved": "https://registry.npmjs.org/mkdirp/-/mkdirp-0.5.6.tgz",
"integrity": "sha512-FP+p8RB8OWpF3YZBCrP5gtADmtXApB5AMLn+vdyA+PyxCjrCs00mjyUozssO33cwDeT3wNGdLxJ5M//YqtHAJw==",
"peer": true,
"dependencies": {
"minimist": "^1.2.6"
},
"bin": {
"mkdirp": "bin/cmd.js"
}
},
"node_modules/ms": {
"version": "2.1.2",
......@@ -5357,6 +5408,29 @@
"node": ">=8"
}
},
"node_modules/portfinder": {
"version": "1.0.28",
"resolved": "https://registry.npmjs.org/portfinder/-/portfinder-1.0.28.tgz",
"integrity": "sha512-Se+2isanIcEqf2XMHjyUKskczxbPH7dQnlMjXX6+dybayyHvAf/TCgyMRlzf/B6QDhAEFOGes0pzRo3by4AbMA==",
"peer": true,
"dependencies": {
"async": "^2.6.2",
"debug": "^3.1.1",
"mkdirp": "^0.5.5"
},
"engines": {
"node": ">= 0.12.0"
}
},
"node_modules/portfinder/node_modules/debug": {
"version": "3.2.7",
"resolved": "https://registry.npmjs.org/debug/-/debug-3.2.7.tgz",
"integrity": "sha512-CFjzYYAi4ThfiQvizrFQevTTXHtnCqWfe7x1AhgEscTz6ZbLbfoLRLPugTQyBth6f8ZERVUSyWHFD/7Wu4t1XQ==",
"peer": true,
"dependencies": {
"ms": "^2.1.1"
}
},
"node_modules/prelude-ls": {
"version": "1.2.1",
"resolved": "https://registry.npmjs.org/prelude-ls/-/prelude-ls-1.2.1.tgz",
......@@ -5813,9 +5887,9 @@
}
},
"node_modules/schemastery": {
"version": "3.4.0",
"resolved": "https://registry.npmjs.org/schemastery/-/schemastery-3.4.0.tgz",
"integrity": "sha512-VGPk/BL/Qs+p3ldNXpqyqxMek9Oi3+2uWMeYhgVJvzQ4V4nOIPFuvEeyixZH+Uq1iGNEUjdBMeLOAV2HeWfaeg==",
"version": "3.4.3",
"resolved": "https://registry.npmjs.org/schemastery/-/schemastery-3.4.3.tgz",
"integrity": "sha512-Ui9sPoxOVaKa2EzR6GS08qB/nIMJUczUtkaLfWjeE44kjYZ+GLUFNVE3TpbXRdxjnbIIExwG+paMd0+M7YimqQ==",
"peer": true,
"dependencies": {
"cosmokit": "^1.1.2"
......@@ -6531,9 +6605,9 @@
}
},
"node_modules/typescript": {
"version": "4.5.5",
"resolved": "https://registry.npmjs.org/typescript/-/typescript-4.5.5.tgz",
"integrity": "sha512-TCTIul70LyWe6IJWT8QSYeA54WQe8EjQFU4wY52Fasj5UKx88LNYKCgBEHcOMOrFF1rKGbD8v/xcNWVUq9SymA==",
"version": "4.6.4",
"resolved": "https://registry.npmjs.org/typescript/-/typescript-4.6.4.tgz",
"integrity": "sha512-9ia/jWHIEbo49HfjrLGfKbZSuWo9iTMwXO+Ca3pRsSpbsMbc7/IU8NKdCZVRRBafVPGnoJeFL76ZOAA84I9fEg==",
"dev": true,
"bin": {
"tsc": "bin/tsc",
......@@ -7594,36 +7668,50 @@
}
},
"@koishijs/core": {
"version": "4.7.0",
"resolved": "https://registry.npmjs.org/@koishijs/core/-/core-4.7.0.tgz",
"integrity": "sha512-MCF8eJaDV8Bw74N3GesFMaxBmRfrUCvez4SwAPkODjRk2uuQpmnxKCAOJu/AFxyyLLg/vQNTGUMG4mPW8RDIyA==",
"version": "4.7.1",
"resolved": "https://registry.npmjs.org/@koishijs/core/-/core-4.7.1.tgz",
"integrity": "sha512-vSd2BgyhDrTW/C7Ju1wDr5Z3vp7Qdyk7LgSpGI/b3QtDEfEkhdYKQ9J9LdHIVdUOFL0L0WeRgImW4ZMBtdVlfg==",
"peer": true,
"requires": {
"@koishijs/utils": "^5.4.3",
"@koishijs/utils": "^5.4.5",
"cordis": "^1.1.1",
"fastest-levenshtein": "^1.0.12",
"minato": "^1.0.10",
"ns-require": "^1.1.2"
"minato": "^1.1.0"
}
},
"@koishijs/plugin-adapter-onebot": {
"version": "4.1.5",
"resolved": "https://registry.npmjs.org/@koishijs/plugin-adapter-onebot/-/plugin-adapter-onebot-4.1.5.tgz",
"integrity": "sha512-6Lb2ifqbY/hTxnbaSLopDHyVbPUBBfnxdDS7FWDapJ7Z0UeXHCNeIyLSSreuEG93UCn3GDzl43ZCVvOhGQUCHg==",
"version": "4.2.4",
"resolved": "https://registry.npmjs.org/@koishijs/plugin-adapter-onebot/-/plugin-adapter-onebot-4.2.4.tgz",
"integrity": "sha512-T1RAzZDAFtdKig/IRAPSM9pa1hIYQ+ANXp34Ko8eqU7l+MzSaUB7esPpct8PbZSztETIWwxH3ly2rFnRP0pu8Q==",
"dev": true,
"requires": {
"qface": "^1.2.0",
"ws": "^8.5.0"
"ws": "^8.6.0"
},
"dependencies": {
"ws": {
"version": "8.5.0",
"resolved": "https://registry.npmjs.org/ws/-/ws-8.5.0.tgz",
"integrity": "sha512-BWX0SWVgLPzYwF8lTzEy1egjhS4S4OEAHfsO8o65WOVsrnSRGaSiUaa9e0ggGlkMTtBlmOpEXiie9RUcBO86qg==",
"version": "8.6.0",
"resolved": "https://registry.npmjs.org/ws/-/ws-8.6.0.tgz",
"integrity": "sha512-AzmM3aH3gk0aX7/rZLYvjdvZooofDu3fFOzGqcSnQ1tOcTWwhM/o+q++E8mAyVVIyUdajrkzWUGftaVSDLn1bw==",
"dev": true,
"requires": {}
}
}
},
"@koishijs/plugin-help": {
"version": "1.0.0",
"resolved": "https://registry.npmjs.org/@koishijs/plugin-help/-/plugin-help-1.0.0.tgz",
"integrity": "sha512-SvOZiSmtysQxnhOUG0He+/Ftxr+IuIbTApsK6KypRpQ4a1q7OuJWmKb2e+f62zS3GhMYBJ8qT0wRMU+TFPP3AQ==",
"peer": true,
"requires": {}
},
"@koishijs/plugin-suggest": {
"version": "1.0.0",
"resolved": "https://registry.npmjs.org/@koishijs/plugin-suggest/-/plugin-suggest-1.0.0.tgz",
"integrity": "sha512-6jmhymcygID59Z3UblAARGXflJoH0+Tj/qi20GNQO0bxrKkoW4qjxJhlmZe2uv+D1hvTO0q2Yv98iEMDhKyXxw==",
"peer": true,
"requires": {}
},
"@koishijs/segment": {
"version": "1.1.1",
"resolved": "https://registry.npmjs.org/@koishijs/segment/-/segment-1.1.1.tgz",
......@@ -7631,15 +7719,15 @@
"peer": true
},
"@koishijs/utils": {
"version": "5.4.4",
"resolved": "https://registry.npmjs.org/@koishijs/utils/-/utils-5.4.4.tgz",
"integrity": "sha512-afPJs9aiwOjcSXZgGaOqmuEqlhIASxhUKdSBoB0msrw9RVz2HmegmyqHm0reRmftFWoeOvGh8Tv/3BKettzklw==",
"version": "5.4.5",
"resolved": "https://registry.npmjs.org/@koishijs/utils/-/utils-5.4.5.tgz",
"integrity": "sha512-tOmhFFcnuhFAudRcG9Bq7OeVmX1yxGvlSsJMbaSBHvb/hUrFzpXjEd2onqnJw4fyx/QLgYYFBeiFcKXDSujoLg==",
"peer": true,
"requires": {
"@koishijs/segment": "^1.1.1",
"cosmokit": "^1.1.2",
"reggol": "^1.0.3",
"schemastery": "^3.4.0",
"schemastery": "^3.4.3",
"supports-color": "^8.1.1"
},
"dependencies": {
......@@ -8249,6 +8337,15 @@
"integrity": "sha512-Z7tMw1ytTXt5jqMcOP+OQteU1VuNK9Y02uuJtKQ1Sv69jXQKKg5cibLwGJow8yzZP+eAc18EmLGPal0bp36rvQ==",
"dev": true
},
"async": {
"version": "2.6.4",
"resolved": "https://registry.npmjs.org/async/-/async-2.6.4.tgz",
"integrity": "sha512-mzo5dfJYwAn29PeiJ0zvwTo04zj8HDJj0Mn8TD7sno7q12prdbnasKJHhkm2c1LgrhlJ0teaea8860oxi51mGA==",
"peer": true,
"requires": {
"lodash": "^4.17.14"
}
},
"asynckit": {
"version": "0.4.0",
"resolved": "https://registry.npmjs.org/asynckit/-/asynckit-0.4.0.tgz",
......@@ -8606,6 +8703,15 @@
"integrity": "sha1-JoD7uAaKSNCGVrYJgJK9r8kG9KU=",
"peer": true
},
"cordis": {
"version": "1.1.1",
"resolved": "https://registry.npmjs.org/cordis/-/cordis-1.1.1.tgz",
"integrity": "sha512-l1tYxBqy+oEb3EKEvQAlH1g5BICDdnTdcIre1MuCY/qWO4bsrh97qd7jQe2Rq/+tg5HRqs7K6RgP5N/85c57xw==",
"peer": true,
"requires": {
"cosmokit": "^1.1.2"
}
},
"core-util-is": {
"version": "1.0.3",
"resolved": "https://registry.npmjs.org/core-util-is/-/core-util-is-1.0.3.tgz",
......@@ -10475,14 +10581,16 @@
}
},
"koishi": {
"version": "4.7.0",
"resolved": "https://registry.npmjs.org/koishi/-/koishi-4.7.0.tgz",
"integrity": "sha512-aCtfE+QydqbcpoOspOp/QCY1CAXieqnPIR101eKtODgrPBHUVc8XbXbkqGAzx6c2kr6wC7mE4ZLBgECqGBn7tw==",
"version": "4.7.1",
"resolved": "https://registry.npmjs.org/koishi/-/koishi-4.7.1.tgz",
"integrity": "sha512-WtY2ZujFMP4/ySKCc08oXLe2dYlZsdZP7f2eUck1w3cdvOh3eAgndckBP7xpkICAL0l6BYxrbzurIYh32Qck6g==",
"peer": true,
"requires": {
"@koa/router": "^10.1.1",
"@koishijs/core": "^4.7.0",
"@koishijs/utils": "^5.4.3",
"@koishijs/core": "^4.7.1",
"@koishijs/plugin-help": "^1.0.0",
"@koishijs/plugin-suggest": "^1.0.0",
"@koishijs/utils": "^5.4.5",
"@types/koa": "*",
"@types/koa__router": "*",
"@types/ws": "^8.5.3",
......@@ -10490,8 +10598,10 @@
"file-type": "^16.5.3",
"koa": "^2.13.4",
"koa-bodyparser": "^4.3.0",
"ns-require": "^1.1.2",
"parseurl": "^1.3.3",
"path-to-regexp": "^6.2.0",
"portfinder": "^1.0.28",
"proxy-agent": "^5.0.0",
"ws": "^8.6.0"
},
......@@ -10672,10 +10782,18 @@
}
},
"minimist": {
"version": "1.2.5",
"resolved": "https://registry.npmjs.org/minimist/-/minimist-1.2.5.tgz",
"integrity": "sha512-FM9nNUYrRBAELZQT3xeZQ7fmMOBg6nWNmJKTcgsJeaLstP/UODVpGsr5OhXhhXg6f+qtJ8uiZ+PUxkDWcgIXLw==",
"dev": true
"version": "1.2.6",
"resolved": "https://registry.npmjs.org/minimist/-/minimist-1.2.6.tgz",
"integrity": "sha512-Jsjnk4bw3YJqYzbdyBiNsPWHPfO++UGG749Cxs6peCu5Xg4nrena6OVxOYxrQTqww0Jmwt+Ref8rggumkTLz9Q=="
},
"mkdirp": {
"version": "0.5.6",
"resolved": "https://registry.npmjs.org/mkdirp/-/mkdirp-0.5.6.tgz",
"integrity": "sha512-FP+p8RB8OWpF3YZBCrP5gtADmtXApB5AMLn+vdyA+PyxCjrCs00mjyUozssO33cwDeT3wNGdLxJ5M//YqtHAJw==",
"peer": true,
"requires": {
"minimist": "^1.2.6"
}
},
"ms": {
"version": "2.1.2",
......@@ -10938,6 +11056,28 @@
"find-up": "^4.0.0"
}
},
"portfinder": {
"version": "1.0.28",
"resolved": "https://registry.npmjs.org/portfinder/-/portfinder-1.0.28.tgz",
"integrity": "sha512-Se+2isanIcEqf2XMHjyUKskczxbPH7dQnlMjXX6+dybayyHvAf/TCgyMRlzf/B6QDhAEFOGes0pzRo3by4AbMA==",
"peer": true,
"requires": {
"async": "^2.6.2",
"debug": "^3.1.1",
"mkdirp": "^0.5.5"
},
"dependencies": {
"debug": {
"version": "3.2.7",
"resolved": "https://registry.npmjs.org/debug/-/debug-3.2.7.tgz",
"integrity": "sha512-CFjzYYAi4ThfiQvizrFQevTTXHtnCqWfe7x1AhgEscTz6ZbLbfoLRLPugTQyBth6f8ZERVUSyWHFD/7Wu4t1XQ==",
"peer": true,
"requires": {
"ms": "^2.1.1"
}
}
}
},
"prelude-ls": {
"version": "1.2.1",
"resolved": "https://registry.npmjs.org/prelude-ls/-/prelude-ls-1.2.1.tgz",
......@@ -11261,9 +11401,9 @@
}
},
"schemastery": {
"version": "3.4.0",
"resolved": "https://registry.npmjs.org/schemastery/-/schemastery-3.4.0.tgz",
"integrity": "sha512-VGPk/BL/Qs+p3ldNXpqyqxMek9Oi3+2uWMeYhgVJvzQ4V4nOIPFuvEeyixZH+Uq1iGNEUjdBMeLOAV2HeWfaeg==",
"version": "3.4.3",
"resolved": "https://registry.npmjs.org/schemastery/-/schemastery-3.4.3.tgz",
"integrity": "sha512-Ui9sPoxOVaKa2EzR6GS08qB/nIMJUczUtkaLfWjeE44kjYZ+GLUFNVE3TpbXRdxjnbIIExwG+paMd0+M7YimqQ==",
"peer": true,
"requires": {
"cosmokit": "^1.1.2"
......@@ -11782,9 +11922,9 @@
}
},
"typescript": {
"version": "4.5.5",
"resolved": "https://registry.npmjs.org/typescript/-/typescript-4.5.5.tgz",
"integrity": "sha512-TCTIul70LyWe6IJWT8QSYeA54WQe8EjQFU4wY52Fasj5UKx88LNYKCgBEHcOMOrFF1rKGbD8v/xcNWVUq9SymA==",
"version": "4.6.4",
"resolved": "https://registry.npmjs.org/typescript/-/typescript-4.6.4.tgz",
"integrity": "sha512-9ia/jWHIEbo49HfjrLGfKbZSuWo9iTMwXO+Ca3pRsSpbsMbc7/IU8NKdCZVRRBafVPGnoJeFL76ZOAA84I9fEg==",
"dev": true
},
"universalify": {
......
......@@ -39,7 +39,7 @@
"testEnvironment": "node"
},
"devDependencies": {
"@koishijs/plugin-adapter-onebot": "^4.1.5",
"@koishijs/plugin-adapter-onebot": "^4.2.4",
"@types/jest": "^27.4.0",
"@types/lodash": "^4.14.178",
"@types/mustache": "^4.1.2",
......@@ -55,7 +55,7 @@
"rimraf": "^3.0.2",
"supertest": "^6.2.2",
"ts-jest": "^27.1.3",
"typescript": "^4.5.5"
"typescript": "^4.6.4"
},
"dependencies": {
"@types/koa": "^2.13.4",
......@@ -66,6 +66,6 @@
"typed-reflector": "^1.0.10"
},
"peerDependencies": {
"koishi": "^4.7.0"
"koishi": "^4.7.1"
}
}
......@@ -10,21 +10,21 @@ import {
KoishiOnContextScope,
OnContextFunction,
PickEventFunction,
PluginDefinition,
TopLevelActionDef,
TypedMethodDecorator,
} from '../def';
import 'reflect-metadata';
import {
Argv,
Awaitable,
BeforeEventMap,
Command,
Dict,
Events,
FieldCollector,
I18n,
Selection,
Session,
I18n,
Awaitable,
Middleware,
} from 'koishi';
import { Metadata } from '../meta/metadata.decorators';
import { CommandPut, DoRegister } from '../registry';
......@@ -33,7 +33,6 @@ import {
applyOptionToCommand,
registerTemplate,
} from '../utility';
import { EventMap, BeforeEventMap } from 'koishi';
// Register method
......@@ -42,7 +41,7 @@ export const UseMiddleware = (prepend = false) =>
export const UseEvent = <K extends EventName>(
name: K,
prepend = false,
): TypedMethodDecorator<PickEventFunction<EventMap, K>> =>
): TypedMethodDecorator<PickEventFunction<Events, K>> =>
DoRegister.event({ name, prepend });
export const UseBeforeEvent = <K extends BeforeEventName>(
name: K,
......
import {
Argv,
Awaitable,
Command,
Context,
Dict,
EventMap,
Events,
I18n,
Plugin,
Selection,
I18n,
Awaitable,
} from 'koishi';
import type { DefaultContext, DefaultState, ParameterizedContext } from 'koa';
import type { RouterParamContext } from '@koa/router';
import { CommandPut } from '../registry/registries/command-put';
import { CommandPut } from '../registry';
export interface Type<T = any> extends Function {
new (...args: any[]): T;
......@@ -62,7 +62,7 @@ export interface CommonEventNameAndPrepend<T extends keyof any> {
prepend?: boolean;
}
export type EventName = keyof EventMap;
export type EventName = keyof Events;
export type EventNameAndPrepend = CommonEventNameAndPrepend<EventName>;
type OmitSubstring<
......
import { MappingStruct } from '../def';
import { renderObject } from '../utility';
export class AbstractRegistry<M extends Record<string | number | symbol, any>> {
private map = new Map<keyof M, any>();
......
......@@ -4,7 +4,7 @@ import {
Awaitable,
BeforeEventMap,
Context,
EventMap,
Events,
I18n,
MaybeArray,
Middleware,
......@@ -84,7 +84,7 @@ export namespace DoRegister {
export interface DecoratorMap {
middleware: Middleware;
onEvent: PickEventFunction<EventMap, EventName>;
onEvent: PickEventFunction<Events, EventName>;
beforeEvent: PickEventFunction<BeforeEventMap, BeforeEventName>;
plugin(): Awaitable<PluginDefinition | undefined>;
command(...args: any[]): Awaitable<string | void | undefined>;
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment