@open-discord-bots/framework 0.2.11 → 0.2.13
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/api/index.d.ts +26 -26
- package/dist/api/index.js +26 -42
- package/dist/api/main.d.ts +24 -24
- package/dist/api/main.js +7 -11
- package/dist/api/modules/action.d.ts +12 -12
- package/dist/api/modules/action.js +11 -17
- package/dist/api/modules/base.d.ts +7 -5
- package/dist/api/modules/base.js +22 -67
- package/dist/api/modules/builder.d.ts +44 -44
- package/dist/api/modules/builder.js +81 -142
- package/dist/api/modules/checker.d.ts +7 -7
- package/dist/api/modules/checker.js +55 -87
- package/dist/api/modules/client.d.ts +4 -4
- package/dist/api/modules/client.js +71 -118
- package/dist/api/modules/code.d.ts +2 -2
- package/dist/api/modules/code.js +3 -8
- package/dist/api/modules/config.d.ts +2 -2
- package/dist/api/modules/config.js +21 -63
- package/dist/api/modules/console.d.ts +16 -16
- package/dist/api/modules/console.js +61 -83
- package/dist/api/modules/cooldown.d.ts +2 -2
- package/dist/api/modules/cooldown.js +13 -23
- package/dist/api/modules/database.d.ts +2 -2
- package/dist/api/modules/database.js +19 -29
- package/dist/api/modules/event.d.ts +2 -2
- package/dist/api/modules/event.js +6 -11
- package/dist/api/modules/flag.d.ts +2 -2
- package/dist/api/modules/flag.js +3 -8
- package/dist/api/modules/fuse.js +2 -7
- package/dist/api/modules/helpmenu.d.ts +2 -2
- package/dist/api/modules/helpmenu.js +8 -16
- package/dist/api/modules/language.d.ts +2 -2
- package/dist/api/modules/language.js +12 -21
- package/dist/api/modules/permission.d.ts +3 -3
- package/dist/api/modules/permission.js +9 -47
- package/dist/api/modules/plugin.d.ts +2 -2
- package/dist/api/modules/plugin.js +9 -18
- package/dist/api/modules/post.d.ts +3 -3
- package/dist/api/modules/post.js +3 -8
- package/dist/api/modules/progressbar.d.ts +2 -2
- package/dist/api/modules/progressbar.js +14 -26
- package/dist/api/modules/responder.d.ts +42 -42
- package/dist/api/modules/responder.js +79 -138
- package/dist/api/modules/session.d.ts +2 -2
- package/dist/api/modules/session.js +4 -42
- package/dist/api/modules/startscreen.d.ts +4 -4
- package/dist/api/modules/startscreen.js +28 -44
- package/dist/api/modules/statistic.d.ts +3 -3
- package/dist/api/modules/statistic.js +11 -22
- package/dist/api/modules/verifybar.d.ts +5 -5
- package/dist/api/modules/verifybar.js +6 -11
- package/dist/api/modules/worker.d.ts +15 -15
- package/dist/api/modules/worker.js +12 -17
- package/dist/cli/editConfig.d.ts +2 -2
- package/dist/cli/editConfig.js +194 -248
- package/dist/cli/index.d.ts +2 -2
- package/dist/cli/index.js +37 -62
- package/dist/index.d.ts +4 -4
- package/dist/index.js +6 -13
- package/dist/startup/compilation.d.ts +1 -1
- package/dist/startup/compilation.js +35 -42
- package/dist/startup/dump.d.ts +1 -1
- package/dist/startup/dump.js +4 -41
- package/dist/startup/errorHandling.d.ts +1 -1
- package/dist/startup/errorHandling.js +2 -38
- package/dist/startup/pluginLauncher.d.ts +1 -1
- package/dist/startup/pluginLauncher.js +14 -52
- package/dist/utilities/index.d.ts +3 -3
- package/dist/utilities/index.js +20 -71
- package/package.json +5 -4
- package/src/api/index.ts +26 -26
- package/src/api/main.ts +25 -25
- package/src/api/modules/action.ts +13 -13
- package/src/api/modules/base.ts +14 -10
- package/src/api/modules/builder.ts +56 -56
- package/src/api/modules/checker.ts +7 -7
- package/src/api/modules/client.ts +18 -18
- package/src/api/modules/code.ts +2 -2
- package/src/api/modules/component.txt +350 -0
- package/src/api/modules/config.ts +3 -3
- package/src/api/modules/console.ts +28 -28
- package/src/api/modules/cooldown.ts +2 -2
- package/src/api/modules/database.ts +3 -3
- package/src/api/modules/event.ts +5 -5
- package/src/api/modules/flag.ts +2 -2
- package/src/api/modules/helpmenu.ts +4 -4
- package/src/api/modules/language.ts +3 -3
- package/src/api/modules/permission.ts +3 -3
- package/src/api/modules/plugin.ts +4 -4
- package/src/api/modules/post.ts +3 -3
- package/src/api/modules/progressbar.ts +5 -3
- package/src/api/modules/responder.ts +48 -48
- package/src/api/modules/session.ts +2 -2
- package/src/api/modules/startscreen.ts +4 -4
- package/src/api/modules/statistic.ts +3 -4
- package/src/api/modules/verifybar.ts +5 -5
- package/src/api/modules/worker.ts +25 -25
- package/src/cli/editConfig.ts +23 -37
- package/src/cli/index.ts +3 -3
- package/src/index.ts +5 -5
- package/src/startup/compilation.ts +2 -2
- package/src/startup/dump.ts +2 -2
- package/src/startup/errorHandling.ts +2 -2
- package/src/startup/pluginLauncher.ts +11 -8
- package/src/utilities/index.ts +4 -4
- package/tools/cleanup.js +1 -1
- package/tsconfig.json +2 -1
|
@@ -1,7 +1,7 @@
|
|
|
1
|
-
import { ODDiscordIdType, ODId, ODManager, ODManagerData, ODNoGeneric, ODValidId, ODValidJsonType } from "./base";
|
|
2
|
-
import { ODConfig } from "./config";
|
|
3
|
-
import { ODLanguageManager } from "./language";
|
|
4
|
-
import { ODDebugger } from "./console";
|
|
1
|
+
import { ODDiscordIdType, ODId, ODManager, ODManagerData, ODNoGeneric, ODValidId, ODValidJsonType } from "./base.js";
|
|
2
|
+
import { ODConfig } from "./config.js";
|
|
3
|
+
import { ODLanguageManager } from "./language.js";
|
|
4
|
+
import { ODDebugger } from "./console.js";
|
|
5
5
|
/**## ODCheckerResult `interface`
|
|
6
6
|
* This interface is the result from a config checker check() function.
|
|
7
7
|
*/
|
|
@@ -349,7 +349,7 @@ export interface ODCheckerObjectStructureOptions extends ODCheckerStructureOptio
|
|
|
349
349
|
export declare class ODCheckerObjectStructure extends ODCheckerStructure {
|
|
350
350
|
options: ODCheckerObjectStructureOptions;
|
|
351
351
|
constructor(id: ODValidId, options: ODCheckerObjectStructureOptions);
|
|
352
|
-
check(checker: ODChecker, value:
|
|
352
|
+
check(checker: ODChecker, value: Record<string, any>, locationTrace: ODCheckerLocationTrace): boolean;
|
|
353
353
|
}
|
|
354
354
|
/**## ODCheckerStringStructureOptions `interface`
|
|
355
355
|
* This interface has the options for `ODCheckerStringStructure`!
|
|
@@ -581,7 +581,7 @@ export interface ODCheckerObjectSwitchStructureOptions extends ODCheckerStructur
|
|
|
581
581
|
export declare class ODCheckerObjectSwitchStructure extends ODCheckerStructure {
|
|
582
582
|
options: ODCheckerObjectSwitchStructureOptions;
|
|
583
583
|
constructor(id: ODValidId, options: ODCheckerObjectSwitchStructureOptions);
|
|
584
|
-
check(checker: ODChecker, value:
|
|
584
|
+
check(checker: ODChecker, value: Record<string, any>, locationTrace: ODCheckerLocationTrace): boolean;
|
|
585
585
|
}
|
|
586
586
|
/**## ODCheckerEnabledObjectStructureOptions `interface`
|
|
587
587
|
* This interface has the options for `ODCheckerEnabledObjectStructure`!
|
|
@@ -602,7 +602,7 @@ export interface ODCheckerEnabledObjectStructureOptions extends ODCheckerStructu
|
|
|
602
602
|
export declare class ODCheckerEnabledObjectStructure extends ODCheckerStructure {
|
|
603
603
|
options: ODCheckerEnabledObjectStructureOptions;
|
|
604
604
|
constructor(id: ODValidId, options: ODCheckerEnabledObjectStructureOptions);
|
|
605
|
-
check(checker: ODChecker, value:
|
|
605
|
+
check(checker: ODChecker, value: Record<string, any>, locationTrace: ODCheckerLocationTrace): boolean;
|
|
606
606
|
}
|
|
607
607
|
/**## ODCheckerCustomStructure_DiscordId `class`
|
|
608
608
|
* This is an Open Discord custom checker structure.
|
|
@@ -1,15 +1,9 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
var __importDefault = (this && this.__importDefault) || function (mod) {
|
|
3
|
-
return (mod && mod.__esModule) ? mod : { "default": mod };
|
|
4
|
-
};
|
|
5
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
6
|
-
exports.ODCheckerCustomStructure_UniqueIdArray = exports.ODCheckerCustomStructure_UniqueId = exports.ODCheckerCustomStructure_UrlString = exports.ODCheckerCustomStructure_EmojiString = exports.ODCheckerCustomStructure_HexColor = exports.ODCheckerCustomStructure_DiscordToken = exports.ODCheckerCustomStructure_DiscordIdArray = exports.ODCheckerCustomStructure_DiscordId = exports.ODCheckerEnabledObjectStructure = exports.ODCheckerObjectSwitchStructure = exports.ODCheckerTypeSwitchStructure = exports.ODCheckerNullStructure = exports.ODCheckerArrayStructure = exports.ODCheckerBooleanStructure = exports.ODCheckerNumberStructure = exports.ODCheckerStringStructure = exports.ODCheckerObjectStructure = exports.ODCheckerStructure = exports.ODChecker = exports.ODCheckerFunctionManager = exports.ODCheckerFunction = exports.ODCheckerTranslationRegister = exports.ODDefaultCheckerRenderer = exports.ODCheckerRenderer = exports.ODCheckerStorage = exports.ODCheckerManager = void 0;
|
|
7
1
|
///////////////////////////////////////
|
|
8
2
|
//CONFIG CHECKER MODULE
|
|
9
3
|
///////////////////////////////////////
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
4
|
+
import { ODId, ODManager, ODManagerData } from "./base.js";
|
|
5
|
+
import { ODConfig } from "./config.js";
|
|
6
|
+
import ansis from "ansis";
|
|
13
7
|
/**## ODCheckerManager `class`
|
|
14
8
|
* This is an Open Discord checker manager.
|
|
15
9
|
*
|
|
@@ -17,7 +11,7 @@ const ansis_1 = __importDefault(require("ansis"));
|
|
|
17
11
|
*
|
|
18
12
|
* You can use this class to get/add a config checker (`ODChecker`) in your plugin!
|
|
19
13
|
*/
|
|
20
|
-
class ODCheckerManager extends
|
|
14
|
+
export class ODCheckerManager extends ODManager {
|
|
21
15
|
/**The global temporary storage shared between all config checkers. */
|
|
22
16
|
storage;
|
|
23
17
|
/**The class responsible for rendering the config checker report. */
|
|
@@ -72,7 +66,7 @@ class ODCheckerManager extends base_1.ODManager {
|
|
|
72
66
|
}
|
|
73
67
|
/**Create temporary and unlisted `ODConfig`, `ODChecker` & `ODCheckerStorage` classes. This will help you use a `ODCheckerStructure` validator without officially registering it in `opendiscord.checkers`. */
|
|
74
68
|
createTemporaryCheckerEnvironment() {
|
|
75
|
-
return new ODChecker("opendiscord:temporary-environment", new ODCheckerStorage(), 0, new
|
|
69
|
+
return new ODChecker("opendiscord:temporary-environment", new ODCheckerStorage(), 0, new ODConfig("opendiscord:temporary-environment", {}), new ODCheckerStructure("opendiscord:temporary-environment", {}));
|
|
76
70
|
}
|
|
77
71
|
get(id) {
|
|
78
72
|
return super.get(id);
|
|
@@ -84,7 +78,6 @@ class ODCheckerManager extends base_1.ODManager {
|
|
|
84
78
|
return super.exists(id);
|
|
85
79
|
}
|
|
86
80
|
}
|
|
87
|
-
exports.ODCheckerManager = ODCheckerManager;
|
|
88
81
|
/**## ODCheckerStorage `class`
|
|
89
82
|
* This is an Open Discord checker storage.
|
|
90
83
|
*
|
|
@@ -94,28 +87,28 @@ exports.ODCheckerManager = ODCheckerManager;
|
|
|
94
87
|
*
|
|
95
88
|
* You can use this class when you create your own config checker implementation! (not required for using the built-in config checker)
|
|
96
89
|
*/
|
|
97
|
-
class ODCheckerStorage {
|
|
90
|
+
export class ODCheckerStorage {
|
|
98
91
|
/**This is the array that stores all the data. ❌ **(don't edit unless really needed!)***/
|
|
99
92
|
storage = [];
|
|
100
93
|
/**Get data from the database (`source` => id of `ODChecker`) */
|
|
101
94
|
get(source, key) {
|
|
102
|
-
const result = this.storage.find(d => (d.source.value == new
|
|
95
|
+
const result = this.storage.find(d => (d.source.value == new ODId(source).value) && (d.key == key));
|
|
103
96
|
return (result) ? result.value : null;
|
|
104
97
|
}
|
|
105
98
|
/**Add data to the database (`source` => id of `ODChecker`). This function also overwrites existing data!*/
|
|
106
99
|
set(source, key, value) {
|
|
107
|
-
const index = this.storage.findIndex(d => (d.source.value == new
|
|
100
|
+
const index = this.storage.findIndex(d => (d.source.value == new ODId(source).value) && (d.key == key));
|
|
108
101
|
if (index > -1) {
|
|
109
102
|
//overwrite
|
|
110
103
|
this.storage[index] = {
|
|
111
|
-
source: new
|
|
104
|
+
source: new ODId(source),
|
|
112
105
|
key, value
|
|
113
106
|
};
|
|
114
107
|
return true;
|
|
115
108
|
}
|
|
116
109
|
else {
|
|
117
110
|
this.storage.push({
|
|
118
|
-
source: new
|
|
111
|
+
source: new ODId(source),
|
|
119
112
|
key, value
|
|
120
113
|
});
|
|
121
114
|
return false;
|
|
@@ -123,7 +116,7 @@ class ODCheckerStorage {
|
|
|
123
116
|
}
|
|
124
117
|
/**Delete data from the database (`source` => id of `ODChecker`) */
|
|
125
118
|
delete(source, key) {
|
|
126
|
-
const index = this.storage.findIndex(d => (d.source.value == new
|
|
119
|
+
const index = this.storage.findIndex(d => (d.source.value == new ODId(source).value) && (d.key == key));
|
|
127
120
|
if (index > -1) {
|
|
128
121
|
//delete
|
|
129
122
|
this.storage.splice(index, 1);
|
|
@@ -137,7 +130,6 @@ class ODCheckerStorage {
|
|
|
137
130
|
this.storage = [];
|
|
138
131
|
}
|
|
139
132
|
}
|
|
140
|
-
exports.ODCheckerStorage = ODCheckerStorage;
|
|
141
133
|
/**## ODCheckerRenderer `class`
|
|
142
134
|
* This is an Open Discord checker renderer.
|
|
143
135
|
*
|
|
@@ -146,7 +138,7 @@ exports.ODCheckerStorage = ODCheckerStorage;
|
|
|
146
138
|
*
|
|
147
139
|
* Use this class to change the config checker looks!
|
|
148
140
|
*/
|
|
149
|
-
class ODCheckerRenderer {
|
|
141
|
+
export class ODCheckerRenderer {
|
|
150
142
|
/**Get all config checker render components. These can be combined and rendered to the console. */
|
|
151
143
|
getComponents(compact, renderEmpty, translation, data) {
|
|
152
144
|
return [];
|
|
@@ -162,13 +154,12 @@ class ODCheckerRenderer {
|
|
|
162
154
|
console.log("\n");
|
|
163
155
|
}
|
|
164
156
|
}
|
|
165
|
-
exports.ODCheckerRenderer = ODCheckerRenderer;
|
|
166
157
|
/**## ODDefaultCheckerRenderer `class`
|
|
167
158
|
* This is the default render class which renders the config checkers in the console for most Open Discord projects.
|
|
168
159
|
*
|
|
169
160
|
* This class can be found in the global variable `opendiscord.checkers.renderer`!
|
|
170
161
|
*/
|
|
171
|
-
class ODDefaultCheckerRenderer extends ODCheckerRenderer {
|
|
162
|
+
export class ODDefaultCheckerRenderer extends ODCheckerRenderer {
|
|
172
163
|
/**The main color used when rendering the config checker. */
|
|
173
164
|
mainColor;
|
|
174
165
|
/**The url to the discord support server. */
|
|
@@ -225,11 +216,11 @@ class ODDefaultCheckerRenderer extends ODCheckerRenderer {
|
|
|
225
216
|
const hasInfo = data.messages.filter((m) => m.type == "info").length > 0;
|
|
226
217
|
if (!renderEmpty && !hasErrors && !hasWarnings && (!hasInfo || compact))
|
|
227
218
|
return [];
|
|
228
|
-
const headerText =
|
|
229
|
-
const footerErrorText = (hasErrors) ? this.footerTipPrefix +
|
|
230
|
-
const footerWarningText = (hasWarnings) ? this.footerTipPrefix +
|
|
231
|
-
const footerSupportText = tm.insertTranslationParams(t.footerSupport, [
|
|
232
|
-
const bottomCompactInfo = (compact) ?
|
|
219
|
+
const headerText = ansis.bold.hex(this.mainColor)(t.headerProjectName) + " " + t.headerConfigchecker + this.headerSeparator + ansis.hex(this.mainColor)(t.headerDescription);
|
|
220
|
+
const footerErrorText = (hasErrors) ? this.footerTipPrefix + ansis.gray(tm.insertTranslationParams(t.footerError, [ansis.bold.red(t.error)])) : "";
|
|
221
|
+
const footerWarningText = (hasWarnings) ? this.footerTipPrefix + ansis.gray(tm.insertTranslationParams(t.footerWarning, [ansis.bold.yellow(t.warning)])) : "";
|
|
222
|
+
const footerSupportText = tm.insertTranslationParams(t.footerSupport, [ansis.green(this.supportUrl), ansis.green(this.docsUrl)]);
|
|
223
|
+
const bottomCompactInfo = (compact) ? ansis.gray(tm.insertTranslationParams(t.compactInfo, [ansis.bold.green("npm start -- --checker")])) : "";
|
|
233
224
|
const finalHeader = [headerText, ...this.extraHeaderText];
|
|
234
225
|
const finalFooter = [footerErrorText, footerWarningText, footerSupportText, ...this.extraFooterText];
|
|
235
226
|
const finalTop = [...this.extraTopText];
|
|
@@ -263,11 +254,11 @@ class ODDefaultCheckerRenderer extends ODCheckerRenderer {
|
|
|
263
254
|
const rawTranslation = tm.get("message", msg.messageId.value);
|
|
264
255
|
const translatedMessage = (rawTranslation) ? tm.insertTranslationParams(rawTranslation, msg.translationParams) : msg.message;
|
|
265
256
|
if (msg.type == "error")
|
|
266
|
-
finalComponents.push(this.verticalFiller + " " +
|
|
257
|
+
finalComponents.push(this.verticalFiller + " " + ansis.bold.red(`${t.error} ${translatedMessage}`));
|
|
267
258
|
else if (msg.type == "warning")
|
|
268
|
-
finalComponents.push(this.verticalFiller + " " +
|
|
259
|
+
finalComponents.push(this.verticalFiller + " " + ansis.bold.yellow(`${t.warning} ${translatedMessage}`));
|
|
269
260
|
const pathSplitter = msg.path ? ":" : "";
|
|
270
|
-
finalComponents.push(this.verticalFiller +
|
|
261
|
+
finalComponents.push(this.verticalFiller + ansis.bold(this.descriptionSeparator) + ansis.cyan(`${ansis.magenta(msg.filepath + pathSplitter)} ${msg.path}`));
|
|
271
262
|
if (index != data.messages.length - 1)
|
|
272
263
|
finalComponents.push(this.verticalFiller);
|
|
273
264
|
});
|
|
@@ -279,17 +270,17 @@ class ODDefaultCheckerRenderer extends ODCheckerRenderer {
|
|
|
279
270
|
const rawTranslation = tm.get("message", msg.messageId.value);
|
|
280
271
|
const translatedMessage = (rawTranslation) ? tm.insertTranslationParams(rawTranslation, msg.translationParams) : msg.message;
|
|
281
272
|
if (msg.type == "error")
|
|
282
|
-
finalComponents.push(this.verticalFiller + " " +
|
|
273
|
+
finalComponents.push(this.verticalFiller + " " + ansis.bold.red(`${t.error} ${translatedMessage}`));
|
|
283
274
|
else if (msg.type == "warning")
|
|
284
|
-
finalComponents.push(this.verticalFiller + " " +
|
|
275
|
+
finalComponents.push(this.verticalFiller + " " + ansis.bold.yellow(`${t.warning} ${translatedMessage}`));
|
|
285
276
|
else if (msg.type == "info")
|
|
286
|
-
finalComponents.push(this.verticalFiller + " " +
|
|
277
|
+
finalComponents.push(this.verticalFiller + " " + ansis.bold.blue(`${t.info} ${translatedMessage}`));
|
|
287
278
|
const pathSplitter = msg.path ? ":" : "";
|
|
288
|
-
finalComponents.push(this.verticalFiller + " " +
|
|
279
|
+
finalComponents.push(this.verticalFiller + " " + ansis.bold((t.dataPath) + this.descriptionSeparator) + ansis.cyan(`${ansis.magenta(msg.filepath + pathSplitter)} ${msg.path}`));
|
|
289
280
|
if (msg.locationDocs)
|
|
290
|
-
finalComponents.push(this.verticalFiller + " " +
|
|
281
|
+
finalComponents.push(this.verticalFiller + " " + ansis.bold(t.dataDocs + this.descriptionSeparator) + ansis.italic.gray(msg.locationDocs));
|
|
291
282
|
if (msg.messageDocs)
|
|
292
|
-
finalComponents.push(this.verticalFiller + " " +
|
|
283
|
+
finalComponents.push(this.verticalFiller + " " + ansis.bold(t.dataMessage + this.descriptionSeparator) + ansis.italic.gray(msg.messageDocs));
|
|
293
284
|
if (index != data.messages.length - 1)
|
|
294
285
|
finalComponents.push(this.verticalFiller);
|
|
295
286
|
});
|
|
@@ -316,7 +307,7 @@ class ODDefaultCheckerRenderer extends ODCheckerRenderer {
|
|
|
316
307
|
}
|
|
317
308
|
/**Get the length of the longest string in the array. */
|
|
318
309
|
#getLongestLength(texts) {
|
|
319
|
-
return Math.max(...texts.map((t) =>
|
|
310
|
+
return Math.max(...texts.map((t) => ansis.strip(t).length));
|
|
320
311
|
}
|
|
321
312
|
/**Get a horizontal divider used between different parts of the config checker result. */
|
|
322
313
|
#getHorizontalDivider(width) {
|
|
@@ -331,12 +322,11 @@ class ODDefaultCheckerRenderer extends ODCheckerRenderer {
|
|
|
331
322
|
#createBlockFromText(text, width) {
|
|
332
323
|
if (width < 3)
|
|
333
324
|
return this.verticalFiller + this.verticalFiller;
|
|
334
|
-
let newWidth = width -
|
|
325
|
+
let newWidth = width - ansis.strip(text).length + 1;
|
|
335
326
|
let final = this.verticalFiller + " " + text + " ".repeat(newWidth) + this.verticalFiller;
|
|
336
327
|
return final;
|
|
337
328
|
}
|
|
338
329
|
}
|
|
339
|
-
exports.ODDefaultCheckerRenderer = ODDefaultCheckerRenderer;
|
|
340
330
|
/**## ODCheckerTranslationRegister `class`
|
|
341
331
|
* This is an Open Discord checker translation register.
|
|
342
332
|
*
|
|
@@ -345,7 +335,7 @@ exports.ODDefaultCheckerRenderer = ODDefaultCheckerRenderer;
|
|
|
345
335
|
*
|
|
346
336
|
* You can use this class if you want to translate your config checker messages! **This is optional & isn't required for the checker to work!**
|
|
347
337
|
*/
|
|
348
|
-
class ODCheckerTranslationRegister {
|
|
338
|
+
export class ODCheckerTranslationRegister {
|
|
349
339
|
/**This is the array that stores all the data. ❌ **(don't edit unless really needed!)***/
|
|
350
340
|
#translations = [];
|
|
351
341
|
get(type, id) {
|
|
@@ -391,14 +381,13 @@ class ODCheckerTranslationRegister {
|
|
|
391
381
|
this.set(type, id, translation);
|
|
392
382
|
}
|
|
393
383
|
}
|
|
394
|
-
exports.ODCheckerTranslationRegister = ODCheckerTranslationRegister;
|
|
395
384
|
/**## ODCheckerFunction `class`
|
|
396
385
|
* This is an Open Discord config checker function.
|
|
397
386
|
*
|
|
398
387
|
* It is a global function that will be executed after all config checkers. It can do additional checks for invalid/missing configurations.
|
|
399
388
|
* It's mostly used for things that need to be checked globally!
|
|
400
389
|
*/
|
|
401
|
-
class ODCheckerFunction extends
|
|
390
|
+
export class ODCheckerFunction extends ODManagerData {
|
|
402
391
|
/**The function which will be executed globally after all config checkers. */
|
|
403
392
|
func;
|
|
404
393
|
constructor(id, func) {
|
|
@@ -406,21 +395,20 @@ class ODCheckerFunction extends base_1.ODManagerData {
|
|
|
406
395
|
this.func = func;
|
|
407
396
|
}
|
|
408
397
|
}
|
|
409
|
-
exports.ODCheckerFunction = ODCheckerFunction;
|
|
410
398
|
/**## ODCheckerFunctionManager `class`
|
|
411
399
|
* This is an Open Discord config checker function manager.
|
|
412
400
|
*
|
|
413
401
|
* It manages all `ODCheckerFunction`'s and it has some extra shortcuts for frequently used methods.
|
|
414
402
|
*/
|
|
415
|
-
class ODCheckerFunctionManager extends
|
|
403
|
+
export class ODCheckerFunctionManager extends ODManager {
|
|
416
404
|
constructor(debug) {
|
|
417
405
|
super(debug, "config checker function");
|
|
418
406
|
}
|
|
419
407
|
/**A shortcut to create a warning, info or error message */
|
|
420
408
|
createMessage(checkerId, id, filepath, type, message, locationTrace, docs, translationParams, locationId, locationDocs) {
|
|
421
409
|
return {
|
|
422
|
-
checkerId: new
|
|
423
|
-
messageId: new
|
|
410
|
+
checkerId: new ODId(checkerId),
|
|
411
|
+
messageId: new ODId(id),
|
|
424
412
|
locationId,
|
|
425
413
|
type, message,
|
|
426
414
|
path: this.locationTraceToString(locationTrace),
|
|
@@ -457,7 +445,6 @@ class ODCheckerFunctionManager extends base_1.ODManager {
|
|
|
457
445
|
return super.exists(id);
|
|
458
446
|
}
|
|
459
447
|
}
|
|
460
|
-
exports.ODCheckerFunctionManager = ODCheckerFunctionManager;
|
|
461
448
|
/**## ODChecker `class`
|
|
462
449
|
* This is an Open Discord config checker.
|
|
463
450
|
*
|
|
@@ -466,7 +453,7 @@ exports.ODCheckerFunctionManager = ODCheckerFunctionManager;
|
|
|
466
453
|
*
|
|
467
454
|
* You can use this class when you create your own custom config file & you want to check it for syntax errors.
|
|
468
455
|
*/
|
|
469
|
-
class ODChecker extends
|
|
456
|
+
export class ODChecker extends ODManagerData {
|
|
470
457
|
/**The storage of this checker (reference for `ODCheckerManager.storage`) */
|
|
471
458
|
storage;
|
|
472
459
|
/**The higher the priority, the faster it gets checked! */
|
|
@@ -537,7 +524,7 @@ class ODChecker extends base_1.ODManagerData {
|
|
|
537
524
|
this.quit = true;
|
|
538
525
|
this.messages.push({
|
|
539
526
|
checkerId: this.id,
|
|
540
|
-
messageId: new
|
|
527
|
+
messageId: new ODId(id),
|
|
541
528
|
locationId,
|
|
542
529
|
type, message,
|
|
543
530
|
path: this.locationTraceToString(locationTrace),
|
|
@@ -548,7 +535,6 @@ class ODChecker extends base_1.ODManagerData {
|
|
|
548
535
|
});
|
|
549
536
|
}
|
|
550
537
|
}
|
|
551
|
-
exports.ODChecker = ODChecker;
|
|
552
538
|
/**## ODCheckerStructure `class`
|
|
553
539
|
* This is an Open Discord config checker structure.
|
|
554
540
|
*
|
|
@@ -557,13 +543,13 @@ exports.ODChecker = ODChecker;
|
|
|
557
543
|
*
|
|
558
544
|
* **Not recommended to use!** It's recommended to extend from another `ODConfigCheckerStructure` class!
|
|
559
545
|
*/
|
|
560
|
-
class ODCheckerStructure {
|
|
546
|
+
export class ODCheckerStructure {
|
|
561
547
|
/**The id of this checker structure */
|
|
562
548
|
id;
|
|
563
549
|
/**The options for this checker structure */
|
|
564
550
|
options;
|
|
565
551
|
constructor(id, options) {
|
|
566
|
-
this.id = new
|
|
552
|
+
this.id = new ODId(id);
|
|
567
553
|
this.options = options;
|
|
568
554
|
}
|
|
569
555
|
/**Check a variable if it matches all settings in this checker. This function is automatically executed by Open Discord! */
|
|
@@ -575,14 +561,13 @@ class ODCheckerStructure {
|
|
|
575
561
|
return true;
|
|
576
562
|
}
|
|
577
563
|
}
|
|
578
|
-
exports.ODCheckerStructure = ODCheckerStructure;
|
|
579
564
|
/**## ODCheckerObjectStructure `class`
|
|
580
565
|
* This is an Open Discord config checker structure.
|
|
581
566
|
*
|
|
582
567
|
* This class will check for an object variable in a config file, customise it in the settings!
|
|
583
568
|
* A checker for the children can be set in the settings.
|
|
584
569
|
*/
|
|
585
|
-
class ODCheckerObjectStructure extends ODCheckerStructure {
|
|
570
|
+
export class ODCheckerObjectStructure extends ODCheckerStructure {
|
|
586
571
|
constructor(id, options) {
|
|
587
572
|
super(id, options);
|
|
588
573
|
}
|
|
@@ -628,13 +613,12 @@ class ODCheckerObjectStructure extends ODCheckerStructure {
|
|
|
628
613
|
return super.check(checker, value, locationTrace);
|
|
629
614
|
}
|
|
630
615
|
}
|
|
631
|
-
exports.ODCheckerObjectStructure = ODCheckerObjectStructure;
|
|
632
616
|
/**## ODCheckerStringStructure `class`
|
|
633
617
|
* This is an Open Discord config checker structure.
|
|
634
618
|
*
|
|
635
619
|
* This class will check for a string variable in a config file, customise it in the settings!
|
|
636
620
|
*/
|
|
637
|
-
class ODCheckerStringStructure extends ODCheckerStructure {
|
|
621
|
+
export class ODCheckerStringStructure extends ODCheckerStructure {
|
|
638
622
|
constructor(id, options) {
|
|
639
623
|
super(id, options);
|
|
640
624
|
}
|
|
@@ -709,13 +693,12 @@ class ODCheckerStringStructure extends ODCheckerStructure {
|
|
|
709
693
|
}
|
|
710
694
|
}
|
|
711
695
|
}
|
|
712
|
-
exports.ODCheckerStringStructure = ODCheckerStringStructure;
|
|
713
696
|
/**## ODCheckerNumberStructure `class`
|
|
714
697
|
* This is an Open Discord config checker structure.
|
|
715
698
|
*
|
|
716
699
|
* This class will check for a number variable in a config file, customise it in the settings!
|
|
717
700
|
*/
|
|
718
|
-
class ODCheckerNumberStructure extends ODCheckerStructure {
|
|
701
|
+
export class ODCheckerNumberStructure extends ODCheckerStructure {
|
|
719
702
|
constructor(id, options) {
|
|
720
703
|
super(id, options);
|
|
721
704
|
}
|
|
@@ -803,13 +786,12 @@ class ODCheckerNumberStructure extends ODCheckerStructure {
|
|
|
803
786
|
return super.check(checker, value, locationTrace);
|
|
804
787
|
}
|
|
805
788
|
}
|
|
806
|
-
exports.ODCheckerNumberStructure = ODCheckerNumberStructure;
|
|
807
789
|
/**## ODCheckerBooleanStructure `class`
|
|
808
790
|
* This is an Open Discord config checker structure.
|
|
809
791
|
*
|
|
810
792
|
* This class will check for a boolean variable in a config file, customise it in the settings!
|
|
811
793
|
*/
|
|
812
|
-
class ODCheckerBooleanStructure extends ODCheckerStructure {
|
|
794
|
+
export class ODCheckerBooleanStructure extends ODCheckerStructure {
|
|
813
795
|
constructor(id, options) {
|
|
814
796
|
super(id, options);
|
|
815
797
|
}
|
|
@@ -832,13 +814,12 @@ class ODCheckerBooleanStructure extends ODCheckerStructure {
|
|
|
832
814
|
return super.check(checker, value, locationTrace);
|
|
833
815
|
}
|
|
834
816
|
}
|
|
835
|
-
exports.ODCheckerBooleanStructure = ODCheckerBooleanStructure;
|
|
836
817
|
/**## ODCheckerArrayStructure `class`
|
|
837
818
|
* This is an Open Discord config checker structure.
|
|
838
819
|
*
|
|
839
820
|
* This class will check for an array variable in a config file, customise it in the settings!
|
|
840
821
|
*/
|
|
841
|
-
class ODCheckerArrayStructure extends ODCheckerStructure {
|
|
822
|
+
export class ODCheckerArrayStructure extends ODCheckerStructure {
|
|
842
823
|
constructor(id, options) {
|
|
843
824
|
super(id, options);
|
|
844
825
|
}
|
|
@@ -940,13 +921,12 @@ class ODCheckerArrayStructure extends ODCheckerStructure {
|
|
|
940
921
|
return hasDoubles;
|
|
941
922
|
}
|
|
942
923
|
}
|
|
943
|
-
exports.ODCheckerArrayStructure = ODCheckerArrayStructure;
|
|
944
924
|
/**## ODCheckerNullStructure `class`
|
|
945
925
|
* This is an Open Discord config checker structure.
|
|
946
926
|
*
|
|
947
927
|
* This class will check for a null variable in a config file, customise it in the settings!
|
|
948
928
|
*/
|
|
949
|
-
class ODCheckerNullStructure extends ODCheckerStructure {
|
|
929
|
+
export class ODCheckerNullStructure extends ODCheckerStructure {
|
|
950
930
|
constructor(id, options) {
|
|
951
931
|
super(id, options);
|
|
952
932
|
}
|
|
@@ -965,13 +945,12 @@ class ODCheckerNullStructure extends ODCheckerStructure {
|
|
|
965
945
|
return super.check(checker, value, locationTrace);
|
|
966
946
|
}
|
|
967
947
|
}
|
|
968
|
-
exports.ODCheckerNullStructure = ODCheckerNullStructure;
|
|
969
948
|
/**## ODCheckerTypeSwitchStructure `class`
|
|
970
949
|
* This is an Open Discord config checker structure.
|
|
971
950
|
*
|
|
972
951
|
* This class will switch checkers based on the type of the variable in a config file, customise it in the settings!
|
|
973
952
|
*/
|
|
974
|
-
class ODCheckerTypeSwitchStructure extends ODCheckerStructure {
|
|
953
|
+
export class ODCheckerTypeSwitchStructure extends ODCheckerStructure {
|
|
975
954
|
constructor(id, options) {
|
|
976
955
|
super(id, options);
|
|
977
956
|
}
|
|
@@ -1009,13 +988,12 @@ class ODCheckerTypeSwitchStructure extends ODCheckerStructure {
|
|
|
1009
988
|
return super.check(checker, value, locationTrace);
|
|
1010
989
|
}
|
|
1011
990
|
}
|
|
1012
|
-
exports.ODCheckerTypeSwitchStructure = ODCheckerTypeSwitchStructure;
|
|
1013
991
|
/**## ODCheckerObjectSwitchStructure `class`
|
|
1014
992
|
* This is an Open Discord config checker structure.
|
|
1015
993
|
*
|
|
1016
994
|
* This class will switch object checkers based on a variable match in one of the objects, customise it in the settings!
|
|
1017
995
|
*/
|
|
1018
|
-
class ODCheckerObjectSwitchStructure extends ODCheckerStructure {
|
|
996
|
+
export class ODCheckerObjectSwitchStructure extends ODCheckerStructure {
|
|
1019
997
|
constructor(id, options) {
|
|
1020
998
|
super(id, options);
|
|
1021
999
|
}
|
|
@@ -1061,13 +1039,12 @@ class ODCheckerObjectSwitchStructure extends ODCheckerStructure {
|
|
|
1061
1039
|
return super.check(checker, value, locationTrace);
|
|
1062
1040
|
}
|
|
1063
1041
|
}
|
|
1064
|
-
exports.ODCheckerObjectSwitchStructure = ODCheckerObjectSwitchStructure;
|
|
1065
1042
|
/**## ODCheckerEnabledObjectStructure `class`
|
|
1066
1043
|
* This is an Open Discord config checker structure.
|
|
1067
1044
|
*
|
|
1068
1045
|
* This class will enable an object checker based on a variable match in the object, customise it in the settings!
|
|
1069
1046
|
*/
|
|
1070
|
-
class ODCheckerEnabledObjectStructure extends ODCheckerStructure {
|
|
1047
|
+
export class ODCheckerEnabledObjectStructure extends ODCheckerStructure {
|
|
1071
1048
|
constructor(id, options) {
|
|
1072
1049
|
super(id, options);
|
|
1073
1050
|
}
|
|
@@ -1098,7 +1075,6 @@ class ODCheckerEnabledObjectStructure extends ODCheckerStructure {
|
|
|
1098
1075
|
}
|
|
1099
1076
|
}
|
|
1100
1077
|
}
|
|
1101
|
-
exports.ODCheckerEnabledObjectStructure = ODCheckerEnabledObjectStructure;
|
|
1102
1078
|
/**## ODCheckerCustomStructure_DiscordId `class`
|
|
1103
1079
|
* This is an Open Discord custom checker structure.
|
|
1104
1080
|
*
|
|
@@ -1107,7 +1083,7 @@ exports.ODCheckerEnabledObjectStructure = ODCheckerEnabledObjectStructure;
|
|
|
1107
1083
|
*
|
|
1108
1084
|
* **This custom checker is made for discord ids (channel, user, role, ...)**
|
|
1109
1085
|
*/
|
|
1110
|
-
class ODCheckerCustomStructure_DiscordId extends ODCheckerStringStructure {
|
|
1086
|
+
export class ODCheckerCustomStructure_DiscordId extends ODCheckerStringStructure {
|
|
1111
1087
|
/**The type of id (used in rendering) */
|
|
1112
1088
|
type;
|
|
1113
1089
|
/**Is this id allowed to be empty */
|
|
@@ -1141,7 +1117,6 @@ class ODCheckerCustomStructure_DiscordId extends ODCheckerStringStructure {
|
|
|
1141
1117
|
this.extraOptions = extraOptions;
|
|
1142
1118
|
}
|
|
1143
1119
|
}
|
|
1144
|
-
exports.ODCheckerCustomStructure_DiscordId = ODCheckerCustomStructure_DiscordId;
|
|
1145
1120
|
/**## ODCheckerCustomStructure_DiscordIdArray `class`
|
|
1146
1121
|
* This is an Open Discord custom checker structure.
|
|
1147
1122
|
*
|
|
@@ -1150,7 +1125,7 @@ exports.ODCheckerCustomStructure_DiscordId = ODCheckerCustomStructure_DiscordId;
|
|
|
1150
1125
|
*
|
|
1151
1126
|
* **This custom checker is made for discord id arrays (channel, user, role, ...)**
|
|
1152
1127
|
*/
|
|
1153
|
-
class ODCheckerCustomStructure_DiscordIdArray extends ODCheckerArrayStructure {
|
|
1128
|
+
export class ODCheckerCustomStructure_DiscordIdArray extends ODCheckerArrayStructure {
|
|
1154
1129
|
/**The type of id (used in rendering) */
|
|
1155
1130
|
type;
|
|
1156
1131
|
/**Extra matches (value will also be valid when one of these options match) */
|
|
@@ -1164,7 +1139,6 @@ class ODCheckerCustomStructure_DiscordIdArray extends ODCheckerArrayStructure {
|
|
|
1164
1139
|
this.extraOptions = extraOptions;
|
|
1165
1140
|
}
|
|
1166
1141
|
}
|
|
1167
|
-
exports.ODCheckerCustomStructure_DiscordIdArray = ODCheckerCustomStructure_DiscordIdArray;
|
|
1168
1142
|
/**## ODCheckerCustomStructure_DiscordToken `class`
|
|
1169
1143
|
* This is an Open Discord custom checker structure.
|
|
1170
1144
|
*
|
|
@@ -1173,7 +1147,7 @@ exports.ODCheckerCustomStructure_DiscordIdArray = ODCheckerCustomStructure_Disco
|
|
|
1173
1147
|
*
|
|
1174
1148
|
* **This custom checker is made for a discord (auth) token**
|
|
1175
1149
|
*/
|
|
1176
|
-
class ODCheckerCustomStructure_DiscordToken extends ODCheckerStringStructure {
|
|
1150
|
+
export class ODCheckerCustomStructure_DiscordToken extends ODCheckerStringStructure {
|
|
1177
1151
|
constructor(id, options) {
|
|
1178
1152
|
//add premade custom structure checker
|
|
1179
1153
|
const newOptions = options ?? {};
|
|
@@ -1188,7 +1162,6 @@ class ODCheckerCustomStructure_DiscordToken extends ODCheckerStringStructure {
|
|
|
1188
1162
|
super(id, newOptions);
|
|
1189
1163
|
}
|
|
1190
1164
|
}
|
|
1191
|
-
exports.ODCheckerCustomStructure_DiscordToken = ODCheckerCustomStructure_DiscordToken;
|
|
1192
1165
|
/**## ODCheckerCustomStructure_DiscordToken `class`
|
|
1193
1166
|
* This is an Open Discord custom checker structure.
|
|
1194
1167
|
*
|
|
@@ -1197,7 +1170,7 @@ exports.ODCheckerCustomStructure_DiscordToken = ODCheckerCustomStructure_Discord
|
|
|
1197
1170
|
*
|
|
1198
1171
|
* **This custom checker is made for a hex color**
|
|
1199
1172
|
*/
|
|
1200
|
-
class ODCheckerCustomStructure_HexColor extends ODCheckerStringStructure {
|
|
1173
|
+
export class ODCheckerCustomStructure_HexColor extends ODCheckerStringStructure {
|
|
1201
1174
|
/**When enabled, you are also allowed to use `#fff` instead of `#ffffff` */
|
|
1202
1175
|
allowShortForm;
|
|
1203
1176
|
/**Allow this hex color to be empty. */
|
|
@@ -1224,7 +1197,6 @@ class ODCheckerCustomStructure_HexColor extends ODCheckerStringStructure {
|
|
|
1224
1197
|
this.emptyAllowed = emptyAllowed;
|
|
1225
1198
|
}
|
|
1226
1199
|
}
|
|
1227
|
-
exports.ODCheckerCustomStructure_HexColor = ODCheckerCustomStructure_HexColor;
|
|
1228
1200
|
/**## ODCheckerCustomStructure_EmojiString `class`
|
|
1229
1201
|
* This is an Open Discord custom checker structure.
|
|
1230
1202
|
*
|
|
@@ -1233,7 +1205,7 @@ exports.ODCheckerCustomStructure_HexColor = ODCheckerCustomStructure_HexColor;
|
|
|
1233
1205
|
*
|
|
1234
1206
|
* **This custom checker is made for an emoji (string)**
|
|
1235
1207
|
*/
|
|
1236
|
-
class ODCheckerCustomStructure_EmojiString extends ODCheckerStringStructure {
|
|
1208
|
+
export class ODCheckerCustomStructure_EmojiString extends ODCheckerStringStructure {
|
|
1237
1209
|
/**The minimum amount of emojis required (0 to allow empty) */
|
|
1238
1210
|
minLength;
|
|
1239
1211
|
/**The maximum amount of emojis allowed */
|
|
@@ -1276,7 +1248,6 @@ class ODCheckerCustomStructure_EmojiString extends ODCheckerStringStructure {
|
|
|
1276
1248
|
this.allowCustomDiscordEmoji = allowCustomDiscordEmoji;
|
|
1277
1249
|
}
|
|
1278
1250
|
}
|
|
1279
|
-
exports.ODCheckerCustomStructure_EmojiString = ODCheckerCustomStructure_EmojiString;
|
|
1280
1251
|
/**## ODCheckerCustomStructure_UrlString `class`
|
|
1281
1252
|
* This is an Open Discord custom checker structure.
|
|
1282
1253
|
*
|
|
@@ -1285,7 +1256,7 @@ exports.ODCheckerCustomStructure_EmojiString = ODCheckerCustomStructure_EmojiStr
|
|
|
1285
1256
|
*
|
|
1286
1257
|
* **This custom checker is made for a URL (string)**
|
|
1287
1258
|
*/
|
|
1288
|
-
class ODCheckerCustomStructure_UrlString extends ODCheckerStringStructure {
|
|
1259
|
+
export class ODCheckerCustomStructure_UrlString extends ODCheckerStringStructure {
|
|
1289
1260
|
/**The settings for this url */
|
|
1290
1261
|
urlSettings;
|
|
1291
1262
|
/**Is this url allowed to be empty? */
|
|
@@ -1392,7 +1363,6 @@ class ODCheckerCustomStructure_UrlString extends ODCheckerStringStructure {
|
|
|
1392
1363
|
}
|
|
1393
1364
|
}
|
|
1394
1365
|
}
|
|
1395
|
-
exports.ODCheckerCustomStructure_UrlString = ODCheckerCustomStructure_UrlString;
|
|
1396
1366
|
/**## ODCheckerCustomStructure_UniqueId `class`
|
|
1397
1367
|
* This is an Open Discord custom checker structure.
|
|
1398
1368
|
*
|
|
@@ -1401,7 +1371,7 @@ exports.ODCheckerCustomStructure_UrlString = ODCheckerCustomStructure_UrlString;
|
|
|
1401
1371
|
*
|
|
1402
1372
|
* **This custom checker is made for a unique id (per source & scope)**
|
|
1403
1373
|
*/
|
|
1404
|
-
class ODCheckerCustomStructure_UniqueId extends ODCheckerStringStructure {
|
|
1374
|
+
export class ODCheckerCustomStructure_UniqueId extends ODCheckerStringStructure {
|
|
1405
1375
|
/**The source of this unique id (generally the plugin name or `opendiscord`) */
|
|
1406
1376
|
source;
|
|
1407
1377
|
/**The scope of this unique id (id needs to be unique in this scope) */
|
|
@@ -1431,7 +1401,6 @@ class ODCheckerCustomStructure_UniqueId extends ODCheckerStringStructure {
|
|
|
1431
1401
|
this.scope = scope;
|
|
1432
1402
|
}
|
|
1433
1403
|
}
|
|
1434
|
-
exports.ODCheckerCustomStructure_UniqueId = ODCheckerCustomStructure_UniqueId;
|
|
1435
1404
|
/**## ODCheckerCustomStructure_UniqueIdArray `class`
|
|
1436
1405
|
* This is an Open Discord custom checker structure.
|
|
1437
1406
|
*
|
|
@@ -1440,7 +1409,7 @@ exports.ODCheckerCustomStructure_UniqueId = ODCheckerCustomStructure_UniqueId;
|
|
|
1440
1409
|
*
|
|
1441
1410
|
* **This custom checker is made for a unique id array (per source & scope)**
|
|
1442
1411
|
*/
|
|
1443
|
-
class ODCheckerCustomStructure_UniqueIdArray extends ODCheckerArrayStructure {
|
|
1412
|
+
export class ODCheckerCustomStructure_UniqueIdArray extends ODCheckerArrayStructure {
|
|
1444
1413
|
/**The source to read unique ids (generally the plugin name or `opendiscord`) */
|
|
1445
1414
|
source;
|
|
1446
1415
|
/**The scope to read unique ids (id needs to be unique in this scope) */
|
|
@@ -1477,7 +1446,6 @@ class ODCheckerCustomStructure_UniqueIdArray extends ODCheckerArrayStructure {
|
|
|
1477
1446
|
this.usedScope = usedScope ?? null;
|
|
1478
1447
|
}
|
|
1479
1448
|
}
|
|
1480
|
-
exports.ODCheckerCustomStructure_UniqueIdArray = ODCheckerCustomStructure_UniqueIdArray;
|
|
1481
1449
|
/*TEMPLATE!!!!
|
|
1482
1450
|
export interface ODCheckerTemplateStructureOptions extends ODCheckerStructureOptions {
|
|
1483
1451
|
|
|
@@ -1,8 +1,8 @@
|
|
|
1
|
-
import { ODManager, ODManagerData, ODNoGeneric, ODValidId } from "./base";
|
|
1
|
+
import { ODManager, ODManagerData, ODNoGeneric, ODValidId } from "./base.js";
|
|
2
2
|
import * as discord from "discord.js";
|
|
3
|
-
import { ODDebugger } from "./console";
|
|
4
|
-
import { ODMessageBuildResult, ODMessageBuildSentResult } from "./builder";
|
|
5
|
-
import { ODManualProgressBar } from "./progressbar";
|
|
3
|
+
import { ODDebugger } from "./console.js";
|
|
4
|
+
import { ODMessageBuildResult, ODMessageBuildSentResult } from "./builder.js";
|
|
5
|
+
import { ODManualProgressBar } from "./progressbar.js";
|
|
6
6
|
/**## ODClientIntents `type`
|
|
7
7
|
* A list of intents required when inviting the bot.
|
|
8
8
|
*/
|