|
@ -8,14 +8,25 @@ export const data = new SlashCommandBuilder() |
|
|
.setName('settings') |
|
|
.setName('settings') |
|
|
.setDescription('BETA - settings configuration'); |
|
|
.setDescription('BETA - settings configuration'); |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
export async function execute(interaction : CommandInteraction) { |
|
|
export async function execute(interaction : CommandInteraction) { |
|
|
await interaction.deferReply(); |
|
|
await interaction.deferReply(); |
|
|
|
|
|
const testEmbed = new MessageEmbed() |
|
|
|
|
|
.setColor('#ffffff'); |
|
|
|
|
|
const testEmbed2 = new MessageEmbed() |
|
|
|
|
|
.setColor('#ffffff'); |
|
|
const settingsEmbed = new MessageEmbed() |
|
|
const settingsEmbed = new MessageEmbed() |
|
|
.setColor('#ffffff'); |
|
|
.setColor('#ffffff'); |
|
|
|
|
|
|
|
|
const user = interaction.options.getUser('user') || interaction.user; |
|
|
const user = interaction.options.getUser('user') || interaction.user; |
|
|
|
|
|
|
|
|
|
|
|
testEmbed |
|
|
|
|
|
.setAuthor({ name: user.tag, iconURL: user.displayAvatarURL() }) |
|
|
|
|
|
.setDescription(`b`); |
|
|
|
|
|
|
|
|
|
|
|
testEmbed2 |
|
|
|
|
|
.setAuthor({ name: user.tag, iconURL: user.displayAvatarURL() }) |
|
|
|
|
|
.setDescription(`c`); |
|
|
|
|
|
|
|
|
settingsEmbed |
|
|
settingsEmbed |
|
|
.setAuthor({ name: user.tag, iconURL: user.displayAvatarURL() }) |
|
|
.setAuthor({ name: user.tag, iconURL: user.displayAvatarURL() }) |
|
|
.setDescription(`a`); |
|
|
.setDescription(`a`); |
|
@ -37,20 +48,17 @@ export async function execute(interaction : CommandInteraction) { |
|
|
}, |
|
|
}, |
|
|
]), |
|
|
]), |
|
|
); |
|
|
); |
|
|
await interaction.followUp({ embeds: [settingsEmbed], components: [menu] }); |
|
|
await interaction.followUp({ embeds: [settingsEmbed], components: [menu] }); |
|
|
await interaction.deferReply; |
|
|
client.on('interactionCreate', async interaction => { |
|
|
const client = interaction.client; |
|
|
if (!interaction.isSelectMenu()) return; |
|
|
client.on('interactionCreate', async interaction => { |
|
|
var values = interaction.values[1]; |
|
|
if (!interaction.isSelectMenu()) return; |
|
|
switch(values) { |
|
|
var values = interaction.values[1]; |
|
|
case "subjects": |
|
|
switch(values) { |
|
|
await interaction.reply({ embeds: [testEmbed] }) |
|
|
case "subjects": |
|
|
break; |
|
|
await interaction.followUp({ content: 'subjects was selected!', components: [] }); |
|
|
case "gradeLevels": |
|
|
break; |
|
|
await interaction.reply({ embeds: [testEmbed2] }) |
|
|
case "gradeLevels": |
|
|
break; |
|
|
await interaction.followUp({ content: 'levels was selected!', components: [] }); |
|
|
} |
|
|
break; |
|
|
}); |
|
|
} |
|
|
} |
|
|
}); |
|
|
|
|
|
|
|
|
|
|
|
} |
|
|
|