@vencord/types 1.8.4 → 1.13.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/Vencord.d.ts +2 -0
- package/api/Badges.d.ts +10 -5
- package/api/ChatButtons.d.ts +6 -5
- package/api/Commands/commandHelpers.d.ts +3 -4
- package/api/Commands/index.d.ts +8 -7
- package/api/Commands/types.d.ts +3 -72
- package/api/ContextMenu.d.ts +6 -5
- package/api/MemberListDecorators.d.ts +14 -26
- package/api/MessageAccessories.d.ts +7 -7
- package/api/MessageDecorations.d.ts +8 -9
- package/api/MessageEvents.d.ts +13 -38
- package/api/MessagePopover.d.ts +9 -9
- package/api/MessageUpdater.d.ts +8 -0
- package/api/Notices.d.ts +2 -1
- package/api/Notifications/NotificationComponent.d.ts +1 -2
- package/api/Notifications/notificationLog.d.ts +1 -2
- package/api/ServerList.d.ts +4 -4
- package/api/Settings.d.ts +3 -1
- package/api/Styles.d.ts +0 -1
- package/api/UserSettings.d.ts +40 -0
- package/api/index.d.ts +10 -0
- package/components/CheckedTextInput.d.ts +1 -2
- package/components/CodeBlock.d.ts +1 -2
- package/components/ErrorBoundary.d.ts +4 -3
- package/components/ErrorCard.d.ts +1 -1
- package/components/Flex.d.ts +1 -2
- package/components/FormDivider.d.ts +4 -0
- package/components/FormSwitch.d.ts +14 -0
- package/components/Grid.d.ts +8 -0
- package/components/Heart.d.ts +2 -2
- package/components/Icons.d.ts +12 -8
- package/components/Link.d.ts +1 -2
- package/components/Switch.d.ts +1 -2
- package/components/index.d.ts +4 -3
- package/components/{VencordSettings → settings}/AddonCard.d.ts +2 -2
- package/components/settings/DonateButton.d.ts +2 -0
- package/components/settings/PluginBadge.d.ts +4 -0
- package/components/settings/QuickAction.d.ts +12 -0
- package/components/settings/SpecialCard.d.ts +14 -0
- package/components/settings/index.d.ts +7 -0
- package/components/{VencordSettings/shared.d.ts → settings/tabs/BaseTab.d.ts} +2 -4
- package/components/settings/tabs/index.d.ts +11 -0
- package/components/settings/tabs/patchHelper/FullPatchInput.d.ts +8 -0
- package/components/settings/tabs/patchHelper/PatchPreview.d.ts +9 -0
- package/components/settings/tabs/patchHelper/ReplacementInput.d.ts +5 -0
- package/components/{VencordSettings/PatchHelperTab.d.ts → settings/tabs/patchHelper/index.d.ts} +0 -1
- package/components/settings/tabs/plugins/ContributorModal.d.ts +3 -0
- package/components/settings/tabs/plugins/LinkIconButton.d.ts +10 -0
- package/components/settings/tabs/plugins/PluginCard.d.ts +10 -0
- package/components/settings/tabs/plugins/PluginModal.d.ts +10 -0
- package/components/settings/tabs/plugins/components/BooleanSetting.d.ts +3 -0
- package/components/settings/tabs/plugins/components/Common.d.ts +24 -0
- package/components/settings/tabs/plugins/components/ComponentSetting.d.ts +3 -0
- package/components/settings/tabs/plugins/components/NumberSetting.d.ts +3 -0
- package/components/settings/tabs/plugins/components/SelectSetting.d.ts +3 -0
- package/components/settings/tabs/plugins/components/SliderSetting.d.ts +3 -0
- package/components/settings/tabs/plugins/components/TextSetting.d.ts +3 -0
- package/components/settings/tabs/plugins/components/index.d.ts +5 -0
- package/components/settings/tabs/plugins/index.d.ts +6 -0
- package/components/{VencordSettings → settings/tabs/sync}/BackupAndRestoreTab.d.ts +0 -1
- package/components/{VencordSettings → settings/tabs/sync}/CloudTab.d.ts +0 -1
- package/components/settings/tabs/themes/CspErrorCard.d.ts +1 -0
- package/components/settings/tabs/themes/LocalThemesTab.d.ts +1 -0
- package/components/settings/tabs/themes/OnlineThemesTab.d.ts +1 -0
- package/components/settings/tabs/themes/ThemeCard.d.ts +9 -0
- package/components/{VencordSettings/ThemesTab.d.ts → settings/tabs/themes/index.d.ts} +1 -1
- package/components/settings/tabs/updater/Components.d.ts +15 -0
- package/components/{VencordSettings/UpdaterTab.d.ts → settings/tabs/updater/index.d.ts} +0 -1
- package/components/settings/tabs/updater/runWithDispatch.d.ts +1 -0
- package/components/settings/tabs/vencord/DonateButton.d.ts +2 -0
- package/components/settings/tabs/vencord/MacVibrancySettings.d.ts +1 -0
- package/components/settings/tabs/vencord/NotificationSettings.d.ts +2 -0
- package/components/{VencordSettings/PluginsTab.d.ts → settings/tabs/vencord/index.d.ts} +0 -1
- package/modules.d.ts +6 -9
- package/package.json +10 -10
- package/plugins/_api/badges/index.d.ts +27 -8
- package/plugins/_api/chatButtons.d.ts +1 -1
- package/plugins/_api/commands.d.ts +2 -1
- package/plugins/_api/contextMenu.d.ts +5 -3
- package/plugins/{noScreensharePreview/index.d.ts → _api/dynamicImageModalApi.d.ts} +2 -2
- package/plugins/_api/{memberListDecorators.d.ts → memberListDecorators/index.d.ts} +2 -1
- package/plugins/_api/menuItemDemangler.d.ts +17 -0
- package/plugins/_api/messageAccessories.d.ts +1 -1
- package/plugins/_api/messageDecorations/index.d.ts +17 -0
- package/plugins/_api/messageEvents.d.ts +2 -2
- package/plugins/_api/messagePopover.d.ts +2 -2
- package/plugins/_api/{messageDecorations.d.ts → messageUpdater.d.ts} +1 -1
- package/plugins/_api/notices.d.ts +12 -3
- package/plugins/_api/serverList.d.ts +1 -1
- package/plugins/_api/userSettings.d.ts +16 -0
- package/plugins/_core/noTrack.d.ts +8 -10
- package/plugins/_core/settings.d.ts +4 -5
- package/plugins/_core/supportHelper.d.ts +18 -7
- package/plugins/accountPanelServerProfile/index.d.ts +45 -0
- package/plugins/alwaysAnimate/index.d.ts +1 -1
- package/plugins/alwaysExpandRoles/index.d.ts +16 -0
- package/plugins/alwaysTrust/index.d.ts +1 -1
- package/plugins/anonymiseFileNames/index.d.ts +18 -18
- package/plugins/appleMusic.desktop/index.d.ts +226 -0
- package/plugins/appleMusic.desktop/native.d.ts +2 -0
- package/plugins/arRPC.web/index.d.ts +5 -3
- package/plugins/{partyMode → autoDndWhilePlaying.discordDesktop}/index.d.ts +16 -25
- package/plugins/betterFolders/FolderSideBar.d.ts +0 -1
- package/plugins/betterFolders/index.d.ts +34 -10
- package/plugins/betterGifAltText/index.d.ts +1 -1
- package/plugins/betterGifPicker/index.d.ts +1 -1
- package/plugins/betterNotes/index.d.ts +30 -18
- package/plugins/betterRoleContext/index.d.ts +32 -2
- package/plugins/betterRoleDot/index.d.ts +1 -10
- package/plugins/betterSessions/components/RenameButton.d.ts +1 -2
- package/plugins/betterSessions/components/RenameModal.d.ts +1 -2
- package/plugins/betterSessions/components/icons.d.ts +9 -9
- package/plugins/betterSessions/index.d.ts +3 -10
- package/plugins/betterSessions/utils.d.ts +1 -2
- package/plugins/betterSettings/PluginsSubmenu.d.ts +1 -0
- package/plugins/betterSettings/index.d.ts +7 -5
- package/plugins/betterUploadButton/index.d.ts +9 -2
- package/plugins/biggerStreamPreview/index.d.ts +2 -2
- package/plugins/biggerStreamPreview/webpack/types/stores.d.ts +1 -1
- package/plugins/blurNsfw/index.d.ts +1 -1
- package/plugins/callTimer/index.d.ts +4 -5
- package/plugins/clearURLs/index.d.ts +15 -8
- package/plugins/clientTheme/components/Settings.d.ts +2 -0
- package/plugins/clientTheme/index.d.ts +30 -14
- package/plugins/clientTheme/utils/colorUtils.d.ts +6 -0
- package/plugins/clientTheme/utils/styleUtils.d.ts +3 -0
- package/plugins/colorSighted/index.d.ts +1 -1
- package/plugins/consoleJanitor/index.d.ts +98 -0
- package/plugins/consoleShortcuts/index.d.ts +10 -180
- package/plugins/consoleShortcuts/native.d.ts +2 -0
- package/plugins/copyEmojiMarkdown/index.d.ts +37 -0
- package/plugins/copyFileContents/index.d.ts +21 -0
- package/plugins/{searchReply → copyStickerLinks}/index.d.ts +2 -1
- package/plugins/copyUserURLs/index.d.ts +1 -1
- package/plugins/crashHandler/index.d.ts +1 -1
- package/plugins/ctrlEnterSend/index.d.ts +1 -1
- package/plugins/customIdle/index.d.ts +48 -0
- package/plugins/customRPC/index.d.ts +15 -13
- package/plugins/dearrow/index.d.ts +14 -2
- package/plugins/decor/index.d.ts +3 -6
- package/plugins/decor/lib/stores/UsersDecorationsStore.d.ts +1 -1
- package/plugins/decor/settings.d.ts +2 -5
- package/plugins/decor/ui/components/DecorDecorationGridDecoration.d.ts +1 -1
- package/plugins/decor/ui/components/DecorSection.d.ts +1 -2
- package/plugins/decor/ui/components/DecorationContextMenu.d.ts +1 -2
- package/plugins/decor/ui/components/DecorationGridCreate.d.ts +1 -1
- package/plugins/decor/ui/components/DecorationGridNone.d.ts +1 -1
- package/plugins/decor/ui/components/Grid.d.ts +1 -1
- package/plugins/decor/ui/components/SectionedGridList.d.ts +1 -1
- package/plugins/decor/ui/components/index.d.ts +1 -1
- package/plugins/decor/ui/index.d.ts +2 -2
- package/plugins/devCompanion.dev/index.d.ts +3 -2
- package/plugins/disableCallIdle/index.d.ts +1 -1
- package/plugins/dontRoundMyTimestamps/index.d.ts +11 -0
- package/plugins/experiments/index.d.ts +20 -17
- package/plugins/{emoteCloner → expressionCloner}/index.d.ts +1 -1
- package/plugins/f8break/index.d.ts +1 -1
- package/plugins/fakeNitro/index.d.ts +6 -83
- package/plugins/fakeProfileThemes/index.d.ts +5 -7
- package/plugins/favEmojiFirst/index.d.ts +2 -2
- package/plugins/favGifSearch/index.d.ts +5 -8
- package/plugins/fixCodeblockGap/index.d.ts +1 -1
- package/plugins/{nsfwGateBypass → fixImagesQuality}/index.d.ts +1 -1
- package/plugins/fixSpotifyEmbeds.desktop/index.d.ts +1 -1
- package/plugins/fixYoutubeEmbeds.desktop/index.d.ts +1 -1
- package/plugins/forceOwnerCrown/index.d.ts +2 -2
- package/plugins/friendInvites/index.d.ts +6 -24
- package/plugins/friendsSince/index.d.ts +3 -3
- package/plugins/fullSearchContext/index.d.ts +22 -0
- package/plugins/fullUserInChatbox/index.d.ts +24 -0
- package/plugins/gameActivityToggle/index.d.ts +6 -5
- package/plugins/gifPaste/index.d.ts +1 -1
- package/plugins/greetStickerPicker/index.d.ts +4 -4
- package/plugins/hideAttachments/index.d.ts +21 -3
- package/plugins/iLoveSpam/index.d.ts +1 -1
- package/plugins/ignoreActivities/index.d.ts +73 -17
- package/plugins/imageFilename/index.d.ts +31 -0
- package/plugins/imageLink/index.d.ts +1 -1
- package/plugins/imageZoom/components/Magnifier.d.ts +0 -1
- package/plugins/imageZoom/index.d.ts +7 -5
- package/plugins/implicitRelationships/index.d.ts +8 -1
- package/plugins/index.d.ts +3 -1
- package/plugins/invisibleChat.desktop/components/DecryptionModal.d.ts +1 -2
- package/plugins/invisibleChat.desktop/index.d.ts +25 -17
- package/plugins/ircColors/index.d.ts +90 -0
- package/plugins/keepCurrentChannel/index.d.ts +8 -1
- package/plugins/{lastfm → lastfmRichPresence}/index.d.ts +39 -25
- package/plugins/loadingQuotes/index.d.ts +42 -3
- package/plugins/memberCount/CircleIcon.d.ts +3 -0
- package/plugins/memberCount/MemberCount.d.ts +1 -2
- package/plugins/memberCount/OnlineMemberCountStore.d.ts +13 -11
- package/plugins/memberCount/VoiceIcon.d.ts +3 -0
- package/plugins/memberCount/index.d.ts +69 -11
- package/plugins/mentionAvatars/index.d.ts +40 -0
- package/plugins/messageClickActions/index.d.ts +2 -2
- package/plugins/messageLatency/index.d.ts +8 -4
- package/plugins/messageLinkEmbeds/index.d.ts +2 -4
- package/plugins/messageLogger/HistoryModal.d.ts +6 -0
- package/plugins/messageLogger/index.d.ts +46 -8
- package/plugins/messageTags/index.d.ts +23 -5
- package/plugins/mutualGroupDMs/index.d.ts +17 -5
- package/plugins/newGuildSettings/index.d.ts +8 -2
- package/plugins/noBlockedMessages/index.d.ts +35 -11
- package/plugins/noDeepLinks.web/index.d.ts +18 -0
- package/plugins/noDevtoolsWarning/index.d.ts +1 -1
- package/plugins/noF1/index.d.ts +1 -1
- package/plugins/{noRPC.discordDesktop → noMaskedUrlPaste}/index.d.ts +2 -2
- package/plugins/noMosaic/index.d.ts +2 -2
- package/plugins/noOnboardingDelay/index.d.ts +16 -0
- package/plugins/noPendingCount/index.d.ts +10 -3
- package/plugins/noProfileThemes/index.d.ts +2 -1
- package/plugins/noReplyMention/index.d.ts +12 -2
- package/plugins/noServerEmojis/index.d.ts +1 -1
- package/plugins/noSystemBadge.discordDesktop/index.d.ts +1 -1
- package/plugins/noTypingAnimation/index.d.ts +2 -2
- package/plugins/noUnblockToJump/index.d.ts +1 -1
- package/plugins/normalizeMessageLinks/index.d.ts +1 -1
- package/plugins/notificationVolume/index.d.ts +1 -1
- package/plugins/onePingPerDM/index.d.ts +2 -2
- package/plugins/oneko/index.d.ts +1 -1
- package/plugins/openInApp/index.d.ts +6 -51
- package/plugins/openInApp/native.d.ts +0 -1
- package/plugins/overrideForumDefaults/index.d.ts +1 -1
- package/plugins/pauseInvitesForever/index.d.ts +1 -2
- package/plugins/permissionFreeWill/index.d.ts +10 -3
- package/plugins/permissionsViewer/components/RolesAndUsersPermissions.d.ts +2 -3
- package/plugins/permissionsViewer/components/UserPermissions.d.ts +2 -3
- package/plugins/permissionsViewer/components/icons.d.ts +3 -4
- package/plugins/permissionsViewer/index.d.ts +7 -25
- package/plugins/permissionsViewer/utils.d.ts +3 -5
- package/plugins/petpet/index.d.ts +4 -4
- package/plugins/pictureInPicture/index.d.ts +3 -4
- package/plugins/pinDms/components/CreateCategoryModal.d.ts +3 -4
- package/plugins/pinDms/data.d.ts +10 -12
- package/plugins/pinDms/index.d.ts +50 -20
- package/plugins/plainFolderIcon/index.d.ts +3 -2
- package/plugins/platformIndicators/index.d.ts +12 -1
- package/plugins/previewMessage/index.d.ts +3 -5
- package/plugins/quickMention/index.d.ts +9 -6
- package/plugins/quickReply/index.d.ts +24 -1
- package/plugins/reactErrorDecoder/index.d.ts +3 -3
- package/plugins/readAllNotificationsButton/index.d.ts +1 -2
- package/plugins/relationshipNotifier/index.d.ts +1 -1
- package/plugins/relationshipNotifier/types.d.ts +1 -4
- package/plugins/relationshipNotifier/utils.d.ts +7 -0
- package/plugins/replaceGoogleSearch/index.d.ts +1 -1
- package/plugins/replyTimestamp/index.d.ts +2 -3
- package/plugins/revealAllSpoilers/index.d.ts +1 -1
- package/plugins/reverseImageSearch/index.d.ts +1 -1
- package/plugins/reviewDB/components/MessageButton.d.ts +3 -4
- package/plugins/reviewDB/components/ReviewBadge.d.ts +1 -2
- package/plugins/reviewDB/components/ReviewComponent.d.ts +2 -3
- package/plugins/reviewDB/components/ReviewModal.d.ts +2 -1
- package/plugins/reviewDB/components/ReviewsView.d.ts +6 -4
- package/plugins/reviewDB/index.d.ts +12 -14
- package/plugins/reviewDB/settings.d.ts +6 -11
- package/plugins/reviewDB/utils.d.ts +1 -1
- package/plugins/roleColorEverywhere/index.d.ts +75 -29
- package/plugins/secretRingTone/index.d.ts +25 -4
- package/plugins/seeSummaries/index.d.ts +39 -0
- package/plugins/sendTimestamps/index.d.ts +5 -6
- package/plugins/serverInfo/GuildInfoModal.d.ts +3 -0
- package/plugins/{serverProfile → serverInfo}/index.d.ts +2 -1
- package/plugins/serverListIndicators/index.d.ts +2 -10
- package/plugins/shikiCodeblocks.desktop/api/languages.d.ts +3 -3
- package/plugins/shikiCodeblocks.desktop/api/shiki.d.ts +27 -1
- package/plugins/shikiCodeblocks.desktop/api/themes.d.ts +29 -3
- package/plugins/shikiCodeblocks.desktop/components/ButtonRow.d.ts +1 -2
- package/plugins/shikiCodeblocks.desktop/components/Code.d.ts +1 -1
- package/plugins/shikiCodeblocks.desktop/components/CopyButton.d.ts +1 -2
- package/plugins/shikiCodeblocks.desktop/components/Header.d.ts +1 -2
- package/plugins/shikiCodeblocks.desktop/components/Highlighter.d.ts +2 -4
- package/plugins/shikiCodeblocks.desktop/hooks/useShikiSettings.d.ts +2 -8
- package/plugins/shikiCodeblocks.desktop/index.d.ts +42 -17
- package/plugins/showAllMessageButtons/index.d.ts +1 -1
- package/plugins/showConnections/VerifiedIcon.d.ts +1 -2
- package/plugins/showConnections/index.d.ts +10 -14
- package/plugins/showHiddenChannels/components/HiddenChannelLockScreen.d.ts +1 -2
- package/plugins/showHiddenChannels/index.d.ts +7 -6
- package/plugins/showHiddenThings/index.d.ts +25 -37
- package/plugins/showMeYourName/index.d.ts +30 -3
- package/plugins/showTimeoutDuration/index.d.ts +2 -2
- package/plugins/silentMessageToggle/index.d.ts +3 -5
- package/plugins/silentTyping/index.d.ts +4 -6
- package/plugins/sortFriendRequests/index.d.ts +8 -6
- package/plugins/spotifyControls/PlayerComponent.d.ts +1 -2
- package/plugins/spotifyControls/SeekBar.d.ts +31 -0
- package/plugins/spotifyControls/SpotifyStore.d.ts +42 -1
- package/plugins/spotifyControls/index.d.ts +7 -3
- package/plugins/spotifyCrack/index.d.ts +1 -1
- package/plugins/spotifyShareCommands/index.d.ts +3 -10
- package/plugins/startupTimings/StartupTimingPage.d.ts +0 -1
- package/plugins/startupTimings/index.d.ts +2 -3
- package/plugins/{noDefaultHangStatus → stickerPaste}/index.d.ts +1 -1
- package/plugins/streamerModeOnStream/index.d.ts +1 -1
- package/plugins/superReactionTweaks/index.d.ts +10 -5
- package/plugins/textReplace/index.d.ts +21 -9
- package/plugins/themeAttributes/index.d.ts +3 -3
- package/plugins/translate/TranslateIcon.d.ts +4 -4
- package/plugins/translate/TranslateModal.d.ts +1 -2
- package/plugins/translate/TranslationAccessory.d.ts +2 -3
- package/plugins/translate/index.d.ts +73 -6
- package/plugins/translate/languages.d.ts +40 -2
- package/plugins/translate/native.d.ts +5 -0
- package/plugins/translate/settings.d.ts +61 -2
- package/plugins/translate/utils.d.ts +172 -1
- package/plugins/typingIndicator/index.d.ts +2 -3
- package/plugins/typingTweaks/index.d.ts +31 -29
- package/plugins/unindent/index.d.ts +3 -4
- package/plugins/unlockedAvatarZoom/index.d.ts +1 -1
- package/plugins/unsuppressEmbeds/index.d.ts +1 -1
- package/plugins/{pronoundb/components → userMessagesPronouns}/PronounsChatComponent.d.ts +1 -5
- package/plugins/userMessagesPronouns/index.d.ts +67 -0
- package/plugins/userMessagesPronouns/settings.d.ts +44 -0
- package/plugins/userMessagesPronouns/utils.d.ts +1 -0
- package/plugins/userVoiceShow/components.d.ts +7 -0
- package/plugins/userVoiceShow/index.d.ts +34 -12
- package/plugins/usrbg/index.d.ts +5 -8
- package/plugins/validReply/index.d.ts +2 -3
- package/plugins/validUser/index.d.ts +2 -3
- package/plugins/vcDoubleClick/index.d.ts +1 -1
- package/plugins/vcNarrator/VoiceSetting.d.ts +1 -0
- package/plugins/vcNarrator/index.d.ts +137 -10
- package/plugins/vcNarrator/settings.d.ts +135 -0
- package/plugins/vencordToolbox/index.d.ts +2 -5
- package/plugins/viewIcons/index.d.ts +6 -12
- package/plugins/viewRaw/index.d.ts +14 -4
- package/plugins/voiceDownload/index.d.ts +3 -4
- package/plugins/voiceMessages/VoicePreview.d.ts +1 -2
- package/plugins/voiceMessages/index.d.ts +1 -1
- package/plugins/voiceMessages/native.d.ts +1 -1
- package/plugins/voiceMessages/utils.d.ts +1 -0
- package/plugins/{volumeBooster.discordDesktop → volumeBooster}/index.d.ts +29 -1
- package/plugins/webContextMenus.web/index.d.ts +19 -3
- package/plugins/webKeybinds.web/index.d.ts +1 -1
- package/plugins/webScreenShareFixes.web/index.d.ts +6 -3
- package/plugins/whoReacted/index.d.ts +4 -6
- package/plugins/{xsOverlay.desktop → xsOverlay}/index.d.ts +32 -3
- package/plugins/youtubeAdblock.desktop/index.d.ts +9 -0
- package/plugins/youtubeAdblock.desktop/native.d.ts +1 -0
- package/shared/IpcEvents.d.ts +13 -10
- package/shared/SettingsStore.d.ts +5 -0
- package/shared/vencordUserAgent.d.ts +0 -1
- package/utils/ChangeList.d.ts +1 -1
- package/utils/clipboard.d.ts +1 -0
- package/utils/cloud.d.ts +1 -0
- package/utils/constants.d.ts +108 -10
- package/utils/cspViolations.d.ts +2 -0
- package/utils/dependencies.d.ts +1 -4
- package/utils/discord.d.ts +51 -8
- package/utils/index.d.ts +3 -0
- package/utils/intlHash.d.ts +8 -0
- package/utils/lazy.d.ts +2 -0
- package/utils/lazyReact.d.ts +5 -2
- package/utils/misc.d.ts +5 -2
- package/utils/modal.d.ts +88 -74
- package/utils/patches.d.ts +2 -2
- package/utils/quickCss.d.ts +1 -1
- package/utils/react.d.ts +9 -6
- package/utils/text.d.ts +3 -0
- package/utils/types.d.ts +83 -34
- package/utils/web.d.ts +1 -0
- package/webpack/common/FormText.d.ts +2 -0
- package/webpack/common/classes.d.ts +1 -2
- package/webpack/common/components.d.ts +161 -30
- package/webpack/common/index.d.ts +1 -4
- package/webpack/common/internal.d.ts +2 -2
- package/webpack/common/menu.d.ts +2 -2
- package/webpack/common/react.d.ts +3 -1
- package/webpack/common/stores.d.ts +18 -23
- package/webpack/common/userSettings.d.ts +4 -0
- package/webpack/common/utils.d.ts +46 -33
- package/webpack/index.d.ts +1 -0
- package/webpack/patchWebpack.d.ts +12 -1
- package/webpack/types.d.ts +17 -0
- package/webpack/webpack.d.ts +68 -37
- package/VencordNative.d.ts +0 -42
- package/components/Badge.d.ts +0 -5
- package/components/DonateButton.d.ts +0 -2
- package/components/ExpandableHeader.d.ts +0 -12
- package/components/PluginSettings/ContributorModal.d.ts +0 -3
- package/components/PluginSettings/PluginModal.d.ts +0 -9
- package/components/PluginSettings/components/SettingBooleanComponent.d.ts +0 -4
- package/components/PluginSettings/components/SettingCustomComponent.d.ts +0 -4
- package/components/PluginSettings/components/SettingNumericComponent.d.ts +0 -4
- package/components/PluginSettings/components/SettingSelectComponent.d.ts +0 -4
- package/components/PluginSettings/components/SettingSliderComponent.d.ts +0 -5
- package/components/PluginSettings/components/SettingTextComponent.d.ts +0 -4
- package/components/PluginSettings/components/index.d.ts +0 -19
- package/components/PluginSettings/index.d.ts +0 -12
- package/components/VencordSettings/VencordTab.d.ts +0 -3
- package/plugins/automodContext/index.d.ts +0 -20
- package/plugins/banger/index.d.ts +0 -25
- package/plugins/clearURLs/defaultRules.d.ts +0 -1
- package/plugins/moreCommands/index.d.ts +0 -26
- package/plugins/moreKaomoji/index.d.ts +0 -18
- package/plugins/moreUserTags/index.d.ts +0 -77
- package/plugins/moyai/index.d.ts +0 -113
- package/plugins/pronoundb/components/PronounsAboutComponent.d.ts +0 -2
- package/plugins/pronoundb/index.d.ts +0 -113
- package/plugins/pronoundb/pronoundbUtils.d.ts +0 -18
- package/plugins/pronoundb/settings.d.ts +0 -87
- package/plugins/pronoundb/types.d.ts +0 -31
- package/plugins/resurrectHome/index.d.ts +0 -63
- package/plugins/serverProfile/GuildProfileModal.d.ts +0 -3
- package/plugins/timeBarAllActivities/index.d.ts +0 -16
- package/plugins/urbanDictionary/index.d.ts +0 -38
- package/plugins/userVoiceShow/components/VoiceChannelSection.d.ts +0 -10
- package/plugins/wikisearch/index.d.ts +0 -23
- package/webpack/common/settingsStores.d.ts +0 -4
- package/webpack/common/types/classes.d.ts +0 -39
- package/webpack/common/types/components.d.ts +0 -460
- package/webpack/common/types/fluxEvents.d.ts +0 -40
- package/webpack/common/types/i18nMessages.d.ts +0 -2
- package/webpack/common/types/index.d.ts +0 -26
- package/webpack/common/types/menu.d.ts +0 -91
- package/webpack/common/types/settingsStores.d.ts +0 -5
- package/webpack/common/types/stores.d.ts +0 -201
- package/webpack/common/types/utils.d.ts +0 -226
- /package/plugins/{xsOverlay.desktop → xsOverlay}/native.d.ts +0 -0
package/Vencord.d.ts
CHANGED
|
@@ -15,6 +15,7 @@
|
|
|
15
15
|
* You should have received a copy of the GNU General Public License
|
|
16
16
|
* along with this program. If not, see <https://www.gnu.org/licenses/>.
|
|
17
17
|
*/
|
|
18
|
+
import "~plugins";
|
|
18
19
|
export * as Api from "./api";
|
|
19
20
|
export * as Components from "./components";
|
|
20
21
|
export * as Plugins from "./plugins";
|
|
@@ -22,6 +23,7 @@ export * as Util from "./utils";
|
|
|
22
23
|
export * as QuickCss from "./utils/quickCss";
|
|
23
24
|
export * as Updater from "./utils/updater";
|
|
24
25
|
export * as Webpack from "./webpack";
|
|
26
|
+
export * as WebpackPatcher from "./webpack/patchWebpack";
|
|
25
27
|
export { PlainSettings, Settings };
|
|
26
28
|
import "./utils/quickCss";
|
|
27
29
|
import "./webpack/patchWebpack";
|
package/api/Badges.d.ts
CHANGED
|
@@ -1,4 +1,3 @@
|
|
|
1
|
-
import { User } from "discord-types/general";
|
|
2
1
|
import { ComponentType, HTMLProps } from "react";
|
|
3
2
|
export declare const enum BadgePosition {
|
|
4
3
|
START = 0,
|
|
@@ -13,7 +12,9 @@ export interface ProfileBadge {
|
|
|
13
12
|
image?: string;
|
|
14
13
|
link?: string;
|
|
15
14
|
/** Action to perform when you click the badge */
|
|
16
|
-
onClick?(event: React.MouseEvent
|
|
15
|
+
onClick?(event: React.MouseEvent, props: ProfileBadge & BadgeUserArgs): void;
|
|
16
|
+
/** Action to perform when you right click the badge */
|
|
17
|
+
onContextMenu?(event: React.MouseEvent, props: BadgeUserArgs & BadgeUserArgs): void;
|
|
17
18
|
/** Should the user display this badge? */
|
|
18
19
|
shouldShow?(userInfo: BadgeUserArgs): boolean;
|
|
19
20
|
/** Optional props (e.g. style) for the badge, ignored for component badges */
|
|
@@ -22,23 +23,27 @@ export interface ProfileBadge {
|
|
|
22
23
|
position?: BadgePosition;
|
|
23
24
|
/** The badge name to display, Discord uses this. Required for component badges */
|
|
24
25
|
key?: string;
|
|
26
|
+
/**
|
|
27
|
+
* Allows dynamically returning multiple badges
|
|
28
|
+
*/
|
|
29
|
+
getBadges?(userInfo: BadgeUserArgs): ProfileBadge[];
|
|
25
30
|
}
|
|
26
31
|
/**
|
|
27
32
|
* Register a new badge with the Badges API
|
|
28
33
|
* @param badge The badge to register
|
|
29
34
|
*/
|
|
30
|
-
export declare function
|
|
35
|
+
export declare function addProfileBadge(badge: ProfileBadge): void;
|
|
31
36
|
/**
|
|
32
37
|
* Unregister a badge from the Badges API
|
|
33
38
|
* @param badge The badge to remove
|
|
34
39
|
*/
|
|
35
|
-
export declare function
|
|
40
|
+
export declare function removeProfileBadge(badge: ProfileBadge): boolean;
|
|
36
41
|
/**
|
|
37
42
|
* Inject badges into the profile badges array.
|
|
38
43
|
* You probably don't need to use this.
|
|
39
44
|
*/
|
|
40
45
|
export declare function _getBadges(args: BadgeUserArgs): ProfileBadge[];
|
|
41
46
|
export interface BadgeUserArgs {
|
|
42
|
-
|
|
47
|
+
userId: string;
|
|
43
48
|
guildId: string;
|
|
44
49
|
}
|
package/api/ChatButtons.d.ts
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import "./ChatButton.css";
|
|
2
|
-
import { Channel } from "discord-types
|
|
3
|
-
import { HTMLProps, MouseEventHandler, ReactNode } from "react";
|
|
2
|
+
import { Channel } from "@vencord/discord-types";
|
|
3
|
+
import { HTMLProps, JSX, MouseEventHandler, ReactNode } from "react";
|
|
4
4
|
export interface ChatBarProps {
|
|
5
5
|
channel: Channel;
|
|
6
6
|
disabled: boolean;
|
|
@@ -58,17 +58,18 @@ export interface ChatBarProps {
|
|
|
58
58
|
sedReplace: boolean;
|
|
59
59
|
};
|
|
60
60
|
}
|
|
61
|
-
export type
|
|
61
|
+
export type ChatBarButtonFactory = (props: ChatBarProps & {
|
|
62
62
|
isMainChat: boolean;
|
|
63
63
|
}) => JSX.Element | null;
|
|
64
64
|
export declare function _injectButtons(buttons: ReactNode[], props: ChatBarProps): void;
|
|
65
|
-
export declare const addChatBarButton: (id: string, button:
|
|
65
|
+
export declare const addChatBarButton: (id: string, button: ChatBarButtonFactory) => Map<string, ChatBarButtonFactory>;
|
|
66
66
|
export declare const removeChatBarButton: (id: string) => boolean;
|
|
67
67
|
export interface ChatBarButtonProps {
|
|
68
68
|
children: ReactNode;
|
|
69
69
|
tooltip: string;
|
|
70
70
|
onClick: MouseEventHandler<HTMLButtonElement>;
|
|
71
71
|
onContextMenu?: MouseEventHandler<HTMLButtonElement>;
|
|
72
|
-
|
|
72
|
+
onAuxClick?: MouseEventHandler<HTMLButtonElement>;
|
|
73
|
+
buttonProps?: Omit<HTMLProps<HTMLButtonElement>, "size" | "onClick" | "onContextMenu" | "onAuxClick">;
|
|
73
74
|
}
|
|
74
75
|
export declare const ChatBarButton: import("react").FunctionComponent<ChatBarButtonProps>;
|
|
@@ -1,6 +1,5 @@
|
|
|
1
|
-
import { Message } from "discord-types
|
|
1
|
+
import { CommandArgument, Message } from "@vencord/discord-types";
|
|
2
2
|
import type { PartialDeep } from "type-fest";
|
|
3
|
-
import { Argument } from "./types";
|
|
4
3
|
export declare function generateId(): string;
|
|
5
4
|
/**
|
|
6
5
|
* Send a message as Clyde
|
|
@@ -16,5 +15,5 @@ export declare function sendBotMessage(channelId: string, message: PartialDeep<M
|
|
|
16
15
|
* @param fallbackValue Fallback value in case this option wasn't passed
|
|
17
16
|
* @returns Value
|
|
18
17
|
*/
|
|
19
|
-
export declare function findOption<T>(args:
|
|
20
|
-
export declare function findOption<T>(args:
|
|
18
|
+
export declare function findOption<T>(args: CommandArgument[], name: string): T & {} | undefined;
|
|
19
|
+
export declare function findOption<T>(args: CommandArgument[], name: string, fallbackValue: T): T & {};
|
package/api/Commands/index.d.ts
CHANGED
|
@@ -1,26 +1,27 @@
|
|
|
1
|
-
import {
|
|
1
|
+
import { CommandOption } from "@vencord/discord-types";
|
|
2
|
+
import { VencordCommand } from "./types";
|
|
2
3
|
export * from "./commandHelpers";
|
|
3
4
|
export * from "./types";
|
|
4
|
-
export declare let BUILT_IN:
|
|
5
|
-
export declare const commands: Record<string,
|
|
5
|
+
export declare let BUILT_IN: VencordCommand[];
|
|
6
|
+
export declare const commands: Record<string, VencordCommand>;
|
|
6
7
|
/**
|
|
7
8
|
* Optional message option named "message" you can use in commands.
|
|
8
9
|
* Used in "tableflip" or "shrug"
|
|
9
10
|
* @see {@link RequiredMessageOption}
|
|
10
11
|
*/
|
|
11
|
-
export declare let OptionalMessageOption:
|
|
12
|
+
export declare let OptionalMessageOption: CommandOption;
|
|
12
13
|
/**
|
|
13
14
|
* Required message option named "message" you can use in commands.
|
|
14
15
|
* Used in "me"
|
|
15
16
|
* @see {@link OptionalMessageOption}
|
|
16
17
|
*/
|
|
17
|
-
export declare let RequiredMessageOption:
|
|
18
|
+
export declare let RequiredMessageOption: CommandOption;
|
|
18
19
|
export declare const _init: never;
|
|
19
20
|
export declare const _handleCommand: never;
|
|
20
21
|
/**
|
|
21
22
|
* Prepare a Command Option for Discord by filling missing fields
|
|
22
23
|
* @param opt
|
|
23
24
|
*/
|
|
24
|
-
export declare function prepareOption<O extends
|
|
25
|
-
export declare function registerCommand<C extends
|
|
25
|
+
export declare function prepareOption<O extends CommandOption | VencordCommand>(opt: O): O;
|
|
26
|
+
export declare function registerCommand<C extends VencordCommand>(command: C, plugin: string): void;
|
|
26
27
|
export declare function unregisterCommand(name: string): boolean;
|
package/api/Commands/types.d.ts
CHANGED
|
@@ -1,74 +1,5 @@
|
|
|
1
|
-
import {
|
|
2
|
-
|
|
3
|
-
export interface
|
|
4
|
-
channel: Channel;
|
|
5
|
-
guild?: Guild;
|
|
6
|
-
}
|
|
7
|
-
export declare const enum ApplicationCommandOptionType {
|
|
8
|
-
SUB_COMMAND = 1,
|
|
9
|
-
SUB_COMMAND_GROUP = 2,
|
|
10
|
-
STRING = 3,
|
|
11
|
-
INTEGER = 4,
|
|
12
|
-
BOOLEAN = 5,
|
|
13
|
-
USER = 6,
|
|
14
|
-
CHANNEL = 7,
|
|
15
|
-
ROLE = 8,
|
|
16
|
-
MENTIONABLE = 9,
|
|
17
|
-
NUMBER = 10,
|
|
18
|
-
ATTACHMENT = 11
|
|
19
|
-
}
|
|
20
|
-
export declare const enum ApplicationCommandInputType {
|
|
21
|
-
BUILT_IN = 0,
|
|
22
|
-
BUILT_IN_TEXT = 1,
|
|
23
|
-
BUILT_IN_INTEGRATION = 2,
|
|
24
|
-
BOT = 3,
|
|
25
|
-
PLACEHOLDER = 4
|
|
26
|
-
}
|
|
27
|
-
export interface Option {
|
|
28
|
-
name: string;
|
|
29
|
-
displayName?: string;
|
|
30
|
-
type: ApplicationCommandOptionType;
|
|
31
|
-
description: string;
|
|
32
|
-
displayDescription?: string;
|
|
33
|
-
required?: boolean;
|
|
34
|
-
options?: Option[];
|
|
35
|
-
choices?: Array<ChoicesOption>;
|
|
36
|
-
}
|
|
37
|
-
export interface ChoicesOption {
|
|
38
|
-
label: string;
|
|
39
|
-
value: string;
|
|
40
|
-
name: string;
|
|
41
|
-
displayName?: string;
|
|
42
|
-
}
|
|
43
|
-
export declare const enum ApplicationCommandType {
|
|
44
|
-
CHAT_INPUT = 1,
|
|
45
|
-
USER = 2,
|
|
46
|
-
MESSAGE = 3
|
|
47
|
-
}
|
|
48
|
-
export interface CommandReturnValue {
|
|
49
|
-
content: string;
|
|
50
|
-
/** TODO: implement */
|
|
51
|
-
cancel?: boolean;
|
|
52
|
-
}
|
|
53
|
-
export interface Argument {
|
|
54
|
-
type: ApplicationCommandOptionType;
|
|
55
|
-
name: string;
|
|
56
|
-
value: string;
|
|
57
|
-
focused: undefined;
|
|
58
|
-
options: Argument[];
|
|
59
|
-
}
|
|
60
|
-
export interface Command {
|
|
61
|
-
id?: string;
|
|
62
|
-
applicationId?: string;
|
|
63
|
-
type?: ApplicationCommandType;
|
|
64
|
-
inputType?: ApplicationCommandInputType;
|
|
65
|
-
plugin?: string;
|
|
1
|
+
import { Command } from "@vencord/discord-types";
|
|
2
|
+
export { ApplicationCommandInputType, ApplicationCommandOptionType, ApplicationCommandType } from "@vencord/discord-types/enums";
|
|
3
|
+
export interface VencordCommand extends Command {
|
|
66
4
|
isVencordCommand?: boolean;
|
|
67
|
-
name: string;
|
|
68
|
-
displayName?: string;
|
|
69
|
-
description: string;
|
|
70
|
-
displayDescription?: string;
|
|
71
|
-
options?: Option[];
|
|
72
|
-
predicate?(ctx: CommandContext): boolean;
|
|
73
|
-
execute(args: Argument[], ctx: CommandContext): Promisable<void | CommandReturnValue>;
|
|
74
5
|
}
|
package/api/ContextMenu.d.ts
CHANGED
|
@@ -3,13 +3,13 @@ import type { ReactElement } from "react";
|
|
|
3
3
|
* @param children The rendered context menu elements
|
|
4
4
|
* @param args Any arguments passed into making the context menu, like the guild, channel, user or message for example
|
|
5
5
|
*/
|
|
6
|
-
export type NavContextMenuPatchCallback = (children: Array<ReactElement | null>, ...args: Array<any>) => void;
|
|
6
|
+
export type NavContextMenuPatchCallback = (children: Array<ReactElement<any> | null>, ...args: Array<any>) => void;
|
|
7
7
|
/**
|
|
8
8
|
* @param navId The navId of the context menu being patched
|
|
9
9
|
* @param children The rendered context menu elements
|
|
10
10
|
* @param args Any arguments passed into making the context menu, like the guild, channel, user or message for example
|
|
11
11
|
*/
|
|
12
|
-
export type GlobalContextMenuPatchCallback = (navId: string, children: Array<ReactElement | null>, ...args: Array<any>) => void;
|
|
12
|
+
export type GlobalContextMenuPatchCallback = (navId: string, children: Array<ReactElement<any> | null>, ...args: Array<any>) => void;
|
|
13
13
|
export declare const navPatches: Map<string, Set<NavContextMenuPatchCallback>>;
|
|
14
14
|
export declare const globalPatches: Set<GlobalContextMenuPatchCallback>;
|
|
15
15
|
/**
|
|
@@ -40,12 +40,13 @@ export declare function removeGlobalContextMenuPatch(patch: GlobalContextMenuPat
|
|
|
40
40
|
* A helper function for finding the children array of a group nested inside a context menu based on the id(s) of its children
|
|
41
41
|
* @param id The id of the child. If an array is specified, all ids will be tried
|
|
42
42
|
* @param children The context menu children
|
|
43
|
+
* @param matchSubstring Whether to check if the id is a substring of the child id
|
|
43
44
|
*/
|
|
44
|
-
export declare function findGroupChildrenByChildId(id: string | string[], children: Array<ReactElement | null
|
|
45
|
+
export declare function findGroupChildrenByChildId(id: string | string[], children: Array<ReactElement<any> | null | undefined>, matchSubstring?: boolean): Array<ReactElement<any> | null | undefined> | null;
|
|
45
46
|
interface ContextMenuProps {
|
|
46
|
-
|
|
47
|
+
contextMenuAPIArguments?: Array<any>;
|
|
47
48
|
navId: string;
|
|
48
|
-
children: Array<ReactElement | null>;
|
|
49
|
+
children: Array<ReactElement<any> | null>;
|
|
49
50
|
"aria-label": string;
|
|
50
51
|
onSelect: (() => void) | undefined;
|
|
51
52
|
onClose: (callback: (...args: Array<any>) => any) => void;
|
|
@@ -1,32 +1,20 @@
|
|
|
1
|
-
|
|
2
|
-
import {
|
|
1
|
+
import { Channel, User } from "@vencord/discord-types";
|
|
2
|
+
import { JSX } from "react";
|
|
3
3
|
interface DecoratorProps {
|
|
4
|
-
|
|
5
|
-
channel: Channel;
|
|
6
|
-
/**
|
|
7
|
-
* Only for DM members
|
|
8
|
-
*/
|
|
9
|
-
channelName?: string;
|
|
10
|
-
/**
|
|
11
|
-
* Only for server members
|
|
12
|
-
*/
|
|
13
|
-
currentUser?: User;
|
|
14
|
-
guildId?: string;
|
|
15
|
-
isMobile: boolean;
|
|
16
|
-
isOwner?: boolean;
|
|
17
|
-
isTyping: boolean;
|
|
18
|
-
selected: boolean;
|
|
19
|
-
status: string;
|
|
4
|
+
type: "guild" | "dm";
|
|
20
5
|
user: User;
|
|
21
|
-
|
|
6
|
+
/** only present when this is a DM list item */
|
|
7
|
+
channel: Channel;
|
|
8
|
+
/** only present when this is a guild list item */
|
|
9
|
+
isOwner: boolean;
|
|
22
10
|
}
|
|
23
|
-
export type
|
|
11
|
+
export type MemberListDecoratorFactory = (props: DecoratorProps) => JSX.Element | null;
|
|
24
12
|
type OnlyIn = "guilds" | "dms";
|
|
25
|
-
export declare const
|
|
26
|
-
|
|
27
|
-
onlyIn?: OnlyIn
|
|
13
|
+
export declare const decoratorsFactories: Map<string, {
|
|
14
|
+
render: MemberListDecoratorFactory;
|
|
15
|
+
onlyIn?: OnlyIn;
|
|
28
16
|
}>;
|
|
29
|
-
export declare function
|
|
30
|
-
export declare function
|
|
31
|
-
export declare function __getDecorators(props: DecoratorProps):
|
|
17
|
+
export declare function addMemberListDecorator(identifier: string, render: MemberListDecoratorFactory, onlyIn?: OnlyIn): void;
|
|
18
|
+
export declare function removeMemberListDecorator(identifier: string): void;
|
|
19
|
+
export declare function __getDecorators(props: DecoratorProps, type: "guild" | "dm"): JSX.Element;
|
|
32
20
|
export {};
|
|
@@ -1,10 +1,10 @@
|
|
|
1
|
-
|
|
2
|
-
export type
|
|
3
|
-
export type
|
|
4
|
-
|
|
1
|
+
import { JSX, ReactNode } from "react";
|
|
2
|
+
export type MessageAccessoryFactory = (props: Record<string, any>) => ReactNode;
|
|
3
|
+
export type MessageAccessory = {
|
|
4
|
+
render: MessageAccessoryFactory;
|
|
5
5
|
position?: number;
|
|
6
6
|
};
|
|
7
|
-
export declare const accessories: Map<
|
|
8
|
-
export declare function
|
|
9
|
-
export declare function
|
|
7
|
+
export declare const accessories: Map<string, MessageAccessory>;
|
|
8
|
+
export declare function addMessageAccessory(identifier: string, render: MessageAccessoryFactory, position?: number): void;
|
|
9
|
+
export declare function removeMessageAccessory(identifier: string): void;
|
|
10
10
|
export declare function _modifyAccessories(elements: JSX.Element[], props: Record<string, any>): JSX.Element[];
|
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
|
|
2
|
-
import {
|
|
3
|
-
interface
|
|
1
|
+
import { Channel, Message } from "@vencord/discord-types";
|
|
2
|
+
import { JSX } from "react";
|
|
3
|
+
export interface MessageDecorationProps {
|
|
4
4
|
author: {
|
|
5
5
|
/**
|
|
6
6
|
* Will be username if the user has no nickname
|
|
@@ -26,9 +26,8 @@ interface DecorationProps {
|
|
|
26
26
|
message: Message;
|
|
27
27
|
[key: string]: any;
|
|
28
28
|
}
|
|
29
|
-
export type
|
|
30
|
-
export declare const
|
|
31
|
-
export declare function
|
|
32
|
-
export declare function
|
|
33
|
-
export declare function __addDecorationsToMessage(props:
|
|
34
|
-
export {};
|
|
29
|
+
export type MessageDecorationFactory = (props: MessageDecorationProps) => JSX.Element | null;
|
|
30
|
+
export declare const decorationsFactories: Map<string, MessageDecorationFactory>;
|
|
31
|
+
export declare function addMessageDecoration(identifier: string, decoration: MessageDecorationFactory): void;
|
|
32
|
+
export declare function removeMessageDecoration(identifier: string): void;
|
|
33
|
+
export declare function __addDecorationsToMessage(props: MessageDecorationProps): JSX.Element;
|
package/api/MessageEvents.d.ts
CHANGED
|
@@ -1,5 +1,4 @@
|
|
|
1
|
-
import { CustomEmoji } from "
|
|
2
|
-
import type { Channel, Message } from "discord-types/general";
|
|
1
|
+
import type { Channel, CloudUpload, CustomEmoji, Message } from "@vencord/discord-types";
|
|
3
2
|
import type { Promisable } from "type-fest";
|
|
4
3
|
export interface MessageObject {
|
|
5
4
|
content: string;
|
|
@@ -7,29 +6,6 @@ export interface MessageObject {
|
|
|
7
6
|
invalidEmojis: any[];
|
|
8
7
|
tts: boolean;
|
|
9
8
|
}
|
|
10
|
-
export interface Upload {
|
|
11
|
-
classification: string;
|
|
12
|
-
currentSize: number;
|
|
13
|
-
description: string | null;
|
|
14
|
-
filename: string;
|
|
15
|
-
id: string;
|
|
16
|
-
isImage: boolean;
|
|
17
|
-
isVideo: boolean;
|
|
18
|
-
item: {
|
|
19
|
-
file: File;
|
|
20
|
-
platform: number;
|
|
21
|
-
};
|
|
22
|
-
loaded: number;
|
|
23
|
-
mimeType: string;
|
|
24
|
-
preCompressionSize: number;
|
|
25
|
-
responseUrl: string;
|
|
26
|
-
sensitive: boolean;
|
|
27
|
-
showLargeMessageDialog: boolean;
|
|
28
|
-
spoiler: boolean;
|
|
29
|
-
status: "NOT_STARTED" | "STARTED" | "UPLOADING" | "ERROR" | "COMPLETED" | "CANCELLED";
|
|
30
|
-
uniqueId: string;
|
|
31
|
-
uploadedFilename: string;
|
|
32
|
-
}
|
|
33
9
|
export interface MessageReplyOptions {
|
|
34
10
|
messageReference: Message["messageReference"];
|
|
35
11
|
allowedMentions?: {
|
|
@@ -37,35 +13,34 @@ export interface MessageReplyOptions {
|
|
|
37
13
|
repliedUser: boolean;
|
|
38
14
|
};
|
|
39
15
|
}
|
|
40
|
-
export interface
|
|
16
|
+
export interface MessageOptions {
|
|
41
17
|
stickers?: string[];
|
|
42
|
-
uploads?:
|
|
18
|
+
uploads?: CloudUpload[];
|
|
43
19
|
replyOptions: MessageReplyOptions;
|
|
44
20
|
content: string;
|
|
45
21
|
channel: Channel;
|
|
46
22
|
type?: any;
|
|
47
23
|
openWarningPopout: (props: any) => any;
|
|
48
24
|
}
|
|
49
|
-
export type
|
|
25
|
+
export type MessageSendListener = (channelId: string, messageObj: MessageObject, options: MessageOptions) => Promisable<void | {
|
|
50
26
|
cancel: boolean;
|
|
51
27
|
}>;
|
|
52
|
-
export type
|
|
28
|
+
export type MessageEditListener = (channelId: string, messageId: string, messageObj: MessageObject) => Promisable<void | {
|
|
53
29
|
cancel: boolean;
|
|
54
30
|
}>;
|
|
55
|
-
export declare function _handlePreSend(channelId: string, messageObj: MessageObject,
|
|
31
|
+
export declare function _handlePreSend(channelId: string, messageObj: MessageObject, options: MessageOptions, replyOptions: MessageReplyOptions): Promise<boolean>;
|
|
56
32
|
export declare function _handlePreEdit(channelId: string, messageId: string, messageObj: MessageObject): Promise<boolean>;
|
|
57
33
|
/**
|
|
58
34
|
* Note: This event fires off before a message is sent, allowing you to edit the message.
|
|
59
35
|
*/
|
|
60
|
-
export declare function
|
|
36
|
+
export declare function addMessagePreSendListener(listener: MessageSendListener): MessageSendListener;
|
|
61
37
|
/**
|
|
62
38
|
* Note: This event fires off before a message's edit is applied, allowing you to further edit the message.
|
|
63
39
|
*/
|
|
64
|
-
export declare function
|
|
65
|
-
export declare function
|
|
66
|
-
export declare function
|
|
67
|
-
type
|
|
40
|
+
export declare function addMessagePreEditListener(listener: MessageEditListener): MessageEditListener;
|
|
41
|
+
export declare function removeMessagePreSendListener(listener: MessageSendListener): boolean;
|
|
42
|
+
export declare function removeMessagePreEditListener(listener: MessageEditListener): boolean;
|
|
43
|
+
export type MessageClickListener = (message: Message, channel: Channel, event: MouseEvent) => void;
|
|
68
44
|
export declare function _handleClick(message: Message, channel: Channel, event: MouseEvent): void;
|
|
69
|
-
export declare function
|
|
70
|
-
export declare function
|
|
71
|
-
export {};
|
|
45
|
+
export declare function addMessageClickListener(listener: MessageClickListener): MessageClickListener;
|
|
46
|
+
export declare function removeMessageClickListener(listener: MessageClickListener): boolean;
|
package/api/MessagePopover.d.ts
CHANGED
|
@@ -1,16 +1,16 @@
|
|
|
1
|
-
import { Channel, Message } from "discord-types
|
|
2
|
-
import type { MouseEventHandler } from "react";
|
|
3
|
-
export interface
|
|
1
|
+
import { Channel, Message } from "@vencord/discord-types";
|
|
2
|
+
import type { ComponentType, MouseEventHandler } from "react";
|
|
3
|
+
export interface MessagePopoverButtonItem {
|
|
4
4
|
key?: string;
|
|
5
5
|
label: string;
|
|
6
|
-
icon:
|
|
6
|
+
icon: ComponentType<any>;
|
|
7
7
|
message: Message;
|
|
8
8
|
channel: Channel;
|
|
9
9
|
onClick?: MouseEventHandler<HTMLButtonElement>;
|
|
10
10
|
onContextMenu?: MouseEventHandler<HTMLButtonElement>;
|
|
11
11
|
}
|
|
12
|
-
export type
|
|
13
|
-
export declare const buttons: Map<string,
|
|
14
|
-
export declare function
|
|
15
|
-
export declare function
|
|
16
|
-
export declare function _buildPopoverElements(
|
|
12
|
+
export type MessagePopoverButtonFactory = (message: Message) => MessagePopoverButtonItem | null;
|
|
13
|
+
export declare const buttons: Map<string, MessagePopoverButtonFactory>;
|
|
14
|
+
export declare function addMessagePopoverButton(identifier: string, item: MessagePopoverButtonFactory): void;
|
|
15
|
+
export declare function removeMessagePopoverButton(identifier: string): void;
|
|
16
|
+
export declare function _buildPopoverElements(Component: React.ComponentType<MessagePopoverButtonItem>, message: Message): import("react").JSX.Element;
|
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
import { Message } from "@vencord/discord-types";
|
|
2
|
+
/**
|
|
3
|
+
* Update and re-render a message
|
|
4
|
+
* @param channelId The channel id of the message
|
|
5
|
+
* @param messageId The message id
|
|
6
|
+
* @param fields The fields of the message to change. Leave empty if you just want to re-render
|
|
7
|
+
*/
|
|
8
|
+
export declare function updateMessage(channelId: string, messageId: string, fields?: Partial<Message & Record<string, any>>): void;
|
package/api/Notices.d.ts
CHANGED
|
@@ -1,5 +1,6 @@
|
|
|
1
|
+
import { ReactNode } from "react";
|
|
1
2
|
export declare const noticesQueue: any[];
|
|
2
3
|
export declare let currentNotice: any;
|
|
3
4
|
export declare function popNotice(): void;
|
|
4
5
|
export declare function nextNotice(): void;
|
|
5
|
-
export declare function showNotice(message:
|
|
6
|
+
export declare function showNotice(message: ReactNode, buttonText: string, onOkClick: () => void): void;
|
|
@@ -1,7 +1,6 @@
|
|
|
1
|
-
/// <reference types="react" />
|
|
2
1
|
import "./styles.css";
|
|
3
2
|
import { NotificationData } from "./Notifications";
|
|
4
3
|
declare const _default: import("react").FunctionComponent<NotificationData & {
|
|
5
|
-
className?: string
|
|
4
|
+
className?: string;
|
|
6
5
|
}>;
|
|
7
6
|
export default _default;
|
|
@@ -1,4 +1,3 @@
|
|
|
1
|
-
/// <reference types="react" />
|
|
2
1
|
import type { NotificationData } from "./Notifications";
|
|
3
2
|
interface PersistentNotificationData extends Pick<NotificationData, "title" | "body" | "image" | "icon" | "color"> {
|
|
4
3
|
timestamp: number;
|
|
@@ -10,6 +9,6 @@ export declare function useLogs(): readonly [PersistentNotificationData[], boole
|
|
|
10
9
|
export declare function NotificationLog({ log, pending }: {
|
|
11
10
|
log: PersistentNotificationData[];
|
|
12
11
|
pending: boolean;
|
|
13
|
-
}): JSX.Element;
|
|
12
|
+
}): import("react").JSX.Element;
|
|
14
13
|
export declare function openNotificationLogModal(): void;
|
|
15
14
|
export {};
|
package/api/ServerList.d.ts
CHANGED
|
@@ -1,8 +1,8 @@
|
|
|
1
|
-
|
|
1
|
+
import { ComponentType } from "react";
|
|
2
2
|
export declare const enum ServerListRenderPosition {
|
|
3
3
|
Above = 0,
|
|
4
4
|
In = 1
|
|
5
5
|
}
|
|
6
|
-
export declare function addServerListElement(position: ServerListRenderPosition, renderFunction:
|
|
7
|
-
export declare function removeServerListElement(position: ServerListRenderPosition, renderFunction:
|
|
8
|
-
export declare const renderAll: (position: ServerListRenderPosition) => JSX.Element[];
|
|
6
|
+
export declare function addServerListElement(position: ServerListRenderPosition, renderFunction: ComponentType): void;
|
|
7
|
+
export declare function removeServerListElement(position: ServerListRenderPosition, renderFunction: ComponentType): void;
|
|
8
|
+
export declare const renderAll: (position: ServerListRenderPosition) => import("react").JSX.Element[];
|
package/api/Settings.d.ts
CHANGED
|
@@ -4,9 +4,10 @@ export interface Settings {
|
|
|
4
4
|
autoUpdate: boolean;
|
|
5
5
|
autoUpdateNotification: boolean;
|
|
6
6
|
useQuickCss: boolean;
|
|
7
|
+
eagerPatches: boolean;
|
|
8
|
+
enabledThemes: string[];
|
|
7
9
|
enableReactDevtools: boolean;
|
|
8
10
|
themeLinks: string[];
|
|
9
|
-
enabledThemes: string[];
|
|
10
11
|
frameless: boolean;
|
|
11
12
|
transparent: boolean;
|
|
12
13
|
winCtrlQ: boolean;
|
|
@@ -57,6 +58,7 @@ export declare const Settings: Settings;
|
|
|
57
58
|
*/
|
|
58
59
|
export declare function useSettings(paths?: UseSettings<Settings>[]): Settings;
|
|
59
60
|
export declare function migratePluginSettings(name: string, ...oldNames: string[]): void;
|
|
61
|
+
export declare function migratePluginSetting(pluginName: string, oldSetting: string, newSetting: string): void;
|
|
60
62
|
export declare function definePluginSettings<Def extends SettingsDefinition, Checks extends SettingsChecks<Def>, PrivateSettings extends object = {}>(def: Def, checks?: Checks): DefinedSettings<Def, Checks, PrivateSettings>;
|
|
61
63
|
type UseSettings<T extends object> = ResolveUseSettings<T>[keyof T];
|
|
62
64
|
type ResolveUseSettings<T extends object> = {
|
package/api/Styles.d.ts
CHANGED
|
@@ -0,0 +1,40 @@
|
|
|
1
|
+
interface UserSettingDefinition<T> {
|
|
2
|
+
/**
|
|
3
|
+
* Get the setting value
|
|
4
|
+
*/
|
|
5
|
+
getSetting(): T;
|
|
6
|
+
/**
|
|
7
|
+
* Update the setting value
|
|
8
|
+
* @param value The new value
|
|
9
|
+
*/
|
|
10
|
+
updateSetting(value: T): Promise<void>;
|
|
11
|
+
/**
|
|
12
|
+
* Update the setting value
|
|
13
|
+
* @param value A callback that accepts the old value as the first argument, and returns the new value
|
|
14
|
+
*/
|
|
15
|
+
updateSetting(value: (old: T) => T): Promise<void>;
|
|
16
|
+
/**
|
|
17
|
+
* Stateful React hook for this setting value
|
|
18
|
+
*/
|
|
19
|
+
useSetting(): T;
|
|
20
|
+
userSettingsAPIGroup: string;
|
|
21
|
+
userSettingsAPIName: string;
|
|
22
|
+
}
|
|
23
|
+
export declare const UserSettings: Record<PropertyKey, UserSettingDefinition<any>> | undefined;
|
|
24
|
+
/**
|
|
25
|
+
* Get the setting with the given setting group and name.
|
|
26
|
+
*
|
|
27
|
+
* @param group The setting group
|
|
28
|
+
* @param name The name of the setting
|
|
29
|
+
*/
|
|
30
|
+
export declare function getUserSetting<T = any>(group: string, name: string): UserSettingDefinition<T> | undefined;
|
|
31
|
+
/**
|
|
32
|
+
* {@link getUserSettingDefinition}, lazy.
|
|
33
|
+
*
|
|
34
|
+
* Get the setting with the given setting group and name.
|
|
35
|
+
*
|
|
36
|
+
* @param group The setting group
|
|
37
|
+
* @param name The name of the setting
|
|
38
|
+
*/
|
|
39
|
+
export declare function getUserSettingLazy<T = any>(group: string, name: string): UserSettingDefinition<T> | undefined;
|
|
40
|
+
export {};
|
package/api/index.d.ts
CHANGED
|
@@ -8,11 +8,13 @@ import * as $MessageAccessories from "./MessageAccessories";
|
|
|
8
8
|
import * as $MessageDecorations from "./MessageDecorations";
|
|
9
9
|
import * as $MessageEventsAPI from "./MessageEvents";
|
|
10
10
|
import * as $MessagePopover from "./MessagePopover";
|
|
11
|
+
import * as $MessageUpdater from "./MessageUpdater";
|
|
11
12
|
import * as $Notices from "./Notices";
|
|
12
13
|
import * as $Notifications from "./Notifications";
|
|
13
14
|
import * as $ServerList from "./ServerList";
|
|
14
15
|
import * as $Settings from "./Settings";
|
|
15
16
|
import * as $Styles from "./Styles";
|
|
17
|
+
import * as $UserSettings from "./UserSettings";
|
|
16
18
|
/**
|
|
17
19
|
* An API allowing you to listen to Message Clicks or run your own logic
|
|
18
20
|
* before a message is sent
|
|
@@ -89,3 +91,11 @@ export declare const ContextMenu: typeof $ContextMenu;
|
|
|
89
91
|
* An API allowing you to add buttons to the chat input
|
|
90
92
|
*/
|
|
91
93
|
export declare const ChatButtons: typeof $ChatButtons;
|
|
94
|
+
/**
|
|
95
|
+
* An API allowing you to update and re-render messages
|
|
96
|
+
*/
|
|
97
|
+
export declare const MessageUpdater: typeof $MessageUpdater;
|
|
98
|
+
/**
|
|
99
|
+
* An API allowing you to get an user setting
|
|
100
|
+
*/
|
|
101
|
+
export declare const UserSettings: typeof $UserSettings;
|
|
@@ -1,4 +1,3 @@
|
|
|
1
|
-
/// <reference types="react" />
|
|
2
1
|
interface TextInputProps {
|
|
3
2
|
/**
|
|
4
3
|
* WARNING: Changing this between renders will have no effect!
|
|
@@ -19,5 +18,5 @@ interface TextInputProps {
|
|
|
19
18
|
* A very simple wrapper around Discord's TextInput that validates input and shows
|
|
20
19
|
* the user an error message and only calls your onChange when the input is valid
|
|
21
20
|
*/
|
|
22
|
-
export declare function CheckedTextInput({ value: initialValue, onChange, validate }: TextInputProps): JSX.Element;
|
|
21
|
+
export declare function CheckedTextInput({ value: initialValue, onChange, validate }: TextInputProps): import("react").JSX.Element;
|
|
23
22
|
export {};
|