-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
6 changed files
with
30 additions
and
26 deletions.
There are no files selected for viewing
15 changes: 15 additions & 0 deletions
15
plugins/tickets/src/discord/components/Template/ButtonConfig.ts
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,15 @@ | ||
import { TemplateBuilder } from "@/class/TemplateBuilder.js"; | ||
import { Component } from "@/discord/base/index.js"; | ||
|
||
new Component({ | ||
customId: 'Config', | ||
type: "Button", | ||
async run(interaction) { | ||
await interaction.deferReply({ ephemeral: true }) | ||
await new TemplateBuilder({ interaction }) | ||
.setMode('debug') | ||
.edit({ messageId: interaction.message.id }) | ||
|
||
if (interaction.deferred && !interaction.replied) await interaction.deleteReply() | ||
} | ||
}) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
File renamed without changes.
15 changes: 15 additions & 0 deletions
15
plugins/tickets/src/discord/components/Template/ButtonSave.ts
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,15 @@ | ||
import { TemplateBuilder } from "@/class/TemplateBuilder.js"; | ||
import { Component } from "@/discord/base/index.js"; | ||
|
||
new Component({ | ||
customId: 'Save', | ||
type: "Button", | ||
async run(interaction) { | ||
await interaction.deferReply({ ephemeral: true }) | ||
await new TemplateBuilder({ interaction }) | ||
.setMode('production') | ||
.edit({ messageId: interaction.message.id }) | ||
|
||
if (!interaction.replied) await interaction.deleteReply() | ||
} | ||
}) |
File renamed without changes.
File renamed without changes.