@discordjs/builders 2.0.0-dev.1752667562-9ff04820b → 2.0.0-dev.1752753955-aee6d311c
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/index.d.mts +3 -4
- package/dist/index.d.ts +3 -4
- package/dist/index.js +4 -2
- package/dist/index.js.map +1 -1
- package/dist/index.mjs +7 -3
- package/dist/index.mjs.map +1 -1
- package/package.json +1 -1
package/dist/index.d.mts
CHANGED
|
@@ -1,10 +1,9 @@
|
|
|
1
1
|
import * as discord_api_types_v10 from 'discord-api-types/v10';
|
|
2
|
-
import { APIButtonComponent, APIButtonComponentWithSKUId, APIMessageComponentEmoji, APIBaseComponent, ComponentType, APIButtonComponentWithCustomId, APIButtonComponentWithURL, Snowflake, APISelectMenuComponent, APIChannelSelectComponent, ChannelType, APIMentionableSelectComponent, APISelectMenuDefaultValue, SelectMenuDefaultValueType, APIRoleSelectComponent, APISelectMenuOption, APIStringSelectComponent, APIUserSelectComponent, APITextInputComponent, TextInputStyle, APIFileComponent, APIMediaGalleryItem, APIMediaGalleryComponent, APITextDisplayComponent, APIThumbnailComponent, APISectionComponent, ButtonStyle, APISeparatorComponent, SeparatorSpacingSize, APIContainerComponent, APIActionRowComponent, APIComponentInContainer, APIModalComponent, APIMessageComponent, APISectionAccessoryComponent, APIComponentInActionRow, APIApplicationCommandIntegerOption, APIApplicationCommandChannelOption, APIApplicationCommandNumberOption, APIApplicationCommandStringOption, APIApplicationCommandOptionChoice, RESTPostAPIApplicationCommandsJSONBody, Locale, APIApplicationCommand, APIApplicationCommandBasicOption, APIApplicationCommandOption, ApplicationCommandOptionType, APIApplicationCommandSubcommandOption, APIApplicationCommandSubcommandGroupOption, InteractionContextType, ApplicationIntegrationType, Permissions, RESTPostAPIChatInputApplicationCommandsJSONBody, ApplicationCommandType, RESTPostAPIContextMenuApplicationCommandsJSONBody, APIModalInteractionResponseCallbackData, APIComponentInModalActionRow, APIEmbedAuthor, APIEmbedField, APIEmbedFooter, APIEmbed, PollLayoutType, APIPollMedia, APIPartialEmoji, APIPollAnswer, RESTAPIPoll, APIAllowedMentions, AllowedMentionsTypes, MessageReferenceType, RESTAPIAttachment, RESTAPIMessageReference, RESTPostAPIChannelMessageJSONBody, APIMessageReference,
|
|
2
|
+
import { APIButtonComponent, APIButtonComponentWithSKUId, APIMessageComponentEmoji, APIBaseComponent, ComponentType, APIButtonComponentWithCustomId, APIButtonComponentWithURL, Snowflake, APISelectMenuComponent, APIChannelSelectComponent, ChannelType, APIMentionableSelectComponent, APISelectMenuDefaultValue, SelectMenuDefaultValueType, APIRoleSelectComponent, APISelectMenuOption, APIStringSelectComponent, APIUserSelectComponent, APITextInputComponent, TextInputStyle, APIFileComponent, APIMediaGalleryItem, APIMediaGalleryComponent, APITextDisplayComponent, APIThumbnailComponent, APISectionComponent, ButtonStyle, APISeparatorComponent, SeparatorSpacingSize, APIContainerComponent, APIActionRowComponent, APIComponentInMessageActionRow, APIComponentInContainer, APIModalComponent, APIMessageComponent, APISectionAccessoryComponent, APIComponentInActionRow, APIApplicationCommandIntegerOption, APIApplicationCommandChannelOption, APIApplicationCommandNumberOption, APIApplicationCommandStringOption, APIApplicationCommandOptionChoice, RESTPostAPIApplicationCommandsJSONBody, Locale, APIApplicationCommand, APIApplicationCommandBasicOption, APIApplicationCommandOption, ApplicationCommandOptionType, APIApplicationCommandSubcommandOption, APIApplicationCommandSubcommandGroupOption, InteractionContextType, ApplicationIntegrationType, Permissions, RESTPostAPIChatInputApplicationCommandsJSONBody, ApplicationCommandType, RESTPostAPIContextMenuApplicationCommandsJSONBody, APIModalInteractionResponseCallbackData, APIComponentInModalActionRow, APIEmbedAuthor, APIEmbedField, APIEmbedFooter, APIEmbed, PollLayoutType, APIPollMedia, APIPartialEmoji, APIPollAnswer, RESTAPIPoll, APIAllowedMentions, AllowedMentionsTypes, MessageReferenceType, RESTAPIAttachment, RESTAPIMessageReference, RESTPostAPIChannelMessageJSONBody, APIMessageReference, APIMessageTopLevelComponent, APIAttachment, MessageFlags, APIPoll } from 'discord-api-types/v10';
|
|
3
3
|
import { JSONEncodable } from '@discordjs/util';
|
|
4
4
|
import * as ts_mixer_dist_types_types_js from 'ts-mixer/dist/types/types.js';
|
|
5
5
|
import * as zod from 'zod';
|
|
6
6
|
import { z } from 'zod';
|
|
7
|
-
import { APIComponentInMessageActionRow, APISeparatorComponent as APISeparatorComponent$1 } from 'discord-api-types/v9';
|
|
8
7
|
import * as zod_v4_core from 'zod/v4/core';
|
|
9
8
|
|
|
10
9
|
interface EmojiOrLabelButtonData extends Pick<Exclude<APIButtonComponent, APIButtonComponentWithSKUId>, 'emoji' | 'label'> {
|
|
@@ -1243,7 +1242,7 @@ declare class ContainerBuilder extends ComponentBuilder<APIContainerComponent> {
|
|
|
1243
1242
|
*
|
|
1244
1243
|
* @param input - The separator components to add
|
|
1245
1244
|
*/
|
|
1246
|
-
addSeparatorComponents(...input: RestOrArray<APISeparatorComponent
|
|
1245
|
+
addSeparatorComponents(...input: RestOrArray<APISeparatorComponent | SeparatorBuilder | ((builder: SeparatorBuilder) => SeparatorBuilder)>): this;
|
|
1247
1246
|
/**
|
|
1248
1247
|
* Adds text display components to this container.
|
|
1249
1248
|
*
|
|
@@ -4009,7 +4008,7 @@ declare class MessageBuilder implements JSONEncodable<RESTPostAPIChannelMessageJ
|
|
|
4009
4008
|
*
|
|
4010
4009
|
* @param components - The action row components to add
|
|
4011
4010
|
*/
|
|
4012
|
-
addActionRowComponents(...components: RestOrArray<ActionRowBuilder | APIActionRowComponent<APIComponentInMessageActionRow
|
|
4011
|
+
addActionRowComponents(...components: RestOrArray<ActionRowBuilder | APIActionRowComponent<APIComponentInMessageActionRow> | ((builder: ActionRowBuilder) => ActionRowBuilder)>): this;
|
|
4013
4012
|
/**
|
|
4014
4013
|
* Adds container components to this message.
|
|
4015
4014
|
*
|
package/dist/index.d.ts
CHANGED
|
@@ -1,10 +1,9 @@
|
|
|
1
1
|
import * as discord_api_types_v10 from 'discord-api-types/v10';
|
|
2
|
-
import { APIButtonComponent, APIButtonComponentWithSKUId, APIMessageComponentEmoji, APIBaseComponent, ComponentType, APIButtonComponentWithCustomId, APIButtonComponentWithURL, Snowflake, APISelectMenuComponent, APIChannelSelectComponent, ChannelType, APIMentionableSelectComponent, APISelectMenuDefaultValue, SelectMenuDefaultValueType, APIRoleSelectComponent, APISelectMenuOption, APIStringSelectComponent, APIUserSelectComponent, APITextInputComponent, TextInputStyle, APIFileComponent, APIMediaGalleryItem, APIMediaGalleryComponent, APITextDisplayComponent, APIThumbnailComponent, APISectionComponent, ButtonStyle, APISeparatorComponent, SeparatorSpacingSize, APIContainerComponent, APIActionRowComponent, APIComponentInContainer, APIModalComponent, APIMessageComponent, APISectionAccessoryComponent, APIComponentInActionRow, APIApplicationCommandIntegerOption, APIApplicationCommandChannelOption, APIApplicationCommandNumberOption, APIApplicationCommandStringOption, APIApplicationCommandOptionChoice, RESTPostAPIApplicationCommandsJSONBody, Locale, APIApplicationCommand, APIApplicationCommandBasicOption, APIApplicationCommandOption, ApplicationCommandOptionType, APIApplicationCommandSubcommandOption, APIApplicationCommandSubcommandGroupOption, InteractionContextType, ApplicationIntegrationType, Permissions, RESTPostAPIChatInputApplicationCommandsJSONBody, ApplicationCommandType, RESTPostAPIContextMenuApplicationCommandsJSONBody, APIModalInteractionResponseCallbackData, APIComponentInModalActionRow, APIEmbedAuthor, APIEmbedField, APIEmbedFooter, APIEmbed, PollLayoutType, APIPollMedia, APIPartialEmoji, APIPollAnswer, RESTAPIPoll, APIAllowedMentions, AllowedMentionsTypes, MessageReferenceType, RESTAPIAttachment, RESTAPIMessageReference, RESTPostAPIChannelMessageJSONBody, APIMessageReference,
|
|
2
|
+
import { APIButtonComponent, APIButtonComponentWithSKUId, APIMessageComponentEmoji, APIBaseComponent, ComponentType, APIButtonComponentWithCustomId, APIButtonComponentWithURL, Snowflake, APISelectMenuComponent, APIChannelSelectComponent, ChannelType, APIMentionableSelectComponent, APISelectMenuDefaultValue, SelectMenuDefaultValueType, APIRoleSelectComponent, APISelectMenuOption, APIStringSelectComponent, APIUserSelectComponent, APITextInputComponent, TextInputStyle, APIFileComponent, APIMediaGalleryItem, APIMediaGalleryComponent, APITextDisplayComponent, APIThumbnailComponent, APISectionComponent, ButtonStyle, APISeparatorComponent, SeparatorSpacingSize, APIContainerComponent, APIActionRowComponent, APIComponentInMessageActionRow, APIComponentInContainer, APIModalComponent, APIMessageComponent, APISectionAccessoryComponent, APIComponentInActionRow, APIApplicationCommandIntegerOption, APIApplicationCommandChannelOption, APIApplicationCommandNumberOption, APIApplicationCommandStringOption, APIApplicationCommandOptionChoice, RESTPostAPIApplicationCommandsJSONBody, Locale, APIApplicationCommand, APIApplicationCommandBasicOption, APIApplicationCommandOption, ApplicationCommandOptionType, APIApplicationCommandSubcommandOption, APIApplicationCommandSubcommandGroupOption, InteractionContextType, ApplicationIntegrationType, Permissions, RESTPostAPIChatInputApplicationCommandsJSONBody, ApplicationCommandType, RESTPostAPIContextMenuApplicationCommandsJSONBody, APIModalInteractionResponseCallbackData, APIComponentInModalActionRow, APIEmbedAuthor, APIEmbedField, APIEmbedFooter, APIEmbed, PollLayoutType, APIPollMedia, APIPartialEmoji, APIPollAnswer, RESTAPIPoll, APIAllowedMentions, AllowedMentionsTypes, MessageReferenceType, RESTAPIAttachment, RESTAPIMessageReference, RESTPostAPIChannelMessageJSONBody, APIMessageReference, APIMessageTopLevelComponent, APIAttachment, MessageFlags, APIPoll } from 'discord-api-types/v10';
|
|
3
3
|
import { JSONEncodable } from '@discordjs/util';
|
|
4
4
|
import * as ts_mixer_dist_types_types_js from 'ts-mixer/dist/types/types.js';
|
|
5
5
|
import * as zod from 'zod';
|
|
6
6
|
import { z } from 'zod';
|
|
7
|
-
import { APIComponentInMessageActionRow, APISeparatorComponent as APISeparatorComponent$1 } from 'discord-api-types/v9';
|
|
8
7
|
import * as zod_v4_core from 'zod/v4/core';
|
|
9
8
|
|
|
10
9
|
interface EmojiOrLabelButtonData extends Pick<Exclude<APIButtonComponent, APIButtonComponentWithSKUId>, 'emoji' | 'label'> {
|
|
@@ -1243,7 +1242,7 @@ declare class ContainerBuilder extends ComponentBuilder<APIContainerComponent> {
|
|
|
1243
1242
|
*
|
|
1244
1243
|
* @param input - The separator components to add
|
|
1245
1244
|
*/
|
|
1246
|
-
addSeparatorComponents(...input: RestOrArray<APISeparatorComponent
|
|
1245
|
+
addSeparatorComponents(...input: RestOrArray<APISeparatorComponent | SeparatorBuilder | ((builder: SeparatorBuilder) => SeparatorBuilder)>): this;
|
|
1247
1246
|
/**
|
|
1248
1247
|
* Adds text display components to this container.
|
|
1249
1248
|
*
|
|
@@ -4009,7 +4008,7 @@ declare class MessageBuilder implements JSONEncodable<RESTPostAPIChannelMessageJ
|
|
|
4009
4008
|
*
|
|
4010
4009
|
* @param components - The action row components to add
|
|
4011
4010
|
*/
|
|
4012
|
-
addActionRowComponents(...components: RestOrArray<ActionRowBuilder | APIActionRowComponent<APIComponentInMessageActionRow
|
|
4011
|
+
addActionRowComponents(...components: RestOrArray<ActionRowBuilder | APIActionRowComponent<APIComponentInMessageActionRow> | ((builder: ActionRowBuilder) => ActionRowBuilder)>): this;
|
|
4013
4012
|
/**
|
|
4014
4013
|
* Adds container components to this message.
|
|
4015
4014
|
*
|
package/dist/index.js
CHANGED
|
@@ -3384,7 +3384,9 @@ var ChatInputCommandBuilder = class extends (0, import_ts_mixer8.Mixin)(
|
|
|
3384
3384
|
// src/interactions/commands/contextMenu/Assertions.ts
|
|
3385
3385
|
var import_v1036 = require("discord-api-types/v10");
|
|
3386
3386
|
var import_zod7 = require("zod");
|
|
3387
|
-
var namePredicate2 = import_zod7.z.string().min(1).max(32).
|
|
3387
|
+
var namePredicate2 = import_zod7.z.string().min(1).max(32).refine((val) => val.trim().length > 0, {
|
|
3388
|
+
error: "Must not consist of only whitespace."
|
|
3389
|
+
});
|
|
3388
3390
|
var contextsPredicate = import_zod7.z.array(import_zod7.z.enum(import_v1036.InteractionContextType));
|
|
3389
3391
|
var integrationTypesPredicate = import_zod7.z.array(import_zod7.z.enum(import_v1036.ApplicationIntegrationType));
|
|
3390
3392
|
var baseContextMenuCommandPredicate = import_zod7.z.object({
|
|
@@ -5433,7 +5435,7 @@ var MessageBuilder = class {
|
|
|
5433
5435
|
};
|
|
5434
5436
|
|
|
5435
5437
|
// src/index.ts
|
|
5436
|
-
var version = "2.0.0-dev.
|
|
5438
|
+
var version = "2.0.0-dev.1752753955-aee6d311c";
|
|
5437
5439
|
// Annotate the CommonJS export names for ESM import in node:
|
|
5438
5440
|
0 && (module.exports = {
|
|
5439
5441
|
ActionRowBuilder,
|