Add server emoji picker
This commit is contained in:
@ -59,6 +59,11 @@ type RoleInfo = {
|
||||
name: string;
|
||||
};
|
||||
|
||||
type EmojiInfo = {
|
||||
fmt: string;
|
||||
name: string;
|
||||
};
|
||||
|
||||
type Template = {
|
||||
id: number;
|
||||
name: string;
|
||||
@ -125,6 +130,15 @@ export const fetchGuildRoles = (guild: string) => ({
|
||||
staleTime: GUILD_INFO_STALE_TIME,
|
||||
});
|
||||
|
||||
export const fetchGuildEmojis = (guild: string) => ({
|
||||
queryKey: ["GUILD_EMOJIS", guild],
|
||||
queryFn: () =>
|
||||
axios.get(`/dashboard/api/guild/${guild}/emojis`).then((resp) => resp.data) as Promise<
|
||||
EmojiInfo[]
|
||||
>,
|
||||
staleTime: GUILD_INFO_STALE_TIME,
|
||||
});
|
||||
|
||||
export const fetchGuildReminders = (guild: string) => ({
|
||||
queryKey: ["GUILD_REMINDERS", guild],
|
||||
queryFn: () =>
|
||||
|
Reference in New Issue
Block a user