necord 5.4.2 → 5.4.3
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/commands/command.discovery.d.ts +8 -8
- package/dist/commands/command.discovery.js +13 -13
- package/dist/commands/commands.service.d.ts +15 -15
- package/dist/commands/commands.service.js +80 -80
- package/dist/commands/context-menus/context-menu.discovery.d.ts +11 -11
- package/dist/commands/context-menus/context-menu.discovery.js +19 -19
- package/dist/commands/context-menus/context-menus.service.d.ts +16 -16
- package/dist/commands/context-menus/context-menus.service.js +52 -52
- package/dist/commands/context-menus/decorators/context-menu.decorator.d.ts +2 -2
- package/dist/commands/context-menus/decorators/context-menu.decorator.js +8 -8
- package/dist/commands/context-menus/decorators/index.d.ts +4 -4
- package/dist/commands/context-menus/decorators/index.js +20 -20
- package/dist/commands/context-menus/decorators/message-command.decorator.d.ts +2 -2
- package/dist/commands/context-menus/decorators/message-command.decorator.js +7 -7
- package/dist/commands/context-menus/decorators/target.decorator.d.ts +7 -7
- package/dist/commands/context-menus/decorators/target.decorator.js +38 -38
- package/dist/commands/context-menus/decorators/user-command.decorator.d.ts +2 -2
- package/dist/commands/context-menus/decorators/user-command.decorator.js +7 -7
- package/dist/commands/context-menus/index.d.ts +3 -3
- package/dist/commands/context-menus/index.js +19 -19
- package/dist/commands/index.d.ts +4 -4
- package/dist/commands/index.js +20 -20
- package/dist/commands/slash-commands/autocomplete/autocomplete.interceptor.d.ts +7 -7
- package/dist/commands/slash-commands/autocomplete/autocomplete.interceptor.js +39 -39
- package/dist/commands/slash-commands/autocomplete/index.d.ts +1 -1
- package/dist/commands/slash-commands/autocomplete/index.js +17 -17
- package/dist/commands/slash-commands/decorators/index.d.ts +3 -3
- package/dist/commands/slash-commands/decorators/index.js +19 -19
- package/dist/commands/slash-commands/decorators/slash-command.decorator.d.ts +2 -2
- package/dist/commands/slash-commands/decorators/slash-command.decorator.js +9 -9
- package/dist/commands/slash-commands/decorators/subcommand-group.decorator.d.ts +2 -2
- package/dist/commands/slash-commands/decorators/subcommand-group.decorator.js +18 -18
- package/dist/commands/slash-commands/decorators/subcommand.decorator.d.ts +2 -2
- package/dist/commands/slash-commands/decorators/subcommand.decorator.js +9 -9
- package/dist/commands/slash-commands/index.d.ts +5 -5
- package/dist/commands/slash-commands/index.js +21 -21
- package/dist/commands/slash-commands/options/attachment-option.decorator.d.ts +7 -7
- package/dist/commands/slash-commands/options/attachment-option.decorator.js +6 -6
- package/dist/commands/slash-commands/options/boolean-option.decorator.d.ts +7 -7
- package/dist/commands/slash-commands/options/boolean-option.decorator.js +6 -6
- package/dist/commands/slash-commands/options/channel-option.decorator.d.ts +8 -8
- package/dist/commands/slash-commands/options/channel-option.decorator.js +6 -6
- package/dist/commands/slash-commands/options/index.d.ts +11 -11
- package/dist/commands/slash-commands/options/index.js +27 -27
- package/dist/commands/slash-commands/options/integer-option.decorator.d.ts +20 -20
- package/dist/commands/slash-commands/options/integer-option.decorator.js +6 -6
- package/dist/commands/slash-commands/options/member-option.decorator.d.ts +7 -7
- package/dist/commands/slash-commands/options/member-option.decorator.js +6 -6
- package/dist/commands/slash-commands/options/mentionable-option.decorator.d.ts +7 -7
- package/dist/commands/slash-commands/options/mentionable-option.decorator.js +6 -6
- package/dist/commands/slash-commands/options/number-option.decorator.d.ts +20 -20
- package/dist/commands/slash-commands/options/number-option.decorator.js +6 -6
- package/dist/commands/slash-commands/options/option.util.d.ts +5 -5
- package/dist/commands/slash-commands/options/option.util.js +21 -21
- package/dist/commands/slash-commands/options/options.decorator.d.ts +2 -2
- package/dist/commands/slash-commands/options/options.decorator.js +32 -32
- package/dist/commands/slash-commands/options/role-option.decorator.d.ts +7 -7
- package/dist/commands/slash-commands/options/role-option.decorator.js +6 -6
- package/dist/commands/slash-commands/options/string-option.decorator.d.ts +20 -20
- package/dist/commands/slash-commands/options/string-option.decorator.js +6 -6
- package/dist/commands/slash-commands/options/user-option.decorator.d.ts +7 -7
- package/dist/commands/slash-commands/options/user-option.decorator.js +6 -6
- package/dist/commands/slash-commands/slash-command.discovery.d.ts +20 -20
- package/dist/commands/slash-commands/slash-command.discovery.js +44 -44
- package/dist/commands/slash-commands/slash-commands.service.d.ts +19 -19
- package/dist/commands/slash-commands/slash-commands.service.js +84 -84
- package/dist/context/decorators/context.decorator.d.ts +2 -2
- package/dist/context/decorators/context.decorator.js +7 -7
- package/dist/context/decorators/discovery.decorator.d.ts +1 -1
- package/dist/context/decorators/discovery.decorator.js +6 -6
- package/dist/context/decorators/index.d.ts +2 -2
- package/dist/context/decorators/index.js +18 -18
- package/dist/context/decorators/params.util.d.ts +3 -3
- package/dist/context/decorators/params.util.js +12 -12
- package/dist/context/index.d.ts +7 -7
- package/dist/context/index.js +23 -23
- package/dist/context/necord-arguments-host.d.ts +13 -13
- package/dist/context/necord-arguments-host.js +22 -22
- package/dist/context/necord-base.discovery.d.ts +30 -30
- package/dist/context/necord-base.discovery.js +47 -47
- package/dist/context/necord-context.interface.d.ts +22 -22
- package/dist/context/necord-context.interface.js +2 -2
- package/dist/context/necord-execution-context.d.ts +6 -6
- package/dist/context/necord-execution-context.js +13 -13
- package/dist/context/necord-params.factory.d.ts +6 -6
- package/dist/context/necord-params.factory.js +19 -19
- package/dist/context/necord-paramtype.enum.d.ts +4 -4
- package/dist/context/necord-paramtype.enum.js +8 -8
- package/dist/index.d.ts +9 -9
- package/dist/index.js +25 -25
- package/dist/listeners/decorators/index.d.ts +3 -3
- package/dist/listeners/decorators/index.js +19 -19
- package/dist/listeners/decorators/listener.decorator.d.ts +2 -2
- package/dist/listeners/decorators/listener.decorator.js +8 -8
- package/dist/listeners/decorators/on.decorator.d.ts +2 -2
- package/dist/listeners/decorators/on.decorator.js +6 -6
- package/dist/listeners/decorators/once.decorator.d.ts +2 -2
- package/dist/listeners/decorators/once.decorator.js +6 -6
- package/dist/listeners/index.d.ts +3 -3
- package/dist/listeners/index.js +19 -19
- package/dist/listeners/listener.discovery.d.ts +11 -11
- package/dist/listeners/listener.discovery.js +19 -19
- package/dist/listeners/listener.interface.d.ts +90 -90
- package/dist/listeners/listener.interface.js +2 -2
- package/dist/listeners/listeners.service.d.ts +22 -22
- package/dist/listeners/listeners.service.js +237 -237
- package/dist/message-components/decorators/button.decorator.d.ts +1 -1
- package/dist/message-components/decorators/button.decorator.js +7 -7
- package/dist/message-components/decorators/component-param.decorator.d.ts +1 -1
- package/dist/message-components/decorators/component-param.decorator.js +17 -17
- package/dist/message-components/decorators/index.d.ts +6 -6
- package/dist/message-components/decorators/index.js +22 -22
- package/dist/message-components/decorators/message-component.decorator.d.ts +2 -2
- package/dist/message-components/decorators/message-component.decorator.js +8 -8
- package/dist/message-components/decorators/select-menu.decorator.d.ts +12 -12
- package/dist/message-components/decorators/select-menu.decorator.js +23 -23
- package/dist/message-components/decorators/selected.decorator.d.ts +10 -10
- package/dist/message-components/decorators/selected.decorator.js +40 -39
- package/dist/message-components/decorators/values.decorator.d.ts +7 -7
- package/dist/message-components/decorators/values.decorator.js +17 -17
- package/dist/message-components/index.d.ts +3 -3
- package/dist/message-components/index.js +19 -19
- package/dist/message-components/message-component.discovery.d.ts +14 -14
- package/dist/message-components/message-component.discovery.js +27 -27
- package/dist/message-components/message-components.service.d.ts +15 -15
- package/dist/message-components/message-components.service.js +55 -55
- package/dist/modals/decorators/fields.decorator.d.ts +1 -1
- package/dist/modals/decorators/fields.decorator.js +14 -14
- package/dist/modals/decorators/index.d.ts +3 -3
- package/dist/modals/decorators/index.js +19 -19
- package/dist/modals/decorators/modal-param.decorator.d.ts +1 -1
- package/dist/modals/decorators/modal-param.decorator.js +17 -17
- package/dist/modals/decorators/modal.decorator.d.ts +1 -1
- package/dist/modals/decorators/modal.decorator.js +8 -8
- package/dist/modals/index.d.ts +3 -3
- package/dist/modals/index.js +19 -19
- package/dist/modals/modal.discovery.d.ts +12 -12
- package/dist/modals/modal.discovery.js +24 -24
- package/dist/modals/modals.service.d.ts +14 -14
- package/dist/modals/modals.service.js +50 -50
- package/dist/necord-client.provider.d.ts +3 -3
- package/dist/necord-client.provider.js +10 -10
- package/dist/necord-explorer.service.d.ts +15 -15
- package/dist/necord-explorer.service.js +59 -59
- package/dist/necord-options.interface.d.ts +17 -17
- package/dist/necord-options.interface.js +2 -2
- package/dist/necord.constants.d.ts +11 -11
- package/dist/necord.constants.js +14 -14
- package/dist/necord.module.d.ts +14 -14
- package/dist/necord.module.js +123 -123
- package/dist/text-commands/decorators/arguments.decorator.d.ts +2 -2
- package/dist/text-commands/decorators/arguments.decorator.js +14 -14
- package/dist/text-commands/decorators/index.d.ts +2 -2
- package/dist/text-commands/decorators/index.js +18 -18
- package/dist/text-commands/decorators/text-command.decorator.d.ts +2 -2
- package/dist/text-commands/decorators/text-command.decorator.js +8 -8
- package/dist/text-commands/index.d.ts +3 -3
- package/dist/text-commands/index.js +19 -19
- package/dist/text-commands/text-command.discovery.d.ts +11 -11
- package/dist/text-commands/text-command.discovery.js +19 -19
- package/dist/text-commands/text-commands.service.d.ts +16 -16
- package/dist/text-commands/text-commands.service.js +72 -72
- package/package.json +8 -8
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import { ContextMenuMeta } from '../context-menu.discovery';
|
|
2
|
-
export declare const UserCommand: (options: Omit<ContextMenuMeta, 'type'>) => import("@nestjs/common").CustomDecorator<string>;
|
|
1
|
+
import { ContextMenuMeta } from '../context-menu.discovery';
|
|
2
|
+
export declare const UserCommand: (options: Omit<ContextMenuMeta, 'type'>) => import("@nestjs/common").CustomDecorator<string>;
|
|
@@ -1,7 +1,7 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
-
exports.UserCommand = void 0;
|
|
4
|
-
const discord_js_1 = require("discord.js");
|
|
5
|
-
const context_menu_decorator_1 = require("./context-menu.decorator");
|
|
6
|
-
const UserCommand = (options) => (0, context_menu_decorator_1.ContextMenu)(Object.assign({ type: discord_js_1.ApplicationCommandType.User }, options));
|
|
7
|
-
exports.UserCommand = UserCommand;
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.UserCommand = void 0;
|
|
4
|
+
const discord_js_1 = require("discord.js");
|
|
5
|
+
const context_menu_decorator_1 = require("./context-menu.decorator");
|
|
6
|
+
const UserCommand = (options) => (0, context_menu_decorator_1.ContextMenu)(Object.assign({ type: discord_js_1.ApplicationCommandType.User }, options));
|
|
7
|
+
exports.UserCommand = UserCommand;
|
|
@@ -1,3 +1,3 @@
|
|
|
1
|
-
export * from './decorators';
|
|
2
|
-
export * from './context-menu.discovery';
|
|
3
|
-
export * from './context-menus.service';
|
|
1
|
+
export * from './decorators';
|
|
2
|
+
export * from './context-menu.discovery';
|
|
3
|
+
export * from './context-menus.service';
|
|
@@ -1,19 +1,19 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
|
|
3
|
-
if (k2 === undefined) k2 = k;
|
|
4
|
-
var desc = Object.getOwnPropertyDescriptor(m, k);
|
|
5
|
-
if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
|
|
6
|
-
desc = { enumerable: true, get: function() { return m[k]; } };
|
|
7
|
-
}
|
|
8
|
-
Object.defineProperty(o, k2, desc);
|
|
9
|
-
}) : (function(o, m, k, k2) {
|
|
10
|
-
if (k2 === undefined) k2 = k;
|
|
11
|
-
o[k2] = m[k];
|
|
12
|
-
}));
|
|
13
|
-
var __exportStar = (this && this.__exportStar) || function(m, exports) {
|
|
14
|
-
for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p);
|
|
15
|
-
};
|
|
16
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
17
|
-
__exportStar(require("./decorators"), exports);
|
|
18
|
-
__exportStar(require("./context-menu.discovery"), exports);
|
|
19
|
-
__exportStar(require("./context-menus.service"), exports);
|
|
1
|
+
"use strict";
|
|
2
|
+
var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
|
|
3
|
+
if (k2 === undefined) k2 = k;
|
|
4
|
+
var desc = Object.getOwnPropertyDescriptor(m, k);
|
|
5
|
+
if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
|
|
6
|
+
desc = { enumerable: true, get: function() { return m[k]; } };
|
|
7
|
+
}
|
|
8
|
+
Object.defineProperty(o, k2, desc);
|
|
9
|
+
}) : (function(o, m, k, k2) {
|
|
10
|
+
if (k2 === undefined) k2 = k;
|
|
11
|
+
o[k2] = m[k];
|
|
12
|
+
}));
|
|
13
|
+
var __exportStar = (this && this.__exportStar) || function(m, exports) {
|
|
14
|
+
for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p);
|
|
15
|
+
};
|
|
16
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
17
|
+
__exportStar(require("./decorators"), exports);
|
|
18
|
+
__exportStar(require("./context-menu.discovery"), exports);
|
|
19
|
+
__exportStar(require("./context-menus.service"), exports);
|
package/dist/commands/index.d.ts
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
export * from './context-menus';
|
|
2
|
-
export * from './slash-commands';
|
|
3
|
-
export * from './command.discovery';
|
|
4
|
-
export * from './commands.service';
|
|
1
|
+
export * from './context-menus';
|
|
2
|
+
export * from './slash-commands';
|
|
3
|
+
export * from './command.discovery';
|
|
4
|
+
export * from './commands.service';
|
package/dist/commands/index.js
CHANGED
|
@@ -1,20 +1,20 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
|
|
3
|
-
if (k2 === undefined) k2 = k;
|
|
4
|
-
var desc = Object.getOwnPropertyDescriptor(m, k);
|
|
5
|
-
if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
|
|
6
|
-
desc = { enumerable: true, get: function() { return m[k]; } };
|
|
7
|
-
}
|
|
8
|
-
Object.defineProperty(o, k2, desc);
|
|
9
|
-
}) : (function(o, m, k, k2) {
|
|
10
|
-
if (k2 === undefined) k2 = k;
|
|
11
|
-
o[k2] = m[k];
|
|
12
|
-
}));
|
|
13
|
-
var __exportStar = (this && this.__exportStar) || function(m, exports) {
|
|
14
|
-
for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p);
|
|
15
|
-
};
|
|
16
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
17
|
-
__exportStar(require("./context-menus"), exports);
|
|
18
|
-
__exportStar(require("./slash-commands"), exports);
|
|
19
|
-
__exportStar(require("./command.discovery"), exports);
|
|
20
|
-
__exportStar(require("./commands.service"), exports);
|
|
1
|
+
"use strict";
|
|
2
|
+
var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
|
|
3
|
+
if (k2 === undefined) k2 = k;
|
|
4
|
+
var desc = Object.getOwnPropertyDescriptor(m, k);
|
|
5
|
+
if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
|
|
6
|
+
desc = { enumerable: true, get: function() { return m[k]; } };
|
|
7
|
+
}
|
|
8
|
+
Object.defineProperty(o, k2, desc);
|
|
9
|
+
}) : (function(o, m, k, k2) {
|
|
10
|
+
if (k2 === undefined) k2 = k;
|
|
11
|
+
o[k2] = m[k];
|
|
12
|
+
}));
|
|
13
|
+
var __exportStar = (this && this.__exportStar) || function(m, exports) {
|
|
14
|
+
for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p);
|
|
15
|
+
};
|
|
16
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
17
|
+
__exportStar(require("./context-menus"), exports);
|
|
18
|
+
__exportStar(require("./slash-commands"), exports);
|
|
19
|
+
__exportStar(require("./command.discovery"), exports);
|
|
20
|
+
__exportStar(require("./commands.service"), exports);
|
|
@@ -1,7 +1,7 @@
|
|
|
1
|
-
import { CallHandler, ExecutionContext, NestInterceptor } from '@nestjs/common';
|
|
2
|
-
import { Observable } from 'rxjs';
|
|
3
|
-
import { AutocompleteInteraction } from 'discord.js';
|
|
4
|
-
export declare abstract class AutocompleteInterceptor implements NestInterceptor {
|
|
5
|
-
abstract transformOptions(interaction: AutocompleteInteraction): void | Promise<void>;
|
|
6
|
-
intercept(context: ExecutionContext, next: CallHandler<any>): Promise<Observable<any>>;
|
|
7
|
-
}
|
|
1
|
+
import { CallHandler, ExecutionContext, NestInterceptor } from '@nestjs/common';
|
|
2
|
+
import { Observable } from 'rxjs';
|
|
3
|
+
import { AutocompleteInteraction } from 'discord.js';
|
|
4
|
+
export declare abstract class AutocompleteInterceptor implements NestInterceptor {
|
|
5
|
+
abstract transformOptions(interaction: AutocompleteInteraction): void | Promise<void>;
|
|
6
|
+
intercept(context: ExecutionContext, next: CallHandler<any>): Promise<Observable<any>>;
|
|
7
|
+
}
|
|
@@ -1,39 +1,39 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
var __decorate = (this && this.__decorate) || function (decorators, target, key, desc) {
|
|
3
|
-
var c = arguments.length, r = c < 3 ? target : desc === null ? desc = Object.getOwnPropertyDescriptor(target, key) : desc, d;
|
|
4
|
-
if (typeof Reflect === "object" && typeof Reflect.decorate === "function") r = Reflect.decorate(decorators, target, key, desc);
|
|
5
|
-
else for (var i = decorators.length - 1; i >= 0; i--) if (d = decorators[i]) r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r;
|
|
6
|
-
return c > 3 && r && Object.defineProperty(target, key, r), r;
|
|
7
|
-
};
|
|
8
|
-
var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, generator) {
|
|
9
|
-
function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }
|
|
10
|
-
return new (P || (P = Promise))(function (resolve, reject) {
|
|
11
|
-
function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } }
|
|
12
|
-
function rejected(value) { try { step(generator["throw"](value)); } catch (e) { reject(e); } }
|
|
13
|
-
function step(result) { result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected); }
|
|
14
|
-
step((generator = generator.apply(thisArg, _arguments || [])).next());
|
|
15
|
-
});
|
|
16
|
-
};
|
|
17
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
18
|
-
exports.AutocompleteInterceptor = void 0;
|
|
19
|
-
const common_1 = require("@nestjs/common");
|
|
20
|
-
const rxjs_1 = require("rxjs");
|
|
21
|
-
const context_1 = require("../../../context");
|
|
22
|
-
const discord_js_1 = require("discord.js");
|
|
23
|
-
let AutocompleteInterceptor = class AutocompleteInterceptor {
|
|
24
|
-
intercept(context, next) {
|
|
25
|
-
return __awaiter(this, void 0, void 0, function* () {
|
|
26
|
-
const necordContext = context_1.NecordExecutionContext.create(context);
|
|
27
|
-
const [interaction] = necordContext.getContext();
|
|
28
|
-
const discovery = necordContext.getDiscovery();
|
|
29
|
-
if (interaction.type !== discord_js_1.InteractionType.ApplicationCommandAutocomplete ||
|
|
30
|
-
!discovery.isSlashCommand())
|
|
31
|
-
return next.handle();
|
|
32
|
-
return (0, rxjs_1.of)(this.transformOptions(interaction));
|
|
33
|
-
});
|
|
34
|
-
}
|
|
35
|
-
};
|
|
36
|
-
AutocompleteInterceptor = __decorate([
|
|
37
|
-
(0, common_1.Injectable)()
|
|
38
|
-
], AutocompleteInterceptor);
|
|
39
|
-
exports.AutocompleteInterceptor = AutocompleteInterceptor;
|
|
1
|
+
"use strict";
|
|
2
|
+
var __decorate = (this && this.__decorate) || function (decorators, target, key, desc) {
|
|
3
|
+
var c = arguments.length, r = c < 3 ? target : desc === null ? desc = Object.getOwnPropertyDescriptor(target, key) : desc, d;
|
|
4
|
+
if (typeof Reflect === "object" && typeof Reflect.decorate === "function") r = Reflect.decorate(decorators, target, key, desc);
|
|
5
|
+
else for (var i = decorators.length - 1; i >= 0; i--) if (d = decorators[i]) r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r;
|
|
6
|
+
return c > 3 && r && Object.defineProperty(target, key, r), r;
|
|
7
|
+
};
|
|
8
|
+
var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, generator) {
|
|
9
|
+
function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }
|
|
10
|
+
return new (P || (P = Promise))(function (resolve, reject) {
|
|
11
|
+
function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } }
|
|
12
|
+
function rejected(value) { try { step(generator["throw"](value)); } catch (e) { reject(e); } }
|
|
13
|
+
function step(result) { result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected); }
|
|
14
|
+
step((generator = generator.apply(thisArg, _arguments || [])).next());
|
|
15
|
+
});
|
|
16
|
+
};
|
|
17
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
18
|
+
exports.AutocompleteInterceptor = void 0;
|
|
19
|
+
const common_1 = require("@nestjs/common");
|
|
20
|
+
const rxjs_1 = require("rxjs");
|
|
21
|
+
const context_1 = require("../../../context");
|
|
22
|
+
const discord_js_1 = require("discord.js");
|
|
23
|
+
let AutocompleteInterceptor = class AutocompleteInterceptor {
|
|
24
|
+
intercept(context, next) {
|
|
25
|
+
return __awaiter(this, void 0, void 0, function* () {
|
|
26
|
+
const necordContext = context_1.NecordExecutionContext.create(context);
|
|
27
|
+
const [interaction] = necordContext.getContext();
|
|
28
|
+
const discovery = necordContext.getDiscovery();
|
|
29
|
+
if (interaction.type !== discord_js_1.InteractionType.ApplicationCommandAutocomplete ||
|
|
30
|
+
!discovery.isSlashCommand())
|
|
31
|
+
return next.handle();
|
|
32
|
+
return (0, rxjs_1.of)(this.transformOptions(interaction));
|
|
33
|
+
});
|
|
34
|
+
}
|
|
35
|
+
};
|
|
36
|
+
AutocompleteInterceptor = __decorate([
|
|
37
|
+
(0, common_1.Injectable)()
|
|
38
|
+
], AutocompleteInterceptor);
|
|
39
|
+
exports.AutocompleteInterceptor = AutocompleteInterceptor;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
export * from './autocomplete.interceptor';
|
|
1
|
+
export * from './autocomplete.interceptor';
|
|
@@ -1,17 +1,17 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
|
|
3
|
-
if (k2 === undefined) k2 = k;
|
|
4
|
-
var desc = Object.getOwnPropertyDescriptor(m, k);
|
|
5
|
-
if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
|
|
6
|
-
desc = { enumerable: true, get: function() { return m[k]; } };
|
|
7
|
-
}
|
|
8
|
-
Object.defineProperty(o, k2, desc);
|
|
9
|
-
}) : (function(o, m, k, k2) {
|
|
10
|
-
if (k2 === undefined) k2 = k;
|
|
11
|
-
o[k2] = m[k];
|
|
12
|
-
}));
|
|
13
|
-
var __exportStar = (this && this.__exportStar) || function(m, exports) {
|
|
14
|
-
for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p);
|
|
15
|
-
};
|
|
16
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
17
|
-
__exportStar(require("./autocomplete.interceptor"), exports);
|
|
1
|
+
"use strict";
|
|
2
|
+
var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
|
|
3
|
+
if (k2 === undefined) k2 = k;
|
|
4
|
+
var desc = Object.getOwnPropertyDescriptor(m, k);
|
|
5
|
+
if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
|
|
6
|
+
desc = { enumerable: true, get: function() { return m[k]; } };
|
|
7
|
+
}
|
|
8
|
+
Object.defineProperty(o, k2, desc);
|
|
9
|
+
}) : (function(o, m, k, k2) {
|
|
10
|
+
if (k2 === undefined) k2 = k;
|
|
11
|
+
o[k2] = m[k];
|
|
12
|
+
}));
|
|
13
|
+
var __exportStar = (this && this.__exportStar) || function(m, exports) {
|
|
14
|
+
for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p);
|
|
15
|
+
};
|
|
16
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
17
|
+
__exportStar(require("./autocomplete.interceptor"), exports);
|
|
@@ -1,3 +1,3 @@
|
|
|
1
|
-
export * from './slash-command.decorator';
|
|
2
|
-
export * from './subcommand.decorator';
|
|
3
|
-
export * from './subcommand-group.decorator';
|
|
1
|
+
export * from './slash-command.decorator';
|
|
2
|
+
export * from './subcommand.decorator';
|
|
3
|
+
export * from './subcommand-group.decorator';
|
|
@@ -1,19 +1,19 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
|
|
3
|
-
if (k2 === undefined) k2 = k;
|
|
4
|
-
var desc = Object.getOwnPropertyDescriptor(m, k);
|
|
5
|
-
if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
|
|
6
|
-
desc = { enumerable: true, get: function() { return m[k]; } };
|
|
7
|
-
}
|
|
8
|
-
Object.defineProperty(o, k2, desc);
|
|
9
|
-
}) : (function(o, m, k, k2) {
|
|
10
|
-
if (k2 === undefined) k2 = k;
|
|
11
|
-
o[k2] = m[k];
|
|
12
|
-
}));
|
|
13
|
-
var __exportStar = (this && this.__exportStar) || function(m, exports) {
|
|
14
|
-
for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p);
|
|
15
|
-
};
|
|
16
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
17
|
-
__exportStar(require("./slash-command.decorator"), exports);
|
|
18
|
-
__exportStar(require("./subcommand.decorator"), exports);
|
|
19
|
-
__exportStar(require("./subcommand-group.decorator"), exports);
|
|
1
|
+
"use strict";
|
|
2
|
+
var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
|
|
3
|
+
if (k2 === undefined) k2 = k;
|
|
4
|
+
var desc = Object.getOwnPropertyDescriptor(m, k);
|
|
5
|
+
if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
|
|
6
|
+
desc = { enumerable: true, get: function() { return m[k]; } };
|
|
7
|
+
}
|
|
8
|
+
Object.defineProperty(o, k2, desc);
|
|
9
|
+
}) : (function(o, m, k, k2) {
|
|
10
|
+
if (k2 === undefined) k2 = k;
|
|
11
|
+
o[k2] = m[k];
|
|
12
|
+
}));
|
|
13
|
+
var __exportStar = (this && this.__exportStar) || function(m, exports) {
|
|
14
|
+
for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p);
|
|
15
|
+
};
|
|
16
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
17
|
+
__exportStar(require("./slash-command.decorator"), exports);
|
|
18
|
+
__exportStar(require("./subcommand.decorator"), exports);
|
|
19
|
+
__exportStar(require("./subcommand-group.decorator"), exports);
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import { SlashCommandMeta } from '../slash-command.discovery';
|
|
2
|
-
export declare const SlashCommand: (options: Omit<SlashCommandMeta, 'type'>) => MethodDecorator;
|
|
1
|
+
import { SlashCommandMeta } from '../slash-command.discovery';
|
|
2
|
+
export declare const SlashCommand: (options: Omit<SlashCommandMeta, 'type'>) => MethodDecorator;
|
|
@@ -1,9 +1,9 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
-
exports.SlashCommand = void 0;
|
|
4
|
-
const common_1 = require("@nestjs/common");
|
|
5
|
-
const slash_command_discovery_1 = require("../slash-command.discovery");
|
|
6
|
-
const necord_constants_1 = require("../../../necord.constants");
|
|
7
|
-
const discord_js_1 = require("discord.js");
|
|
8
|
-
const SlashCommand = (options) => (0, common_1.SetMetadata)(necord_constants_1.SLASH_COMMAND_METADATA, new slash_command_discovery_1.SlashCommandDiscovery(Object.assign({ type: discord_js_1.ApplicationCommandType.ChatInput }, options)));
|
|
9
|
-
exports.SlashCommand = SlashCommand;
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.SlashCommand = void 0;
|
|
4
|
+
const common_1 = require("@nestjs/common");
|
|
5
|
+
const slash_command_discovery_1 = require("../slash-command.discovery");
|
|
6
|
+
const necord_constants_1 = require("../../../necord.constants");
|
|
7
|
+
const discord_js_1 = require("discord.js");
|
|
8
|
+
const SlashCommand = (options) => (0, common_1.SetMetadata)(necord_constants_1.SLASH_COMMAND_METADATA, new slash_command_discovery_1.SlashCommandDiscovery(Object.assign({ type: discord_js_1.ApplicationCommandType.ChatInput }, options)));
|
|
9
|
+
exports.SlashCommand = SlashCommand;
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import { SlashCommandMeta } from '../slash-command.discovery';
|
|
2
|
-
export declare const createCommandGroupDecorator: (rootOptions: Omit<SlashCommandMeta, 'type'>) => (subOptions?: Omit<SlashCommandMeta, 'type'>) => ClassDecorator;
|
|
1
|
+
import { SlashCommandMeta } from '../slash-command.discovery';
|
|
2
|
+
export declare const createCommandGroupDecorator: (rootOptions: Omit<SlashCommandMeta, 'type'>) => (subOptions?: Omit<SlashCommandMeta, 'type'>) => ClassDecorator;
|
|
@@ -1,18 +1,18 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
-
exports.createCommandGroupDecorator = void 0;
|
|
4
|
-
const common_1 = require("@nestjs/common");
|
|
5
|
-
const necord_constants_1 = require("../../../necord.constants");
|
|
6
|
-
const discord_js_1 = require("discord.js");
|
|
7
|
-
const slash_command_discovery_1 = require("../slash-command.discovery");
|
|
8
|
-
const slash_command_decorator_1 = require("./slash-command.decorator");
|
|
9
|
-
const rxjs_1 = require("rxjs");
|
|
10
|
-
const SubcommandGroup = (options) => (0, common_1.SetMetadata)(necord_constants_1.SUBCOMMAND_GROUP_METADATA, new slash_command_discovery_1.SlashCommandDiscovery(Object.assign({ type: discord_js_1.ApplicationCommandOptionType.SubcommandGroup }, options)));
|
|
11
|
-
const createCommandGroupDecorator = (rootOptions) => {
|
|
12
|
-
const rootCommand = (0, slash_command_decorator_1.SlashCommand)(rootOptions);
|
|
13
|
-
return (subOptions) => {
|
|
14
|
-
const subCommandGroup = subOptions ? SubcommandGroup(subOptions) : rxjs_1.noop;
|
|
15
|
-
return (0, common_1.applyDecorators)(rootCommand, subCommandGroup);
|
|
16
|
-
};
|
|
17
|
-
};
|
|
18
|
-
exports.createCommandGroupDecorator = createCommandGroupDecorator;
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.createCommandGroupDecorator = void 0;
|
|
4
|
+
const common_1 = require("@nestjs/common");
|
|
5
|
+
const necord_constants_1 = require("../../../necord.constants");
|
|
6
|
+
const discord_js_1 = require("discord.js");
|
|
7
|
+
const slash_command_discovery_1 = require("../slash-command.discovery");
|
|
8
|
+
const slash_command_decorator_1 = require("./slash-command.decorator");
|
|
9
|
+
const rxjs_1 = require("rxjs");
|
|
10
|
+
const SubcommandGroup = (options) => (0, common_1.SetMetadata)(necord_constants_1.SUBCOMMAND_GROUP_METADATA, new slash_command_discovery_1.SlashCommandDiscovery(Object.assign({ type: discord_js_1.ApplicationCommandOptionType.SubcommandGroup }, options)));
|
|
11
|
+
const createCommandGroupDecorator = (rootOptions) => {
|
|
12
|
+
const rootCommand = (0, slash_command_decorator_1.SlashCommand)(rootOptions);
|
|
13
|
+
return (subOptions) => {
|
|
14
|
+
const subCommandGroup = subOptions ? SubcommandGroup(subOptions) : rxjs_1.noop;
|
|
15
|
+
return (0, common_1.applyDecorators)(rootCommand, subCommandGroup);
|
|
16
|
+
};
|
|
17
|
+
};
|
|
18
|
+
exports.createCommandGroupDecorator = createCommandGroupDecorator;
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import { SlashCommandMeta } from '../slash-command.discovery';
|
|
2
|
-
export declare const Subcommand: (options: Omit<SlashCommandMeta, 'type'>) => MethodDecorator;
|
|
1
|
+
import { SlashCommandMeta } from '../slash-command.discovery';
|
|
2
|
+
export declare const Subcommand: (options: Omit<SlashCommandMeta, 'type'>) => MethodDecorator;
|
|
@@ -1,9 +1,9 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
-
exports.Subcommand = void 0;
|
|
4
|
-
const common_1 = require("@nestjs/common");
|
|
5
|
-
const slash_command_discovery_1 = require("../slash-command.discovery");
|
|
6
|
-
const necord_constants_1 = require("../../../necord.constants");
|
|
7
|
-
const discord_js_1 = require("discord.js");
|
|
8
|
-
const Subcommand = (options) => (0, common_1.SetMetadata)(necord_constants_1.SUBCOMMAND_METADATA, new slash_command_discovery_1.SlashCommandDiscovery(Object.assign({ type: discord_js_1.ApplicationCommandOptionType.Subcommand }, options)));
|
|
9
|
-
exports.Subcommand = Subcommand;
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.Subcommand = void 0;
|
|
4
|
+
const common_1 = require("@nestjs/common");
|
|
5
|
+
const slash_command_discovery_1 = require("../slash-command.discovery");
|
|
6
|
+
const necord_constants_1 = require("../../../necord.constants");
|
|
7
|
+
const discord_js_1 = require("discord.js");
|
|
8
|
+
const Subcommand = (options) => (0, common_1.SetMetadata)(necord_constants_1.SUBCOMMAND_METADATA, new slash_command_discovery_1.SlashCommandDiscovery(Object.assign({ type: discord_js_1.ApplicationCommandOptionType.Subcommand }, options)));
|
|
9
|
+
exports.Subcommand = Subcommand;
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
export * from './autocomplete';
|
|
2
|
-
export * from './decorators';
|
|
3
|
-
export * from './options';
|
|
4
|
-
export * from './slash-command.discovery';
|
|
5
|
-
export * from './slash-commands.service';
|
|
1
|
+
export * from './autocomplete';
|
|
2
|
+
export * from './decorators';
|
|
3
|
+
export * from './options';
|
|
4
|
+
export * from './slash-command.discovery';
|
|
5
|
+
export * from './slash-commands.service';
|
|
@@ -1,21 +1,21 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
|
|
3
|
-
if (k2 === undefined) k2 = k;
|
|
4
|
-
var desc = Object.getOwnPropertyDescriptor(m, k);
|
|
5
|
-
if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
|
|
6
|
-
desc = { enumerable: true, get: function() { return m[k]; } };
|
|
7
|
-
}
|
|
8
|
-
Object.defineProperty(o, k2, desc);
|
|
9
|
-
}) : (function(o, m, k, k2) {
|
|
10
|
-
if (k2 === undefined) k2 = k;
|
|
11
|
-
o[k2] = m[k];
|
|
12
|
-
}));
|
|
13
|
-
var __exportStar = (this && this.__exportStar) || function(m, exports) {
|
|
14
|
-
for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p);
|
|
15
|
-
};
|
|
16
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
17
|
-
__exportStar(require("./autocomplete"), exports);
|
|
18
|
-
__exportStar(require("./decorators"), exports);
|
|
19
|
-
__exportStar(require("./options"), exports);
|
|
20
|
-
__exportStar(require("./slash-command.discovery"), exports);
|
|
21
|
-
__exportStar(require("./slash-commands.service"), exports);
|
|
1
|
+
"use strict";
|
|
2
|
+
var __createBinding = (this && this.__createBinding) || (Object.create ? (function(o, m, k, k2) {
|
|
3
|
+
if (k2 === undefined) k2 = k;
|
|
4
|
+
var desc = Object.getOwnPropertyDescriptor(m, k);
|
|
5
|
+
if (!desc || ("get" in desc ? !m.__esModule : desc.writable || desc.configurable)) {
|
|
6
|
+
desc = { enumerable: true, get: function() { return m[k]; } };
|
|
7
|
+
}
|
|
8
|
+
Object.defineProperty(o, k2, desc);
|
|
9
|
+
}) : (function(o, m, k, k2) {
|
|
10
|
+
if (k2 === undefined) k2 = k;
|
|
11
|
+
o[k2] = m[k];
|
|
12
|
+
}));
|
|
13
|
+
var __exportStar = (this && this.__exportStar) || function(m, exports) {
|
|
14
|
+
for (var p in m) if (p !== "default" && !Object.prototype.hasOwnProperty.call(exports, p)) __createBinding(exports, m, p);
|
|
15
|
+
};
|
|
16
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
17
|
+
__exportStar(require("./autocomplete"), exports);
|
|
18
|
+
__exportStar(require("./decorators"), exports);
|
|
19
|
+
__exportStar(require("./options"), exports);
|
|
20
|
+
__exportStar(require("./slash-command.discovery"), exports);
|
|
21
|
+
__exportStar(require("./slash-commands.service"), exports);
|
|
@@ -1,7 +1,7 @@
|
|
|
1
|
-
export declare const AttachmentOption: (data: {
|
|
2
|
-
name: string;
|
|
3
|
-
description: string;
|
|
4
|
-
name_localizations?: Partial<Record<"en-US" | "en-GB" | "bg" | "zh-CN" | "zh-TW" | "hr" | "cs" | "da" | "nl" | "fi" | "fr" | "de" | "el" | "hi" | "hu" | "it" | "ja" | "ko" | "lt" | "no" | "pl" | "pt-BR" | "ro" | "ru" | "es-ES" | "sv-SE" | "th" | "tr" | "uk" | "vi", string>>;
|
|
5
|
-
description_localizations?: Partial<Record<"en-US" | "en-GB" | "bg" | "zh-CN" | "zh-TW" | "hr" | "cs" | "da" | "nl" | "fi" | "fr" | "de" | "el" | "hi" | "hu" | "it" | "ja" | "ko" | "lt" | "no" | "pl" | "pt-BR" | "ro" | "ru" | "es-ES" | "sv-SE" | "th" | "tr" | "uk" | "vi", string>>;
|
|
6
|
-
required?: boolean;
|
|
7
|
-
}) => PropertyDecorator;
|
|
1
|
+
export declare const AttachmentOption: (data: {
|
|
2
|
+
name: string;
|
|
3
|
+
description: string;
|
|
4
|
+
name_localizations?: Partial<Record<"id" | "en-US" | "en-GB" | "bg" | "zh-CN" | "zh-TW" | "hr" | "cs" | "da" | "nl" | "fi" | "fr" | "de" | "el" | "hi" | "hu" | "it" | "ja" | "ko" | "lt" | "no" | "pl" | "pt-BR" | "ro" | "ru" | "es-ES" | "sv-SE" | "th" | "tr" | "uk" | "vi", string>>;
|
|
5
|
+
description_localizations?: Partial<Record<"id" | "en-US" | "en-GB" | "bg" | "zh-CN" | "zh-TW" | "hr" | "cs" | "da" | "nl" | "fi" | "fr" | "de" | "el" | "hi" | "hu" | "it" | "ja" | "ko" | "lt" | "no" | "pl" | "pt-BR" | "ro" | "ru" | "es-ES" | "sv-SE" | "th" | "tr" | "uk" | "vi", string>>;
|
|
6
|
+
required?: boolean;
|
|
7
|
+
}) => PropertyDecorator;
|
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
-
exports.AttachmentOption = void 0;
|
|
4
|
-
const discord_js_1 = require("discord.js");
|
|
5
|
-
const option_util_1 = require("./option.util");
|
|
6
|
-
exports.AttachmentOption = (0, option_util_1.createOptionDecorator)(discord_js_1.ApplicationCommandOptionType.Attachment, 'getAttachment');
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.AttachmentOption = void 0;
|
|
4
|
+
const discord_js_1 = require("discord.js");
|
|
5
|
+
const option_util_1 = require("./option.util");
|
|
6
|
+
exports.AttachmentOption = (0, option_util_1.createOptionDecorator)(discord_js_1.ApplicationCommandOptionType.Attachment, 'getAttachment');
|
|
@@ -1,7 +1,7 @@
|
|
|
1
|
-
export declare const BooleanOption: (data: {
|
|
2
|
-
name: string;
|
|
3
|
-
description: string;
|
|
4
|
-
name_localizations?: Partial<Record<"en-US" | "en-GB" | "bg" | "zh-CN" | "zh-TW" | "hr" | "cs" | "da" | "nl" | "fi" | "fr" | "de" | "el" | "hi" | "hu" | "it" | "ja" | "ko" | "lt" | "no" | "pl" | "pt-BR" | "ro" | "ru" | "es-ES" | "sv-SE" | "th" | "tr" | "uk" | "vi", string>>;
|
|
5
|
-
description_localizations?: Partial<Record<"en-US" | "en-GB" | "bg" | "zh-CN" | "zh-TW" | "hr" | "cs" | "da" | "nl" | "fi" | "fr" | "de" | "el" | "hi" | "hu" | "it" | "ja" | "ko" | "lt" | "no" | "pl" | "pt-BR" | "ro" | "ru" | "es-ES" | "sv-SE" | "th" | "tr" | "uk" | "vi", string>>;
|
|
6
|
-
required?: boolean;
|
|
7
|
-
}) => PropertyDecorator;
|
|
1
|
+
export declare const BooleanOption: (data: {
|
|
2
|
+
name: string;
|
|
3
|
+
description: string;
|
|
4
|
+
name_localizations?: Partial<Record<"id" | "en-US" | "en-GB" | "bg" | "zh-CN" | "zh-TW" | "hr" | "cs" | "da" | "nl" | "fi" | "fr" | "de" | "el" | "hi" | "hu" | "it" | "ja" | "ko" | "lt" | "no" | "pl" | "pt-BR" | "ro" | "ru" | "es-ES" | "sv-SE" | "th" | "tr" | "uk" | "vi", string>>;
|
|
5
|
+
description_localizations?: Partial<Record<"id" | "en-US" | "en-GB" | "bg" | "zh-CN" | "zh-TW" | "hr" | "cs" | "da" | "nl" | "fi" | "fr" | "de" | "el" | "hi" | "hu" | "it" | "ja" | "ko" | "lt" | "no" | "pl" | "pt-BR" | "ro" | "ru" | "es-ES" | "sv-SE" | "th" | "tr" | "uk" | "vi", string>>;
|
|
6
|
+
required?: boolean;
|
|
7
|
+
}) => PropertyDecorator;
|
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
-
exports.BooleanOption = void 0;
|
|
4
|
-
const discord_js_1 = require("discord.js");
|
|
5
|
-
const option_util_1 = require("./option.util");
|
|
6
|
-
exports.BooleanOption = (0, option_util_1.createOptionDecorator)(discord_js_1.ApplicationCommandOptionType.Boolean, 'getBoolean');
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.BooleanOption = void 0;
|
|
4
|
+
const discord_js_1 = require("discord.js");
|
|
5
|
+
const option_util_1 = require("./option.util");
|
|
6
|
+
exports.BooleanOption = (0, option_util_1.createOptionDecorator)(discord_js_1.ApplicationCommandOptionType.Boolean, 'getBoolean');
|
|
@@ -1,8 +1,8 @@
|
|
|
1
|
-
export declare const ChannelOption: (data: {
|
|
2
|
-
name: string;
|
|
3
|
-
description: string;
|
|
4
|
-
name_localizations?: Partial<Record<"en-US" | "en-GB" | "bg" | "zh-CN" | "zh-TW" | "hr" | "cs" | "da" | "nl" | "fi" | "fr" | "de" | "el" | "hi" | "hu" | "it" | "ja" | "ko" | "lt" | "no" | "pl" | "pt-BR" | "ro" | "ru" | "es-ES" | "sv-SE" | "th" | "tr" | "uk" | "vi", string>>;
|
|
5
|
-
description_localizations?: Partial<Record<"en-US" | "en-GB" | "bg" | "zh-CN" | "zh-TW" | "hr" | "cs" | "da" | "nl" | "fi" | "fr" | "de" | "el" | "hi" | "hu" | "it" | "ja" | "ko" | "lt" | "no" | "pl" | "pt-BR" | "ro" | "ru" | "es-ES" | "sv-SE" | "th" | "tr" | "uk" | "vi", string>>;
|
|
6
|
-
required?: boolean;
|
|
7
|
-
channel_types?: (import("discord.js").ChannelType.GuildText | import("discord.js").ChannelType.GuildVoice | import("discord.js").ChannelType.GuildCategory | import("discord.js").ChannelType.GuildAnnouncement | import("discord.js").ChannelType.AnnouncementThread | import("discord.js").ChannelType.PublicThread | import("discord.js").ChannelType.PrivateThread | import("discord.js").ChannelType.GuildStageVoice | import("discord.js").ChannelType.GuildDirectory | import("discord.js").ChannelType.GuildForum)[];
|
|
8
|
-
}) => PropertyDecorator;
|
|
1
|
+
export declare const ChannelOption: (data: {
|
|
2
|
+
name: string;
|
|
3
|
+
description: string;
|
|
4
|
+
name_localizations?: Partial<Record<"id" | "en-US" | "en-GB" | "bg" | "zh-CN" | "zh-TW" | "hr" | "cs" | "da" | "nl" | "fi" | "fr" | "de" | "el" | "hi" | "hu" | "it" | "ja" | "ko" | "lt" | "no" | "pl" | "pt-BR" | "ro" | "ru" | "es-ES" | "sv-SE" | "th" | "tr" | "uk" | "vi", string>>;
|
|
5
|
+
description_localizations?: Partial<Record<"id" | "en-US" | "en-GB" | "bg" | "zh-CN" | "zh-TW" | "hr" | "cs" | "da" | "nl" | "fi" | "fr" | "de" | "el" | "hi" | "hu" | "it" | "ja" | "ko" | "lt" | "no" | "pl" | "pt-BR" | "ro" | "ru" | "es-ES" | "sv-SE" | "th" | "tr" | "uk" | "vi", string>>;
|
|
6
|
+
required?: boolean;
|
|
7
|
+
channel_types?: (import("discord.js").ChannelType.GuildText | import("discord.js").ChannelType.GuildVoice | import("discord.js").ChannelType.GuildCategory | import("discord.js").ChannelType.GuildAnnouncement | import("discord.js").ChannelType.AnnouncementThread | import("discord.js").ChannelType.PublicThread | import("discord.js").ChannelType.PrivateThread | import("discord.js").ChannelType.GuildStageVoice | import("discord.js").ChannelType.GuildDirectory | import("discord.js").ChannelType.GuildForum)[];
|
|
8
|
+
}) => PropertyDecorator;
|
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
-
exports.ChannelOption = void 0;
|
|
4
|
-
const discord_js_1 = require("discord.js");
|
|
5
|
-
const option_util_1 = require("./option.util");
|
|
6
|
-
exports.ChannelOption = (0, option_util_1.createOptionDecorator)(discord_js_1.ApplicationCommandOptionType.Channel, 'getChannel');
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.ChannelOption = void 0;
|
|
4
|
+
const discord_js_1 = require("discord.js");
|
|
5
|
+
const option_util_1 = require("./option.util");
|
|
6
|
+
exports.ChannelOption = (0, option_util_1.createOptionDecorator)(discord_js_1.ApplicationCommandOptionType.Channel, 'getChannel');
|
|
@@ -1,11 +1,11 @@
|
|
|
1
|
-
export * from './attachment-option.decorator';
|
|
2
|
-
export * from './boolean-option.decorator';
|
|
3
|
-
export * from './channel-option.decorator';
|
|
4
|
-
export * from './integer-option.decorator';
|
|
5
|
-
export * from './member-option.decorator';
|
|
6
|
-
export * from './mentionable-option.decorator';
|
|
7
|
-
export * from './number-option.decorator';
|
|
8
|
-
export * from './role-option.decorator';
|
|
9
|
-
export * from './string-option.decorator';
|
|
10
|
-
export * from './user-option.decorator';
|
|
11
|
-
export * from './options.decorator';
|
|
1
|
+
export * from './attachment-option.decorator';
|
|
2
|
+
export * from './boolean-option.decorator';
|
|
3
|
+
export * from './channel-option.decorator';
|
|
4
|
+
export * from './integer-option.decorator';
|
|
5
|
+
export * from './member-option.decorator';
|
|
6
|
+
export * from './mentionable-option.decorator';
|
|
7
|
+
export * from './number-option.decorator';
|
|
8
|
+
export * from './role-option.decorator';
|
|
9
|
+
export * from './string-option.decorator';
|
|
10
|
+
export * from './user-option.decorator';
|
|
11
|
+
export * from './options.decorator';
|