@wilcosp/rex
Version:
Rex is an automated command manager for discord js
31 lines (30 loc) • 1.29 kB
TypeScript
/*!
* This Source Code Form is subject to the terms of the Mozilla Public
* License, v. 2.0. If a copy of the MPL was not distributed with this
* file, You can obtain one at https://mozilla.org/MPL/2.0/.
*/
import { ApplicationCommandOptionChoiceData, AutocompleteInteraction } from "discord.js";
import { RexInteractionBase } from "../interactionBase.js";
import { RexSlashInteractionOptionsResolver } from "./optionsResolver.js";
export declare class RexAutoCompleteInteraction extends RexInteractionBase {
inter: AutocompleteInteraction;
readonly options: RexSlashInteractionOptionsResolver;
constructor(inter: AutocompleteInteraction);
get responded(): boolean;
/**
* Respond to an autocomplete intereaction with choices
* @param choices choices with a name & value
* @returns Promise<void>
*/
respond(...choices: ApplicationCommandOptionChoiceData[] | ApplicationCommandOptionChoiceData[][]): Promise<void>;
/**
* respond to an autocomplete interaction with only the values
* @param choices all the choices where both the value & name are the same
* @returns Promise<void>
*/
respondNormalized(...choices: {
toString(): string;
}[] | {
toString(): string;
}[][]): Promise<void>;
}