koishi-plugin-rzgtboeyndxsklmq-commons 1.0.3 → 1.0.5
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/lib/index.d.ts +0 -1
- package/lib/index.js +0 -16
- package/lib/utils/I18n.d.ts +1 -1
- package/package.json +1 -1
package/lib/index.d.ts
CHANGED
package/lib/index.js
CHANGED
|
@@ -34,7 +34,6 @@ __export(src_exports, {
|
|
|
34
34
|
BeanType: () => BeanType,
|
|
35
35
|
Config: () => Config,
|
|
36
36
|
apply: () => apply,
|
|
37
|
-
loadLocales: () => loadLocales,
|
|
38
37
|
name: () => name,
|
|
39
38
|
readDirFiles: () => readDirFiles,
|
|
40
39
|
test: () => test,
|
|
@@ -280,20 +279,6 @@ async function test2(name2, count, run) {
|
|
|
280
279
|
}
|
|
281
280
|
__name(test2, "test2");
|
|
282
281
|
|
|
283
|
-
// src/utils/I18n.ts
|
|
284
|
-
var import_node_path2 = __toESM(require("node:path"));
|
|
285
|
-
async function loadLocales(ctx, dirPath) {
|
|
286
|
-
const files = await readDirFiles(dirPath);
|
|
287
|
-
for (const file of files) {
|
|
288
|
-
if (!file.endsWith(".yml")) {
|
|
289
|
-
continue;
|
|
290
|
-
}
|
|
291
|
-
const l = import_node_path2.default.basename(file);
|
|
292
|
-
ctx.i18n.define(l, require(file));
|
|
293
|
-
}
|
|
294
|
-
}
|
|
295
|
-
__name(loadLocales, "loadLocales");
|
|
296
|
-
|
|
297
282
|
// src/index.ts
|
|
298
283
|
var name = "rzgtboeyndxsklmq-commons";
|
|
299
284
|
var Config = import_koishi.Schema.object({});
|
|
@@ -306,7 +291,6 @@ __name(apply, "apply");
|
|
|
306
291
|
BeanType,
|
|
307
292
|
Config,
|
|
308
293
|
apply,
|
|
309
|
-
loadLocales,
|
|
310
294
|
name,
|
|
311
295
|
readDirFiles,
|
|
312
296
|
test,
|
package/lib/utils/I18n.d.ts
CHANGED
|
@@ -1,2 +1,2 @@
|
|
|
1
1
|
import { Context } from "koishi";
|
|
2
|
-
export declare function loadLocales(ctx: Context, dirPath: string):
|
|
2
|
+
export declare function loadLocales(ctx: Context, dirPath: string): void;
|