@vencord/types 1.8.4 → 1.11.5
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 +1 -0
- package/VencordNative.d.ts +2 -4
- package/api/Badges.d.ts +7 -4
- package/api/ChatButtons.d.ts +5 -4
- package/api/Commands/types.d.ts +2 -0
- package/api/ContextMenu.d.ts +6 -5
- package/api/MemberListDecorators.d.ts +8 -8
- package/api/MessageAccessories.d.ts +7 -7
- package/api/MessageDecorations.d.ts +7 -8
- package/api/MessageEvents.d.ts +9 -10
- package/api/MessagePopover.d.ts +8 -8
- package/api/MessageUpdater.d.ts +8 -0
- 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/Badge.d.ts +1 -2
- package/components/CheckedTextInput.d.ts +1 -2
- package/components/CodeBlock.d.ts +1 -2
- package/components/DonateButton.d.ts +2 -2
- package/components/ErrorBoundary.d.ts +2 -2
- package/components/ErrorCard.d.ts +1 -1
- package/components/Flex.d.ts +1 -2
- 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/PluginSettings/LinkIconButton.d.ts +10 -0
- package/components/PluginSettings/PluginModal.d.ts +3 -2
- package/components/PluginSettings/components/SettingBooleanComponent.d.ts +1 -2
- package/components/PluginSettings/components/SettingCustomComponent.d.ts +2 -3
- package/components/PluginSettings/components/SettingNumericComponent.d.ts +1 -2
- package/components/PluginSettings/components/SettingSelectComponent.d.ts +1 -2
- package/components/PluginSettings/components/SettingSliderComponent.d.ts +1 -2
- package/components/PluginSettings/components/SettingTextComponent.d.ts +1 -2
- package/components/PluginSettings/components/index.d.ts +3 -1
- package/components/PluginSettings/index.d.ts +1 -1
- package/components/Switch.d.ts +1 -2
- package/components/VencordSettings/AddonCard.d.ts +1 -1
- package/components/VencordSettings/BackupAndRestoreTab.d.ts +0 -1
- package/components/VencordSettings/CloudTab.d.ts +0 -1
- package/components/VencordSettings/NotificationSettings.d.ts +2 -0
- package/components/VencordSettings/PatchHelperTab.d.ts +0 -1
- package/components/VencordSettings/PluginsTab.d.ts +0 -1
- package/components/VencordSettings/SpecialCard.d.ts +14 -0
- package/components/VencordSettings/ThemesTab.d.ts +0 -1
- package/components/VencordSettings/UpdaterTab.d.ts +0 -1
- package/components/VencordSettings/VencordTab.d.ts +0 -1
- package/components/VencordSettings/quickActions.d.ts +12 -0
- package/components/VencordSettings/shared.d.ts +1 -1
- package/components/index.d.ts +0 -1
- package/modules.d.ts +6 -2
- package/package.json +9 -9
- package/plugins/_api/badges/index.d.ts +16 -4
- package/plugins/_api/chatButtons.d.ts +1 -1
- package/plugins/_api/commands.d.ts +1 -0
- package/plugins/_api/contextMenu.d.ts +4 -2
- package/plugins/_api/dynamicImageModalApi.d.ts +16 -0
- package/plugins/_api/{memberListDecorators.d.ts → memberListDecorators/index.d.ts} +1 -0
- package/plugins/_api/menuItemDemangler.d.ts +17 -0
- package/plugins/_api/messageDecorations/index.d.ts +17 -0
- package/plugins/_api/messageEvents.d.ts +1 -1
- package/plugins/_api/messagePopover.d.ts +1 -1
- package/plugins/_api/userSettings.d.ts +16 -0
- package/plugins/_core/noTrack.d.ts +4 -9
- package/plugins/_core/settings.d.ts +2 -3
- package/plugins/_core/supportHelper.d.ts +16 -5
- package/plugins/accountPanelServerProfile/index.d.ts +45 -0
- package/plugins/alwaysAnimate/index.d.ts +8 -0
- package/plugins/alwaysExpandRoles/index.d.ts +16 -0
- package/plugins/anonymiseFileNames/index.d.ts +0 -1
- package/plugins/appleMusic.desktop/index.d.ts +225 -0
- package/plugins/appleMusic.desktop/native.d.ts +2 -0
- package/plugins/arRPC.web/index.d.ts +3 -2
- package/plugins/banger/index.d.ts +16 -8
- package/plugins/betterFolders/FolderSideBar.d.ts +0 -1
- package/plugins/betterFolders/index.d.ts +4 -2
- package/plugins/betterNotes/index.d.ts +29 -17
- package/plugins/betterRoleContext/index.d.ts +31 -1
- package/plugins/betterRoleDot/index.d.ts +0 -9
- 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 +8 -8
- package/plugins/betterSessions/index.d.ts +2 -9
- package/plugins/betterSessions/utils.d.ts +1 -2
- package/plugins/betterSettings/PluginsSubmenu.d.ts +1 -0
- package/plugins/betterSettings/index.d.ts +6 -4
- package/plugins/callTimer/index.d.ts +2 -4
- package/plugins/clearURLs/index.d.ts +3 -3
- package/plugins/clientTheme/index.d.ts +5 -11
- package/plugins/consoleJanitor/index.d.ts +79 -0
- package/plugins/consoleShortcuts/index.d.ts +9 -179
- 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/ctrlEnterSend/index.d.ts +8 -2
- package/plugins/customRPC/index.d.ts +12 -4
- package/plugins/customidle/index.d.ts +49 -0
- package/plugins/dearrow/index.d.ts +13 -1
- package/plugins/decor/index.d.ts +2 -5
- 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/index.d.ts +2 -2
- package/plugins/devCompanion.dev/index.d.ts +2 -1
- package/plugins/dontRoundMyTimestamps/index.d.ts +11 -0
- package/plugins/experiments/index.d.ts +13 -17
- package/plugins/fakeNitro/index.d.ts +3 -79
- package/plugins/fakeProfileThemes/index.d.ts +2 -2
- package/plugins/favGifSearch/index.d.ts +1 -2
- package/plugins/friendInvites/index.d.ts +5 -23
- package/plugins/friendsSince/index.d.ts +2 -2
- package/plugins/fullSearchContext/index.d.ts +22 -0
- package/plugins/fullUserInChatbox/index.d.ts +24 -0
- package/plugins/gameActivityToggle/index.d.ts +2 -3
- package/plugins/greetStickerPicker/index.d.ts +2 -2
- package/plugins/hideAttachments/index.d.ts +19 -2
- package/plugins/ignoreActivities/index.d.ts +63 -15
- package/plugins/imageZoom/components/Magnifier.d.ts +0 -1
- package/plugins/imageZoom/index.d.ts +4 -2
- package/plugins/implicitRelationships/index.d.ts +7 -0
- package/plugins/index.d.ts +3 -1
- package/plugins/invisibleChat.desktop/components/DecryptionModal.d.ts +1 -2
- package/plugins/invisibleChat.desktop/index.d.ts +22 -15
- package/plugins/ircColors/index.d.ts +76 -0
- package/plugins/keepCurrentChannel/index.d.ts +7 -0
- package/plugins/lastfm/index.d.ts +11 -2
- package/plugins/loadingQuotes/index.d.ts +41 -2
- package/plugins/memberCount/MemberCount.d.ts +1 -2
- package/plugins/memberCount/OnlineMemberCountStore.d.ts +2 -2
- package/plugins/memberCount/index.d.ts +12 -5
- package/plugins/mentionAvatars/index.d.ts +40 -0
- package/plugins/messageClickActions/index.d.ts +1 -1
- package/plugins/messageLatency/index.d.ts +1 -2
- package/plugins/messageLinkEmbeds/index.d.ts +1 -3
- package/plugins/messageLogger/HistoryModal.d.ts +6 -0
- package/plugins/messageLogger/index.d.ts +38 -7
- package/plugins/messageTags/index.d.ts +21 -3
- package/plugins/moreCommands/index.d.ts +0 -1
- package/plugins/moreKaomoji/index.d.ts +0 -1
- package/plugins/mutualGroupDMs/index.d.ts +15 -4
- package/plugins/newGuildSettings/index.d.ts +7 -1
- package/plugins/noBlockedMessages/index.d.ts +34 -10
- package/plugins/noMosaic/index.d.ts +1 -1
- package/plugins/noOnboardingDelay/index.d.ts +16 -0
- package/plugins/noProfileThemes/index.d.ts +1 -0
- package/plugins/noUnblockToJump/index.d.ts +1 -1
- package/plugins/openInApp/index.d.ts +9 -50
- package/plugins/openInApp/native.d.ts +0 -1
- package/plugins/partyMode/index.d.ts +2 -1
- package/plugins/pauseInvitesForever/index.d.ts +0 -1
- package/plugins/permissionFreeWill/index.d.ts +9 -2
- package/plugins/permissionsViewer/components/RolesAndUsersPermissions.d.ts +1 -2
- package/plugins/permissionsViewer/components/UserPermissions.d.ts +1 -2
- package/plugins/permissionsViewer/components/icons.d.ts +3 -4
- package/plugins/permissionsViewer/index.d.ts +5 -23
- package/plugins/permissionsViewer/utils.d.ts +1 -3
- package/plugins/petpet/index.d.ts +0 -1
- package/plugins/pictureInPicture/index.d.ts +2 -3
- package/plugins/pinDms/components/CreateCategoryModal.d.ts +3 -4
- package/plugins/pinDms/data.d.ts +10 -12
- package/plugins/pinDms/index.d.ts +48 -18
- package/plugins/platformIndicators/index.d.ts +11 -0
- package/plugins/previewMessage/index.d.ts +2 -4
- package/plugins/quickMention/index.d.ts +8 -5
- package/plugins/quickReply/index.d.ts +12 -0
- package/plugins/readAllNotificationsButton/index.d.ts +0 -1
- package/plugins/relationshipNotifier/utils.d.ts +7 -0
- package/plugins/replyTimestamp/index.d.ts +0 -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 +0 -1
- package/plugins/reviewDB/components/ReviewModal.d.ts +2 -1
- package/plugins/reviewDB/components/ReviewsView.d.ts +6 -4
- package/plugins/reviewDB/index.d.ts +10 -12
- package/plugins/reviewDB/settings.d.ts +6 -11
- package/plugins/reviewDB/utils.d.ts +1 -1
- package/plugins/roleColorEverywhere/index.d.ts +74 -28
- package/plugins/secretRingTone/index.d.ts +24 -3
- package/plugins/seeSummaries/index.d.ts +39 -0
- package/plugins/sendTimestamps/index.d.ts +4 -5
- package/plugins/{serverProfile/GuildProfileModal.d.ts → serverInfo/GuildInfoModal.d.ts} +1 -1
- package/plugins/{serverProfile → serverInfo}/index.d.ts +1 -0
- package/plugins/serverListIndicators/index.d.ts +1 -9
- 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 -1
- 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 -3
- package/plugins/shikiCodeblocks.desktop/index.d.ts +43 -16
- package/plugins/showConnections/VerifiedIcon.d.ts +1 -2
- package/plugins/showConnections/index.d.ts +8 -12
- package/plugins/showHiddenChannels/components/HiddenChannelLockScreen.d.ts +0 -1
- package/plugins/showHiddenChannels/index.d.ts +6 -6
- package/plugins/showHiddenThings/index.d.ts +20 -36
- package/plugins/showMeYourName/index.d.ts +0 -1
- package/plugins/silentMessageToggle/index.d.ts +2 -4
- package/plugins/silentTyping/index.d.ts +2 -4
- package/plugins/sortFriendRequests/index.d.ts +6 -4
- package/plugins/spotifyControls/PlayerComponent.d.ts +1 -2
- package/plugins/spotifyControls/SpotifyStore.d.ts +40 -1
- package/plugins/spotifyControls/index.d.ts +6 -2
- package/plugins/spotifyShareCommands/index.d.ts +0 -1
- package/plugins/startupTimings/StartupTimingPage.d.ts +0 -1
- package/plugins/startupTimings/index.d.ts +0 -1
- package/plugins/textReplace/index.d.ts +20 -7
- package/plugins/translate/TranslateIcon.d.ts +4 -4
- package/plugins/translate/TranslateModal.d.ts +1 -2
- package/plugins/translate/TranslationAccessory.d.ts +1 -2
- package/plugins/translate/index.d.ts +71 -5
- 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 +1 -2
- package/plugins/typingTweaks/index.d.ts +18 -18
- package/plugins/unindent/index.d.ts +2 -3
- package/plugins/{pronoundb/components → userMessagesPronouns}/PronounsChatComponent.d.ts +0 -4
- package/plugins/userMessagesPronouns/index.d.ts +61 -0
- package/plugins/userMessagesPronouns/settings.d.ts +44 -0
- package/plugins/userMessagesPronouns/utils.d.ts +1 -0
- package/plugins/userVoiceShow/components.d.ts +6 -0
- package/plugins/userVoiceShow/index.d.ts +33 -11
- package/plugins/usrbg/index.d.ts +4 -7
- package/plugins/validUser/index.d.ts +1 -2
- package/plugins/vcNarrator/index.d.ts +4 -4
- package/plugins/viewIcons/index.d.ts +4 -10
- package/plugins/viewRaw/index.d.ts +13 -3
- package/plugins/voiceDownload/index.d.ts +2 -3
- package/plugins/voiceMessages/VoicePreview.d.ts +1 -2
- package/plugins/voiceMessages/native.d.ts +1 -1
- package/plugins/voiceMessages/utils.d.ts +1 -0
- package/plugins/{volumeBooster.discordDesktop → volumeBooster}/index.d.ts +28 -0
- package/plugins/webContextMenus.web/index.d.ts +14 -0
- package/plugins/whoReacted/index.d.ts +2 -3
- package/plugins/{xsOverlay.desktop → xsOverlay}/index.d.ts +30 -1
- package/plugins/youtubeAdblock.desktop/adguard.d.ts +54 -0
- package/plugins/youtubeAdblock.desktop/index.d.ts +9 -0
- package/plugins/youtubeAdblock.desktop/native.d.ts +1 -0
- package/shared/SettingsStore.d.ts +5 -0
- package/shared/vencordUserAgent.d.ts +0 -1
- package/utils/ChangeList.d.ts +1 -1
- package/utils/apng-canvas.d.ts +1 -0
- package/utils/constants.d.ts +91 -9
- package/utils/dependencies.d.ts +0 -3
- package/utils/discord.d.ts +28 -5
- package/utils/index.d.ts +1 -0
- package/utils/intlHash.d.ts +8 -0
- package/utils/lazy.d.ts +2 -0
- package/utils/misc.d.ts +3 -1
- package/utils/modal.d.ts +79 -64
- package/utils/patches.d.ts +2 -2
- package/utils/react.d.ts +4 -6
- package/utils/text.d.ts +3 -0
- package/utils/types.d.ts +63 -10
- package/webpack/common/components.d.ts +94 -24
- package/webpack/common/index.d.ts +1 -1
- package/webpack/common/internal.d.ts +0 -1
- package/webpack/common/menu.d.ts +1 -1
- package/webpack/common/react.d.ts +1 -0
- package/webpack/common/stores.d.ts +4 -2
- package/webpack/common/types/components.d.ts +70 -24
- package/webpack/common/types/fluxEvents.d.ts +1 -1
- package/webpack/common/types/index.d.ts +0 -2
- package/webpack/common/types/menu.d.ts +5 -0
- package/webpack/common/types/stores.d.ts +38 -4
- package/webpack/common/types/utils.d.ts +136 -25
- package/webpack/common/userSettings.d.ts +4 -0
- package/webpack/common/utils.d.ts +42 -27
- package/webpack/index.d.ts +1 -0
- package/webpack/patchWebpack.d.ts +12 -1
- package/webpack/webpack.d.ts +63 -35
- package/webpack/wreq.d.ts +238 -0
- package/components/ExpandableHeader.d.ts +0 -12
- package/plugins/automodContext/index.d.ts +0 -20
- package/plugins/moreUserTags/index.d.ts +0 -77
- 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/searchReply/index.d.ts +0 -13
- 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/i18nMessages.d.ts +0 -2
- package/webpack/common/types/settingsStores.d.ts +0 -5
- package/plugins/_api/{messageDecorations.d.ts → messageUpdater.d.ts} +0 -0
- package/plugins/{noDefaultHangStatus → fixImagesQuality}/index.d.ts +0 -0
- package/plugins/{timeBarAllActivities → noMaskedUrlPaste}/index.d.ts +1 -1
- /package/plugins/{noScreensharePreview → stickerPaste}/index.d.ts +0 -0
- /package/plugins/{xsOverlay.desktop → xsOverlay}/native.d.ts +0 -0
package/Vencord.d.ts
CHANGED
|
@@ -22,6 +22,7 @@ export * as Util from "./utils";
|
|
|
22
22
|
export * as QuickCss from "./utils/quickCss";
|
|
23
23
|
export * as Updater from "./utils/updater";
|
|
24
24
|
export * as Webpack from "./webpack";
|
|
25
|
+
export * as WebpackPatcher from "./webpack/patchWebpack";
|
|
25
26
|
export { PlainSettings, Settings };
|
|
26
27
|
import "./utils/quickCss";
|
|
27
28
|
import "./webpack/patchWebpack";
|
package/VencordNative.d.ts
CHANGED
|
@@ -1,9 +1,7 @@
|
|
|
1
|
-
|
|
2
|
-
/// <reference types="node" />
|
|
1
|
+
import type { Settings } from "./api/Settings";
|
|
3
2
|
import type { UserThemeHeader } from "./main/themes";
|
|
4
3
|
import { IpcEvents } from "./shared/IpcEvents";
|
|
5
4
|
import { IpcRes } from "./utils/types";
|
|
6
|
-
import type { Settings } from "api/Settings";
|
|
7
5
|
export declare function sendSync<T = any>(event: IpcEvents, ...args: any[]): T;
|
|
8
6
|
declare const _default: {
|
|
9
7
|
themes: {
|
|
@@ -15,7 +13,7 @@ declare const _default: {
|
|
|
15
13
|
getSystemValues: () => Promise<Record<string, string>>;
|
|
16
14
|
};
|
|
17
15
|
updater: {
|
|
18
|
-
getUpdates: () => Promise<IpcRes<Record<"
|
|
16
|
+
getUpdates: () => Promise<IpcRes<Record<"message" | "author" | "hash", string>[]>>;
|
|
19
17
|
update: () => Promise<IpcRes<boolean>>;
|
|
20
18
|
rebuild: () => Promise<IpcRes<boolean>>;
|
|
21
19
|
getRepo: () => Promise<IpcRes<string>>;
|
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,
|
|
@@ -22,23 +21,27 @@ export interface ProfileBadge {
|
|
|
22
21
|
position?: BadgePosition;
|
|
23
22
|
/** The badge name to display, Discord uses this. Required for component badges */
|
|
24
23
|
key?: string;
|
|
24
|
+
/**
|
|
25
|
+
* Allows dynamically returning multiple badges
|
|
26
|
+
*/
|
|
27
|
+
getBadges?(userInfo: BadgeUserArgs): ProfileBadge[];
|
|
25
28
|
}
|
|
26
29
|
/**
|
|
27
30
|
* Register a new badge with the Badges API
|
|
28
31
|
* @param badge The badge to register
|
|
29
32
|
*/
|
|
30
|
-
export declare function
|
|
33
|
+
export declare function addProfileBadge(badge: ProfileBadge): void;
|
|
31
34
|
/**
|
|
32
35
|
* Unregister a badge from the Badges API
|
|
33
36
|
* @param badge The badge to remove
|
|
34
37
|
*/
|
|
35
|
-
export declare function
|
|
38
|
+
export declare function removeProfileBadge(badge: ProfileBadge): boolean;
|
|
36
39
|
/**
|
|
37
40
|
* Inject badges into the profile badges array.
|
|
38
41
|
* You probably don't need to use this.
|
|
39
42
|
*/
|
|
40
43
|
export declare function _getBadges(args: BadgeUserArgs): ProfileBadge[];
|
|
41
44
|
export interface BadgeUserArgs {
|
|
42
|
-
|
|
45
|
+
userId: string;
|
|
43
46
|
guildId: string;
|
|
44
47
|
}
|
package/api/ChatButtons.d.ts
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import "./ChatButton.css";
|
|
2
2
|
import { Channel } from "discord-types/general";
|
|
3
|
-
import { HTMLProps, MouseEventHandler, ReactNode } from "react";
|
|
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>;
|
package/api/Commands/types.d.ts
CHANGED
|
@@ -65,8 +65,10 @@ export interface Command {
|
|
|
65
65
|
plugin?: string;
|
|
66
66
|
isVencordCommand?: boolean;
|
|
67
67
|
name: string;
|
|
68
|
+
untranslatedName?: string;
|
|
68
69
|
displayName?: string;
|
|
69
70
|
description: string;
|
|
71
|
+
untranslatedDescription?: string;
|
|
70
72
|
displayDescription?: string;
|
|
71
73
|
options?: Option[];
|
|
72
74
|
predicate?(ctx: CommandContext): boolean;
|
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,5 +1,5 @@
|
|
|
1
|
-
/// <reference types="react" />
|
|
2
1
|
import { Channel, User } from "discord-types/general/index.js";
|
|
2
|
+
import { JSX } from "react";
|
|
3
3
|
interface DecoratorProps {
|
|
4
4
|
activities: any[];
|
|
5
5
|
channel: Channel;
|
|
@@ -20,13 +20,13 @@ interface DecoratorProps {
|
|
|
20
20
|
user: User;
|
|
21
21
|
[key: string]: any;
|
|
22
22
|
}
|
|
23
|
-
export type
|
|
23
|
+
export type MemberListDecoratorFactory = (props: DecoratorProps) => JSX.Element | null;
|
|
24
24
|
type OnlyIn = "guilds" | "dms";
|
|
25
|
-
export declare const
|
|
26
|
-
|
|
27
|
-
onlyIn?: OnlyIn
|
|
25
|
+
export declare const decoratorsFactories: Map<string, {
|
|
26
|
+
render: MemberListDecoratorFactory;
|
|
27
|
+
onlyIn?: OnlyIn;
|
|
28
28
|
}>;
|
|
29
|
-
export declare function
|
|
30
|
-
export declare function
|
|
31
|
-
export declare function __getDecorators(props: DecoratorProps):
|
|
29
|
+
export declare function addMemberListDecorator(identifier: string, render: MemberListDecoratorFactory, onlyIn?: OnlyIn): void;
|
|
30
|
+
export declare function removeMemberListDecorator(identifier: string): void;
|
|
31
|
+
export declare function __getDecorators(props: DecoratorProps): JSX.Element;
|
|
32
32
|
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
|
-
/// <reference types="react" />
|
|
2
1
|
import { Channel, Message } from "discord-types/general/index.js";
|
|
3
|
-
|
|
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
|
@@ -46,10 +46,10 @@ export interface MessageExtra {
|
|
|
46
46
|
type?: any;
|
|
47
47
|
openWarningPopout: (props: any) => any;
|
|
48
48
|
}
|
|
49
|
-
export type
|
|
49
|
+
export type MessageSendListener = (channelId: string, messageObj: MessageObject, extra: MessageExtra) => Promisable<void | {
|
|
50
50
|
cancel: boolean;
|
|
51
51
|
}>;
|
|
52
|
-
export type
|
|
52
|
+
export type MessageEditListener = (channelId: string, messageId: string, messageObj: MessageObject) => Promisable<void | {
|
|
53
53
|
cancel: boolean;
|
|
54
54
|
}>;
|
|
55
55
|
export declare function _handlePreSend(channelId: string, messageObj: MessageObject, extra: MessageExtra, replyOptions: MessageReplyOptions): Promise<boolean>;
|
|
@@ -57,15 +57,14 @@ export declare function _handlePreEdit(channelId: string, messageId: string, mes
|
|
|
57
57
|
/**
|
|
58
58
|
* Note: This event fires off before a message is sent, allowing you to edit the message.
|
|
59
59
|
*/
|
|
60
|
-
export declare function
|
|
60
|
+
export declare function addMessagePreSendListener(listener: MessageSendListener): MessageSendListener;
|
|
61
61
|
/**
|
|
62
62
|
* Note: This event fires off before a message's edit is applied, allowing you to further edit the message.
|
|
63
63
|
*/
|
|
64
|
-
export declare function
|
|
65
|
-
export declare function
|
|
66
|
-
export declare function
|
|
67
|
-
type
|
|
64
|
+
export declare function addMessagePreEditListener(listener: MessageEditListener): MessageEditListener;
|
|
65
|
+
export declare function removeMessagePreSendListener(listener: MessageSendListener): boolean;
|
|
66
|
+
export declare function removeMessagePreEditListener(listener: MessageEditListener): boolean;
|
|
67
|
+
export type MessageClickListener = (message: Message, channel: Channel, event: MouseEvent) => void;
|
|
68
68
|
export declare function _handleClick(message: Message, channel: Channel, event: MouseEvent): void;
|
|
69
|
-
export declare function
|
|
70
|
-
export declare function
|
|
71
|
-
export {};
|
|
69
|
+
export declare function addMessageClickListener(listener: MessageClickListener): MessageClickListener;
|
|
70
|
+
export declare function removeMessageClickListener(listener: MessageClickListener): boolean;
|
package/api/MessagePopover.d.ts
CHANGED
|
@@ -1,16 +1,16 @@
|
|
|
1
1
|
import { Channel, Message } from "discord-types/general";
|
|
2
|
-
import type { MouseEventHandler } from "react";
|
|
3
|
-
export interface
|
|
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 "discord-types/general";
|
|
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;
|
|
@@ -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;
|
package/components/Badge.d.ts
CHANGED
|
@@ -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 {};
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
|
|
2
|
-
export default function DonateButton(props:
|
|
1
|
+
import { ButtonProps } from "../webpack/common/types";
|
|
2
|
+
export default function DonateButton({ look, color, ...props }: Partial<ButtonProps>): import("react").JSX.Element;
|
|
@@ -1,4 +1,3 @@
|
|
|
1
|
-
/// <reference types="react" />
|
|
2
1
|
interface Props<T = any> {
|
|
3
2
|
/** Render nothing if an error occurs */
|
|
4
3
|
noop?: boolean;
|
|
@@ -7,6 +6,7 @@ interface Props<T = any> {
|
|
|
7
6
|
error: any;
|
|
8
7
|
message: string;
|
|
9
8
|
stack: string;
|
|
9
|
+
wrappedProps: T;
|
|
10
10
|
}>>;
|
|
11
11
|
/** called when an error occurs. The props property is only available if using .wrap */
|
|
12
12
|
onError?(data: {
|
|
@@ -19,7 +19,7 @@ interface Props<T = any> {
|
|
|
19
19
|
/** The props passed to the wrapped component. Only used by wrap */
|
|
20
20
|
wrappedProps?: T;
|
|
21
21
|
}
|
|
22
|
-
declare const ErrorBoundary:
|
|
22
|
+
declare const ErrorBoundary: React.ComponentType<React.PropsWithChildren<Props>> & {
|
|
23
23
|
wrap<T extends object = any>(Component: React.ComponentType<T>, errorBoundaryProps?: Omit<Props<T>, "wrappedProps">): React.FunctionComponent<T>;
|
|
24
24
|
};
|
|
25
25
|
export default ErrorBoundary;
|
|
@@ -1,3 +1,3 @@
|
|
|
1
1
|
import "./ErrorCard.css";
|
|
2
2
|
import type { HTMLProps } from "react";
|
|
3
|
-
export declare function ErrorCard(props: React.PropsWithChildren<HTMLProps<HTMLDivElement>>): JSX.Element;
|
|
3
|
+
export declare function ErrorCard(props: React.PropsWithChildren<HTMLProps<HTMLDivElement>>): import("react").JSX.Element;
|
package/components/Flex.d.ts
CHANGED
|
@@ -1,6 +1,5 @@
|
|
|
1
|
-
/// <reference types="react" />
|
|
2
1
|
export declare function Flex(props: React.PropsWithChildren<{
|
|
3
2
|
flexDirection?: React.CSSProperties["flexDirection"];
|
|
4
3
|
style?: React.CSSProperties;
|
|
5
4
|
className?: string;
|
|
6
|
-
} & React.HTMLProps<HTMLDivElement>>): JSX.Element;
|
|
5
|
+
} & React.HTMLProps<HTMLDivElement>>): import("react").JSX.Element;
|
package/components/Heart.d.ts
CHANGED
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
|
|
2
|
-
export declare function Heart(): JSX.Element;
|
|
1
|
+
import { SVGProps } from "react";
|
|
2
|
+
export declare function Heart(props: SVGProps<SVGSVGElement>): import("react").JSX.Element;
|
package/components/Icons.d.ts
CHANGED
|
@@ -1,17 +1,12 @@
|
|
|
1
1
|
import "./iconStyles.css";
|
|
2
|
-
import type {
|
|
3
|
-
|
|
4
|
-
className?: string;
|
|
5
|
-
height?: string | number;
|
|
6
|
-
width?: string | number;
|
|
7
|
-
}
|
|
2
|
+
import type { JSX } from "react";
|
|
3
|
+
type IconProps = JSX.IntrinsicElements["svg"];
|
|
8
4
|
/**
|
|
9
5
|
* Discord's link icon, as seen in the Message context menu "Copy Message Link" option
|
|
10
6
|
*/
|
|
11
7
|
export declare function LinkIcon({ height, width, className }: IconProps): JSX.Element;
|
|
12
8
|
/**
|
|
13
|
-
* Discord's copy icon, as seen in the user popout right of the username
|
|
14
|
-
* your own username in the bottom left user panel
|
|
9
|
+
* Discord's copy icon, as seen in the user panel popout on the right of the username and in large code blocks
|
|
15
10
|
*/
|
|
16
11
|
export declare function CopyIcon(props: IconProps): JSX.Element;
|
|
17
12
|
/**
|
|
@@ -33,4 +28,13 @@ export declare function ReplyIcon(props: IconProps): JSX.Element;
|
|
|
33
28
|
export declare function DeleteIcon(props: IconProps): JSX.Element;
|
|
34
29
|
export declare function PlusIcon(props: IconProps): JSX.Element;
|
|
35
30
|
export declare function NoEntrySignIcon(props: IconProps): JSX.Element;
|
|
31
|
+
export declare function SafetyIcon(props: IconProps): JSX.Element;
|
|
32
|
+
export declare function NotesIcon(props: IconProps): JSX.Element;
|
|
33
|
+
export declare function FolderIcon(props: IconProps): JSX.Element;
|
|
34
|
+
export declare function LogIcon(props: IconProps): JSX.Element;
|
|
35
|
+
export declare function RestartIcon(props: IconProps): JSX.Element;
|
|
36
|
+
export declare function PaintbrushIcon(props: IconProps): JSX.Element;
|
|
37
|
+
export declare function PencilIcon(props: IconProps): JSX.Element;
|
|
38
|
+
export declare function GithubIcon(props: IconProps): JSX.Element;
|
|
39
|
+
export declare function WebsiteIcon(props: IconProps): JSX.Element;
|
|
36
40
|
export {};
|
package/components/Link.d.ts
CHANGED
|
@@ -1,6 +1,5 @@
|
|
|
1
|
-
/// <reference types="react" />
|
|
2
1
|
interface Props extends React.DetailedHTMLProps<React.AnchorHTMLAttributes<HTMLAnchorElement>, HTMLAnchorElement> {
|
|
3
2
|
disabled?: boolean;
|
|
4
3
|
}
|
|
5
|
-
export declare function Link(props: React.PropsWithChildren<Props>): JSX.Element;
|
|
4
|
+
export declare function Link(props: React.PropsWithChildren<Props>): import("react").JSX.Element;
|
|
6
5
|
export {};
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
import "./LinkIconButton.css";
|
|
2
|
+
export declare function GithubLinkIcon(): import("react").JSX.Element;
|
|
3
|
+
export declare function WebsiteLinkIcon(): import("react").JSX.Element;
|
|
4
|
+
interface Props {
|
|
5
|
+
text: string;
|
|
6
|
+
href: string;
|
|
7
|
+
}
|
|
8
|
+
export declare const WebsiteButton: (props: Props) => import("react").JSX.Element;
|
|
9
|
+
export declare const GithubButton: (props: Props) => import("react").JSX.Element;
|
|
10
|
+
export {};
|
|
@@ -1,9 +1,10 @@
|
|
|
1
|
-
|
|
1
|
+
import "./PluginModal.css";
|
|
2
2
|
import { ModalProps } from "../../utils/modal";
|
|
3
3
|
import { Plugin } from "../../utils/types";
|
|
4
4
|
interface PluginModalProps extends ModalProps {
|
|
5
5
|
plugin: Plugin;
|
|
6
6
|
onRestartNeeded(): void;
|
|
7
7
|
}
|
|
8
|
-
export default function PluginModal({ plugin, onRestartNeeded, onClose, transitionState }: PluginModalProps): JSX.Element;
|
|
8
|
+
export default function PluginModal({ plugin, onRestartNeeded, onClose, transitionState }: PluginModalProps): import("react").JSX.Element;
|
|
9
|
+
export declare function openPluginModal(plugin: Plugin, onRestartNeeded?: (pluginName: string) => void): void;
|
|
9
10
|
export {};
|
|
@@ -1,4 +1,3 @@
|
|
|
1
|
-
/// <reference types="react" />
|
|
2
1
|
import { PluginOptionBoolean } from "../../../utils/types";
|
|
3
2
|
import { ISettingElementProps } from ".";
|
|
4
|
-
export declare function SettingBooleanComponent({ option, pluginSettings, definedSettings, id, onChange, onError }: ISettingElementProps<PluginOptionBoolean>): JSX.Element;
|
|
3
|
+
export declare function SettingBooleanComponent({ option, pluginSettings, definedSettings, id, onChange, onError }: ISettingElementProps<PluginOptionBoolean>): import("react").JSX.Element;
|
|
@@ -1,4 +1,3 @@
|
|
|
1
|
-
/// <reference types="react" />
|
|
2
1
|
import { PluginOptionComponent } from "../../../utils/types";
|
|
3
|
-
import {
|
|
4
|
-
export declare function SettingCustomComponent({ option, onChange, onError }:
|
|
2
|
+
import { ISettingCustomElementProps } from ".";
|
|
3
|
+
export declare function SettingCustomComponent({ option, onChange, onError }: ISettingCustomElementProps<PluginOptionComponent>): import("react").JSX.Element;
|
|
@@ -1,4 +1,3 @@
|
|
|
1
|
-
/// <reference types="react" />
|
|
2
1
|
import { PluginOptionNumber } from "../../../utils/types";
|
|
3
2
|
import { ISettingElementProps } from ".";
|
|
4
|
-
export declare function SettingNumericComponent({ option, pluginSettings, definedSettings, id, onChange, onError }: ISettingElementProps<PluginOptionNumber>): JSX.Element;
|
|
3
|
+
export declare function SettingNumericComponent({ option, pluginSettings, definedSettings, id, onChange, onError }: ISettingElementProps<PluginOptionNumber>): import("react").JSX.Element;
|
|
@@ -1,4 +1,3 @@
|
|
|
1
|
-
/// <reference types="react" />
|
|
2
1
|
import { PluginOptionSelect } from "../../../utils/types";
|
|
3
2
|
import { ISettingElementProps } from ".";
|
|
4
|
-
export declare function SettingSelectComponent({ option, pluginSettings, definedSettings, onChange, onError, id }: ISettingElementProps<PluginOptionSelect>): JSX.Element;
|
|
3
|
+
export declare function SettingSelectComponent({ option, pluginSettings, definedSettings, onChange, onError, id }: ISettingElementProps<PluginOptionSelect>): import("react").JSX.Element;
|
|
@@ -1,5 +1,4 @@
|
|
|
1
|
-
/// <reference types="react" />
|
|
2
1
|
import { PluginOptionSlider } from "../../../utils/types";
|
|
3
2
|
import { ISettingElementProps } from ".";
|
|
4
3
|
export declare function makeRange(start: number, end: number, step?: number): number[];
|
|
5
|
-
export declare function SettingSliderComponent({ option, pluginSettings, definedSettings, id, onChange, onError }: ISettingElementProps<PluginOptionSlider>): JSX.Element;
|
|
4
|
+
export declare function SettingSliderComponent({ option, pluginSettings, definedSettings, id, onChange, onError }: ISettingElementProps<PluginOptionSlider>): import("react").JSX.Element;
|