From 137401630e5b2944cf2f173e5572a94f76943d9d Mon Sep 17 00:00:00 2001 From: Taken Date: Fri, 16 Feb 2024 15:31:30 +0100 Subject: [PATCH] Updated interfacess and types --- .../{Autocomplete.ts => IAutocomplete.ts} | 2 +- src/interfaces/{Button.ts => IButton.ts} | 2 +- src/interfaces/{Command.ts => ICommand.ts} | 3 +- .../{ContextMenu.ts => IContextMenu.ts} | 2 +- src/interfaces/{Cron.ts => ICron.ts} | 6 +- src/interfaces/{Env.ts => IEnv.ts} | 2 +- src/interfaces/{Event.ts => IEvent.ts} | 2 +- src/interfaces/{Guild.ts => IGuild.ts} | 6 +- src/interfaces/{Modal.ts => IModal.ts} | 2 +- src/interfaces/{Player.ts => IPlayer.ts} | 134 +++--- src/interfaces/TimeZones.ts | 430 ----------------- src/interfaces/index.ts | 46 +- src/typings/TimeZones.ts | 432 ++++++++++++++++++ src/typings/index.ts | 5 +- 14 files changed, 538 insertions(+), 536 deletions(-) rename src/interfaces/{Autocomplete.ts => IAutocomplete.ts} (83%) rename src/interfaces/{Button.ts => IButton.ts} (84%) rename src/interfaces/{Command.ts => ICommand.ts} (87%) rename src/interfaces/{ContextMenu.ts => IContextMenu.ts} (88%) rename src/interfaces/{Cron.ts => ICron.ts} (76%) rename src/interfaces/{Env.ts => IEnv.ts} (92%) rename src/interfaces/{Event.ts => IEvent.ts} (86%) rename src/interfaces/{Guild.ts => IGuild.ts} (95%) rename src/interfaces/{Modal.ts => IModal.ts} (85%) rename src/interfaces/{Player.ts => IPlayer.ts} (99%) delete mode 100644 src/interfaces/TimeZones.ts create mode 100644 src/typings/TimeZones.ts diff --git a/src/interfaces/Autocomplete.ts b/src/interfaces/IAutocomplete.ts similarity index 83% rename from src/interfaces/Autocomplete.ts rename to src/interfaces/IAutocomplete.ts index e20e4a3..3c62ce9 100644 --- a/src/interfaces/Autocomplete.ts +++ b/src/interfaces/IAutocomplete.ts @@ -1,7 +1,7 @@ /* eslint-disable no-unused-vars */ import { AutocompleteInteraction } from "discord.js" -export default interface Autocomplete { +export default interface IAutocomplete { name: string description: string execute: (interacion: AutocompleteInteraction) => Promise diff --git a/src/interfaces/Button.ts b/src/interfaces/IButton.ts similarity index 84% rename from src/interfaces/Button.ts rename to src/interfaces/IButton.ts index 49cf822..91a9705 100644 --- a/src/interfaces/Button.ts +++ b/src/interfaces/IButton.ts @@ -1,7 +1,7 @@ /* eslint-disable no-unused-vars */ import { ButtonInteraction } from "discord.js" -export default interface Button { +export default interface IButton { name: string description: string execute: (interaction: ButtonInteraction) => Promise diff --git a/src/interfaces/Command.ts b/src/interfaces/ICommand.ts similarity index 87% rename from src/interfaces/Command.ts rename to src/interfaces/ICommand.ts index 124acb4..11ae866 100644 --- a/src/interfaces/Command.ts +++ b/src/interfaces/ICommand.ts @@ -2,12 +2,11 @@ import { ChatInputCommandInteraction, SlashCommandBuilder } from "discord.js" import { ExtendedClient as Client } from "utils/Client" -export default interface Command { +export default interface ICommand { name: string description: string dev?: boolean public: boolean - disabled?: boolean subcommands?: boolean data: SlashCommandBuilder execute: (interaction: ChatInputCommandInteraction, client: Client) => Promise diff --git a/src/interfaces/ContextMenu.ts b/src/interfaces/IContextMenu.ts similarity index 88% rename from src/interfaces/ContextMenu.ts rename to src/interfaces/IContextMenu.ts index 5ad8052..067c960 100644 --- a/src/interfaces/ContextMenu.ts +++ b/src/interfaces/IContextMenu.ts @@ -4,7 +4,7 @@ import { ContextMenuCommandBuilder } from "discord.js" -export default interface ContextMenu { +export default interface IContextMenu { name: string description: string dev?: boolean diff --git a/src/interfaces/Cron.ts b/src/interfaces/ICron.ts similarity index 76% rename from src/interfaces/Cron.ts rename to src/interfaces/ICron.ts index 5b7aeb0..a5e4fd4 100644 --- a/src/interfaces/Cron.ts +++ b/src/interfaces/ICron.ts @@ -1,4 +1,4 @@ -import { TimeZones } from "." +import { TimeZones } from "typings" interface TimeFormat { seconds: "*" | number @@ -9,10 +9,10 @@ interface TimeFormat { dayOfWeek: "*" | number } -export default interface Cron { +export default interface ICron { time: TimeFormat execute: () => void onComplete?: null | undefined start?: boolean | null | undefined - timeZone: keyof TimeZones + timeZone: TimeZones } diff --git a/src/interfaces/Env.ts b/src/interfaces/IEnv.ts similarity index 92% rename from src/interfaces/Env.ts rename to src/interfaces/IEnv.ts index 88b436b..fff8e21 100644 --- a/src/interfaces/Env.ts +++ b/src/interfaces/IEnv.ts @@ -13,7 +13,7 @@ interface DevEnv { guildid: string | undefined } -export default interface Env { +export default interface IEnv { prod: ProdEnv dev: DevEnv } diff --git a/src/interfaces/Event.ts b/src/interfaces/IEvent.ts similarity index 86% rename from src/interfaces/Event.ts rename to src/interfaces/IEvent.ts index 9b9efb7..17d6196 100644 --- a/src/interfaces/Event.ts +++ b/src/interfaces/IEvent.ts @@ -1,7 +1,7 @@ /* eslint-disable no-unused-vars */ import { ClientEvents } from "discord.js" -export default interface Event { +export default interface IEvent { name: string description: string event: keyof ClientEvents diff --git a/src/interfaces/Guild.ts b/src/interfaces/IGuild.ts similarity index 95% rename from src/interfaces/Guild.ts rename to src/interfaces/IGuild.ts index f95463f..858232e 100644 --- a/src/interfaces/Guild.ts +++ b/src/interfaces/IGuild.ts @@ -1,11 +1,11 @@ -export interface Guild { +export interface IGuild { data: { success: boolean - guild: GuildData + guild: IGuildData } } -export interface GuildData { +export interface IGuildData { _id: string name: string coins?: number diff --git a/src/interfaces/Modal.ts b/src/interfaces/IModal.ts similarity index 85% rename from src/interfaces/Modal.ts rename to src/interfaces/IModal.ts index 9737e9c..faf0dd6 100644 --- a/src/interfaces/Modal.ts +++ b/src/interfaces/IModal.ts @@ -1,7 +1,7 @@ /* eslint-disable no-unused-vars */ import { ModalSubmitInteraction } from "discord.js" -export default interface Modal { +export default interface IModal { name: string description: string execute: (interaction: ModalSubmitInteraction) => Promise diff --git a/src/interfaces/Player.ts b/src/interfaces/IPlayer.ts similarity index 99% rename from src/interfaces/Player.ts rename to src/interfaces/IPlayer.ts index a9130ad..afe7fe1 100644 --- a/src/interfaces/Player.ts +++ b/src/interfaces/IPlayer.ts @@ -1,11 +1,11 @@ -export interface Player { +export interface IPlayer { data: { success: boolean - player: PlayerData + player: IPlayerData } } -export interface PlayerData { +export interface IPlayerData { _id?: string uuid?: string firstLogin?: number @@ -8910,7 +8910,7 @@ export interface Active { started?: number } -export interface Objectives {} +export interface Objectives { } export interface DuelsKiller { completions?: Completion2[] @@ -8926,7 +8926,7 @@ export interface Active2 { started?: number } -export interface Objectives2 {} +export interface Objectives2 { } export interface SkywarsArcadeWin { completions?: Completion3[] @@ -8942,7 +8942,7 @@ export interface Active3 { started?: number } -export interface Objectives3 {} +export interface Objectives3 { } export interface PrototypePitDailyKills { completions?: Completion4[] @@ -9020,7 +9020,7 @@ export interface Active7 { started?: number } -export interface Objectives7 {} +export interface Objectives7 { } export interface DuelsWeeklyWins { completions?: Completion9[] @@ -9081,7 +9081,7 @@ export interface Active9 { started?: number } -export interface Objectives9 {} +export interface Objectives9 { } export interface SkywarsWeeklyFreeLootChest { completions?: Completion14[] @@ -9115,7 +9115,7 @@ export interface Active11 { started?: number } -export interface Objectives11 {} +export interface Objectives11 { } export interface SkywarsWeeklyKills { completions?: Completion16[] @@ -9149,7 +9149,7 @@ export interface Active13 { started?: number } -export interface Objectives13 {} +export interface Objectives13 { } export interface SkywarsSoloWin { completions?: Completion18[] @@ -9165,7 +9165,7 @@ export interface Active14 { started?: number } -export interface Objectives14 {} +export interface Objectives14 { } export interface SkywarsWeeklyArcadeWinAll { active?: Active15 @@ -9231,7 +9231,7 @@ export interface Active17 { started?: number } -export interface Objectives17 {} +export interface Objectives17 { } export interface WallsWeekly { active?: Active18 @@ -9261,7 +9261,7 @@ export interface Active19 { started?: number } -export interface Objectives19 {} +export interface Objectives19 { } export interface QuakeDailyWin { completions?: Completion24[] @@ -9277,7 +9277,7 @@ export interface Active20 { started?: number } -export interface Objectives20 {} +export interface Objectives20 { } export interface QuakeDailyKill { completions?: Completion25[] @@ -9293,7 +9293,7 @@ export interface Active21 { started?: number } -export interface Objectives21 {} +export interface Objectives21 { } export interface PaintballExpert { active?: Active22 @@ -9318,7 +9318,7 @@ export interface Active23 { started?: number } -export interface Objectives23 {} +export interface Objectives23 { } export interface ArenaWeeklyPlay { active?: Active24 @@ -9387,7 +9387,7 @@ export interface Active28 { started?: number } -export interface Objectives28 {} +export interface Objectives28 { } export interface VampirezDailyPlay { completions?: Completion27[] @@ -9470,7 +9470,7 @@ export interface Active33 { started?: number } -export interface Objectives33 {} +export interface Objectives33 { } export interface GingerbreadBlingBling { completions?: Completion30[] @@ -9486,7 +9486,7 @@ export interface Active34 { started?: number } -export interface Objectives34 {} +export interface Objectives34 { } export interface GingerbreadMastery { active?: Active35 @@ -9564,7 +9564,7 @@ export interface Active39 { started?: number } -export interface Objectives39 {} +export interface Objectives39 { } export interface VampirezWeeklyHumanKill { active?: Active40 @@ -9588,7 +9588,7 @@ export interface Active41 { started?: number } -export interface Objectives41 {} +export interface Objectives41 { } export interface PrototypePitWeeklyGold { completions?: Completion34[] @@ -9630,7 +9630,7 @@ export interface Active43 { started?: number } -export interface Objectives43 {} +export interface Objectives43 { } export interface ArcadeSpecialist { completions?: Completion37[] @@ -9726,7 +9726,7 @@ export interface Active49 { started?: number } -export interface Objectives49 {} +export interface Objectives49 { } export interface TntPvprunDaily { completions?: Completion41[] @@ -9760,7 +9760,7 @@ export interface Active51 { started?: number } -export interface Objectives51 {} +export interface Objectives51 { } export interface TntPvprunWeekly { completions?: Completion43[] @@ -9794,7 +9794,7 @@ export interface Active53 { started?: number } -export interface Objectives53 {} +export interface Objectives53 { } export interface TntTnttagDaily { completions?: Completion45[] @@ -9810,7 +9810,7 @@ export interface Active54 { started?: number } -export interface Objectives54 {} +export interface Objectives54 { } export interface TntTntrunWeekly { completions?: Completion46[] @@ -9826,7 +9826,7 @@ export interface Active55 { started?: number } -export interface Objectives55 {} +export interface Objectives55 { } export interface TntTntrunDaily { completions?: Completion47[] @@ -9842,7 +9842,7 @@ export interface Active56 { started?: number } -export interface Objectives56 {} +export interface Objectives56 { } export interface CvcKillDailyNormal { completions?: Completion48[] @@ -9858,7 +9858,7 @@ export interface Active57 { started?: number } -export interface Objectives57 {} +export interface Objectives57 { } export interface CvcKillWeekly { active?: Active58 @@ -9883,7 +9883,7 @@ export interface Active59 { started?: number } -export interface Objectives59 {} +export interface Objectives59 { } export interface CvcWinDailyNormal { completions?: Completion49[] @@ -9899,7 +9899,7 @@ export interface Active60 { started?: number } -export interface Objectives60 {} +export interface Objectives60 { } export interface CvcKill { active?: Active61 @@ -9947,7 +9947,7 @@ export interface Active63 { started?: number } -export interface Objectives63 {} +export interface Objectives63 { } export interface BlitzLootChestWeekly { completions?: Completion52[] @@ -9982,7 +9982,7 @@ export interface Active65 { started?: number } -export interface Objectives65 {} +export interface Objectives65 { } export interface BlitzLootChestDaily { completions?: Completion54[] @@ -10052,7 +10052,7 @@ export interface Active69 { started?: number } -export interface Objectives69 {} +export interface Objectives69 { } export interface MmDailyPowerPlay { completions?: Completion58[] @@ -10068,7 +10068,7 @@ export interface Active70 { started?: number } -export interface Objectives70 {} +export interface Objectives70 { } export interface MmWeeklyWins { completions?: Completion59[] @@ -10084,7 +10084,7 @@ export interface Active71 { started?: number } -export interface Objectives71 {} +export interface Objectives71 { } export interface MmDailyTargetKill { completions?: Completion60[] @@ -10100,7 +10100,7 @@ export interface Active72 { started?: number } -export interface Objectives72 {} +export interface Objectives72 { } export interface MmWeeklyMurdererKills { completions?: Completion61[] @@ -10147,7 +10147,7 @@ export interface Active75 { started?: number } -export interface Objectives75 {} +export interface Objectives75 { } export interface UhcTeam { completions?: Completion63[] @@ -10163,7 +10163,7 @@ export interface Active76 { started?: number } -export interface Objectives76 {} +export interface Objectives76 { } export interface UhcWeekly { active?: Active77 @@ -10192,7 +10192,7 @@ export interface Active78 { started?: number } -export interface Objectives78 {} +export interface Objectives78 { } export interface UhcWeeklySpecialCookie { active?: Active79 @@ -10203,7 +10203,7 @@ export interface Active79 { started?: number } -export interface Objectives79 {} +export interface Objectives79 { } export interface UhcSolo { active?: Active80 @@ -10214,7 +10214,7 @@ export interface Active80 { started?: number } -export interface Objectives80 {} +export interface Objectives80 { } export interface UhcMadness { completions?: Completion65[] @@ -10261,7 +10261,7 @@ export interface Active83 { started?: number } -export interface Objectives83 {} +export interface Objectives83 { } export interface TntWeeklySpecial { active?: Active84 @@ -10272,7 +10272,7 @@ export interface Active84 { started?: number } -export interface Objectives84 {} +export interface Objectives84 { } export interface SupersmashSoloWin { completions?: Completion67[] @@ -10288,7 +10288,7 @@ export interface Active85 { started?: number } -export interface Objectives85 {} +export interface Objectives85 { } export interface SupersmashTeamWin { active?: Active86 @@ -10299,7 +10299,7 @@ export interface Active86 { started?: number } -export interface Objectives86 {} +export interface Objectives86 { } export interface SupersmashTeamKills { active?: Active87 @@ -10310,7 +10310,7 @@ export interface Active87 { started?: number } -export interface Objectives87 {} +export interface Objectives87 { } export interface SupersmashSoloKills { completions?: Completion68[] @@ -10326,7 +10326,7 @@ export interface Active88 { started?: number } -export interface Objectives88 {} +export interface Objectives88 { } export interface SupersmashWeeklyKills { active?: Active89 @@ -10372,7 +10372,7 @@ export interface Active91 { started?: number } -export interface Objectives91 {} +export interface Objectives91 { } export interface WarlordsDedication { active?: Active92 @@ -10383,7 +10383,7 @@ export interface Active92 { started?: number } -export interface Objectives92 {} +export interface Objectives92 { } export interface WarlordsVictorious { active?: Active93 @@ -10394,7 +10394,7 @@ export interface Active93 { started?: number } -export interface Objectives93 {} +export interface Objectives93 { } export interface WarlordsDomination { active?: Active94 @@ -10405,7 +10405,7 @@ export interface Active94 { started?: number } -export interface Objectives94 {} +export interface Objectives94 { } export interface WarlordsCtf { active?: Active95 @@ -10416,7 +10416,7 @@ export interface Active95 { started?: number } -export interface Objectives95 {} +export interface Objectives95 { } export interface BuildBattlePlayer { completions?: Completion70[] @@ -10468,7 +10468,7 @@ export interface Active98 { started?: number } -export interface Objectives98 {} +export interface Objectives98 { } export interface MegaWallsWeekly { active?: Active99 @@ -10498,7 +10498,7 @@ export interface Active100 { started?: number } -export interface Objectives100 {} +export interface Objectives100 { } export interface MegaWallsFaithful { active?: Active101 @@ -10535,7 +10535,7 @@ export interface Active103 { started?: number } -export interface Objectives103 {} +export interface Objectives103 { } export interface MmSpecialWeeklyKillerInstinct2020 { active?: Active104 @@ -10546,7 +10546,7 @@ export interface Active104 { started?: number } -export interface Objectives104 {} +export interface Objectives104 { } export interface SkywarsHalloweenHarvest2020 { active?: Active105 @@ -10575,7 +10575,7 @@ export interface Active106 { started?: number } -export interface Objectives106 {} +export interface Objectives106 { } export interface BuildBattleChristmas { active?: Active107 @@ -10586,7 +10586,7 @@ export interface Active107 { started?: number } -export interface Objectives107 {} +export interface Objectives107 { } export interface BuildBattleChristmasWeekly { active?: Active108 @@ -10597,7 +10597,7 @@ export interface Active108 { started?: number } -export interface Objectives108 {} +export interface Objectives108 { } export interface MmDailyInfector { active?: Active109 @@ -10621,7 +10621,7 @@ export interface Active110 { started?: number } -export interface Objectives110 {} +export interface Objectives110 { } export interface BuildBattleHalloween { active?: Active111 @@ -10632,7 +10632,7 @@ export interface Active111 { started?: number } -export interface Objectives111 {} +export interface Objectives111 { } export interface SkywarsHalloweenHarvest2021 { active?: Active112 @@ -10669,7 +10669,7 @@ export interface Active113 { started?: number } -export interface Objectives113 {} +export interface Objectives113 { } export interface WoolWarsDailyWins { completions?: Completion77[] @@ -10756,7 +10756,7 @@ export interface Active119 { started?: number } -export interface Objectives119 {} +export interface Objectives119 { } export interface PitWeeklyGold { active?: Active120 @@ -10806,7 +10806,7 @@ export interface Active122 { started?: number } -export interface Objectives122 {} +export interface Objectives122 { } export interface BedwarsDailyFinalKiller { completions?: Completion81[] @@ -10833,7 +10833,7 @@ export interface Active123 { started?: number } -export interface Objectives123 {} +export interface Objectives123 { } export interface MmSpecialWeeklyKillerInstinct2023 { active?: Active124 @@ -10844,7 +10844,7 @@ export interface Active124 { started?: number } -export interface Objectives124 {} +export interface Objectives124 { } export interface Dmcrates102019 { MVP_PLUS?: boolean diff --git a/src/interfaces/TimeZones.ts b/src/interfaces/TimeZones.ts deleted file mode 100644 index 807e591..0000000 --- a/src/interfaces/TimeZones.ts +++ /dev/null @@ -1,430 +0,0 @@ -export default interface TimeZones { - "Africa/Abidjan": string - "Africa/Accra": string - "Africa/Addis_Ababa": string - "Africa/Algiers": string - "Africa/Asmera": string - "Africa/Bamako": string - "Africa/Bangui": string - "Africa/Banjul": string - "Africa/Bissau": string - "Africa/Blantyre": string - "Africa/Brazzaville": string - "Africa/Bujumbura": string - "Africa/Cairo": string - "Africa/Casablanca": string - "Africa/Ceuta": string - "Africa/Conakry": string - "Africa/Dakar": string - "Africa/Dar_es_Salaam": string - "Africa/Djibouti": string - "Africa/Douala": string - "Africa/El_Aaiun": string - "Africa/Freetown": string - "Africa/Gaborone": string - "Africa/Harare": string - "Africa/Johannesburg": string - "Africa/Juba": string - "Africa/Kampala": string - "Africa/Khartoum": string - "Africa/Kigali": string - "Africa/Kinshasa": string - "Africa/Lagos": string - "Africa/Libreville": string - "Africa/Lome": string - "Africa/Luanda": string - "Africa/Lubumbashi": string - "Africa/Lusaka": string - "Africa/Malabo": string - "Africa/Maputo": string - "Africa/Maseru": string - "Africa/Mbabane": string - "Africa/Mogadishu": string - "Africa/Monrovia": string - "Africa/Nairobi": string - "Africa/Ndjamena": string - "Africa/Niamey": string - "Africa/Nouakchott": string - "Africa/Ouagadougou": string - "Africa/Porto-Novo": string - "Africa/Sao_Tome": string - "Africa/Tripoli": string - "Africa/Tunis": string - "Africa/Windhoek": string - "America/Adak": string - "America/Anchorage": string - "America/Anguilla": string - "America/Antigua": string - "America/Araguaina": string - "America/Argentina/La_Rioja": string - "America/Argentina/Rio_Gallegos": string - "America/Argentina/Salta": string - "America/Argentina/San_Juan": string - "America/Argentina/San_Luis": string - "America/Argentina/Tucuman": string - "America/Argentina/Ushuaia": string - "America/Aruba": string - "America/Asuncion": string - "America/Bahia": string - "America/Bahia_Banderas": string - "America/Barbados": string - "America/Belem": string - "America/Belize": string - "America/Blanc-Sablon": string - "America/Boa_Vista": string - "America/Bogota": string - "America/Boise": string - "America/Buenos_Aires": string - "America/Cambridge_Bay": string - "America/Campo_Grande": string - "America/Cancun": string - "America/Caracas": string - "America/Catamarca": string - "America/Cayenne": string - "America/Cayman": string - "America/Chicago": string - "America/Chihuahua": string - "America/Ciudad_Juarez": string - "America/Coral_Harbour": string - "America/Cordoba": string - "America/Costa_Rica": string - "America/Creston": string - "America/Cuiaba": string - "America/Curacao": string - "America/Danmarkshavn": string - "America/Dawson": string - "America/Dawson_Creek": string - "America/Denver": string - "America/Detroit": string - "America/Dominica": string - "America/Edmonton": string - "America/Eirunepe": string - "America/El_Salvador": string - "America/Fort_Nelson": string - "America/Fortaleza": string - "America/Glace_Bay": string - "America/Godthab": string - "America/Goose_Bay": string - "America/Grand_Turk": string - "America/Grenada": string - "America/Guadeloupe": string - "America/Guatemala": string - "America/Guayaquil": string - "America/Guyana": string - "America/Halifax": string - "America/Havana": string - "America/Hermosillo": string - "America/Indiana/Knox": string - "America/Indiana/Marengo": string - "America/Indiana/Petersburg": string - "America/Indiana/Tell_City": string - "America/Indiana/Vevay": string - "America/Indiana/Vincennes": string - "America/Indiana/Winamac": string - "America/Indianapolis": string - "America/Inuvik": string - "America/Iqaluit": string - "America/Jamaica": string - "America/Jujuy": string - "America/Juneau": string - "America/Kentucky/Monticello": string - "America/Kralendijk": string - "America/La_Paz": string - "America/Lima": string - "America/Los_Angeles": string - "America/Louisville": string - "America/Lower_Princes": string - "America/Maceio": string - "America/Managua": string - "America/Manaus": string - "America/Marigot": string - "America/Martinique": string - "America/Matamoros": string - "America/Mazatlan": string - "America/Mendoza": string - "America/Menominee": string - "America/Merida": string - "America/Metlakatla": string - "America/Mexico_City": string - "America/Miquelon": string - "America/Moncton": string - "America/Monterrey": string - "America/Montevideo": string - "America/Montserrat": string - "America/Nassau": string - "America/New_York": string - "America/Nipigon": string - "America/Nome": string - "America/Noronha": string - "America/North_Dakota/Beulah": string - "America/North_Dakota/Center": string - "America/North_Dakota/New_Salem": string - "America/Ojinaga": string - "America/Panama": string - "America/Pangnirtung": string - "America/Paramaribo": string - "America/Phoenix": string - "America/Port-au-Prince": string - "America/Port_of_Spain": string - "America/Porto_Velho": string - "America/Puerto_Rico": string - "America/Punta_Arenas": string - "America/Rainy_River": string - "America/Rankin_Inlet": string - "America/Recife": string - "America/Regina": string - "America/Resolute": string - "America/Rio_Branco": string - "America/Santa_Isabel": string - "America/Santarem": string - "America/Santiago": string - "America/Santo_Domingo": string - "America/Sao_Paulo": string - "America/Scoresbysund": string - "America/Sitka": string - "America/St_Barthelemy": string - "America/St_Johns": string - "America/St_Kitts": string - "America/St_Lucia": string - "America/St_Thomas": string - "America/St_Vincent": string - "America/Swift_Current": string - "America/Tegucigalpa": string - "America/Thule": string - "America/Thunder_Bay": string - "America/Tijuana": string - "America/Toronto": string - "America/Tortola": string - "America/Vancouver": string - "America/Whitehorse": string - "America/Winnipeg": string - "America/Yakutat": string - "America/Yellowknife": string - "Antarctica/Casey": string - "Antarctica/Davis": string - "Antarctica/DumontDUrville": string - "Antarctica/Macquarie": string - "Antarctica/Mawson": string - "Antarctica/McMurdo": string - "Antarctica/Palmer": string - "Antarctica/Rothera": string - "Antarctica/Syowa": string - "Antarctica/Troll": string - "Antarctica/Vostok": string - "Arctic/Longyearbyen": string - "Asia/Aden": string - "Asia/Almaty": string - "Asia/Amman": string - "Asia/Anadyr": string - "Asia/Aqtau": string - "Asia/Aqtobe": string - "Asia/Ashgabat": string - "Asia/Atyrau": string - "Asia/Baghdad": string - "Asia/Bahrain": string - "Asia/Baku": string - "Asia/Bangkok": string - "Asia/Barnaul": string - "Asia/Beirut": string - "Asia/Bishkek": string - "Asia/Brunei": string - "Asia/Calcutta": string - "Asia/Chita": string - "Asia/Choibalsan": string - "Asia/Colombo": string - "Asia/Damascus": string - "Asia/Dhaka": string - "Asia/Dili": string - "Asia/Dubai": string - "Asia/Dushanbe": string - "Asia/Famagusta": string - "Asia/Gaza": string - "Asia/Hebron": string - "Asia/Hong_Kong": string - "Asia/Hovd": string - "Asia/Irkutsk": string - "Asia/Jakarta": string - "Asia/Jayapura": string - "Asia/Jerusalem": string - "Asia/Kabul": string - "Asia/Kamchatka": string - "Asia/Karachi": string - "Asia/Katmandu": string - "Asia/Khandyga": string - "Asia/Krasnoyarsk": string - "Asia/Kuala_Lumpur": string - "Asia/Kuching": string - "Asia/Kuwait": string - "Asia/Macau": string - "Asia/Magadan": string - "Asia/Makassar": string - "Asia/Manila": string - "Asia/Muscat": string - "Asia/Nicosia": string - "Asia/Novokuznetsk": string - "Asia/Novosibirsk": string - "Asia/Omsk": string - "Asia/Oral": string - "Asia/Phnom_Penh": string - "Asia/Pontianak": string - "Asia/Pyongyang": string - "Asia/Qatar": string - "Asia/Qostanay": string - "Asia/Qyzylorda": string - "Asia/Rangoon": string - "Asia/Riyadh": string - "Asia/Saigon": string - "Asia/Sakhalin": string - "Asia/Samarkand": string - "Asia/Seoul": string - "Asia/Shanghai": string - "Asia/Singapore": string - "Asia/Srednekolymsk": string - "Asia/Taipei": string - "Asia/Tashkent": string - "Asia/Tbilisi": string - "Asia/Tehran": string - "Asia/Thimphu": string - "Asia/Tokyo": string - "Asia/Tomsk": string - "Asia/Ulaanbaatar": string - "Asia/Urumqi": string - "Asia/Ust-Nera": string - "Asia/Vientiane": string - "Asia/Vladivostok": string - "Asia/Yakutsk": string - "Asia/Yekaterinburg": string - "Asia/Yerevan": string - "Atlantic/Azores": string - "Atlantic/Bermuda": string - "Atlantic/Canary": string - "Atlantic/Cape_Verde": string - "Atlantic/Faeroe": string - "Atlantic/Madeira": string - "Atlantic/Reykjavik": string - "Atlantic/South_Georgia": string - "Atlantic/St_Helena": string - "Atlantic/Stanley": string - "Australia/Adelaide": string - "Australia/Brisbane": string - "Australia/Broken_Hill": string - "Australia/Currie": string - "Australia/Darwin": string - "Australia/Eucla": string - "Australia/Hobart": string - "Australia/Lindeman": string - "Australia/Lord_Howe": string - "Australia/Melbourne": string - "Australia/Perth": string - "Australia/Sydney": string - "Europe/Amsterdam": string - "Europe/Andorra": string - "Europe/Astrakhan": string - "Europe/Athens": string - "Europe/Belgrade": string - "Europe/Berlin": string - "Europe/Bratislava": string - "Europe/Brussels": string - "Europe/Bucharest": string - "Europe/Budapest": string - "Europe/Busingen": string - "Europe/Chisinau": string - "Europe/Copenhagen": string - "Europe/Dublin": string - "Europe/Gibraltar": string - "Europe/Guernsey": string - "Europe/Helsinki": string - "Europe/Isle_of_Man": string - "Europe/Istanbul": string - "Europe/Jersey": string - "Europe/Kaliningrad": string - "Europe/Kiev": string - "Europe/Kirov": string - "Europe/Lisbon": string - "Europe/Ljubljana": string - "Europe/London": string - "Europe/Luxembourg": string - "Europe/Madrid": string - "Europe/Malta": string - "Europe/Mariehamn": string - "Europe/Minsk": string - "Europe/Monaco": string - "Europe/Moscow": string - "Europe/Oslo": string - "Europe/Paris": string - "Europe/Podgorica": string - "Europe/Prague": string - "Europe/Riga": string - "Europe/Rome": string - "Europe/Samara": string - "Europe/San_Marino": string - "Europe/Sarajevo": string - "Europe/Saratov": string - "Europe/Simferopol": string - "Europe/Skopje": string - "Europe/Sofia": string - "Europe/Stockholm": string - "Europe/Tallinn": string - "Europe/Tirane": string - "Europe/Ulyanovsk": string - "Europe/Uzhgorod": string - "Europe/Vaduz": string - "Europe/Vatican": string - "Europe/Vienna": string - "Europe/Vilnius": string - "Europe/Volgograd": string - "Europe/Warsaw": string - "Europe/Zagreb": string - "Europe/Zaporozhye": string - "Europe/Zurich": string - "Indian/Antananarivo": string - "Indian/Chagos": string - "Indian/Christmas": string - "Indian/Cocos": string - "Indian/Comoro": string - "Indian/Kerguelen": string - "Indian/Mahe": string - "Indian/Maldives": string - "Indian/Mauritius": string - "Indian/Mayotte": string - "Indian/Reunion": string - "Pacific/Apia": string - "Pacific/Auckland": string - "Pacific/Bougainville": string - "Pacific/Chatham": string - "Pacific/Easter": string - "Pacific/Efate": string - "Pacific/Enderbury": string - "Pacific/Fakaofo": string - "Pacific/Fiji": string - "Pacific/Funafuti": string - "Pacific/Galapagos": string - "Pacific/Gambier": string - "Pacific/Guadalcanal": string - "Pacific/Guam": string - "Pacific/Honolulu": string - "Pacific/Johnston": string - "Pacific/Kiritimati": string - "Pacific/Kosrae": string - "Pacific/Kwajalein": string - "Pacific/Majuro": string - "Pacific/Marquesas": string - "Pacific/Midway": string - "Pacific/Nauru": string - "Pacific/Niue": string - "Pacific/Norfolk": string - "Pacific/Noumea": string - "Pacific/Pago_Pago": string - "Pacific/Palau": string - "Pacific/Pitcairn": string - "Pacific/Ponape": string - "Pacific/Port_Moresby": string - "Pacific/Rarotonga": string - "Pacific/Saipan": string - "Pacific/Tahiti": string - "Pacific/Tarawa": string - "Pacific/Tongatapu": string - "Pacific/Truk": string - "Pacific/Wake": string - "Pacific/Wallis": string -} diff --git a/src/interfaces/index.ts b/src/interfaces/index.ts index 9314e42..1aec9b3 100644 --- a/src/interfaces/index.ts +++ b/src/interfaces/index.ts @@ -1,29 +1,27 @@ -import Autocomplete from "./Autocomplete" -import Button from "./Button" -import Command from "./Command" -import ContextMenu from "./ContextMenu" -import Event from "./Event" -import Modal from "./Modal" +import IAutocomplete from "./IAutocomplete" +import IButton from "./IButton" +import ICommand from "./ICommand" +import IContextMenu from "./IContextMenu" +import IEvent from "./IEvent" +import IModal from "./IModal" -import Env from "./Env" -import Cron from "./Cron" -import TimeZones from "./TimeZones" +import IEnv from "./IEnv" +import ICron from "./ICron" -import { Guild, GuildData } from "./Guild" -import { Player, PlayerData } from "./Player" +import { IGuild, IGuildData } from "./IGuild" +import { IPlayer, IPlayerData } from "./IPlayer" export { - Env, - Cron, - TimeZones, - Autocomplete, - Button, - Command, - ContextMenu, - Event, - Modal, - Guild, - GuildData, - Player, - PlayerData + IEnv, + ICron, + IAutocomplete, + IButton, + ICommand, + IContextMenu, + IEvent, + IModal, + IGuild, + IGuildData, + IPlayer, + IPlayerData } diff --git a/src/typings/TimeZones.ts b/src/typings/TimeZones.ts new file mode 100644 index 0000000..fab62cd --- /dev/null +++ b/src/typings/TimeZones.ts @@ -0,0 +1,432 @@ +const TimeZones = [ + "Africa/Abidjan", + "Africa/Accra", + "Africa/Addis_Ababa", + "Africa/Algiers", + "Africa/Asmera", + "Africa/Bamako", + "Africa/Bangui", + "Africa/Banjul", + "Africa/Bissau", + "Africa/Blantyre", + "Africa/Brazzaville", + "Africa/Bujumbura", + "Africa/Cairo", + "Africa/Casablanca", + "Africa/Ceuta", + "Africa/Conakry", + "Africa/Dakar", + "Africa/Dar_es_Salaam", + "Africa/Djibouti", + "Africa/Douala", + "Africa/El_Aaiun", + "Africa/Freetown", + "Africa/Gaborone", + "Africa/Harare", + "Africa/Johannesburg", + "Africa/Juba", + "Africa/Kampala", + "Africa/Khartoum", + "Africa/Kigali", + "Africa/Kinshasa", + "Africa/Lagos", + "Africa/Libreville", + "Africa/Lome", + "Africa/Luanda", + "Africa/Lubumbashi", + "Africa/Lusaka", + "Africa/Malabo", + "Africa/Maputo", + "Africa/Maseru", + "Africa/Mbabane", + "Africa/Mogadishu", + "Africa/Monrovia", + "Africa/Nairobi", + "Africa/Ndjamena", + "Africa/Niamey", + "Africa/Nouakchott", + "Africa/Ouagadougou", + "Africa/Porto-Novo", + "Africa/Sao_Tome", + "Africa/Tripoli", + "Africa/Tunis", + "Africa/Windhoek", + "America/Adak", + "America/Anchorage", + "America/Anguilla", + "America/Antigua", + "America/Araguaina", + "America/Argentina/La_Rioja", + "America/Argentina/Rio_Gallegos", + "America/Argentina/Salta", + "America/Argentina/San_Juan", + "America/Argentina/San_Luis", + "America/Argentina/Tucuman", + "America/Argentina/Ushuaia", + "America/Aruba", + "America/Asuncion", + "America/Bahia", + "America/Bahia_Banderas", + "America/Barbados", + "America/Belem", + "America/Belize", + "America/Blanc-Sablon", + "America/Boa_Vista", + "America/Bogota", + "America/Boise", + "America/Buenos_Aires", + "America/Cambridge_Bay", + "America/Campo_Grande", + "America/Cancun", + "America/Caracas", + "America/Catamarca", + "America/Cayenne", + "America/Cayman", + "America/Chicago", + "America/Chihuahua", + "America/Ciudad_Juarez", + "America/Coral_Harbour", + "America/Cordoba", + "America/Costa_Rica", + "America/Creston", + "America/Cuiaba", + "America/Curacao", + "America/Danmarkshavn", + "America/Dawson", + "America/Dawson_Creek", + "America/Denver", + "America/Detroit", + "America/Dominica", + "America/Edmonton", + "America/Eirunepe", + "America/El_Salvador", + "America/Fort_Nelson", + "America/Fortaleza", + "America/Glace_Bay", + "America/Godthab", + "America/Goose_Bay", + "America/Grand_Turk", + "America/Grenada", + "America/Guadeloupe", + "America/Guatemala", + "America/Guayaquil", + "America/Guyana", + "America/Halifax", + "America/Havana", + "America/Hermosillo", + "America/Indiana/Knox", + "America/Indiana/Marengo", + "America/Indiana/Petersburg", + "America/Indiana/Tell_City", + "America/Indiana/Vevay", + "America/Indiana/Vincennes", + "America/Indiana/Winamac", + "America/Indianapolis", + "America/Inuvik", + "America/Iqaluit", + "America/Jamaica", + "America/Jujuy", + "America/Juneau", + "America/Kentucky/Monticello", + "America/Kralendijk", + "America/La_Paz", + "America/Lima", + "America/Los_Angeles", + "America/Louisville", + "America/Lower_Princes", + "America/Maceio", + "America/Managua", + "America/Manaus", + "America/Marigot", + "America/Martinique", + "America/Matamoros", + "America/Mazatlan", + "America/Mendoza", + "America/Menominee", + "America/Merida", + "America/Metlakatla", + "America/Mexico_City", + "America/Miquelon", + "America/Moncton", + "America/Monterrey", + "America/Montevideo", + "America/Montserrat", + "America/Nassau", + "America/New_York", + "America/Nipigon", + "America/Nome", + "America/Noronha", + "America/North_Dakota/Beulah", + "America/North_Dakota/Center", + "America/North_Dakota/New_Salem", + "America/Ojinaga", + "America/Panama", + "America/Pangnirtung", + "America/Paramaribo", + "America/Phoenix", + "America/Port-au-Prince", + "America/Port_of_Spain", + "America/Porto_Velho", + "America/Puerto_Rico", + "America/Punta_Arenas", + "America/Rainy_River", + "America/Rankin_Inlet", + "America/Recife", + "America/Regina", + "America/Resolute", + "America/Rio_Branco", + "America/Santa_Isabel", + "America/Santarem", + "America/Santiago", + "America/Santo_Domingo", + "America/Sao_Paulo", + "America/Scoresbysund", + "America/Sitka", + "America/St_Barthelemy", + "America/St_Johns", + "America/St_Kitts", + "America/St_Lucia", + "America/St_Thomas", + "America/St_Vincent", + "America/Swift_Current", + "America/Tegucigalpa", + "America/Thule", + "America/Thunder_Bay", + "America/Tijuana", + "America/Toronto", + "America/Tortola", + "America/Vancouver", + "America/Whitehorse", + "America/Winnipeg", + "America/Yakutat", + "America/Yellowknife", + "Antarctica/Casey", + "Antarctica/Davis", + "Antarctica/DumontDUrville", + "Antarctica/Macquarie", + "Antarctica/Mawson", + "Antarctica/McMurdo", + "Antarctica/Palmer", + "Antarctica/Rothera", + "Antarctica/Syowa", + "Antarctica/Troll", + "Antarctica/Vostok", + "Arctic/Longyearbyen", + "Asia/Aden", + "Asia/Almaty", + "Asia/Amman", + "Asia/Anadyr", + "Asia/Aqtau", + "Asia/Aqtobe", + "Asia/Ashgabat", + "Asia/Atyrau", + "Asia/Baghdad", + "Asia/Bahrain", + "Asia/Baku", + "Asia/Bangkok", + "Asia/Barnaul", + "Asia/Beirut", + "Asia/Bishkek", + "Asia/Brunei", + "Asia/Calcutta", + "Asia/Chita", + "Asia/Choibalsan", + "Asia/Colombo", + "Asia/Damascus", + "Asia/Dhaka", + "Asia/Dili", + "Asia/Dubai", + "Asia/Dushanbe", + "Asia/Famagusta", + "Asia/Gaza", + "Asia/Hebron", + "Asia/Hong_Kong", + "Asia/Hovd", + "Asia/Irkutsk", + "Asia/Jakarta", + "Asia/Jayapura", + "Asia/Jerusalem", + "Asia/Kabul", + "Asia/Kamchatka", + "Asia/Karachi", + "Asia/Katmandu", + "Asia/Khandyga", + "Asia/Krasnoyarsk", + "Asia/Kuala_Lumpur", + "Asia/Kuching", + "Asia/Kuwait", + "Asia/Macau", + "Asia/Magadan", + "Asia/Makassar", + "Asia/Manila", + "Asia/Muscat", + "Asia/Nicosia", + "Asia/Novokuznetsk", + "Asia/Novosibirsk", + "Asia/Omsk", + "Asia/Oral", + "Asia/Phnom_Penh", + "Asia/Pontianak", + "Asia/Pyongyang", + "Asia/Qatar", + "Asia/Qostanay", + "Asia/Qyzylorda", + "Asia/Rangoon", + "Asia/Riyadh", + "Asia/Saigon", + "Asia/Sakhalin", + "Asia/Samarkand", + "Asia/Seoul", + "Asia/Shanghai", + "Asia/Singapore", + "Asia/Srednekolymsk", + "Asia/Taipei", + "Asia/Tashkent", + "Asia/Tbilisi", + "Asia/Tehran", + "Asia/Thimphu", + "Asia/Tokyo", + "Asia/Tomsk", + "Asia/Ulaanbaatar", + "Asia/Urumqi", + "Asia/Ust-Nera", + "Asia/Vientiane", + "Asia/Vladivostok", + "Asia/Yakutsk", + "Asia/Yekaterinburg", + "Asia/Yerevan", + "Atlantic/Azores", + "Atlantic/Bermuda", + "Atlantic/Canary", + "Atlantic/Cape_Verde", + "Atlantic/Faeroe", + "Atlantic/Madeira", + "Atlantic/Reykjavik", + "Atlantic/South_Georgia", + "Atlantic/St_Helena", + "Atlantic/Stanley", + "Australia/Adelaide", + "Australia/Brisbane", + "Australia/Broken_Hill", + "Australia/Currie", + "Australia/Darwin", + "Australia/Eucla", + "Australia/Hobart", + "Australia/Lindeman", + "Australia/Lord_Howe", + "Australia/Melbourne", + "Australia/Perth", + "Australia/Sydney", + "Europe/Amsterdam", + "Europe/Andorra", + "Europe/Astrakhan", + "Europe/Athens", + "Europe/Belgrade", + "Europe/Berlin", + "Europe/Bratislava", + "Europe/Brussels", + "Europe/Bucharest", + "Europe/Budapest", + "Europe/Busingen", + "Europe/Chisinau", + "Europe/Copenhagen", + "Europe/Dublin", + "Europe/Gibraltar", + "Europe/Guernsey", + "Europe/Helsinki", + "Europe/Isle_of_Man", + "Europe/Istanbul", + "Europe/Jersey", + "Europe/Kaliningrad", + "Europe/Kiev", + "Europe/Kirov", + "Europe/Lisbon", + "Europe/Ljubljana", + "Europe/London", + "Europe/Luxembourg", + "Europe/Madrid", + "Europe/Malta", + "Europe/Mariehamn", + "Europe/Minsk", + "Europe/Monaco", + "Europe/Moscow", + "Europe/Oslo", + "Europe/Paris", + "Europe/Podgorica", + "Europe/Prague", + "Europe/Riga", + "Europe/Rome", + "Europe/Samara", + "Europe/San_Marino", + "Europe/Sarajevo", + "Europe/Saratov", + "Europe/Simferopol", + "Europe/Skopje", + "Europe/Sofia", + "Europe/Stockholm", + "Europe/Tallinn", + "Europe/Tirane", + "Europe/Ulyanovsk", + "Europe/Uzhgorod", + "Europe/Vaduz", + "Europe/Vatican", + "Europe/Vienna", + "Europe/Vilnius", + "Europe/Volgograd", + "Europe/Warsaw", + "Europe/Zagreb", + "Europe/Zaporozhye", + "Europe/Zurich", + "Indian/Antananarivo", + "Indian/Chagos", + "Indian/Christmas", + "Indian/Cocos", + "Indian/Comoro", + "Indian/Kerguelen", + "Indian/Mahe", + "Indian/Maldives", + "Indian/Mauritius", + "Indian/Mayotte", + "Indian/Reunion", + "Pacific/Apia", + "Pacific/Auckland", + "Pacific/Bougainville", + "Pacific/Chatham", + "Pacific/Easter", + "Pacific/Efate", + "Pacific/Enderbury", + "Pacific/Fakaofo", + "Pacific/Fiji", + "Pacific/Funafuti", + "Pacific/Galapagos", + "Pacific/Gambier", + "Pacific/Guadalcanal", + "Pacific/Guam", + "Pacific/Honolulu", + "Pacific/Johnston", + "Pacific/Kiritimati", + "Pacific/Kosrae", + "Pacific/Kwajalein", + "Pacific/Majuro", + "Pacific/Marquesas", + "Pacific/Midway", + "Pacific/Nauru", + "Pacific/Niue", + "Pacific/Norfolk", + "Pacific/Noumea", + "Pacific/Pago_Pago", + "Pacific/Palau", + "Pacific/Pitcairn", + "Pacific/Ponape", + "Pacific/Port_Moresby", + "Pacific/Rarotonga", + "Pacific/Saipan", + "Pacific/Tahiti", + "Pacific/Tarawa", + "Pacific/Tongatapu", + "Pacific/Truk", + "Pacific/Wake", + "Pacific/Wallis" +] as const + +export default TimeZones \ No newline at end of file diff --git a/src/typings/index.ts b/src/typings/index.ts index 36d73a3..2d968d7 100644 --- a/src/typings/index.ts +++ b/src/typings/index.ts @@ -1,5 +1,8 @@ import { ChatInputCommandInteraction } from "discord.js" import { ExtendedClient } from "utils/Client" +import TZs from "./TimeZones" + +export type TimeZones = typeof TZs[number] export type SubcommandFunc = (interaction: ChatInputCommandInteraction, client?: ExtendedClient) => Promise @@ -10,4 +13,4 @@ export type SnipeCache = { createdAt: number deletedAt: number attachments: string[] -} +} \ No newline at end of file