@discordjs/builders 1.11.0 → 1.11.2
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 +1 -1
- package/dist/index.d.ts +1 -1
- package/dist/index.js +4 -5
- package/dist/index.js.map +1 -1
- package/dist/index.mjs +4 -5
- package/dist/index.mjs.map +1 -1
- package/package.json +3 -3
package/dist/index.d.mts
CHANGED
|
@@ -1477,7 +1477,7 @@ declare class ThumbnailBuilder extends ComponentBuilder<APIThumbnailComponent> {
|
|
|
1477
1477
|
* @example
|
|
1478
1478
|
* Creating a thumbnail from an API data object:
|
|
1479
1479
|
* ```ts
|
|
1480
|
-
* const
|
|
1480
|
+
* const thumbnail = new ThumbnailBuilder({
|
|
1481
1481
|
* description: 'some text',
|
|
1482
1482
|
* media: {
|
|
1483
1483
|
* url: 'https://cdn.discordapp.com/embed/avatars/4.png',
|
package/dist/index.d.ts
CHANGED
|
@@ -1477,7 +1477,7 @@ declare class ThumbnailBuilder extends ComponentBuilder<APIThumbnailComponent> {
|
|
|
1477
1477
|
* @example
|
|
1478
1478
|
* Creating a thumbnail from an API data object:
|
|
1479
1479
|
* ```ts
|
|
1480
|
-
* const
|
|
1480
|
+
* const thumbnail = new ThumbnailBuilder({
|
|
1481
1481
|
* description: 'some text',
|
|
1482
1482
|
* media: {
|
|
1483
1483
|
* url: 'https://cdn.discordapp.com/embed/avatars/4.png',
|
package/dist/index.js
CHANGED
|
@@ -1439,7 +1439,7 @@ var ThumbnailBuilder = class extends ComponentBuilder {
|
|
|
1439
1439
|
* @example
|
|
1440
1440
|
* Creating a thumbnail from an API data object:
|
|
1441
1441
|
* ```ts
|
|
1442
|
-
* const
|
|
1442
|
+
* const thumbnail = new ThumbnailBuilder({
|
|
1443
1443
|
* description: 'some text',
|
|
1444
1444
|
* media: {
|
|
1445
1445
|
* url: 'https://cdn.discordapp.com/embed/avatars/4.png',
|
|
@@ -1525,11 +1525,11 @@ var textDisplayContentPredicate = import_shapeshift4.s.string().lengthGreaterTha
|
|
|
1525
1525
|
var accessoryPredicate = import_shapeshift4.s.instance(ButtonBuilder).or(import_shapeshift4.s.instance(ThumbnailBuilder)).setValidationEnabled(isValidationEnabled);
|
|
1526
1526
|
var containerColorPredicate = colorPredicate.nullish();
|
|
1527
1527
|
function assertReturnOfBuilder(input, ExpectedInstanceOf) {
|
|
1528
|
-
import_shapeshift4.s.instance(ExpectedInstanceOf).parse(input);
|
|
1528
|
+
import_shapeshift4.s.instance(ExpectedInstanceOf).setValidationEnabled(isValidationEnabled).parse(input);
|
|
1529
1529
|
}
|
|
1530
1530
|
__name(assertReturnOfBuilder, "assertReturnOfBuilder");
|
|
1531
1531
|
function validateComponentArray(input, min, max, ExpectedInstanceOf) {
|
|
1532
|
-
(ExpectedInstanceOf ? import_shapeshift4.s.instance(ExpectedInstanceOf) : import_shapeshift4.s.instance(ComponentBuilder)).array().lengthGreaterThanOrEqual(min).lengthLessThanOrEqual(max).parse(input);
|
|
1532
|
+
(ExpectedInstanceOf ? import_shapeshift4.s.instance(ExpectedInstanceOf) : import_shapeshift4.s.instance(ComponentBuilder)).array().lengthGreaterThanOrEqual(min).lengthLessThanOrEqual(max).setValidationEnabled(isValidationEnabled).parse(input);
|
|
1533
1533
|
}
|
|
1534
1534
|
__name(validateComponentArray, "validateComponentArray");
|
|
1535
1535
|
|
|
@@ -1865,7 +1865,6 @@ var ContainerBuilder = class extends ComponentBuilder {
|
|
|
1865
1865
|
* {@inheritDoc ComponentBuilder.toJSON}
|
|
1866
1866
|
*/
|
|
1867
1867
|
toJSON() {
|
|
1868
|
-
validateComponentArray(this.components, 1, 10);
|
|
1869
1868
|
return {
|
|
1870
1869
|
...this.data,
|
|
1871
1870
|
components: this.components.map((component) => component.toJSON())
|
|
@@ -3681,7 +3680,7 @@ function embedLength(data) {
|
|
|
3681
3680
|
__name(embedLength, "embedLength");
|
|
3682
3681
|
|
|
3683
3682
|
// src/index.ts
|
|
3684
|
-
var version = "1.11.
|
|
3683
|
+
var version = "1.11.2";
|
|
3685
3684
|
// Annotate the CommonJS export names for ESM import in node:
|
|
3686
3685
|
0 && (module.exports = {
|
|
3687
3686
|
ActionRowBuilder,
|