From e4450c8417624b71d779cb4f41692538f9165e10 Mon Sep 17 00:00:00 2001 From: sowgro Date: Sat, 2 Sep 2023 19:12:47 -0400 Subject: first commit --- .../src/structures/BaseSelectMenuComponent.js | 56 ++++++++++++++++++++++ 1 file changed, 56 insertions(+) create mode 100644 node_modules/discord.js/src/structures/BaseSelectMenuComponent.js (limited to 'node_modules/discord.js/src/structures/BaseSelectMenuComponent.js') diff --git a/node_modules/discord.js/src/structures/BaseSelectMenuComponent.js b/node_modules/discord.js/src/structures/BaseSelectMenuComponent.js new file mode 100644 index 0000000..7177f43 --- /dev/null +++ b/node_modules/discord.js/src/structures/BaseSelectMenuComponent.js @@ -0,0 +1,56 @@ +'use strict'; + +const Component = require('./Component'); + +/** + * Represents a select menu component + * @extends {Component} + */ +class BaseSelectMenuComponent extends Component { + /** + * The placeholder for this select menu + * @type {?string} + * @readonly + */ + get placeholder() { + return this.data.placeholder ?? null; + } + + /** + * The maximum amount of options that can be selected + * @type {?number} + * @readonly + */ + get maxValues() { + return this.data.max_values ?? null; + } + + /** + * The minimum amount of options that must be selected + * @type {?number} + * @readonly + */ + get minValues() { + return this.data.min_values ?? null; + } + + /** + * The custom id of this select menu + * @type {string} + * @readonly + */ + get customId() { + return this.data.custom_id; + } + + /** + * Whether this select menu is disabled + * @type {boolean} + * @readonly + */ + get disabled() { + return this.data.disabled ?? false; + } +} + +module.exports = BaseSelectMenuComponent; -- cgit v1.2.3