@magicyan/discord 1.0.28 → 1.0.30
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/README.md +30 -1
- package/dist/functions/channels.cjs +15 -15
- package/dist/functions/channels.mjs +15 -15
- package/dist/functions/embeds/assets.cjs +2 -2
- package/dist/functions/embeds/assets.mjs +2 -2
- package/dist/functions/embeds/author.cjs +27 -24
- package/dist/functions/embeds/author.mjs +27 -24
- package/dist/functions/embeds/embedplus.cjs +8 -5
- package/dist/functions/embeds/embedplus.mjs +8 -5
- package/dist/functions/embeds/fields.cjs +10 -0
- package/dist/functions/embeds/fields.mjs +10 -0
- package/dist/index.cjs +12 -12
- package/dist/index.d.cts +139 -123
- package/dist/index.d.mts +139 -123
- package/dist/index.d.ts +139 -123
- package/dist/index.mjs +5 -5
- package/package.json +1 -1
package/README.md
CHANGED
|
@@ -114,8 +114,37 @@ function run(interaction: ModalSubmitInteraction){
|
|
|
114
114
|
console.log(fields.bio);
|
|
115
115
|
}
|
|
116
116
|
```
|
|
117
|
+
|
|
117
118
|
## Embeds
|
|
118
|
-
|
|
119
|
+
Easily create embeds with this function
|
|
120
|
+
```ts
|
|
121
|
+
const embed = createEmbed({
|
|
122
|
+
title: "Welcome",
|
|
123
|
+
description: "Hello world",
|
|
124
|
+
color: "Random"
|
|
125
|
+
});
|
|
126
|
+
```
|
|
127
|
+
You can set the thumbnail and image in a simple way
|
|
128
|
+
```ts
|
|
129
|
+
const embed = createEmbed({
|
|
130
|
+
// ...
|
|
131
|
+
thumbnail: "https://github.com/rinckodev.png",
|
|
132
|
+
image: guild.iconURL()
|
|
133
|
+
});
|
|
134
|
+
|
|
135
|
+
// Or passing an options object
|
|
136
|
+
const embed = createEmbed({
|
|
137
|
+
// ...
|
|
138
|
+
image: { url: "imageurl", width: 400, height: 100 }
|
|
139
|
+
});
|
|
140
|
+
|
|
141
|
+
//Or passing an attachment
|
|
142
|
+
const attachment = new AttachmentBuilder(buffer, { name: "myimage.png" });
|
|
143
|
+
const embed = createEmbed({
|
|
144
|
+
// ...
|
|
145
|
+
image: attachment // attachment://myimage.png
|
|
146
|
+
});
|
|
147
|
+
```
|
|
119
148
|
|
|
120
149
|
## Channels
|
|
121
150
|
You can try to get information from a channel url
|
|
@@ -6,53 +6,53 @@ function findChannel(guild, type) {
|
|
|
6
6
|
const channelType = type ?? discord_js.ChannelType.GuildText;
|
|
7
7
|
const cache = guild.channels.cache;
|
|
8
8
|
return {
|
|
9
|
-
|
|
9
|
+
byId(id) {
|
|
10
10
|
return cache.find(
|
|
11
|
-
(c) => c.
|
|
11
|
+
(c) => c.id === id && c.type === channelType
|
|
12
12
|
);
|
|
13
13
|
},
|
|
14
|
-
|
|
14
|
+
byName(name, and = () => true) {
|
|
15
15
|
return cache.find(
|
|
16
|
-
(c) => c.
|
|
16
|
+
(c) => c.name === name && c.type === channelType && and(c)
|
|
17
17
|
);
|
|
18
18
|
},
|
|
19
19
|
byFilter(filter) {
|
|
20
|
-
return cache.find((c) => c.type == type && filter);
|
|
20
|
+
return cache.find((c) => c.type == type && filter(c));
|
|
21
21
|
},
|
|
22
22
|
inCategoryId(id) {
|
|
23
23
|
return {
|
|
24
|
-
|
|
24
|
+
byId(id2) {
|
|
25
25
|
return cache.find(
|
|
26
|
-
(c) => c.
|
|
26
|
+
(c) => c.id === id2 && c.type === channelType && c.parentId == id2
|
|
27
27
|
);
|
|
28
28
|
},
|
|
29
|
-
|
|
29
|
+
byName(name, and = () => true) {
|
|
30
30
|
return cache.find(
|
|
31
|
-
(c) => c.
|
|
31
|
+
(c) => c.name === name && c.type === channelType && c.parentId == id && and(c)
|
|
32
32
|
);
|
|
33
33
|
},
|
|
34
34
|
byFilter(filter) {
|
|
35
35
|
return cache.find(
|
|
36
|
-
(c) => c.type === channelType && c.parent?.id == id && filter
|
|
36
|
+
(c) => c.type === channelType && c.parent?.id == id && filter(c)
|
|
37
37
|
);
|
|
38
38
|
}
|
|
39
39
|
};
|
|
40
40
|
},
|
|
41
41
|
inCategoryName(name) {
|
|
42
42
|
return {
|
|
43
|
-
|
|
43
|
+
byId(id) {
|
|
44
44
|
return cache.find(
|
|
45
|
-
(c) => c.
|
|
45
|
+
(c) => c.id === id && c.type === channelType && c.parent?.name == name
|
|
46
46
|
);
|
|
47
47
|
},
|
|
48
|
-
|
|
48
|
+
byName(name2, and = () => true) {
|
|
49
49
|
return cache.find(
|
|
50
|
-
(c) => c.
|
|
50
|
+
(c) => c.name === name2 && c.type === channelType && c.parent?.name == name2 && and(c)
|
|
51
51
|
);
|
|
52
52
|
},
|
|
53
53
|
byFilter(filter) {
|
|
54
54
|
return cache.find(
|
|
55
|
-
(c) => c.type === channelType && c.parent?.name == name && filter
|
|
55
|
+
(c) => c.type === channelType && c.parent?.name == name && filter(c)
|
|
56
56
|
);
|
|
57
57
|
}
|
|
58
58
|
};
|
|
@@ -4,53 +4,53 @@ function findChannel(guild, type) {
|
|
|
4
4
|
const channelType = type ?? ChannelType.GuildText;
|
|
5
5
|
const cache = guild.channels.cache;
|
|
6
6
|
return {
|
|
7
|
-
|
|
7
|
+
byId(id) {
|
|
8
8
|
return cache.find(
|
|
9
|
-
(c) => c.
|
|
9
|
+
(c) => c.id === id && c.type === channelType
|
|
10
10
|
);
|
|
11
11
|
},
|
|
12
|
-
|
|
12
|
+
byName(name, and = () => true) {
|
|
13
13
|
return cache.find(
|
|
14
|
-
(c) => c.
|
|
14
|
+
(c) => c.name === name && c.type === channelType && and(c)
|
|
15
15
|
);
|
|
16
16
|
},
|
|
17
17
|
byFilter(filter) {
|
|
18
|
-
return cache.find((c) => c.type == type && filter);
|
|
18
|
+
return cache.find((c) => c.type == type && filter(c));
|
|
19
19
|
},
|
|
20
20
|
inCategoryId(id) {
|
|
21
21
|
return {
|
|
22
|
-
|
|
22
|
+
byId(id2) {
|
|
23
23
|
return cache.find(
|
|
24
|
-
(c) => c.
|
|
24
|
+
(c) => c.id === id2 && c.type === channelType && c.parentId == id2
|
|
25
25
|
);
|
|
26
26
|
},
|
|
27
|
-
|
|
27
|
+
byName(name, and = () => true) {
|
|
28
28
|
return cache.find(
|
|
29
|
-
(c) => c.
|
|
29
|
+
(c) => c.name === name && c.type === channelType && c.parentId == id && and(c)
|
|
30
30
|
);
|
|
31
31
|
},
|
|
32
32
|
byFilter(filter) {
|
|
33
33
|
return cache.find(
|
|
34
|
-
(c) => c.type === channelType && c.parent?.id == id && filter
|
|
34
|
+
(c) => c.type === channelType && c.parent?.id == id && filter(c)
|
|
35
35
|
);
|
|
36
36
|
}
|
|
37
37
|
};
|
|
38
38
|
},
|
|
39
39
|
inCategoryName(name) {
|
|
40
40
|
return {
|
|
41
|
-
|
|
41
|
+
byId(id) {
|
|
42
42
|
return cache.find(
|
|
43
|
-
(c) => c.
|
|
43
|
+
(c) => c.id === id && c.type === channelType && c.parent?.name == name
|
|
44
44
|
);
|
|
45
45
|
},
|
|
46
|
-
|
|
46
|
+
byName(name2, and = () => true) {
|
|
47
47
|
return cache.find(
|
|
48
|
-
(c) => c.
|
|
48
|
+
(c) => c.name === name2 && c.type === channelType && c.parent?.name == name2 && and(c)
|
|
49
49
|
);
|
|
50
50
|
},
|
|
51
51
|
byFilter(filter) {
|
|
52
52
|
return cache.find(
|
|
53
|
-
(c) => c.type === channelType && c.parent?.name == name && filter
|
|
53
|
+
(c) => c.type === channelType && c.parent?.name == name && filter(c)
|
|
54
54
|
);
|
|
55
55
|
}
|
|
56
56
|
};
|
|
@@ -7,9 +7,9 @@ function createEmbedAsset(source, options) {
|
|
|
7
7
|
return { url: `attachment://${source.name}`, ...options };
|
|
8
8
|
}
|
|
9
9
|
if (source && typeof source === "object" && "url" in source) {
|
|
10
|
-
return source;
|
|
10
|
+
return Object.assign(source, options ?? (options = {}));
|
|
11
11
|
}
|
|
12
|
-
return source ? { url: source,
|
|
12
|
+
return source ? Object.assign({ url: source }, options) : void 0;
|
|
13
13
|
}
|
|
14
14
|
|
|
15
15
|
exports.createEmbedAsset = createEmbedAsset;
|
|
@@ -5,9 +5,9 @@ function createEmbedAsset(source, options) {
|
|
|
5
5
|
return { url: `attachment://${source.name}`, ...options };
|
|
6
6
|
}
|
|
7
7
|
if (source && typeof source === "object" && "url" in source) {
|
|
8
|
-
return source;
|
|
8
|
+
return Object.assign(source, options ?? (options = {}));
|
|
9
9
|
}
|
|
10
|
-
return source ? { url: source,
|
|
10
|
+
return source ? Object.assign({ url: source }, options) : void 0;
|
|
11
11
|
}
|
|
12
12
|
|
|
13
13
|
export { createEmbedAsset };
|
|
@@ -1,30 +1,33 @@
|
|
|
1
1
|
'use strict';
|
|
2
2
|
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
const
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
displayName
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
3
|
+
const discord_js = require('discord.js');
|
|
4
|
+
|
|
5
|
+
function createEmbedAuthor(type, options) {
|
|
6
|
+
const { prefix = "", suffix = "", url, iconURL: icon, extension, forceStatic, size = 1024 } = options ?? {};
|
|
7
|
+
let name = "";
|
|
8
|
+
let iconURL = icon;
|
|
9
|
+
const imageOptions = { extension, forceStatic, size };
|
|
10
|
+
switch (true) {
|
|
11
|
+
case type instanceof discord_js.User: {
|
|
12
|
+
const { property = "displayName" } = options ?? {};
|
|
13
|
+
name = type[property] ?? type.displayName;
|
|
14
|
+
iconURL = type.displayAvatarURL(imageOptions);
|
|
15
|
+
break;
|
|
16
|
+
}
|
|
17
|
+
case type instanceof discord_js.GuildMember: {
|
|
18
|
+
const { property = "displayName" } = options ?? {};
|
|
19
|
+
name = (property == "username" || property == "globalName" ? type.user[property] : type[property]) ?? type.displayName;
|
|
20
|
+
iconURL = type.displayAvatarURL(imageOptions);
|
|
21
|
+
break;
|
|
22
|
+
}
|
|
23
|
+
case type instanceof discord_js.Guild: {
|
|
24
|
+
const { property = "name" } = options ?? {};
|
|
25
|
+
name = type[property];
|
|
26
|
+
iconURL = type.iconURL(imageOptions) ?? void 0;
|
|
27
|
+
break;
|
|
28
|
+
}
|
|
21
29
|
}
|
|
22
|
-
|
|
23
|
-
return {
|
|
24
|
-
name: `${prefix}${options.user[property]}${suffix}`,
|
|
25
|
-
url,
|
|
26
|
-
iconURL: iconURL || user.displayAvatarURL(avatarOptions)
|
|
27
|
-
};
|
|
30
|
+
return { name: `${prefix}${name}${suffix}`, url: url ?? void 0, iconURL };
|
|
28
31
|
}
|
|
29
32
|
|
|
30
33
|
exports.createEmbedAuthor = createEmbedAuthor;
|
|
@@ -1,28 +1,31 @@
|
|
|
1
|
-
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
const
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
displayName
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
1
|
+
import { Guild, GuildMember, User } from 'discord.js';
|
|
2
|
+
|
|
3
|
+
function createEmbedAuthor(type, options) {
|
|
4
|
+
const { prefix = "", suffix = "", url, iconURL: icon, extension, forceStatic, size = 1024 } = options ?? {};
|
|
5
|
+
let name = "";
|
|
6
|
+
let iconURL = icon;
|
|
7
|
+
const imageOptions = { extension, forceStatic, size };
|
|
8
|
+
switch (true) {
|
|
9
|
+
case type instanceof User: {
|
|
10
|
+
const { property = "displayName" } = options ?? {};
|
|
11
|
+
name = type[property] ?? type.displayName;
|
|
12
|
+
iconURL = type.displayAvatarURL(imageOptions);
|
|
13
|
+
break;
|
|
14
|
+
}
|
|
15
|
+
case type instanceof GuildMember: {
|
|
16
|
+
const { property = "displayName" } = options ?? {};
|
|
17
|
+
name = (property == "username" || property == "globalName" ? type.user[property] : type[property]) ?? type.displayName;
|
|
18
|
+
iconURL = type.displayAvatarURL(imageOptions);
|
|
19
|
+
break;
|
|
20
|
+
}
|
|
21
|
+
case type instanceof Guild: {
|
|
22
|
+
const { property = "name" } = options ?? {};
|
|
23
|
+
name = type[property];
|
|
24
|
+
iconURL = type.iconURL(imageOptions) ?? void 0;
|
|
25
|
+
break;
|
|
26
|
+
}
|
|
19
27
|
}
|
|
20
|
-
|
|
21
|
-
return {
|
|
22
|
-
name: `${prefix}${options.user[property]}${suffix}`,
|
|
23
|
-
url,
|
|
24
|
-
iconURL: iconURL || user.displayAvatarURL(avatarOptions)
|
|
25
|
-
};
|
|
28
|
+
return { name: `${prefix}${name}${suffix}`, url: url ?? void 0, iconURL };
|
|
26
29
|
}
|
|
27
30
|
|
|
28
31
|
export { createEmbedAuthor };
|
|
@@ -15,7 +15,7 @@ var __publicField = (obj, key, value) => {
|
|
|
15
15
|
class EmbedPlusBuilder extends discord_js.EmbedBuilder {
|
|
16
16
|
constructor(data) {
|
|
17
17
|
const { mergeFields = false, extends: extendsEmbed, ...embedData } = data;
|
|
18
|
-
const extendsEmbedData = extendsEmbed ? "data" in extendsEmbed ? extendsEmbed.data :
|
|
18
|
+
const extendsEmbedData = extendsEmbed ? "data" in extendsEmbed ? extendsEmbed.data : extendsEmbed : {};
|
|
19
19
|
const { fields: extendsFields, ...extendsData } = extendsEmbedData;
|
|
20
20
|
const fields$1 = (mergeFields ? [extendsFields ?? [], data.fields ?? []].flat() : data.fields ?? extendsFields ?? []).map((field) => Object.assign(
|
|
21
21
|
{ name: field.name ?? chars.chars.invisible, value: field.value ?? chars.chars.invisible },
|
|
@@ -57,16 +57,19 @@ class EmbedPlusBuilder extends discord_js.EmbedBuilder {
|
|
|
57
57
|
setBorderColor(color) {
|
|
58
58
|
if (color === null) {
|
|
59
59
|
this.setColor("#2B2D31");
|
|
60
|
+
} else if (typeof color === "number") {
|
|
61
|
+
this.update({ color });
|
|
60
62
|
} else {
|
|
61
63
|
this.setColor(color);
|
|
62
64
|
}
|
|
63
65
|
return this;
|
|
64
66
|
}
|
|
65
67
|
setAsset(asset, source) {
|
|
66
|
-
|
|
67
|
-
|
|
68
|
-
|
|
69
|
-
|
|
68
|
+
if (source === null) {
|
|
69
|
+
asset === "image" ? this.setImage(source) : this.setThumbnail(source);
|
|
70
|
+
} else {
|
|
71
|
+
this.update({ [asset]: source });
|
|
72
|
+
}
|
|
70
73
|
return this;
|
|
71
74
|
}
|
|
72
75
|
static fromInteraction(interaction, index = 0, data = {}) {
|
|
@@ -13,7 +13,7 @@ var __publicField = (obj, key, value) => {
|
|
|
13
13
|
class EmbedPlusBuilder extends EmbedBuilder {
|
|
14
14
|
constructor(data) {
|
|
15
15
|
const { mergeFields = false, extends: extendsEmbed, ...embedData } = data;
|
|
16
|
-
const extendsEmbedData = extendsEmbed ? "data" in extendsEmbed ? extendsEmbed.data :
|
|
16
|
+
const extendsEmbedData = extendsEmbed ? "data" in extendsEmbed ? extendsEmbed.data : extendsEmbed : {};
|
|
17
17
|
const { fields: extendsFields, ...extendsData } = extendsEmbedData;
|
|
18
18
|
const fields = (mergeFields ? [extendsFields ?? [], data.fields ?? []].flat() : data.fields ?? extendsFields ?? []).map((field) => Object.assign(
|
|
19
19
|
{ name: field.name ?? chars.invisible, value: field.value ?? chars.invisible },
|
|
@@ -55,16 +55,19 @@ class EmbedPlusBuilder extends EmbedBuilder {
|
|
|
55
55
|
setBorderColor(color) {
|
|
56
56
|
if (color === null) {
|
|
57
57
|
this.setColor("#2B2D31");
|
|
58
|
+
} else if (typeof color === "number") {
|
|
59
|
+
this.update({ color });
|
|
58
60
|
} else {
|
|
59
61
|
this.setColor(color);
|
|
60
62
|
}
|
|
61
63
|
return this;
|
|
62
64
|
}
|
|
63
65
|
setAsset(asset, source) {
|
|
64
|
-
|
|
65
|
-
|
|
66
|
-
|
|
67
|
-
|
|
66
|
+
if (source === null) {
|
|
67
|
+
asset === "image" ? this.setImage(source) : this.setThumbnail(source);
|
|
68
|
+
} else {
|
|
69
|
+
this.update({ [asset]: source });
|
|
70
|
+
}
|
|
68
71
|
return this;
|
|
69
72
|
}
|
|
70
73
|
static fromInteraction(interaction, index = 0, data = {}) {
|
|
@@ -57,6 +57,9 @@ class EmbedPlusFields {
|
|
|
57
57
|
set(...fields) {
|
|
58
58
|
this.embed.setFields(fields);
|
|
59
59
|
}
|
|
60
|
+
map(callback) {
|
|
61
|
+
return this.toArray().map(callback);
|
|
62
|
+
}
|
|
60
63
|
update(predicate, field) {
|
|
61
64
|
const index = this.getPredicateIndex(predicate);
|
|
62
65
|
if (index == -1)
|
|
@@ -77,6 +80,13 @@ class EmbedPlusFields {
|
|
|
77
80
|
this.embed.spliceFields(index, 1);
|
|
78
81
|
return true;
|
|
79
82
|
}
|
|
83
|
+
/**
|
|
84
|
+
* Remove all fields
|
|
85
|
+
*/
|
|
86
|
+
clear() {
|
|
87
|
+
this.fields = [];
|
|
88
|
+
return this;
|
|
89
|
+
}
|
|
80
90
|
toArray() {
|
|
81
91
|
return Array.from(this);
|
|
82
92
|
}
|
|
@@ -55,6 +55,9 @@ class EmbedPlusFields {
|
|
|
55
55
|
set(...fields) {
|
|
56
56
|
this.embed.setFields(fields);
|
|
57
57
|
}
|
|
58
|
+
map(callback) {
|
|
59
|
+
return this.toArray().map(callback);
|
|
60
|
+
}
|
|
58
61
|
update(predicate, field) {
|
|
59
62
|
const index = this.getPredicateIndex(predicate);
|
|
60
63
|
if (index == -1)
|
|
@@ -75,6 +78,13 @@ class EmbedPlusFields {
|
|
|
75
78
|
this.embed.spliceFields(index, 1);
|
|
76
79
|
return true;
|
|
77
80
|
}
|
|
81
|
+
/**
|
|
82
|
+
* Remove all fields
|
|
83
|
+
*/
|
|
84
|
+
clear() {
|
|
85
|
+
this.fields = [];
|
|
86
|
+
return this;
|
|
87
|
+
}
|
|
78
88
|
toArray() {
|
|
79
89
|
return Array.from(this);
|
|
80
90
|
}
|
package/dist/index.cjs
CHANGED
|
@@ -3,19 +3,19 @@
|
|
|
3
3
|
const chars = require('./constants/chars.cjs');
|
|
4
4
|
const client = require('./constants/client.cjs');
|
|
5
5
|
const misc = require('./functions/misc.cjs');
|
|
6
|
+
const assets = require('./functions/embeds/assets.cjs');
|
|
7
|
+
const author = require('./functions/embeds/author.cjs');
|
|
8
|
+
const embedplus = require('./functions/embeds/embedplus.cjs');
|
|
9
|
+
const footer = require('./functions/embeds/footer.cjs');
|
|
10
|
+
const components = require('./functions/components.cjs');
|
|
6
11
|
const channels = require('./functions/channels.cjs');
|
|
7
12
|
const commands = require('./functions/commands.cjs');
|
|
8
|
-
const components = require('./functions/components.cjs');
|
|
9
13
|
const modals = require('./functions/modals.cjs');
|
|
10
14
|
const emojis = require('./functions/emojis.cjs');
|
|
11
15
|
const members = require('./functions/members.cjs');
|
|
12
16
|
const message = require('./functions/message.cjs');
|
|
13
17
|
const roles = require('./functions/roles.cjs');
|
|
14
18
|
const regex = require('./functions/regex.cjs');
|
|
15
|
-
const assets = require('./functions/embeds/assets.cjs');
|
|
16
|
-
const author = require('./functions/embeds/author.cjs');
|
|
17
|
-
const embedplus = require('./functions/embeds/embedplus.cjs');
|
|
18
|
-
const footer = require('./functions/embeds/footer.cjs');
|
|
19
19
|
const core = require('@magicyan/core');
|
|
20
20
|
|
|
21
21
|
|
|
@@ -24,11 +24,16 @@ exports.chars = chars.chars;
|
|
|
24
24
|
exports.CustomItents = client.CustomItents;
|
|
25
25
|
exports.CustomPartials = client.CustomPartials;
|
|
26
26
|
exports.setMobileStatus = misc.setMobileStatus;
|
|
27
|
+
exports.createEmbedAsset = assets.createEmbedAsset;
|
|
28
|
+
exports.createEmbedAuthor = author.createEmbedAuthor;
|
|
29
|
+
exports.EmbedPlusBuilder = embedplus.EmbedPlusBuilder;
|
|
30
|
+
exports.createEmbed = embedplus.createEmbed;
|
|
31
|
+
exports.createEmbedFooter = footer.createEmbedFooter;
|
|
32
|
+
exports.createLinkButton = components.createLinkButton;
|
|
33
|
+
exports.createRow = components.createRow;
|
|
27
34
|
exports.findChannel = channels.findChannel;
|
|
28
35
|
exports.getChannelUrlInfo = channels.getChannelUrlInfo;
|
|
29
36
|
exports.findCommand = commands.findCommand;
|
|
30
|
-
exports.createLinkButton = components.createLinkButton;
|
|
31
|
-
exports.createRow = components.createRow;
|
|
32
37
|
exports.createModalFields = modals.createModalFields;
|
|
33
38
|
exports.createModalInput = modals.createModalInput;
|
|
34
39
|
exports.modalFieldsToRecord = modals.modalFieldsToRecord;
|
|
@@ -38,11 +43,6 @@ exports.findMessage = message.findMessage;
|
|
|
38
43
|
exports.getMessageUrlInfo = message.getMessageUrlInfo;
|
|
39
44
|
exports.findRole = roles.findRole;
|
|
40
45
|
exports.extractMentionId = regex.extractMentionId;
|
|
41
|
-
exports.createEmbedAsset = assets.createEmbedAsset;
|
|
42
|
-
exports.createEmbedAuthor = author.createEmbedAuthor;
|
|
43
|
-
exports.EmbedPlusBuilder = embedplus.EmbedPlusBuilder;
|
|
44
|
-
exports.createEmbed = embedplus.createEmbed;
|
|
45
|
-
exports.createEmbedFooter = footer.createEmbedFooter;
|
|
46
46
|
Object.keys(core).forEach(function (k) {
|
|
47
47
|
if (k !== 'default' && !Object.prototype.hasOwnProperty.call(exports, k)) exports[k] = core[k];
|
|
48
48
|
});
|