UNPKG

1.45 kBJavaScriptView Raw
1"use strict";
2Object.defineProperty(exports, "__esModule", { value: true });
3var Constants;
4(function (Constants) {
5 Constants.SUCCESS_EMOJI = '🆗';
6 Constants.FAIL_EMOJI = '❌';
7 Constants.WARNING_EMOJI = '⚠';
8 Constants.DELETE_EMOJI = '🗑';
9 Constants.COMMAND_PREFIX = '*';
10 Constants.ARGUMENT_REGEX = /[^'"\s]+|(?:["'])([^'"]+)(?:["'])/g;
11 Constants.BOT_ICON = "https://assets.dynastic.co/brand/img/icon-64.png";
12 Constants.BOT_AUTHOR = "Dynastic";
13 Constants.TEMP_DIR = "/tmp/bot-downloads";
14 Constants.COLORS = {
15 DANGER: 0xff895e
16 };
17 let ErrorFormat;
18 (function (ErrorFormat) {
19 ErrorFormat[ErrorFormat["EMBED"] = 0] = "EMBED";
20 ErrorFormat[ErrorFormat["TEXT"] = 1] = "TEXT";
21 })(ErrorFormat = Constants.ErrorFormat || (Constants.ErrorFormat = {}));
22 Constants.ERROR_RENDER_FORMAT = ErrorFormat.EMBED;
23 Constants.ROLES = { moderator: [], admin: [], root: [] };
24 Constants.ERROR_PREFIX = "**Uh oh!**";
25 /**
26 * Applies patches to BotKit constants
27 * @param patches the patches to apply
28 */
29 function applyPatches(patches) {
30 let script = "";
31 for (let key in patches) {
32 script += `Constants.${key} = patches.${key} || Constants.${key};`;
33 }
34 eval(script);
35 }
36 Constants.applyPatches = applyPatches;
37})(Constants || (Constants = {}));
38exports.default = Constants;
39//# sourceMappingURL=Constants.js.map
\No newline at end of file