1 |
import { MessageEmbed, User, MessageEmbedOptions } from 'discord.js'; |
import { MessageEmbed, User, MessageEmbedOptions } from 'discord.js'; |
2 |
|
|
3 |
export class ModerationEmbed extends MessageEmbed { |
export default class ModerationEmbed extends MessageEmbed { |
4 |
constructor(protected user: User, protected mod: User, options?: MessageEmbedOptions) { |
constructor(protected user: User, protected mod: User, options?: MessageEmbedOptions) { |
5 |
super({ |
super({ |
6 |
author: { |
author: { |
10 |
...options |
...options |
11 |
}); |
}); |
12 |
|
|
13 |
this.addField('Executor', [ |
this.addField('Executor', `Tag: ${mod.tag}\nID: ${mod.id}`); |
|
`Tag: ${mod.tag}`, |
|
|
`ID: ${mod.id}` |
|
|
]); |
|
14 |
|
|
15 |
this.setFooter({ |
this.setFooter({ |
16 |
text: `${user.id}` |
text: `${user.id}` |
28 |
else { |
else { |
29 |
this.addField('Reason', '*No reason provided*'); |
this.addField('Reason', '*No reason provided*'); |
30 |
} |
} |
31 |
|
|
32 |
|
return this; |
33 |
} |
} |
34 |
} |
} |