Mateleo
Mateleo
SIASapphire - Imagine a framework
Created by Mikkel on 7/11/2023 in #sapphire-support
Question - handling interactions
@Mikkel Have you done it ? I would love to see an example of an expiration of a button
15 replies
SIASapphire - Imagine a framework
Created by Mateleo on 12/15/2023 in #sapphire-support
Global precondition error
perfect ! Maybe I can write a PR to update the doc ?
7 replies
SIASapphire - Imagine a framework
Created by Mateleo on 11/9/2023 in #sapphire-support
props to button
Your solution is working perfectly thnks !
13 replies
SIASapphire - Imagine a framework
Created by Mateleo on 11/9/2023 in #sapphire-support
props to button
Thks a lot will try something like this
13 replies
SIASapphire - Imagine a framework
Created by Mateleo on 11/9/2023 in #sapphire-support
props to button
So I would like to retrieve the data in the button logic too
13 replies
SIASapphire - Imagine a framework
Created by Mateleo on 11/9/2023 in #sapphire-support
props to button
I have an addUserOption() in the slash command
13 replies
SIASapphire - Imagine a framework
Created by Mateleo on 11/9/2023 in #sapphire-support
props to button
And also what about interaction.options ?
13 replies
SIASapphire - Imagine a framework
Created by Mateleo on 11/9/2023 in #sapphire-support
props to button
from chatInputRun --> InteractionHandler
13 replies
SIASapphire - Imagine a framework
Created by Mateleo on 10/29/2023 in #sapphire-support
Global precondition
Thank you very much 🙏
14 replies
SIASapphire - Imagine a framework
Created by Mateleo on 10/29/2023 in #sapphire-support
Global precondition
No description
14 replies
SIASapphire - Imagine a framework
Created by Mateleo on 10/29/2023 in #sapphire-support
Global precondition
Il will check that
14 replies
SIASapphire - Imagine a framework
Created by Mateleo on 10/29/2023 in #sapphire-support
Global precondition
Any idea?
14 replies
SIASapphire - Imagine a framework
Created by Mateleo on 10/29/2023 in #sapphire-support
Global precondition
The main issue is that no reply is send to the client, and "commandDenied" doesn't seems to be used
14 replies
SIASapphire - Imagine a framework
Created by Mateleo on 10/29/2023 in #sapphire-support
Global precondition
My goal is to reject every slashcommands based on a single role check
14 replies
SIASapphire - Imagine a framework
Created by Mateleo on 10/29/2023 in #sapphire-support
Global precondition
No description
14 replies
SIASapphire - Imagine a framework
Created by Mateleo on 10/29/2023 in #sapphire-support
Global precondition
The error is "The application did not respond" I'm pretty sure it's because I'm not able to link those two files
14 replies
SIASapphire - Imagine a framework
Created by Mateleo on 10/29/2023 in #sapphire-support
Global precondition
import { Events, Listener, type ChatInputCommandDeniedPayload, type UserError } from "@sapphire/framework";

export class ChatInputCommandDenied extends Listener<typeof Events.ChatInputCommandDenied> {
public run(error: UserError, { interaction }: ChatInputCommandDeniedPayload) {
const isSilent = Reflect.get(Object(error.context), "silent");

if (interaction.deferred || interaction.replied) {
return interaction.editReply({
content: isSilent ? "\u200b" : error.message,
});
}

return interaction.reply({
content: isSilent ? "\u200b" : error.message,
ephemeral: true,
});
}
}
import { Events, Listener, type ChatInputCommandDeniedPayload, type UserError } from "@sapphire/framework";

export class ChatInputCommandDenied extends Listener<typeof Events.ChatInputCommandDenied> {
public run(error: UserError, { interaction }: ChatInputCommandDeniedPayload) {
const isSilent = Reflect.get(Object(error.context), "silent");

if (interaction.deferred || interaction.replied) {
return interaction.editReply({
content: isSilent ? "\u200b" : error.message,
});
}

return interaction.reply({
content: isSilent ? "\u200b" : error.message,
ephemeral: true,
});
}
}
14 replies
SIASapphire - Imagine a framework
Created by Mateleo on 9/6/2023 in #sapphire-support
Issue with pnpm (A type annotation is necessary)
Indeed the final answer is Promise<Option<{name:string, value:string}[]
8 replies
SIASapphire - Imagine a framework
Created by Mateleo on 9/6/2023 in #sapphire-support
Issue with pnpm (A type annotation is necessary)
Thank you so much, I finally found it Promise<Option.None | Option.Some<{name:string, value:string}[]>>
8 replies