From 7d153f28e073d4d5c935b59b363c417caf6d524c Mon Sep 17 00:00:00 2001 From: poslop Date: Tue, 30 Apr 2024 15:32:45 -0500 Subject: [PATCH] update --- .../BetterDiscord/plugins/0BDFDB.config.json | 16 +- .../BetterDiscord/plugins/0BDFDB.data.json | 1512 ++++++++--------- .../BetterDiscord/plugins/0BDFDB.plugin.js | 762 +++++---- .config/BetterDiscord/plugins/0BDFDB.raw.css | 20 +- .../BetterDiscord/plugins/EditRoles.plugin.js | 24 +- .../plugins/ImageUtilities.config.json | 2 + .../plugins/ImageUtilities.plugin.js | 404 +++-- .../plugins/InvisibleTyping.config.json | 5 +- .../plugins/NotificationSounds.config.json | 88 + .../plugins/NotificationSounds.plugin.js | 166 +- .../BetterDiscord/plugins/PinDMs.config.json | 2 +- .../BetterDiscord/plugins/PinDMs.plugin.js | 103 +- .../plugins/PluginRepo.config.json | 2 +- .../plugins/PluginRepo.plugin.js | 125 +- .../BetterDiscord/themes/PinkNord.theme.css | 2 +- .config/i3/config | 2 +- .../oomox/export_config/gtk_theme_oomox.json | 2 +- .config/oomox/ui_config.json | 2 +- .config/polybar/config.ini | 15 +- .config/qt5ct/qt5ct.conf | 2 +- .config/rofi/config.rasi | 2 +- .profile | 1 + .zshrc | 12 +- 23 files changed, 1781 insertions(+), 1490 deletions(-) diff --git a/.config/BetterDiscord/plugins/0BDFDB.config.json b/.config/BetterDiscord/plugins/0BDFDB.config.json index 2356107..654993d 100644 --- a/.config/BetterDiscord/plugins/0BDFDB.config.json +++ b/.config/BetterDiscord/plugins/0BDFDB.config.json @@ -1,13 +1,13 @@ { "all": { "changeLogs": { - "BDFDB": "3.2.0", + "BDFDB": "3.5.9", "CreationDate": "1.4.6", - "EditRoles": "1.1.4", - "ImageUtilities": "5.1.9", - "NotificationSounds": "3.7.8", - "PinDMs": "1.9.7", - "PluginRepo": "2.4.6" + "EditRoles": "1.1.7", + "ImageUtilities": "5.4.0", + "NotificationSounds": "3.9.2", + "PinDMs": "2.0.3", + "PluginRepo": "2.5.5" }, "choices": { "toastPosition": "right" @@ -19,8 +19,8 @@ "useChromium": false }, "hashes": { - "0BDFDB.data.json": "a6567d782bfade3434800f57ac73d037d233a5b2", - "0BDFDB.raw.css": "26087554c644b93f1f9d6c64e7a7918b6ec66dfe" + "0BDFDB.data.json": "4476361c3ca209217e9e539dfb2af7b406e061d8", + "0BDFDB.raw.css": "8c083e2a87a82aded5f3b2e27fb8b2f816b5f74a" } } } \ No newline at end of file diff --git a/.config/BetterDiscord/plugins/0BDFDB.data.json b/.config/BetterDiscord/plugins/0BDFDB.data.json index a6567d7..4476361 100644 --- a/.config/BetterDiscord/plugins/0BDFDB.data.json +++ b/.config/BetterDiscord/plugins/0BDFDB.data.json @@ -2,6 +2,7 @@ "PluginNameMap": {}, "PluginUrlMap": { "BDFDB": "https://mwittrien.github.io/BetterDiscordAddons/Library/0BDFDB.plugin.js", + "CopyRawMessage": "https://mwittrien.github.io/BetterDiscordAddons/_DEAD/CopyRawMessage.plugin.js", "CreationDate": "https://mwittrien.github.io/BetterDiscordAddons/_DEAD/CreationDate.plugin.js", "ForceImagePreviews": "https://mwittrien.github.io/BetterDiscordAddons/_DEAD/ForceImagePreviews.plugin.js", "JoinedAtDate": "https://mwittrien.github.io/BetterDiscordAddons/_DEAD/JoinedAtDate.plugin.js", @@ -11,7 +12,7 @@ "LibraryRequires": ["electron", "fs", "path", "process", "request"], "DiscordObjects": { "Channel": {"props": ["getRecipientId", "isManaged", "getGuildId"]}, - "Guild": {"props": ["getIconURL", "getMaxEmojiSlots", "getRole"]}, + "Guild": {"strings": ["hasCommunityInfoSubheader()", "publicUpdatesChannelId", ".GuildFeatures.NON_COMMUNITY_RAID_ALERTS"]}, "Invite": {"props": ["getExpiresAt", "isExpired"]}, "Message": {"props": ["getReaction", "isEdited", "getChannelId"]}, "Messages": {"props": ["jumpToMessage", "hasAfterCached", "forEach"]}, @@ -19,13 +20,6 @@ "User": {"props": ["addGuildAvatarHash", "isLocalBot"]} }, "CustomDiscordConstants": { - "MAX_GUILD_FOLDER_NAME_LENGTH": 32, - "MAX_MESSAGE_LENGTH": 2000, - "MAX_MESSAGE_LENGTH_PREMIUM": 4000, - "MAX_MESSAGES_PER_CHANNEL": 50, - "MAX_VIDEO_HEIGHT": 720, - "MAX_VIDEO_WIDTH": 1280, - "ME": "@me", "MenuItemColors": { "BRAND": "brand", "DANGER": "danger", @@ -34,7 +28,6 @@ "PREMIUMGRADIENT": "premiumgradient", "SUCCESS": "success" }, - "SEARCH_PAGE_SIZE": 25, "ToastIcons": { "info": "INFO", "danger": "CLOSE_CIRCLE", @@ -45,191 +38,131 @@ "center": "toastscenter", "left": "toastsleft", "right": "toastsright" - } + }, + "UserBadges": { + "active_developer": "6bdc42827a38498929a4920da12695d9", + "automod": "f2459b691ac7453ed6039bbcfaccbfcd", + "bot_commands": "6f9e37f9029ff57aef81db857890005e", + "bug_hunter_lvl1": "2717692c7dca7289b35297368a940dd0", + "bug_hunter_lvl2": "848f79194d4be5ff5f81505cbd0ce1e6", + "certified_moderator": "fee1624003e2fee35cb398e125dc479b", + "guild_booster_lvl1": "51040c70d4f20a921ad6674ff86fc95c", + "guild_booster_lvl2": "0e4080d1d333bc7ad29ef6528b6f2fb7", + "guild_booster_lvl3": "72bed924410c304dbe3d00a6e593ff59", + "guild_booster_lvl4": "df199d2050d3ed4ebf84d64ae83989f8", + "guild_booster_lvl5": "996b3e870e8a22ce519b3a50e6bdd52f", + "guild_booster_lvl6": "991c9f39ee33d7537d9f408c3e53141e", + "guild_booster_lvl7": "cb3ae83c15e970e8f3d410bc62cb8b99", + "guild_booster_lvl8": "7142225d31238f6387d9f09efaa02759", + "guild_booster_lvl9": "ec92202290b48d0879b7413d2dde3bab", + "hypesquad": "bf01d1073931f921909045f3a39fd264", + "hypesquad_house_1": "8a88d63823d8a71cd5e390baa45efa02", + "hypesquad_house_2": "011940fd013da3f7fb926e4a1cd2e618", + "hypesquad_house_3": "3aa41de486fa12454c3761e8e223442e", + "partner": "3f9748e53446a137a052f3454e2de41e", + "premium": "2ba85e8026a8614b640c2837bcdfe21b", + "premium_early_supporter": "7060786766c9c840eb3019e725d2b358", + "staff": "5e74e9b61934fc1f67c65515d1f7e60d", + "verified_developer": "6df5892e0f35b051f8b61eace34f4967" + }, + "UserPremiumLevels": {"1": 1, "2": 2, "3": 3, "4": 6, "5": 9, "6": 12, "7": 15, "8": 18, "9": 24} }, "DiscordConstants": { - "ActivityTypes": ["STREAMING", "LISTENING", "CUSTOM_STATUS"], - "AnalyticsObjects": ["CONTEXT_MENU", "TOOLTIP", "CHANNEL"], - "AnalyticsPages": ["AUTH", "GUILD_CHANNEL", "CUSTOM_STATUS_MODAL"], - "AnalyticsSections": ["CHANNEL_LIST", "ACCOUNT_PANEL", "MEMBER_LIST"], - "AutocompleterQuerySymbols": ["VOICE_CHANNEL", "TEXT_CHANNEL", "USER", "APPLICATION"], "AutocompleterResultTypes": ["VOICE_CHANNEL", "TEXT_CHANNEL", "USER", "LINK"], "ChannelTextAreaTypes": ["CREATE_FORUM_POST", "PROFILE_BIO_INPUT", "FORUM_CHANNEL_GUIDELINES"], - "ChannelTypes": ["GUILD_TEXT", "GUILD_STORE", "DM"], - "ChannelTypeGroups": ["GUILD_TEXTUAL", "GUILD_VOCAL", "ALL_DMS"], "Colors": ["SPOTIFY", "RED_100", "BLUE"], - "ColorVariables": ["status-danger", "background-primary"], - "ComponentActions": ["INSERT_TEXT", "TEXTAREA_FOCUS"], - "EmojiSprites": ["DiversityPerRow", "PickerPerRow"], - "Endpoints": ["CAPTCHA", "GUILD", "MESSAGES"], - "FriendsSections": ["ALL", "ONLINE", "ADD_FRIEND"], + "ColorsCSS": ["BUTTON_DANGER_BACKGROUND", "STATUS_DANGER", "HEADER_PRIMARY"], + "EmojiSprites": ["DiversityPerRow", "PickerCount", "PickerPerRow"], "InboxTabs": ["MENTIONS", "UNREADS"], - "KeyboardDeviceTypes": ["KEYBOARD_KEY", "MOUSE_BUTTON"], - "MenuItemColors": ["BRAND", "GREEN", "PREMIUM_GRADIENT"], - "MessageStates": ["SENT", "SENDING", "SEND_FAILED"], - "MessageTypeGroups": ["USER_MESSAGE", "DELETABLE"], - "MessageTypes": ["CHAT_INPUT_COMMAND", "CHANNEL_PINNED_MESSAGE"], - "Permissions": ["ADMINISTRATOR", "MANAGE_MESSAGES", "MANAGE_ROLES", "MANAGE_GUILD_EXPRESSIONS"], + "MessageTypeGroups": ["USER_MESSAGE", "UNDELETABLE"], "ReadStateTypes": ["GUILD_EVENT", "NOTIFICATION_CENTER", "CHANNEL"], - "RelationshipTypes": ["FRIEND", "PENDING_INCOMING", "PENDING_OUTGOING"], - "Routes": ["CHANNEL_THREAD_VIEW", "MESSAGE_REQUESTS"], - "UserBadges": ["HYPESQUAD", "GUILD_BOOSTER_LEVEL_1", "STAFF"], - "UserFlags": ["MFA_SMS", "VERIFIED_BOT"], - "UserNotificationSettings": ["NULL", "NO_MESSAGES", "ALL_MESSAGES"], - "UserSettingsActionTypes": ["SLOW_USER_ACTION", "DAILY"], - "UserSettingsSections": ["ACCOUNT", "DEVELOPER_OPTIONS", "DISMISSIBLE_CONTENT_OPTIONS"] + "UserSettingsActionTypes": ["SLOW_USER_ACTION", "DAILY"] }, "LibraryModules": { - "AckUtils": {"strings": ["type:\"BULK_ACK\""], "exported": false, "value": "exports", "map": { - "ack": ["type:\"CHANNEL_ACK\"", "messageId", "channelId"], - "bulkAck": ["type:\"BULK_ACK\""] - }}, + "AckUtils": {"props": ["ack", "bulkAck", "localAck"]}, "ActivityUtils": {"props": ["sendActivityInvite", "updateActivity"]}, "AnalyticsUtils": {"props": ["isThrottled", "track"]}, "AnimationUtils": {"props": ["spring", "decay"]}, "APIEncodeUtils": {"props": ["stringify", "parse", "encode"]}, "APIUtils": {"props": ["getAPIBaseURL"]}, "AppearanceSettingsUtils": {"props": ["updateLocale", "updateTheme"]}, - "ApplicationAssetUtils": {"strings": ["ApplicationAssetUtils", "getAssetImage"], "exported": false, "value": "exports", "map": { - "getAssetImage": ["ApplicationAssetUtils", "getAssetImage"] - }}, + "ApplicationAssetUtils": {"props": ["getAssetImage", "getAssetIds"]}, "AppUtils": {"props": ["clipboard", "os"]}, "ArrayUtils": {"props": ["isArrayLike", "zipObject"]}, + "CategoryCollapseUtils": {"props": ["categoryCollapse", "categoryExpand"]}, "ChannelUtils": {"props": ["selectChannel", "selectPrivateChannel"]}, - "ChatRestrictionUtils": {"strings": ["openWarningPopout", "userCanUsePremiumMessageLength"], "exported": false, "value": "exports", "map": { - "applyChatRestrictions": ["openWarningPopout", "userCanUsePremiumMessageLength"] + "ChatRestrictionUtils": {"props": ["applyChatRestrictions"]}, + "ConnectionMetadataUtils": {"props": ["generateEbayMetadataItems", "generatePaypalMetadataItems"], "exported": false, "value": "exports", "map": { + "getEbay": ["generateEbayMetadataItems"], + "getPaypal": ["generatePaypalMetadataItems"], + "getReddit": ["generateRedditMetadataItems"], + "getSteam": ["generateSteamMetadataItems"], + "getTiktok": ["generateTikTokMetadataItems"], + "getTwitter": ["generateTwitterMetadataItems"] }}, "ConnectionProviderUtils": {"props": ["get", "isSupported", "filter"]}, "ConnectionUtils": {"props": ["setShowActivity", "setVisibility"]}, - "ContextMenuUtils": {"strings": ["renderLazy", "type:\"CONTEXT_MENU_CLOSE\""], "exported": false, "value": "exports", "map": { - "openContextMenu": ["renderLazy"], - "closeContextMenu": ["type:\"CONTEXT_MENU_CLOSE\""] - }}, + "ContextMenuUtils": {"props": ["openContextMenu", "closeContextMenu"]}, "CurrentUserStore": {"props": ["getCurrentUser"]}, "DesktopNotificationUtils": {"props": ["showNotification", "requestPermission"]}, "DispatchApiUtils": {"props": ["dispatch", "isDispatching"]}, - "DispatchUtils": {"strings": ["dispatchToLastSubscribed", "setMaxListeners"], "map": { - "ComponentDispatch": ["_eventsCount"] - }}, + "DispatchUtils": {"props": ["ComponentDispatch", "ComponentDispatcher"]}, "EmojiUtils": {"props": ["translateInlineEmojiToSurrogates", "translateSurrogatesToInlineEmoji"]}, "EmojiStateUtils": {"props": ["getURL", "isEmojiDisabled"]}, "Env": {"props": ["env"]}, - "FileRequestUtils": {"props": ["getFileData", "getImageData"]}, - "FolderSettingsUtils": {"props": ["updateLocale", "updateTheme"], "exported": false, "value": "exports", "map": { - "saveGuildFolders": ["guildFolders"] - }}, - "GuildBoostUtils": {"strings": ["getPremiumTypeSubscription", "PREMIUM_GUILD_TIER_1"], "exported": false, "value": "exports", "map": { - "getUserLevel": ["\"months\"", "next"] - }}, + "FolderSettingsUtils": {"props": ["saveGuildFolders", "saveClientTheme"]}, "GuildNotificationsUtils": {"props": ["updateChannelOverrideSettings", "updateGuildNotificationSettings"]}, "GuildUtils": {"props": ["selectGuild", "transitionToGuildSync"]}, - "HistoryUtils": {"strings": ["transitionTo - Transitioning to "], "exported": false, "value": "exports", "map": { - "transitionTo": ["transitionTo - Transitioning to "] - }}, + "HistoryUtils": {"props": ["transitionTo", "transitionToGuild"]}, "IconUtils": {"props": ["getGuildIconURL", "getGuildBannerURL"]}, "InviteUtils": {"props": ["acceptInvite", "createInvite"]}, "InternalReactUtils": {"props": ["jsx", "jsxs", "Fragment"]}, - "KeyCodeUtils": {"strings": ["Unrecognized DeviceType", "GAMEPAD"], "exported": false, "value": "exports", "assign": true, "map": { - "codeToKey": ["[\"\"+", "MACOS"], - "keyToCode": ["Unrecognized DeviceType"], - "toName": ["appVersion"] - }}, + "KeyCodeUtils": {"props": ["codeToKey", "keyToCode"]}, "KeyEvents": {"props": ["aliases", "code", "codes"]}, "LoginUtils": {"props": ["login", "logout"]}, - "MediaComponentUtils": {"strings": ["renderAdjacentContent", "imageContent"], "exported": false, "value": "exports", "map": { - "renderImageComponent": ["renderAdjacentContent", "imageContent"] - }}, + "MediaComponentUtils": {"props": ["renderImageComponent", "renderVideoComponent"]}, "MediaEngineUtils": {"props": ["setOutputDevice", "setInputDevice"]}, - "MemberDisplayUtils": {"strings": ["getUserProfile", "getGuildMemberProfile", "_userProfile"], "exported": false, "value": "exports", "map": { - "getDisplayProfile": ["getUserProfile"], - "getUserProfile": ["function(){return"] + "MemberDisplayUtils": {"props": ["getDisplayProfile", "default"], "exported": false, "value": "exports", "map": { + "getUserProfile": ["default"] }}, - "MentionUtils": {"strings": ["rawMessage", "mention_everyone", "mentionUsers"], "exported": false, "value": "exports", "map": { - "isRawMessageMentioned": ["rawMessage", "mention_everyone", "mentionUsers"] - }}, - "MessageAuthorUtils": {"strings": [".friendNickname", "colorRoleName:null"], "exported": false, "value": "exports", "map": { - "getAuthor": ["Result cannot be null because the message is not null"], - "getMessageAuthor": [".getChannel(e.channel_id)", "(e.author"] - }}, - "MessageComponentUtils": {"strings": ["ANIMATE_CHAT_AVATAR", "interactionUsernameProfile"], "exported": false, "value": "exports", "map": { - "useHoveredMessage": ["ANIMATE_CHAT_AVATAR"] - }}, - "MessageManageUtils": {"strings": ["showMentionToggle", "SEND_FAILED", "shouldMention"], "exported": false, "value": "exports", "map": { - "copyLink": [".guild_id"], - "replyToMessage": ["showMentionToggle", "shouldMention"] + "MentionUtils": {"props": ["isRawMessageMentioned", "isMentioned"]}, + "MessageAuthorUtils": {"props": ["getMessageAuthor", "getUserAuthor"], "exported": false, "value": "exports", "map": { + "getAuthor": ["default"] }}, + "MessageComponentUtils": {"props": ["useClickReply", "useHoveredMessage"]}, + "MessageManageUtils": {"props": ["copyLink", "replyToMessage"]}, "MessageParser": {"props": ["parseEmbedTitle", "defaultRules"]}, "MessagePinUtils": {"props": ["pinMessage", "unpinMessage"]}, "MessageUtils": {"props": ["receiveMessage", "editMessage"]}, - "ModalUtils": {"strings": ["modalKey", "instant", "contextKey"], "nonStrings": ["LOGIN_REQUIRED_ACTIONS_MODAL_KEY"], "exported": false, "value": "exports", "map": { - "openModal": [".modalKey", ".instant", ".Layer", ".onCloseRequest"] - }}, + "ModalUtils": {"props": ["openModal", "hasModalOpen", "useHasAnyModalOpen"]}, "NitroUtils": {"props": ["canUseIncreasedMessageLength", "canUsePremiumGuildMemberProfile"]}, "NotificationSettingsUtils": {"props": ["setDesktopType", "setTTSType"]}, - "PlatformUtils": {"strings": ["return/^win/.test"], "exported": false, "value": "exports", "map": { - "isAndroid": ["\"android\""], - "isDarwin": ["\"darwin\""], - "isIOS": ["ios"], - "isLinux": ["\"linux\""], - "isWindows": ["return/^win/.test"] - }}, + "PlatformUtils": {"props": ["isAndroid", "isWindows"]}, "PermissionRoleUtils": {"props": ["can", "ALLOW", "DENY"]}, - "PreferencesContext": {"strings": ["reducedMotion", "forcedColors", "alwaysShowLinkDecorations", "createContext"], "exported": false, "value": "exports", "map": { - "AccessibilityPreferencesContext": ["object Object"] - }}, + "PreferencesContext": {"strings": ["reducedMotion", "forcedColors", "alwaysShowLinkDecorations", "createContext"]}, "PrivateChannelUtils": {"props": ["addRecipient", "openPrivateChannel"]}, "QuerySearchUtils": {"props": ["queryGuilds", "queryGroupDMs"]}, - "ReactionEmojiUtils": {"strings": ["optionallyDiverseSequence,animated", "convertSurrogateToName"], "exported": false, "value": "exports", "map": { - "getReactionEmojiName": ["convertSurrogateToName"] - }}, - "ReactionUtils": {"strings": ["\"MESSAGE_REACTION_ADD\"", "\"MESSAGE_REACTION_REMOVE\"", "\"@me\""], "exported": false, "value": "exports", "map": { - "getReactions": [".apply("] - }}, + "ReactionEmojiUtils": {"props": ["getReactionEmojiName", "getAccessibleEmojiDisplayName"]}, "RecentMentionUtils": {"props": ["deleteRecentMention", "fetchRecentMentions"]}, "RelationshipUtils": {"props": ["addRelationship", "removeRelationship"]}, - "RoleIconUtils": {"strings": [".ROLE_ICONS", "convertSurrogateToName", "customIconSrc"], "exported": false, "value": "exports", "map": { - "canGuildUseRoleIcons": [".ROLE_ICONS"], - "getRoleIconData": ["convertSurrogateToName", "customIconSrc"] - }}, + "RoleIconUtils": {"props": ["canGuildUseRoleIcons", "getRoleIconData"]}, "RTCConnectionUtils": {"props": ["getChannelId", "getGuildId", "getRTCConnectionId"]}, - "SearchPageUtils": {"strings": ["searchId", "sort_by", "sort_order"], "exported": false, "value": "exports", "map": { - "changePage": ["*"] - }}, - "SettingsUtils": {"strings": ["ON_FOR_LARGE_GUILDS", "updateSetting", "useSetting"], "exported": false, "value": "exports"}, - "SimpleMarkdownComponents": {"strings": ["customEmoji", "emojiTooltipPosition", "timestampTooltip"]}, + "SearchPageUtils": {"props": ["changePage", "search", "clearHistory"]}, "SimpleMarkdownParser": {"props": ["parseBlock", "parseInline", "defaultOutput"]}, - "SlateRichUtils": {"strings": ["textValue", "richValue", "text:\"\""], "nonStrings": [".jsx)"], "exported": false, "value": "exports", "map": { - "toRichValue": [".split(\"\\n\")"] - }}, - "SlateTextUtils": {"strings": ["ignoreTrailingEmptyNodes", "preventEmojiSurrogates"], "nonStrings": [".jsx)"], "exported": false, "value": "exports", "map": { - "toTextValue": ["ignoreTrailingEmptyNodes"] - }}, + "SlateRichUtils": {"props": ["createState", "toRichValue"]}, + "SlateTextUtils": {"props": ["serializeDescendant", "toTextValue"]}, "SoundParser": {"strings": ["discodo", "ddr-down", "mute"]}, - "SoundUtils": {"strings": [".play()", ".disableSounds", "getSoundpack"], "nonStrings": [".jsx)"], "exported": false, "value": "exports", "map": { - "createSound": ["return new"], - "createSoundpackSound": [");return"], - "playSound": ["getSoundpack"] - }}, - "SortedGuildUtils": {"props": ["getSortedGuilds", "getFlattenedGuildIds"]}, - "SpotifyUtils": {"strings": ["\"SPOTIFY_SET_ACTIVE_DEVICE\"", "deviceId", "accountId"], "exported": false, "value": "exports", "map": { - "getAccessToken": ["SPOTIFY_ACCOUNT_ACCESS_TOKEN_REVOKE", "CONNECTION_ACCESS_TOKEN"], - "pause": ["SPOTIFY_PLAYER_PAUSE"], - "play": ["SPOTIFY_PLAYER_PLAY"] - }}, - "StateStoreUtils": {"strings": ["this._currentDispatchActionType"], "exported": false, "value": "exports"}, + "SoundUtils": {"props": ["createSound", "createSoundForPack", "playSound"]}, + "SpotifyUtils": {"props": ["getAccessToken", "pause", "play"]}, "StoreChangeUtils": {"props": ["get", "set", "clear", "remove"]}, + "TimeoutUtils": {"strings": ["_timeout.isStarted()"]}, "TimestampUtils": {"props": ["fromTimestamp", "extractTimestamp"]}, "UploadUtils": {"props": ["upload", "instantBatchUpload"]}, "URLParser": {"props": ["parse", "resolveObject"]}, "UserNameUtils": {"props": ["getNickname", "getName", "useName"]}, - "UserPopoutUtils": {"strings": ["Cannot moderate", "user:", "showMute"], "exported": false, "value": "exports", "map": { - "openUserContextMenu": ["showMute"] - }}, - "UserProfileUtils": {"strings": ["USER_AGREEMENTS", "user cannot be undefined"], "exported": false, "value": "exports", "map": { - "fetchProfile": [".apply("], - "getUser": ["\"USER_UPDATE\""] - }}, - "UserSettingsProtoUtils": {"strings": ["UserSettingsProtoLastWriteTimes"], "exported": false, "value": "exports"}, + "UserPopoutUtils": {"props": ["openUserContextMenu", "openModerateRoleContextMenu"]}, + "UserProfileUtils": {"props": ["fetchProfile", "getUser"]}, + "UserSettingsProtoUtils": {"props": ["addDismissedContent", "updateUserChannelSettings"]}, "UserSettingsUtils": {"props": ["open", "updateAccount"]}, "Utilities": {"props": ["flatMap", "cloneDeep"]}, "WindowUtils": {"props": ["minimize", "maximize", "close"]} @@ -237,29 +170,30 @@ "NativeSubComponents": { "Button": {"props": ["Colors", "Hovers", "Looks"]}, "Checkbox": {"props": ["Aligns", "Shapes", "Types"]}, - "Clickable": {"strings": [".ENTER", "preventDefault", ").handleKeyPress"]}, + "Clickable": {"strings": [".ENTER", "renderNonInteractive", ".handleKeyPress"]}, "KeybindRecorder": {"strings": [".RECORDING", ".DEFAULT", "toggleRecordMode"]}, "PopoutContainer": {"props": ["Animation", "defaultProps"]}, "RadioGroup": {"strings": ["itemInfoClassName", "hasSelection", ".radioItemIconClassName"]}, - "SearchBar": {"strings": [").inputRef", ".containerRef", ".handleOnChange"]}, - "SearchableSelect": {"strings": ["serialize", "haspopup", ".maxVisibleItems"], "exported": false, "value": "exports", "funcStrings": [".onChange,", ".jsx)", "isSelected:function"]}, + "SearchBar": {"strings": ["this.inputRef", ".containerRef", ".handleOnChange"]}, + "SearchableSelect": {"strings": ["serialize", "haspopup", "maxVisibleItems"]}, "Slider": {"strings": [".stickToMarkers", "sortedMarkers"]}, "TabBar": {"props": ["Item", "Header", "Panel"]}, "Table": {"props": ["SortDirection", "defaultProps"]}, - "TextArea": {"strings": ["onKeyDown=function", "defaultDirty"]}, - "TextInput": {"strings": ["onFocus=function", "MAXIMUM_LENGTH_ERROR", "translate3d"], "exported": false, "value": "exports", "funcStrings": ["MAXIMUM_LENGTH_ERROR"]}, - "TooltipContainer": {"strings": ["handleContextMenu=function", "shouldShowTooltip", "clickable"]} + "TextArea": {"strings": ["onKeyDown", "defaultDirty"]}, + "TextInput": {"strings": ["onFocus", "MAXIMUM_LENGTH_ERROR", "getIsOverFlowing"]}, + "TooltipContainer": {"strings": ["Tooltip cannot find DOM node", "shouldShowTooltip", "clickable"]} }, "LibraryComponents": { "Anchor": {"strings": ["anchorUnderlineOnHover", "noreferrer noopener"]}, - "Animations": {"props": ["Controller", "Spring"]}, - "AppReferencePositionLayer": {"strings": [".LayerProvider,", ".LayerContainer,", ".layerContext,"], "funcStrings": [",{children:(", "({ref:"]}, + "Animations": {"props": ["Controller", "Spring", "animated"]}, + "AppReferencePositionLayer": {"props": ["AppReferencePositionLayer", "appLayerContext"], "funcStrings": ["{children:(", "{ref:"]}, + "AutocompleterComponents": {"props": ["AutocompleterQuerySymbols", "createHeaderResult"]}, "AvatarConstants": {"strings": ["\"SIZE_20\"", "\"SIZE_32\""], "exported": false, "value": "exports", "map": { "Sizes": ["\"SIZE_20\"", "\"SIZE_32\""] }}, - "Avatars": {"strings": ["\"statusColor\"", "ONLINE", "isMobile"], "exported": false, "value": "exports", "map": { - "AnimatedAvatar": ["compare"], - "Avatar": ["statusColor"] + "Avatars": {"props": ["AnimatedAvatar", "Avatar"], "exported": false, "value": "exports", "map": { + "AnimatedAvatar": ["AnimatedAvatar"], + "Avatar": ["Avatar"] }}, "Badges": {"strings": ["disableColor", "baseShapeRound", "textBadge"], "exported": false, "value": "exports", "map": { "BadgeShapes": ["baseShapeRoundRight", "baseShapeRoundLeft"], @@ -267,35 +201,30 @@ "NumberBadge": [".numberBadge"], "TextBadge": [".textBadge"] }}, - "Checkmark": {"strings": ["d:\"M8.99991 16.17L4.82991"]}, + "Checkmark": {"strings": ["d:\"M8.99991 16.17L4.82991"], "funcStrings": ["foreground:"]}, "Emoji": {"strings": ["emojiName", "shouldAnimate", "jumboable"], "funcStrings": ["autoplay"]}, - "EmojiButton": {"strings": ["renderButtonContents", "PickerPerRow", "SELECT_EMOJI"]}, - "EmojiPicker": {"strings": ["emojiSize", "inExpressionPicker", ",emojiPaddingHorizontal:"], "funcStrings": ["compare"]}, + "EmojiButton": {"strings": ["renderButtonContents", "\"emojiButton\"", "SELECT_EMOJI"]}, + "EmojiPicker": {"strings": ["emojiSize", "inspectedExpressionPosition", ",emojiPaddingHorizontal:"], "funcStrings": ["compare"]}, "Flex": {"props": ["Wrap", "Direction", "Child"]}, "FlowerStar": {"strings": ["flowerStarContainer", ".jsx)"]}, "FocusRingScope": {"strings": ["FocusRing", "ringTarget was not"]}, - "FormComponents": {"props": ["INPUT_PLACEHOLDER", "LABEL_SELECTED"], "exported": false, "value": "exports", "map": { - "FormDivider": [".divider"], - "FormItem": [".titleClassName", "required"], - "FormNotice": [".iconClassName", ".imageData"], - "FormSection": ["sectionTitle", "titleId"], - "FormTags": ["\"H1\":\"h1\"", "\"H2\":\"h2\""], - "FormText": [".type", ".DEFAULT"], - "FormTitle": [".tag", ".errorSeparator"] - }}, - "GuildBadge": {"strings": ["VERIFIED_AND_PARTNERED", "renderBadge", "flowerStarClassName"]}, - "GuildIconComponents": {"strings": ["SMOL", "badgeStrokeColor"], "map": { - "Icon": [".apply"], - "Sizes": ["\"SMOL\"", "\"SMALLER\""] + "FormComponents": {"props": ["FormText", "FormTitleTags", "FormDivider"], "exported": false, "value": "exports", "map": { + "FormDivider": ["FormDivider"], + "FormItem": ["FormItem"], + "FormNotice": ["FormNotice"], + "FormSection": ["FormSection"], + "FormTags": ["FormTitleTags"], + "FormText": ["FormText"], + "FormTextTypes": ["FormTextTypes"], + "FormTitle": ["FormTitle"] }}, + "GuildBadge": {"strings": ["foregroundDarkColor", "getBadgeCategory"]}, + "GuildIcon": {"strings": ["SMOL", "badgeStrokeColor"], "funcStrings": ["render()"]}, + "GuildItem": {"strings": ["guildNode:", "useShouldShowInvitesDisabledNotif"]}, "GuildTooltipMutedText": {"strings": [".muteConfig", "color:\"text-muted\""]}, - "Header": {"props": ["Sizes", "Tags"]}, "Heading": {"strings": ["data-excessive", ".defaultColor"]}, "HeaderBarComponents": {"strings": ["isAuthenticated", ".HEADER_BAR"]}, - "ImageComponents": {"strings": ["containerRef", "zoomable", "LOADING"], "exported": false, "value": "exports", "map": { - "Image": ["containerRef"], - "ImageReadyStates": ["LOADING", "ERROR"] - }}, + "Image": {"strings": ["containerRef", "zoomable", "LOADING"]}, "ImageModal": {"strings": ["renderLinkComponent", ".Messages.OPEN_IN_BROWSER", "animated"]}, "ImageVideoModal": {"strings": ["renderLinkComponent", ".Messages.OPEN_IN_BROWSER", "videoWrapper"]}, "LayerContainerComponents": {"strings": ["layerContainerElement", "LayerProvider"], "exported": false, "value": "exports", "map": { @@ -303,52 +232,53 @@ "LayerContainer": [".layerContainer", "missing parent"] }}, "LazyImage": {"protos": ["loadImage", "getRatio", "getSrc"]}, - "ListHeader": {"strings": [".container", "\"h2\"", "[\"aria-label\"]"]}, "Mask": {"props": "Masks"}, - "Menu": {"strings": ["Menu API only allows Items and groups of Items as children"], "funcStrings": ["keyboardModeEnabled"]}, - "MessageGroup": {"strings": ["renderThreadAccessory", "HAS_THREAD", "allowHeading"], "nonStrings": ["THREAD_STARTER"]}, + "Menu": {"strings": ["Menu API only allows Items and groups of Items as children"]}, + "MessageGroup": {"strings": [".ephemeral", "animateAvatar:", "getMessageByReference"]}, "MessagesPopoutComponents": {"strings": ["canCloseAllMessages", "loadingMore"], "exported": false, "value": "exports", "map": { - "EmptyState": ["emptyPlaceholder"], + "EmptyState": [".emptyPlaceholder", "backgroundImage"], "Header": [".header", "heading"], "Popout": ["renderHeader", "renderEmptyState"] }}, - "ModalComponents": {"strings": [".renderModal,", "onCloseRequest"], "exported": false, "value": "exports", "map": { - "Modal": [".renderModal"], - "ModalCloseButton": ["closeWithCircle"], - "ModalContent": [".content,"], - "ModalFooter": [".footer,"], - "ModalHeader": [".headerId"], - "ModalListContent": [".scrollerRef"], - "ModalRoot": [".transitionState", ".size"], - "ModalSize": ["DYNAMIC", "SMALL"] + "ModalComponents": {"props": ["Modal", "ModalCloseButton"], "exported": false, "value": "exports", "map": { + "Modal": ["Modal"], + "ModalCloseButton": ["ModalCloseButton"], + "ModalContent": ["ModalContent"], + "ModalFooter": ["ModalFooter"], + "ModalHeader": ["ModalHeader"], + "ModalListContent": ["ModalListContent"], + "ModalRoot": ["ModalRoot"], + "ModalSize": ["ModalSize"] }}, - "Paginator": {"strings": ["totalPageCount", "selectedPage"]}, + "Paginator": {"strings": ["totalPageCount", "selectedPage", "endButtonInner"]}, "PanelButton": {"strings": ["Masks.PANEL_BUTTON"]}, "PopoutFocusLock": {"strings": ["impressionName", "useImperativeHandle"], "funcStrings": ["impressionName"]}, - "PrivateChannelItems": {"strings": ["handleCloseButtonMouseDown", "LEAVE_GROUP_DM_MANAGED_BODY"], "exported": false, "value": "exports", "map": { + "PrivateChannelItems": {"strings": ["getRecipientId", "LEAVE_GROUP_DM_MANAGED_BODY"], "exported": false, "value": "exports", "map": { "DirectMessage": ["getUser", "getRecipientId"], - "GroupDM": [".getGuildId", "selected:n,muted"], "LinkButton": [".apply(this"] }}, - "RoleMention": {"strings": ["rolePopout", "inlinePreview"], "funcStrings": ["inlinePreview"]}, - "Scrollers": {"strings": ["().thin", "().none", "().auto", "().fade)}"], "exported": false, "value": "exports"}, + "Scrollers": {"props": ["ScrollerThin", "ScrollerAuto", "ScrollerNone"], "exported": false, "value": "exports", "map": { + "Auto": ["ScrollerAuto"], + "None": ["ScrollerNone"], + "Thin": ["ScrollerThin"] + }}, + "SearchResultsPagination": {"strings": ["pageLength", "changePage", "maxVisiblePages"]}, "SpinnerComponents": {"strings": ["WANDERING_CUBES", "wanderingCubes", ".spinningCircleInner"], "exported": false, "value": "exports", "map": { "Spinner": [".spinningCircleInner"], "Types": ["WANDERING_CUBES", "wanderingCubes"] }}, - "StatusComponents": {"strings": ["().status}", ".isMobile", ".ONLINE"], "exported": false, "value": "exports", "map": { - "Status": ["().status}", ".isMobile", ".ONLINE"], - "Types": ["\"online\"", "\"unknown\""] + "StatusComponents": {"props": ["Status", "StatusTypes"], "exported": false, "value": "exports", "map": { + "Status": ["Status"], + "Types": ["StatusTypes"] }}, "Text": {"strings": ["lineClamp:", ".selectable", ".defaultColor"]}, - "TextElement": {"strings": [".strong,", ".STANDARD"]}, + "TextElement": {"strings": [".strong]", ".STANDARD"]}, "Timeout": {"protos": ["start", "stop", "isStarted"]}, - "UserBadges": {"props": ["BadgeSizes"]}, "UserBadgeComponents": {"strings": [".PROFILE_USER_BADGES", "SIZE_24"], "exported": false, "value": "exports", "map": { "UserBadges": [".PROFILE_USER_BADGES"], "Sizes": ["\"SIZE_24\":"] }}, - "UserPopout": {"strings": ["\"userId\"", "\"Unexpected missing user\"", "getUser"]}, + "UserPopout": {"strings": ["{user:", "userId:", "\"Unexpected missing user\")", "getUser"]}, "UserPopoutSection": {"strings": [".section,", ".lastSection"]}, "UserSummaryItem": {"strings": ["popoutUserId:", ".clickableAvatar"]}, "VideoForwardRef": {"strings": ["HTMLSourceElement", "autoPlay"], "funcStrings": ["externalRef"]} @@ -375,37 +305,38 @@ "AuditLogEntry": {"protos": ["renderRoleUpdate", "renderChangeDetails", "getActionTypeColor", "renderPermissionUpdate"]}, "AuditLogs": {"strings": ["Messages.SEARCH_MEMBERS", "._lastExpandedRef", ".handleActionFilterQueryClear"]}, "AuthWrapper": {"protos": ["renderDefault", "renderMobile", "mobileReplaceWith"]}, - "Autocomplete": {"strings": [".autocompleteInner", "\"innerClassName\"", "().autocomplete,"]}, - "AutocompleteChannelResult": {"strings": [".channel", ".category", ".type===", ".GUILD_CATEGORY?", "().icon}"]}, - "AutocompleteRoleResult": {"strings": [".hideDescription", ".colorString", ".Messages.MENTION_USERS_WITH_ROLE"]}, + "Autocomplete": {"strings": ["autocompleteInner", "innerClassName:", "autocomplete"]}, + "AutocompleteChannelResult": {"strings": ["channel:", "category:", ".type===", ".GUILD_CATEGORY?", "AutocompleteRowHeading"], "noSearch": true}, + "AutocompleteRoleResult": {"strings": ["hideDescription:", "colorString:", ".Messages.MENTION_USERS_WITH_ROLE"], "noSearch": true}, "AutocompleteRowContentPrimary": {"strings": [".jsx)(\"div\"", "autocompleteRowContentPrimary"]}, "AutocompleteRowContentSecondary": {"strings": [".jsx)(", "autocompleteRowContentSecondary"]}, "AutocompleteRowIcon": {"strings": [".jsx)(\"div\"", "autocompleteRowIcon"]}, - "AutocompleteUserResult": {"strings": [".descriptionUsername", ".descriptionDiscriminator", "\"#\"", "Sizes.SIZE_24"]}, + "AutocompleteUserResult": {"strings": ["hidePersonalInformation:", ".descriptionDiscriminator", "\"#\"", "Sizes.SIZE_24"], "noSearch": true}, "BlobMask": {"protos": ["getBadgePositionInterpolation", "getUpperBadgeStyles"]}, "BlockedMessageGroup": {"strings": ["collapsed-message-item", "isBeforeGroup", "collapsedReason"]}, "ChannelCall": {"strings": ["maybeLeaveFullScreen", "handleFullscreenParticipant", "CHANNEL_CALL_POPOUT"]}, - "ChannelCallHeader": {"strings": ["focusedApplication:", "focusedParticipant:", ".getSelectedParticipant", ".appContext"]}, - "ChannelCallGrid": {"strings": [".totalNumberOfParticipants", "keyExtractor:", "channel_user_limit:"]}, - "ChannelCallVideoParticipants": {"strings": [".tileSizer", ".participantTileWidth", ".COVER"]}, - "ChannelEmptyMessages": {"strings": [".Messages.BEGINNING_CHANNEL_WELCOME", ".Messages.BEGINNING_GROUP_DM_MANAGED", ".showingBanner"]}, - "ChannelItem": {"strings": ["canHaveDot", "unreadRelevant", "UNREAD_HIGHLIGHT"]}, - "ChannelItemIcon": {"strings": [".hasActiveThreads", ".locked", ".iconContainer"]}, + "ChannelCallHeader": {"strings": ["focusedApplication:", "focusedParticipant:", ".getSelectedParticipant", "appContext"]}, + "ChannelCallGrid": {"strings": ["totalNumberOfParticipants:", "keyExtractor:", "channel_user_limit:"]}, + "ChannelCallVideoParticipants": {"strings": [".tileSizer", "participantTileWidth:", ".COVER"]}, + "ChannelEmptyMessages": {"strings": [".Messages.BEGINNING_CHANNEL_WELCOME", ".Messages.BEGINNING_GROUP_DM_MANAGED", "showingBanner:"]}, + "ChannelFloatingSidebar": {"strings": ["messageRequestSidebarWidth", "floatingLayer:", "chatLayerWrapper"]}, + "ChannelItem": {"strings": ["hasActiveThreads", ".unreadImportant", "UNREAD_IMPORTANT"]}, + "ChannelItemIcon": {"strings": ["hasActiveThreads:", "locked:", ".iconContainer"]}, "ChannelMembers": {"strings": ["MEMBER_LIST_VIEWED", "getDimensions", "member-"]}, "ChannelPins": {"strings": ["PINNED_MESSAGES", "renderEmptyState", "listName"]}, "ChannelReply": {"strings": [".messageReference", ".REPLY_MENTION_OFF", ".mentionIcon"]}, "ChannelSidebar": {"strings": ["ACCOUNT_PANEL", "RTC_CONNECTION_PANEL", "ACCOUNT_A11Y_LABEL"]}, "ChannelsList": {"protos": ["isUnreadVisible", "renderBottomUnread", "getSectionRowsFromChannel"]}, - "ChannelTextAreaButtons": {"strings": [".buttons", "\"expression\"", "activeCommandOption"]}, + "ChannelTextAreaButtons": {"strings": [".buttons", "\"emoji\"", "activeCommandOption"]}, "ChannelTextAreaContainer": {"strings": ["TOGGLE_EMOJI_POPOUT", "textValue", "richValue"]}, "ChannelTextAreaCounter": {"strings": [".flairContainer", "CHARACTER_COUNT_CLOSE_TO_LIMIT"]}, "ChannelTextAreaEditor": {"strings": ["onHideAutocomplete", "onMaybeShowAutocomplete", "uploadPromptCharacterCount", "_focusBlurQueue"]}, "ChannelTextAreaForm": {"strings": ["renderApplicationCommandIcon", "handleTextareaChange", "handleSendMessage"]}, "ChannelThreadItem": {"strings": [".typeThread", ".modeUnread", ".Messages.GUILD_SIDEBAR_THREAD"]}, - "CircleIconButton": {"strings": [".circleIconButton", "lowerBadge", ".circleButtonMask"]}, - "Clickable": {"strings": [".ENTER", "preventDefault", ").handleKeyPress"]}, + "CircleIconButton": {"strings": ["circleIconButton", "lowerBadge", "circleButtonMask"]}, + "Clickable": {"strings": [".ENTER", "renderNonInteractive", ".handleKeyPress"]}, "CloseButton": {"strings": [".closeButton", ".closeIcon", "offset:{"]}, - "ConnectedLazyImageZoomable": {"strings": ["{isWindowFocused", ",appContext:"]}, + "ConnectedLazyImageZoomable": {"strings": ["isWindowFocused:", ",appContext:"]}, "CustomStatusModal": {"protos": ["renderCustomStatusInput", "renderClearAfter", "getEmojiButtonRenderer"]}, "DefaultChannelEmptyMessage": {"strings": [".CHANNEL_WELCOME", ".titleName", "handlePersonalize"]}, "DirectMessage": {"strings": ["getRecipientId", "Controller", "handleContextMenu", ".DM"]}, @@ -413,26 +344,27 @@ "DirectMessageAddPopoutRow": {"strings": [".weightMedium", ".friendSelected", ".friendWrapper"]}, "DiscordTag": {"strings": ["hidePersonalInformation", "isVerifiedBot", "botType"]}, "Embed": {"strings": ["gridContainer", "renderEmbedContent", "hasThumbnail"]}, - "EmojiPicker": {"strings": [".closePopout", ".pickerIntention", "inExpressionPicker"]}, - "EmojiPickerHeader": {"strings": [".pickerIntention", ".headerClassName", ".Messages.BURST_REACTIONS_"]}, - "EmojiPickerListRow": {"strings": ["emojiSize", "surrogateCodePoint", "EMOJI_FAVORITE_TOOLTIP"]}, + "EmojiPicker": {"strings": ["emojiSize", "disableEmojiTutorial", ",emojiPaddingHorizontal:"]}, + "EmojiPickerHeader": {"strings": ["COMMUNITY_CONTENT_ONLY", "headerClassName", ".EmojiIntention.REACTION"]}, + "EmojiPickerListRow": {"strings": ["emojiSize", "surrogateCodePoint", "showEmojiFavoriteTooltip"]}, "FocusRingScope": {"strings": ["FocusRing", "ringTarget was not"]}, - "FolderHeader": {"strings": [".folderNode", "expandedFolderIconWrapper", "forceCircular"]}, - "FolderIcon": {"strings": [".folderNode", "folderIconWrapper", "closedFolderIconWrapper"]}, - "FolderItem": {"strings": [".folderNode", "expandedFolderBackground", "onExpandCollapse"]}, - "FolderItemWrapper": {"strings": [".folderNode", "getCurrentUserActiveStream", "currentActiveVoiceType"]}, - "FolderSettingsModal": {"strings": [".handleNameChange=", ".handleSubmit", "folderName:"]}, + "FolderHeader": {"strings": ["folderNode:", "expandedFolderIconWrapper", "forceCircular"]}, + "FolderContextMenu": {"strings": ["GUILD_ACTIONS_MENU_LABEL", "navId:\"guild", "folderId:"], "noSearch": true}, + "FolderIcon": {"strings": ["folderNode:", "folderIconWrapper", "closedFolderIconWrapper"]}, + "FolderItem": {"strings": ["folderNode:", "expandedFolderBackground", "onExpandCollapse"]}, + "FolderItemWrapper": {"strings": ["folderNode:", "isFolderExpanded", "defaultFolderName:"]}, + "FolderSettingsModal": {"strings": [".handleNameChange=", ".handleSubmit", "folderName:"], "noSearch": true}, "GuildBans": {"strings": [".Messages.BANS_NO_USERS_BANNED", ".Messages.BANS_SEARCH_PLACEHOLDER", ".getSortedBans"]}, - "GuildChannelListContextMenu": {"strings": ["GUILD_ACTIONS_MENU_LABEL", "\"guild-context\",\"aria-label\""]}, - "GuildContextMenu": {"strings": ["GUILD_ACTIONS_MENU_LABEL", "navId:\"guild", "GuildContextMenu"]}, + "GuildChannelListContextMenu": {"strings": ["GUILD_ACTIONS_MENU_LABEL", "\"guild-context\",\"aria-label\""], "noSearch": true}, + "GuildContextMenu": {"strings": ["GUILD_ACTIONS_MENU_LABEL", "navId:\"guild", "GuildContextMenu"], "noSearch": true}, "GuildEmojis": {"strings": ["getMaxEmojiSlots", "lightSrc:", ".Messages.NO_EMOJI"]}, "GuildFavorites": {"strings": [".favoriteIcon", "FAVORITES_GUILD_NAME"]}, - "GuildHeader": {"strings": [".bannerVisible", ".disableBannerAnimation", "onContextMenu"]}, + "GuildHeader": {"strings": ["bannerVisible:", "disableBannerAnimation:", "onContextMenu"]}, "GuildIcon": {"strings": [",animate:", ",size:", "{active:!0"], "noSearch": true}, - "GuildIconWrapper": {"strings": [".badgeStrokeColor", ".textScale"]}, - "GuildInvitationRow": {"strings": [".getSelectedInviteMetadata", ".getSuggestedProps", "inviteKey:"]}, + "GuildIconWrapper": {"strings": ["badgeStrokeColor:", "textScale:"]}, + "GuildInvitationRow": {"strings": [".getSelectedInviteMetadata", ".getSuggestedProps", "inviteKey:"], "noSearch": true}, "GuildInvites": {"strings": [".NO_INVITES_BODY", ".DISABLE_INVITES", "submitting"]}, - "GuildItem": {"strings": [".guildNode", "guildJoinRequestStatus", "lowerBadgeWidth"]}, + "GuildItem": {"strings": ["guildNode:", "guildJoinRequestStatus", "lowerBadgeWidth"]}, "GuildItemWrapper": {"strings": [".pauseBackground", ".isUnavailable", "guildJoinRequestStatus"]}, "GuildMemberEntry": {"strings": [".renderOwnerHelpIcon(", ".overflowButton", ".roleWrapper"]}, "GuildsBar": {"strings": ["unreadMentionsIndicatorTop", "disableAppDownload", ".GUILD_MEMBER_VERIFICATION"]}, @@ -441,40 +373,44 @@ "HeaderBar": {"strings": [".hamburger", "scrollable", "themed"]}, "HeaderBarChannelName": {"strings": ["onDoubleClick", ".setName", "maxLen:"]}, "HeaderBarContainer": {"strings": ["isAuthenticated", ".HEADER_BAR"]}, + "HeaderBarRecipient": {"strings": [".Messages.DIRECT_MESSAGE", "getRecipientId", ".avatar", "getName"]}, "HeaderBarTitle": {"strings": [".titleWrapper", ",onContextMenu", "forceLevel:"]}, - "HeaderBarTitleIcon": {"strings": ["HEADER_BAR_BADGE", ".iconBadge", ".iconClassName"]}, - "HomeButton": {"strings": ["isOnOtherSidebarRoute", "showProgressBadge", "maybeTrackExposure"]}, - "HomeButtonDefault": {"strings": ["BUTTON_HOME", ".homeIcon", ".DISCODO_ENABLED"]}, + "HeaderBarTitleIcon": {"strings": ["HEADER_BAR_BADGE", ".iconBadge", "iconClassName:"]}, + "HomeButtonDefault": {"strings": [".DISCODO_ENABLED", "home_button_no_track", "tutorialContainer"]}, "I18nLoader": {"strings": [".Messages.I18N_LOCALE_LOADING_ERROR", ".loading"]}, "ImageModal": {"strings": ["renderLinkComponent", ".Messages.OPEN_IN_BROWSER", "animated"], "noSearch": true}, - "ImageVideoModal": {"strings": ["renderLinkComponent", ".Messages.OPEN_IN_BROWSER", "videoWrapper"]}, + "ImageVideoModal": {"strings": ["renderLinkComponent", ".Messages.OPEN_IN_BROWSER", "videoWrapper"], "noSearch": true}, "InboxHeader": {"strings": [".UNREADS", ".TODOS", ".controls"]}, "IncomingCallModal": {"strings": [".Messages.INCOMING_VIDEO_CALL_ELLIPSIS", ".isFocused", "maxX:window.innerWidth"]}, - "InviteGuildName": {"strings": [".guild;return", "().guildName", "().guildNameWrapper"]}, + "InviteGuildName": {"strings": ["{guild:",".guildName",".guildNameWrapper", ".name", "jsx)(\"span\","], "noSearch": true}, + "KeybindRecorder": {"strings": [".RECORDING", ".DEFAULT", "toggleRecordMode"], "noSearch": true}, "LayerProvider": {"strings": ["layerContainerElement", "getContextValue"]}, "LayersProvider": {"strings": ["._currentlyTransitioningKeys", "._keysToEnter", "._keyChildMapping"]}, "LazyImage": {"protos": ["loadImage", "getRatio", "getSrc"]}, "LazyImageZoomable": {"strings": ["renderLinkComponent", "onCloseImage"]}, "ListItemTooltip": {"strings": [".listItemWrapper", "tooltipClassName", "disableWrapper"]}, - "MemberListItem": {"protos": ["renderOwner", "renderDecorators", "renderPremium"]}, - "Mention": {"strings": [".iconType", ".color,", "),backgroundColor:"]}, + "MemberListItem": {"strings": ["ownerTooltipText", "onClickPremiumGuildIcon:", "Messages.GUILD_OWNER"]}, + "Mention": {"strings": ["iconType:", "color:", "),backgroundColor:"]}, "Menu": {"strings": ["\"empty\"", "getItemProps", "isUsingKeyboardNavigation"]}, "Message": {"strings": ["childrenMessageContent", "childrenRepliedMessage", "zalgo", ".buttonContainer"]}, "MessageAccessories": {"protos": ["renderGiftCodes", "renderEmbeds", "renderActivityInvite"]}, "MessageActionsContextMenu": {"strings": ["canReport:", "navId:\"message-actions\"", "useMessageMenu"]}, "MessageContent": {"strings": [".SEND_FAILED", "editedTimestamp", ".MESSAGE_EDITED"]}, "MessageContextMenu": {"strings": ["MESSAGE_ACTIONS_MENU_LABEL", "navId:\"message", "getGuildId"]}, - "MessageGroup": {"strings": ["backgroundFlash", "renderMediaEmbeds", "THREAD_STARTER_MESSAG"]}, + "MessageGroup": {"strings": [".ephemeral", "animateAvatar:", "getMessageByReference"]}, "MessageHeader": {"strings": ["showTimestampOnHover", "usernameClassName", "isVisibleOnlyOnHover:"], "noSearch": true}, - "MessageReply": {"strings": [".isFirstMessageInForumPost", ".referencedUsernameProfile", "referencedMessage"]}, + "MessageReply": {"strings": [".isFirstMessageInForumPost", "referencedUsernameProfile:", "referencedMessage"]}, + "MessageReplyHeader": {"strings": ["pollBadgeReplied", "referencedMessage"]}, "Messages": {"strings": ["messageGroupSpacing", "groupSpacing", "jumpToPresent"]}, "MessageSearchResultContextMenu": {"strings": ["MESSAGE_ACTIONS_MENU_LABEL", "navId:\"message"], "nonStrings": ["getGuildId"]}, "MessageTimestamp": {"strings": [".timestampVisibleOnHover", "MESSAGE_EDITED_TIMESTAMP", ".timestampTooltip"], "noSearch": true}, - "MessageToolbar": {"strings": ["Messages.MORE", "hasDeveloperMode", "emojiPicker:", "Messages.MESSAGE_TODOS_MARK_AS_DONE"], "noSearch": true}, + "MessageToolbar": {"strings": ["Messages.MORE", "hasDeveloperMode", "emojiPicker:"], "noSearch": true}, "MessageUsername": {"strings": ["\"username\"", "colorString", "compact"]}, "ModalCarousel": {"strings": [".gotoNext", "currentIndex", "gotoPrevThrottled"]}, - "ModalHeader": {"strings": [".headerIdIsManaged", ".header,", "Direction.HORIZONTAL"]}, + "ModalHeader": {"strings": ["headerIdIsManaged:", ".header,", "Direction.HORIZONTAL"]}, "ModalFooter": {"strings": [".footerSeparator", ".separator", "Direction.HORIZONTAL_REVERSE"]}, + "ModalRoot": {"strings": ["rootWithShadow", "ImpressionTypes.MODAL", "ModalTransitionState"]}, + "NameContainer": {"strings": ["\"listitem\"", "wrappedName", "innerClassName"]}, "NameTag": {"strings": ["invertColor:", "usernameClass", "discriminatorClass"]}, "NavItem": {"strings": [".selected", ".childWrapper", "fontSize:"]}, "Note": {"strings": [".noteRef", "handleBlur", ".SPACE"]}, @@ -487,10 +423,10 @@ "PeopleListItemBlocked": {"strings": [".listItemContents", "UNKNOWN", ".BLOCKED"]}, "PeopleListItemFriend": {"strings": [".getMutablePrivateChannels", ".handleOpenPrivateChannel", "isActiveRow"]}, "PeopleListItemPending": {"strings": ["PENDING_INCOMING", ".DENY", "addRelationship"]}, - "PeopleListSectionedLazy": {"strings": [".statusSections", ".peopleList", "id:\"people-list\""]}, - "PeopleListSectionedNonLazy": {"strings": [".statusSections", ".peopleList", "id:\"people\""]}, - "PictureInPictureVideo": {"strings": [".topControls", ".bottomControl", ".screenMessage", ".renderBottomLeftControls"]}, - "PrivateChannel": {"strings": ["LEAVE_GROUP_DM_MANAGED_BODY", "handleCloseButtonMouseDown", "handleLeaveGroup"]}, + "PeopleListSectionedLazy": {"strings": ["statusSections", "peopleList", "id:\"people-list\""]}, + "PeopleListSectionedNonLazy": {"strings": ["statusSections", "peopleList", "id:\"people\""]}, + "PictureInPictureVideo": {"strings": [".topControls", ".bottomControl", "screenMessage", "renderBottomLeftControls:"]}, + "PrivateChannel": {"strings": ["LEAVE_GROUP_DM_MANAGED_BODY", "PrivateChannel.renderAvatar"]}, "PrivateChannelRecipients": {"strings": [".membersWrap", "recipients"]}, "PrivateChannelsList": {"strings": ["privateChannelIds", "privateChannelRecipientsInviteButtonIcon"]}, "QuickMessage": {"strings": ["QUICK_DM_USER", ".NORMAL"]}, @@ -499,72 +435,73 @@ "QuickSwitchGroupDMResult": {"strings": ["getAccessibilityLabel", ".contentUnread", "dmIconContainer"]}, "QuickSwitchGuildResult": {"strings": ["getAccessibilityLabel", ".contentUnread", "guildIconContainer"]}, "QuickSwitchUserResult": {"strings": ["getAccessibilityLabel", ".contentUnread", "getDisplayNickname"]}, - "Reactions": {"strings": ["disableTransitionAppear", "reactionsCount:", "message.reactions.length"]}, - "Reactor": {"strings": ["currentUser cannot be undefined", "reactorDefault"]}, - "Reactors": {"strings": ["hasMore", "emoji", "spinnerMore"]}, - "RecentMentions": {"strings": ["canCloseAllMessages", "RECENT_MENTIONS", "badgeable"]}, - "RecentsChannelHeader": {"strings": [".subtextContainer", ".channelNameSpan", ".channelNameHeader", ".gotoChannel"]}, - "RichChannelMention": {"strings": ["iconType:", "Messages.DELETED_CHANNEL_PLACEHOLDER"]}, - "RichRoleMention": {"strings": [".color?null", ".guildId", ".roles[", "\"@\""]}, - "RichUserMention": {"strings": ["hidePersonalInformation", "getUser", "userTooltip"]}, + "Reactions": {"strings": ["showImmediate:", ".BURST", "reactions:", ".emoji.name"], "noSearch": true}, + "ReactionsModal": {"strings": [".BURST", ".reactions", ".emoji.name", "selectedReaction"], "noSearch": true}, + "ReactionsModalUser": {"strings": ["currentUser cannot be undefined", "reactorDefault"]}, + "ReactionsModalUsers": {"strings": ["hasMore", "emoji", "spinnerMore"], "noSearch": true}, + "RecentMentions": {"strings": ["canCloseAllMessages", "RECENT_MENTIONS", "badgeState:"]}, + "RecentsChannelHeader": {"strings": [".subtextContainer", ".channelNameSpan", ".channelNameHeader", "gotoChannel:"]}, + "RichChannelMention": {"strings": ["iconType:", "Messages.UNKNOWN_CHANNEL", "\"locked\""], "noSearch": true}, + "RichRoleMention": {"strings": ["\"@deleted-role\"", "guildId:", ".RoleDot"], "noSearch": true}, + "RichUserMention": {"strings": ["hidePersonalInformation", "getUser", "userTooltip"], "noSearch": true}, "RTCConnection": {"strings": [".NOISE_CANCELLATION_POPOUT", ".voicePanelIntroductionButton"]}, - "RTCConnectionVoiceUsers": {"strings": [".Messages.VOICE_PANEL_SHOW_EXTRAS", ".Messages.VOICE_PANEL_USERS", ".voiceStates"]}, - "SearchBar": {"strings": [").inputRef", ".containerRef", ".handleOnChange"]}, + "RTCConnectionVoiceUsers": {"strings": [".Messages.VOICE_PANEL_SHOW_EXTRAS", ".Messages.VOICE_PANEL_USERS", "voiceStates:"]}, + "SearchBar": {"strings": ["this.inputRef", ".containerRef", ".handleOnChange"]}, "SearchPopout": {"strings": [".handleHintClick", ".selectedIndex", "token.start"]}, "SearchPopoutOption": {"strings": [".plusIcon", ".option,", ".filter"]}, - "SearchResult": {"strings": [".onJump", "message:", "handleMessageClick"]}, + "SearchResult": {"strings": ["onJump:", "message:", "handleMessageClick"]}, "SearchResults": {"strings": ["SEARCH_ERROR", "emptyResultsText", "isSearching"]}, - "SearchResultsHeader": {"strings": [".Messages.SEARCH_OLDEST_SHOR", ".Messages.SEARCH_MOST_RELEVANT_SHORT", ".searchByMode"]}, + "SearchResultsHeader": {"strings": [".Messages.SEARCH_OLDEST_SHOR", ".Messages.SEARCH_MOST_RELEVANT_SHORT", "searchByMode"]}, "SearchResultsInner": {"strings": ["SEARCH_HIDE_BLOCKED_MESSAGES", "totalResults", "\"search-result-\""]}, - "SearchResultsPagination": {"strings": [".pageLength", ".changePage", "maxVisiblePages"]}, + "SearchResultsPagination": {"strings": ["pageLength", "changePage", "maxVisiblePages"]}, "SettingsView": {"strings": ["tabBarItemContainer", "PROFILE_CUSTOMIZATION", "badgeCount"]}, "Shakeable": {"protos": ["shake", "getDefaultAnimProps", "stop"]}, - "Spoiler": {"strings": ["revealSpoiler", ".onReveal"]}, + "Spoiler": {"strings": [".removeObscurity", "onReveal:"]}, "SpoilerWarning": {"strings": [".spoilerWarning", ".SPOILER"]}, - "StandardSidebarView": {"strings": ["standardSidebarView", ".sidebarTheme", "mobileSidebarHeader"]}, + "StandardSidebarView": {"strings": ["standardSidebarView", "sidebarTheme:", "mobileSidebarHeader"]}, "SystemMessageThreadCreated": {"strings": ["threadOnClick:", ".SYSTEM_MESSAGE_THREAD_CREATED", "viewThreadsOnClick:"]}, "SystemMessageWrapper": {"strings": ["unknown message type", "\"SystemMessage\""]}, "TabBar": {"props": ["Item", "Header", "Panel"]}, "TextChannelEmptyMessage": {"strings": ["MANAGE_CHANNELS", ".BEGINNING_CHANNEL_DESCRIPTION", "topicHook:"]}, - "ThreadCard": {"strings": [".threadId", ".gotoThread", ".container", ".threadName"]}, + "TextInput": {"strings": ["onFocus", "MAXIMUM_LENGTH_ERROR", "getIsOverFlowing"], "noSearch": true}, + "ThreadCard": {"strings": ["threadId:", ".container", ".threadName"]}, "ThreadCardDescription": {"strings": [".Messages.THREAD_BROWSER_STARTED_BY", ".bullet", ".lastMessageId"]}, "ThreadEmptyMessage": {"strings": [",{channel:", ".name", "{channelId:", ".iconWrapper", ".icon}"]}, "ThreadEmptyMessageAuthor": {"strings": [".threadCreatorName", ".unknownCreatorName", ".getUser"]}, "ThreadMessageAccessories": {"strings": ["threadMetadata", "NO_RECENT_THREAD_MESSAGES", ".Messages.THREAD"]}, "ThreadMessageAccessoryMessage": {"strings": [".threadMessageAccessoryPlaceholder", ".threadMessageAccessoryContent", "formatInline:"]}, - "ThreadSidebar": {"strings": [".baseChannelId", ".SIDEBAR", ".THREAD_HEADER_BAR"]}, + "ThreadSidebar": {"strings": ["baseChannelId:", ".SIDEBAR", ".THREAD_HEADER_BAR"]}, "TooltipContainer": {"protos": ["renderTooltip", "setDomElement", "shouldShowTooltip", "toggleShow"]}, "TransitionGroup": {"protos": ["performAppear", "performEnter", "performLeave"]}, "TypingUsers": {"strings": ["Easing.quad", ".emphasizeSlowmodeCooldown", ".sequence("]}, "UnavailableGuildsButton": {"strings": [".errorInner", ".guildsError", "Messages.PARTIAL_OUTAGE"]}, - "UnreadDMs": {"strings": ["getMutablePrivateChannels", "selectedVoiceGuildId", ".selectedVoiceChannelId"]}, - "UseCopyIdItem": {"strings": ["\"devmode-copy-id\""]}, + "UnreadDMs": {"strings": ["getMutablePrivateChannels", "selectedVoiceGuildId", "selectedVoiceChannelId:"]}, "UserBadges": {"strings": [".PROFILE_USER_BADGES", "SIZE_24"]}, - "UserBanner": {"strings": [".showPremiumBadgeUpsell", ".isPremiumAtLeast", ".SETTINGS"]}, - "UserBannerMask": {"strings": [".overrideAvatarDecorationURL", "hasBannerImage:", "foreignObject"]}, - "UserBioSection": {"strings": [".isUsingGuildBio", "aboutMeGuildIcon", "GUILD_IDENTITY_BIO_TOAST"]}, + "UserBanner": {"strings": ["showPremiumBadgeUpsell:", ".isPremiumAtLeast", ".SETTINGS"]}, + "UserBannerMask": {"strings": [".bannerSVGWrapper", "getAvatarSpecs", "foreignObject"]}, + "UserBioSection": {"strings": ["isUsingGuildBio:", "aboutMeGuildIcon", "GUILD_IDENTITY_BIO_TOAST"]}, "UserConnectionsSection": {"strings": [".applicationRoleConnections)", ".CONNECTIONS_ROLE_POPOUT_VIEW_ALL"]}, - "UserGenericContextMenu": {"strings": ["USER_ACTIONS_MENU_LABEL", "navId:\"user", ".USER_GENERIC_MENU"]}, + "UserGenericContextMenu": {"strings": ["USER_ACTIONS_MENU_LABEL", "navId:\"user", ".USER_GENERIC_MENU"], "noSearch": true}, "UserInfo": {"strings": [".botTag", "isMobile:", ".discordTag"]}, - "UserMemberContextMenu": {"strings": ["USER_ACTIONS_MENU_LABEL", "navId:\"user", ".GUILD_CHANNEL_USER_MENU"]}, + "UserMemberContextMenu": {"strings": ["USER_ACTIONS_MENU_LABEL", "navId:\"user", ".GUILD_CHANNEL_USER_MENU"], "noSearch": true}, "UserMemberSince": {"strings": [".memberSinceContainer", ".USER_PROFILE_DISCORD_MEMBER_SINCE"]}, - "UserMemberSinceSection": {"strings": [".userId", "headingClassName", "().title", ".guildMember"]}, - "UserMention": {"strings": [".inlinePreview", "\"@\"", "renderPopout:"]}, - "UsernameSection": {"strings": [".shouldCopyOnClick", ".userTagDiscriminatorNoNickname"]}, - "UserPopout": {"strings": ["\"userId\"", "\"Unexpected missing user\"", "getUser"]}, + "UserMemberSinceSection": {"strings": ["userId:", "headingClassName", ".title", "guildMember:"]}, + "UserMention": {"strings": ["inlinePreview", "\"@\"", "renderPopout:"]}, + "UsernameSection": {"strings": ["shouldCopyOnClick:", ".userTagDiscriminatorNoNickname"]}, + "UserPopout": {"strings": ["{user:", "userId:", "\"Unexpected missing user\")", "getUser"]}, "UserPopoutAvatar": {"strings": [".avatarDecorationHint", ".VIEW_PROFILE"], "noSearch": true}, - "UserPopoutBody": {"strings": [".customStatusActivity", ".canDM", ".hidePersonalInformation", ".showCopiableUsername"]}, - "UserProfile": {"strings": [".PROFILE_MODAL", "USER_INFO_CONNECTIONS", ".topSection"]}, - "UserProfileBody": {"strings": [".userInfoSectionHeader", "Messages.NOTE", "connectedAccounts:"]}, - "UserProfileHeader": {"strings": [".friendToken", ".additionalActionsIcon", "onMessage"]}, + "UserPopoutBody": {"strings": ["customStatusActivity:", "canDM:", "hidePersonalInformation:", "showCopiableUsername:"]}, + "UserProfile": {"strings": [".PROFILE_MODAL", "USER_INFO_CONNECTIONS", ".topSection"], "noSearch": true}, + "UserProfileBody": {"strings": [".userInfoSectionHeader", "Messages.NOTE", "connectedAccounts:"], "noSearch": true}, + "UserProfileHeader": {"strings": ["friendToken:", ".additionalActionsIcon", "onMessage"], "noSearch": true}, "UserProfileMutualFriends": {"strings": [".getMutualFriends", ".listScroller", ".emptyText"]}, "UserProfileMutualGuilds": {"strings": [".getMutualGuilds", ".listScroller", ".emptyText"]}, - "UserProfileUsername": {"strings": [".customStatusEmoji", ".customStatusSoloEmoji", ".findActivity(", ".CUSTOM_STATUS"]}, + "UserProfileUsername": {"strings": [".customStatusEmoji", ".customStatusSoloEmoji", ".findActivity(", ".CUSTOM_STATUS"], "noSearch": true}, "UserRolesSection": {"strings": [".rolePillBorder", "numRoles", "roleClassName"]}, "UserSummaryItem": {"protos": ["renderMoreUsers", "renderUsers", "renderIcon"]}, "UserSettingsAppearance": {"protos": ["renderTheme", "renderDisplayMode", "renderMessageGroupSpacingSlider"]}, "UserTheme": {"strings": [".profileColors", "useDefaultClientTheme:"], "noSearch": true}, - "VideoBackground": {"strings": [".backgroundSrc", ".pulseSpeakingIndicator", ".avatarWrapper"]}, + "VideoBackground": {"strings": ["backgroundSrc:", "pulseSpeakingIndicator:", ".avatarWrapper"]}, "VoiceUser": {"protos": ["renderPrioritySpeaker", "renderIcons", "renderAvatar"]}, "VoiceUsers": {"strings": ["hidePreview", "previewIsOpen", "previewUserIdAfterDelay"]} }, @@ -621,7 +558,7 @@ "icon": "" }, "CHANGELOG": { - "icon": "" + "icon": "" }, "CHECKBOX": { "defaultProps": { @@ -693,13 +630,10 @@ "icon": "" }, "GAMEPAD": { - "icon": "" + "icon": "" }, "GAMEPAD_DISABLED": { - "defaultProps": { - "foreground": "" - }, - "icon": "" + "icon": "" }, "GITHUB": { "icon": "" @@ -845,196 +779,194 @@ "CustomClassModules": { "BDFDB": { "BDFDBundefined": "BDFDB_undefined", - "accountDetailsButtonDisabled": "disabled-GROwTe", - "accountDetailsButtonEnabled": "enabled-9OeuTA", - "avatarDisabled": "disabled-6G33EE", - "badge": "badge-7R_W3s", - "badgeAvatar": "avatar-hF52Er", - "bdRepo": "repo-k8F4Sd", - "bdRepoEntry": "entry-9JnAPs", - "bdRepoFooterControls": "controls-p0SrvV", - "bdRepoHeaderControls": "controls-18FQsW", - "bdRepoListHeader": "repoHeader-2KfNvH", - "bdRepoListScroller": "repoScroller-9JnAPs", - "cardDisabled": "cardDisabled-wnh5ZW", - "cardHorizontal": "horizontal-0ffRsT", - "cardInner": "inner-OP_8zd", - "cardWrapper": "card-rT4Wbb", - "changeLogButton": "changeLogButton-L9FFs5", - "charCounter": "counter-uAzbKp", - "changeLogModal": "changeLogModal-ny_dHC", - "collapseContainer": "container-fAVkOf", - "collapseContainerCollapsed": "collapsed-2BUBZm", - "collapseContainerHeader": "header-2s6x-5", - "collapseContainerInner": "inner-TkGytd", - "collapseContainerMini": "container-fAVkOf containerMini-_k6Rts", - "collapseContainerTitle": "title-ROsJi-", - "colorPicker": "colorPicker-h5sF8g", - "colorPickerAlpha": "alpha-VcPGeR", + "avatarDisabled": "disabled_6G33EE", + "badge": "badge_7R_W3s", + "badgeAvatar": "avatar_hF52Er", + "bdRepo": "repo_k8F4Sd", + "bdRepoEntry": "entry_9JnAPs", + "bdRepoFooterControls": "controls_p0SrvV", + "bdRepoHeaderControls": "controls_18FQsW", + "bdRepoListHeader": "repoHeader_2KfNvH", + "bdRepoListScroller": "repoScroller_9JnAPs", + "cardDisabled": "cardDisabled_wnh5ZW", + "cardHorizontal": "horizontal_0ffRsT", + "cardInner": "inner_OP_8zd", + "cardWrapper": "card_rT4Wbb", + "changeLogButton": "changeLogButton_L9FFs5", + "charCounter": "counter_uAzbKp", + "changeLogModal": "changeLogModal_ny_dHC", + "collapseContainer": "container_fAVkOf", + "collapseContainerCollapsed": "collapsed_2BUBZm", + "collapseContainerHeader": "header_2s6x-5", + "collapseContainerInner": "inner_TkGytd", + "collapseContainerMini": "container_fAVkOf containerMini__k6Rts", + "collapseContainerTitle": "title_ROsJi-", + "colorPicker": "colorPicker_h5sF8g", + "colorPickerAlpha": "alpha_VcPGeR", "colorPickerAlphaCheckered": "alpha-checkered", - "colorPickerAlphaCursor": "alpha-cursor", + "colorPickerAlphaCursor": "alpha_cursor", "colorPickerAlphaHorizontal": "alpha-horizontal", - "colorPickerGradient": "gradient-TJOYTr", + "colorPickerGradient": "gradient_TJOYTr", "colorPickerGradientCheckered": "gradient-checkered", - "colorPickerGradientCursor": "gradient-cursor", + "colorPickerGradientCursor": "gradient_cursor", "colorPickerGradientCursorEdge": "gradient-cursor-edge", "colorPickerGradientCursorSelected": "gradient-cursor-selected", "colorPickerGradientHorizontal": "gradient-horizontal", - "colorPickerGradientButton": "gradientButton-eBBuwD", - "colorPickerGradientButtonEnabled": "enabled-MypHME", - "colorPickerSwatches": "swatches-QxZw_N", - "colorPickerSwatchesDisabled": "disabled-2JgNxl", - "colorPickerSwatchSelected": "selected-f5IVXN", - "colorPickerSwatchSingle": "single-Fbb1wB", - "colorPickerSwatchSingleWrapper": "swatch-7FsRaa", - "confirmModal": "confirmModal-t-WDWJ", - "cursorPointer": "cursorPointer-B3uwDA", - "dateInputButton": "dateInputButton-jTGUJg", - "dateInputButtonSelected": "selected-8F23Ra", - "dateInputControls": "dateInputControls-cgfPf9", - "dateInputField": "dateInputField-2vhGP1", - "dateInputInner": "dateInputInner-ORXFwT", - "dateInputPreview": "dateInputPreview-lG5sMM", - "dateInputPreviewPrefix": "dateInputPreviewPrefix-6Fww21", - "dateInputPreviewSuffix": "dateInputPreviewSuffix-f4Sr32", - "dateInputWrapper": "dateInputWrapper-6tQOYp", - "dev": "dev-A7f2Rx", - "discoveryCard": "card-x5zW6z", - "discoveryCardAuthor": "author-d2JIcl", - "discoveryCardButton": "button-coQXfM", - "discoveryCardControls": "controls-T0w-Wc", - "discoveryCardCover": "cover-qyY86I", - "discoveryCardCoverBadge": "coverBadge-I41ZIY", - "discoveryCardCoverWrapper": "coverWrapper-J-mDGJ", - "discoveryCardDescription": "description-zXiu5E", - "discoveryCardFooter": "footer-C1KpS6", - "discoveryCardHeader": "header-4hHJgv", - "discoveryCardIcon": "icon-0jmVrJ", - "discoveryCardIconLoading": "loading-f8Gs22", - "discoveryCardIconWrapper": "iconWrapper-eK7GO6", - "discoveryCardInfo": "info-xw-o76", - "discoveryCardName": "name-OSUjF9", - "discoveryCards": "list-QuW8QR", - "discoveryCardStat": "stat-eRknnn", - "discoveryCardStatIcon": "statIcon-o40EX1", - "discoveryCardStats": "stats-Pc5tYW", - "discoveryCardTag": "tag-PbPfwP", - "discoveryCardTags": "tags-9KJ-1X", - "discoveryCardTitle": "title-SSzExd", - "discoveryCardTitleButton": "button-SxdSzE", - "favButtonContainer": "favbutton-8Fzu45", - "guild": "guild-r3yAE_", - "guildLowerLeftBadge": "lowerLeftBadge-zr4T_9", - "guildsLabel": "label-2wRs_g", - "guildSummaryClickableIcon": "clickableIcon-7I6aVc", - "guildSummaryContainer": "container-5VyO4t", - "guildSummaryEmptyGuild": "emptyGuild-Am9XfC", - "guildSummaryIcon": "icon-r6DlKo", - "guildSummaryIconContainer": "iconContainer-IBAtWs", - "guildSummaryIconContainerMasked": "iconContainerMasked-G-akdf iconContainer-IBAtWs", - "guildSummaryMoreGuilds": "moreGuilds-c5JVlC", - "guildSummarySvgIcon": "icon-5TsFrr", - "guildUpperLeftBadge": "upperLeftBadge-e35IpL", - "guildVoiceList": "guildVoiceList-9ads4k", - "hasBadge": "hasBadge-4rT8_u", - "hotkeyResetButton": "resetButton-hI9Ax7", - "hotkeyWrapper": "recorder-can0vx", - "inputNumberButton": "button-J9muv5", - "inputNumberButtonDown": "down-cOY7Qp button-J9muv5", - "inputNumberButtonUp": "up-mUs_72 button-J9muv5", - "inputNumberButtons": "buttons-our3p-", - "inputNumberWrapper": "numberInputWrapper-j4svZS", - "inputNumberWrapperDefault": "numberInputWrapperDefault-gRxcuK numberInputWrapper-j4svZS", - "inputNumberWrapperMini": "numberInputWrapperMini-wtUU31 numberInputWrapper-j4svZS", - "layerContainerZIndexDisabled": "zIndexDisabled-Pf4Txx", - "listInput": "listInput-11g5Sr", - "listInputDelete": "delete-M_nPTt", - "listInputItem": "item-wGC8aX", - "listInputItems": "items-D9PGwH", - "listRow": "listRow-7SfZww", - "loadingIcon": "loadingIcon-cOYMPl", - "loadingIconWrapper": "loadingIconWrapper-PsVJ9m", - "overflowEllipsis": "ellipsis-qlo9sA", - "pagination": "pagination-09Sd5R", - "paginationBottom": "bottom-jTb32i", - "paginationList": "list-PIKebU", - "paginationListAlphabet": "alphabet-2ANo0x", - "paginationListAlphabetChar": "alphabetChar-bq-8Go", - "paginationListAlphabetCharDisabled": "disabled-XmhCq2", - "paginationListContent": "listContent-aG3Fq8", - "paginationListMini": "mini-GMiniS", - "paginationMini": "mini-hODxXf", - "paginationTop": "top-v-18jZ", - "popoutArrow": "popoutArrow-g8f4Ss", - "popoutArrowBottom": "popoutArrowBottom-r5Tzui", - "popoutArrowTop": "popoutArrowTop-lK9F3a", - "popoutWrapper": "popout-xwjvsX", - "quickSelectWrapper": "quickSelectWrapper-UCfTKz", - "marginLeft4": "marginLeft4-58StzA", - "marginLeft8": "marginLeft8-3RhhAa", - "menuColorCustom": "colorCustom-44asd2", - "menuItemHint": "hint-BK71lM", - "modalHeaderShade": "shade-h6F4sT", - "modalHeaderHasSibling": "hasSiblings-fRyjyl", - "modalNoScroller": "noScroller-YgPpF3", - "modalSidebar": "sidebar-_0OpfR", - "modalTabContent": "tabContent-nZ-1U5", - "modalTabContentOpen": "open-yICTYu", - "modalSubInner": "inner-t84Frz", - "modalTextContent": "text-8fSrts", - "modalWrapper": "modal-6GHvdM", - "multiInput": "multiInput-Ft9zQo", - "multiInputField": "multiInputField-GfMBpr", - "multiInputFirst": "multiInputFirst-5rMj_O", - "multiInputLast": "multiInputLast-HWxgTr", - "multiInputWrapper": "multiInputWrapper-g6Srtv", - "noticeClosing": "closing-g5Srr2", - "noticeText": "text-kRs522", - "noticeUpdate": "updateNotice-2DjjHs", - "noticeUpdateButtonAll": "all-iF7Saa", - "noticeUpdateButtonReload": "reload-LkMrac", - "noticeUpdateEntries": "entries-Br6Sda", - "noticeUpdateEntry": "entry-oFts5R", + "colorPickerGradientButton": "gradientButton_eBBuwD", + "colorPickerGradientButtonEnabled": "enabled_MypHME", + "colorPickerSwatches": "swatches_QxZw_N", + "colorPickerSwatchesDisabled": "disabled_2JgNxl", + "colorPickerSwatchSelected": "selected_f5IVXN", + "colorPickerSwatchSingle": "single_Fbb1wB", + "colorPickerSwatchSingleWrapper": "swatch_7FsRaa", + "confirmModal": "confirmModal_t-WDWJ", + "cursorPointer": "cursorPointer_B3uwDA", + "dateInputButton": "dateInputButton_jTGUJg", + "dateInputButtonSelected": "selected_8F23Ra", + "dateInputControls": "dateInputControls_cgfPf9", + "dateInputField": "dateInputField_2vhGP1", + "dateInputInner": "dateInputInner_ORXFwT", + "dateInputPreview": "dateInputPreview_lG5sMM", + "dateInputPreviewPrefix": "dateInputPreviewPrefix_6Fww21", + "dateInputPreviewSuffix": "dateInputPreviewSuffix_f4Sr32", + "dateInputWrapper": "dateInputWrapper_6tQOYp", + "dev": "dev_A7f2Rx", + "discoveryCard": "card_x5zW6z", + "discoveryCardAuthor": "author_d2JIcl", + "discoveryCardButton": "button_coQXfM", + "discoveryCardControls": "controls_T0w-Wc", + "discoveryCardCover": "cover_qyY86I", + "discoveryCardCoverBadge": "coverBadge_I41ZIY", + "discoveryCardCoverWrapper": "coverWrapper_J-mDGJ", + "discoveryCardDescription": "description_zXiu5E", + "discoveryCardFooter": "footer_C1KpS6", + "discoveryCardHeader": "header_4hHJgv", + "discoveryCardIcon": "icon_0jmVrJ", + "discoveryCardIconLoading": "loading_f8Gs22", + "discoveryCardIconWrapper": "iconWrapper_eK7GO6", + "discoveryCardInfo": "info_xw-o76", + "discoveryCardName": "name_OSUjF9", + "discoveryCards": "list_QuW8QR", + "discoveryCardStat": "stat_eRknnn", + "discoveryCardStatIcon": "statIcon_o40EX1", + "discoveryCardStats": "stats_Pc5tYW", + "discoveryCardTag": "tag_PbPfwP", + "discoveryCardTags": "tags_9KJ-1X", + "discoveryCardTitle": "title_SSzExd", + "discoveryCardTitleButton": "button_SxdSzE", + "favButtonContainer": "favbutton_8Fzu45", + "guild": "guild_r3yAE_", + "guildLowerLeftBadge": "lowerLeftBadge_zr4T_9", + "guildsLabel": "label_2wRs_g", + "guildSummaryClickableIcon": "clickableIcon_7I6aVc", + "guildSummaryContainer": "container_5VyO4t", + "guildSummaryEmptyGuild": "emptyGuild_Am9XfC", + "guildSummaryIcon": "icon_r6DlKo", + "guildSummaryIconContainer": "iconContainer_IBAtWs", + "guildSummaryIconContainerMasked": "iconContainerMasked_G-akdf iconContainer_IBAtWs", + "guildSummaryMoreGuilds": "moreGuilds_c5JVlC", + "guildSummarySvgIcon": "icon_5TsFrr", + "guildUpperLeftBadge": "upperLeftBadge_e35IpL", + "guildVoiceList": "guildVoiceList_9ads4k", + "hasBadge": "hasBadge_4rT8_u", + "hotkeyResetButton": "resetButton_hI9Ax7", + "hotkeyWrapper": "recorder_can0vx", + "inputNumberButton": "button_J9muv5", + "inputNumberButtonDown": "down_cOY7Qp button_J9muv5", + "inputNumberButtonUp": "up_mUs_72 button_J9muv5", + "inputNumberButtons": "buttons_our3p-", + "inputNumberWrapper": "numberInputWrapper_j4svZS", + "inputNumberWrapperDefault": "numberInputWrapperDefault_gRxcuK numberInputWrapper_j4svZS", + "inputNumberWrapperMini": "numberInputWrapperMini_wtUU31 numberInputWrapper_j4svZS", + "layerContainerZIndexDisabled": "zIndexDisabled_Pf4Txx", + "listInput": "listInput_11g5Sr", + "listInputDelete": "delete_M_nPTt", + "listInputItem": "item_wGC8aX", + "listInputItems": "items_D9PGwH", + "listRow": "listRow_7SfZww", + "loadingIcon": "loadingIcon_cOYMPl", + "loadingIconWrapper": "loadingIconWrapper_PsVJ9m", + "overflowEllipsis": "ellipsis_qlo9sA", + "pagination": "pagination_09Sd5R", + "paginationBottom": "bottom_jTb32i", + "paginationList": "list_PIKebU", + "paginationListAlphabet": "alphabet_2ANo0x", + "paginationListAlphabetChar": "alphabetChar_bq-8Go", + "paginationListAlphabetCharDisabled": "disabled_XmhCq2", + "paginationListContent": "listContent_aG3Fq8", + "paginationListMini": "mini_GMiniS", + "paginationMini": "mini_hODxXf", + "paginationTop": "top_v-18jZ", + "popoutArrow": "popoutArrow_g8f4Ss", + "popoutArrowBottom": "popoutArrowBottom_r5Tzui", + "popoutArrowTop": "popoutArrowTop_lK9F3a", + "popoutWrapper": "popout_xwjvsX", + "quickSelectWrapper": "quickSelectWrapper_UCfTKz", + "marginLeft4": "marginLeft4_58StzA", + "marginLeft8": "marginLeft8_3RhhAa", + "menuColorCustom": "colorCustom_44asd2", + "menuItemHint": "hint_BK71lM", + "modalHeaderShade": "shade_h6F4sT", + "modalHeaderHasSibling": "hasSiblings_fRyjyl", + "modalNoScroller": "noScroller_YgPpF3", + "modalSidebar": "sidebar__0OpfR", + "modalTabContent": "tabContent_nZ-1U5", + "modalTabContentOpen": "open_yICTYu", + "modalSubInner": "inner_t84Frz", + "modalTextContent": "text_8fSrts", + "modalWrapper": "modal_6GHvdM", + "multiInput": "multiInput_Ft9zQo", + "multiInputField": "multiInputField_GfMBpr", + "multiInputFirst": "multiInputFirst_5rMj_O", + "multiInputLast": "multiInputLast_HWxgTr", + "multiInputWrapper": "multiInputWrapper_g6Srtv", + "noticeClosing": "closing_g5Srr2", + "noticeText": "text_kRs522", + "noticeUpdate": "updateNotice_2DjjHs", + "noticeUpdateButtonAll": "all_iF7Saa", + "noticeUpdateButtonReload": "reload_LkMrac", + "noticeUpdateEntries": "entries_Br6Sda", + "noticeUpdateEntry": "entry_oFts5R", "noticeUpdateText": "notice-message", - "noticeUpdateSeparator": "separator-g5DsaR", - "noticeWrapper": "noticeWrapper-8z511t", - "searchBarWrapper": "searchBarWrapper-1GpKvB", - "selectWrapper": "selectWrapper-yPjeij", - "settingsGuild": "guild-J3Egt5", - "settingsGuildDisabled": "disabled-b2o83O", - "settingsPanel": "settingsPanel-w2ySNR", - "settingsPanelList": "settingsList-eZjkXj", - "settingsPanelListWrapper": "wrapper-kRsR33", - "settingsPanelListWrapperMini": "mini-2Iug3W", - "settingsRow": "settingsRow-o9Ft44", - "settingsTableCard": "settingsTableCard-628t52", - "settingsTableCardConfigs": "settingsTableCardConfigs-w5X9-Z", - "settingsTableCardLabel": "settingsTableCardLabel-MElgIg", - "settingsTableHeaderOptions": "headerOptions-8F_5Ss", - "settingsTableHeaders": "settingsTableHeaders-WKzw9_", - "settingsTableHeaderVertical": "headerVertical-4MNxqk", - "settingsTableList": "settingsTableList-f6sW2y", - "sidebar": "sidebar-frSZx3", - "sidebarContent": "content-1SbgDG", - "sidebarList": "list-VCoBc2", - "sliderBubble": "bubble-3we2di", - "switchMini": "mini-6F2SSa", - "supporter": "supporter-Z3FfwL", - "supporterTier1": "tier1-841W86", - "supporterTier2": "tier2-VDTzC3", - "supporterTier3": "tier3-yTxjsy", - "supporterTier4": "tier4-5RNl6k", - "svgIcon": "icon-GhnIRB", - "svgIconWrapper": "iconWrapper-g20jFn", - "tabBarContainerBottom": "bottom-b8sdfs", - "table": "table-moqjM0", - "tableBodyCell": "bodyCell-dQam9V", - "tableHeaderCell": "headerCell-T6Fo3K", - "textScroller": "textScroller-dc9_kz", - "themedPopout": "themedPopout-1TrfdI", - "tooltipCustom": "tooltipCustom-hH39_Z", - "tooltipNote": "note-e4Jh6_", - "tooltipRowExtra": "extraRow-6F2Dss" + "noticeUpdateSeparator": "separator_g5DsaR", + "noticeWrapper": "noticeWrapper_8z511t", + "searchBarWrapper": "searchBarWrapper_1GpKvB", + "selectWrapper": "selectWrapper_yPjeij", + "settingsGuild": "guild_J3Egt5", + "settingsGuildDisabled": "disabled_b2o83O", + "settingsPanel": "settingsPanel_w2ySNR", + "settingsPanelList": "settingsList_eZjkXj", + "settingsPanelListWrapper": "wrapper_kRsR33", + "settingsPanelListWrapperMini": "mini_2Iug3W", + "settingsRow": "settingsRow_o9Ft44", + "settingsTableCard": "settingsTableCard_628t52", + "settingsTableCardConfigs": "settingsTableCardConfigs_w5X9-Z", + "settingsTableCardLabel": "settingsTableCardLabel_MElgIg", + "settingsTableHeaderOptions": "headerOptions_8F_5Ss", + "settingsTableHeaders": "settingsTableHeaders_WKzw9_", + "settingsTableHeaderVertical": "headerVertical_4MNxqk", + "settingsTableList": "settingsTableList_f6sW2y", + "sidebar": "sidebar_frSZx3", + "sidebarContent": "content_1SbgDG", + "sidebarList": "list_VCoBc2", + "sliderBubble": "bubble_3we2di", + "switchMini": "mini_6F2SSa", + "supporter": "supporter_Z3FfwL", + "supporterTier1": "tier1_841W86", + "supporterTier2": "tier2_VDTzC3", + "supporterTier3": "tier3_yTxjsy", + "supporterTier4": "tier4_5RNl6k", + "svgIcon": "icon_GhnIRB", + "svgIconWrapper": "iconWrapper_g20jFn", + "tabBarContainerBottom": "bottom_b8sdfs", + "table": "table_moqjM0", + "tableBodyCell": "bodyCell_dQam9V", + "tableHeaderCell": "headerCell_T6Fo3K", + "textScroller": "textScroller_dc9_kz", + "themedPopout": "themedPopout_1TrfdI", + "tooltipCustom": "tooltipCustom_hH39_Z", + "tooltipNote": "note_e4Jh6_", + "tooltipRowExtra": "extraRow_6F2Dss" }, "BD": { "bdAddonCard": "bd-addon-card", @@ -1084,298 +1016,292 @@ "switchWrapper": "ui-switch-wrapper" }, "BetterFriendList": { - "mutualGuilds": "mutualGuilds-s7F2aa", - "nameCell": "nameCell-7F4sRs", - "title": "title-3aDrFs" + "mutualGuilds": "mutualGuilds_s7F2aa", + "nameCell": "nameCell_7F4sRs", + "title": "title_3aDrFs" }, "BetterNsfwTag": { - "nsfwTag": "nsfwTag-666omg" + "nsfwTag": "nsfwTag_666omg" }, "BetterSearchPage": { - "pagination": "pagination-shit69" + "pagination": "pagination_shit69" }, "ChatFilter": { - "blocked": "blocked-jUhayi", - "blockedStamp": "blockedStamp-ijVeNn", - "censored": "censored-UYfeYg", - "censoredStamp": "censoredStamp-fb2cYb" + "blocked": "blocked_jUhayi", + "blockedStamp": "blockedStamp_ijVeNn", + "censored": "censored_UYfeYg", + "censoredStamp": "censoredStamp_fb2cYb" }, "CharCounter": { - "charCounter": "charCounter-7fw40k", - "chatCounter": "chatCounter-XOMPsh", - "counterAdded": "charCounterAdded-zz9O4t", - "customStatusCounter": "customStatusCounter-G8FrsT", - "editCounter": "editCounter-pNT1Xe", - "popoutNoteCounter": "popoutNoteCounter-62U4Rh", - "profileNoteCounter": "profileNoteCounter-p0fWA_", - "threadCreation": "threadCreation-p0fWA_", - "uploadCounter": "uploadCounter-iEGQQk" + "charCounter": "charCounter_7fw40k", + "chatCounter": "chatCounter_XOMPsh", + "counterAdded": "charCounterAdded_zz9O4t", + "customStatusCounter": "customStatusCounter_G8FrsT", + "editCounter": "editCounter_pNT1Xe", + "popoutNoteCounter": "popoutNoteCounter_62U4Rh", + "profileNoteCounter": "profileNoteCounter_p0fWA_", + "threadCreation": "threadCreation_p0fWA_", + "uploadCounter": "uploadCounter_iEGQQk" }, "CustomStatusPresets": { - "customStatusItem": "customStatusItem-f5Trsa", - "deleteButton": "deleteButton-k8a4Sa", - "deleteIcon": "deleteIcon-22SgHa", - "dragPreview": "dragPreview-3F0ssT", - "sortableCard": "sortableCard-oF6sTT", - "sortDivider": "sortDivider-d8SzzU", - "status": "status-0f5Sr2" + "customStatusItem": "customStatusItem_f5Trsa", + "deleteButton": "deleteButton_k8a4Sa", + "deleteIcon": "deleteIcon_22SgHa", + "dragPreview": "dragPreview_3F0ssT", + "sortableCard": "sortableCard_oF6sTT", + "sortDivider": "sortDivider_d8SzzU", + "status": "status_0f5Sr2" }, "DisplayServersAsChannels": { - "badge": "badge-fxFrUP", - "muted": "muted-k5Fraa", - "name": "name-z5133D", - "styled": "styledGuildsAsChannels-DNHtg_" + "badge": "badge_fxFrUP", + "muted": "muted_k5Fraa", + "name": "name_z5133D", + "styled": "styledGuildsAsChannels_DNHtg_" }, "EmojiStatistics": { - "amountCell": "amountCell-g_W6Rx", - "iconCell": "iconCell--wniOu", - "nameCell": "nameCell-xyXENZ", - "statisticsButton": "statisticsButton-nW2KoM" + "amountCell": "amountCell_g_W6Rx", + "iconCell": "iconCell_-wniOu", + "nameCell": "nameCell_xyXENZ", + "statisticsButton": "statisticsButton_nW2KoM" }, "FriendNotifications": { - "friendsOnline": "friendsOnline-2JkivW", - "friendsOnlineWrap": "friendsOnlineWrap-0gZ63m", - "logAvatar": "avatar-GgGssS", - "logContent": "content-_3_FFs", - "logTime": "time-00Fs44", - "timeLogModal": "timeLogModal-9s4Rts", - "typeLabel": "label-9FgsSa" + "friendsOnline": "friendsOnline_2JkivW", + "friendsOnlineWrap": "friendsOnlineWrap_0gZ63m", + "logAvatar": "avatar_GgGssS", + "logContent": "content__3_FFs", + "logTime": "time_00Fs44", + "timeLogModal": "timeLogModal_9s4Rts", + "typeLabel": "label_9FgsSa" }, "GameActivityToggle": { - "added": "gameActivityToggleAdded-Yd-YxC" + "added": "gameActivityToggleAdded_Yd-YxC" }, "ImageUtilities": { - "details": "details-9dkFPc", - "detailsAdded": "detailsAdded-fHiJlm", - "detailsLabel": "label-mrlccN", - "detailsWrapper": "detailsWrapper-TE1mu5", - "gallery": "gallery-JViwKR", - "imageDetails": "imageDetails-1t6Zms", - "imageDetailsAdded": "imageDetailsAdded-sda9Fa", - "lens": "zoomLens-uOK8xV", - "lensBackdrop": "lensBackdrop-yEm7Om", - "next": "next-SHEZrz", - "operations": "operations-3V47CY", - "previous": "previous-xsNq6B", - "sibling": "sibling-6vI7Pu", - "switchIcon": "switchIcon-QY6cR4" + "details": "details_9dkFPc", + "detailsAdded": "detailsAdded_fHiJlm", + "detailsLabel": "label_mrlccN", + "detailsWrapper": "detailsWrapper_TE1mu5", + "gallery": "gallery_JViwKR", + "imageDetails": "imageDetails_1t6Zms", + "imageDetailsAdded": "imageDetailsAdded_sda9Fa", + "lens": "zoomLens_uOK8xV", + "lensBackdrop": "lensBackdrop_yEm7Om", + "next": "next_SHEZrz", + "operations": "operations_3V47CY", + "previous": "previous_xsNq6B", + "sibling": "sibling_6vI7Pu", + "switchIcon": "switchIcon_QY6cR4" }, "LastMessageDate": { - "icon": "icon-ocEw13" + "icon": "icon_ocEw13" }, "OldTitleBar": { - "oldTitleBarEnabled": "oldTitleBarEnabled-D8ppJQ", - "settingsToolbar": "settingsToolbar-wu4yfQ", - "toolbar": "toolbar-hRzFw-" + "oldTitleBarEnabled": "oldTitleBarEnabled_D8ppJQ", + "settingsToolbar": "settingsToolbar_wu4yfQ", + "toolbar": "toolbar_hRzFw-" }, "PersonalPins": { - "messageTag": "messageTag-yRSUYg", - "messageTagAdd": "messageTagAdd-vKM0VY", - "messageTagAddActive": "active-G0VvAY", - "messageTagDelete": "messageTagDelete-QaGh6V", - "messageTagName": "messageTagName-dT8OZ4" + "messageTag": "messageTag_yRSUYg", + "messageTagAdd": "messageTagAdd_vKM0VY", + "messageTagAddActive": "active_G0VvAY", + "messageTagDelete": "messageTagDelete_QaGh6V", + "messageTagName": "messageTagName_dT8OZ4" }, "PinDMs": { - "dragPreview": "dragPreview-nXiByA", - "dmChannelPinned": "pinned-0lM4wD", - "dmChannelPlaceholder": "placeholder-7bhR5s", - "pinnedChannelsHeaderAmount": "headerAmount-_-7GrS", - "pinnedChannelsHeaderArrow": "pinnedChannelsHeaderArrow-44rrTz", - "pinnedChannelsHeaderCollapsed": "collapsed-3w_-ff", - "pinnedChannelsHeaderColored": "colored-oIzG5s", - "pinnedChannelsHeaderContainer": "pinnedChannelsHeaderContainer-89Gjv4", - "recentPinned": "pinned-jHvFrr", - "recentPlaceholder": "placeholder-Uff-gH", - "unpinButton": "unpinButton-z3-UVO", - "unpinIcon": "unpinIcon-79ZnEr" + "dragPreview": "dragPreview_nXiByA", + "dmChannelPinned": "pinned_0lM4wD", + "dmChannelPlaceholder": "placeholder_7bhR5s", + "pinnedChannelsHeaderAmount": "headerAmount__-7GrS", + "pinnedChannelsHeaderArrow": "pinnedChannelsHeaderArrow_44rrTz", + "pinnedChannelsHeaderCollapsed": "collapsed_3w_-ff", + "pinnedChannelsHeaderColored": "colored_oIzG5s", + "pinnedChannelsHeaderContainer": "pinnedChannelsHeaderContainer_89Gjv4", + "recentPinned": "pinned_jHvFrr", + "recentPlaceholder": "placeholder_Uff-gH", + "unpinButton": "unpinButton_z3-UVO", + "unpinIcon": "unpinIcon_79ZnEr" }, "PluginRepo": { - "failNotice": "failNotice-OtHUGb", - "loadingIcon": "loadingIcon-dB3qSe", - "loadingTooltip": "loadingTooltip-SzsTEU", - "newEntriesNotice": "newEntriesNotice-qvvpPx", - "outdatedNotice": "outdatedNotice-9Q9gJv", - "repoNotice": "repoNotice-P5ss6R" + "failNotice": "failNotice_OtHUGb", + "loadingIcon": "loadingIcon_dB3qSe", + "loadingTooltip": "loadingTooltip_SzsTEU", + "newEntriesNotice": "newEntriesNotice_qvvpPx", + "outdatedNotice": "outdatedNotice_9Q9gJv", + "repoNotice": "repoNotice_P5ss6R" }, "ReadAllNotificationsButton": { - "button": "button-Jt-tIg", - "frame": "frame-oXWS21", - "innerFrame": "innerFrame-8Hg64E" + "button": "button_Jt-tIg", + "frame": "frame_oXWS21", + "innerFrame": "innerFrame_8Hg64E" }, "ServerCounter": { - "serverCount": "serverCount-FsTTs1", - "serverCountWrap": "serverCountWrap-k8F5De" + "serverCount": "serverCount_FsTTs1", + "serverCountWrap": "serverCountWrap_k8F5De" }, "ServerDetails": { - "details": "details-08FrsT", - "icon": "icon-hSL42R", - "tooltip": "detailsTooltip-G9hSSa" + "details": "details_08FrsT", + "icon": "icon_hSL42R", + "tooltip": "detailsTooltip_G9hSSa" }, "ServerFolders": { - "dragPreview": "dragPreview-nXiByA", - "folderContent": "content-Pph8t6", - "folderContentClosed": "closed-j55_T-", - "folderContentIsOpen": "folderContentIsOpen-zz6FgW", - "guildPlaceholder": "placeholder-7bhR5s", - "hasSideBar": "hasSideBar-sda9Fa", - "iconSwatch": "iconSwatch-_78Ghj", - "iconSwatchInner": "iconInner-aOY-qk", - "iconSwatchPreview": "preview-Bbg_24", - "iconSwatchNoPreview": "noPreview-G8SS4t", - "iconSwatchSelected": "selected-P5oePO" + "dragPreview": "dragPreview_nXiByA", + "folderContent": "content_Pph8t6", + "folderContentClosed": "closed_j55_T-", + "folderContentIsOpen": "folderContentIsOpen_zz6FgW", + "guildPlaceholder": "placeholder_7bhR5s", + "hasSideBar": "hasSideBar_sda9Fa", + "iconSwatch": "iconSwatch__78Ghj", + "iconSwatchInner": "iconInner_aOY-qk", + "iconSwatchPreview": "preview_Bbg_24", + "iconSwatchNoPreview": "noPreview_G8SS4t", + "iconSwatchSelected": "selected_P5oePO" }, "SpellCheck": { - "error": "error-k9z2IV", - "overlay": "spellCheckOverlay-cNSap5" + "error": "error_k9z2IV", + "overlay": "spellCheckOverlay_cNSap5" }, "ShowBadgesInChat": { - "badges": "badges-XRnWAp", - "badgesChat": "badgesChat-f_cbR8", - "badgesDMs": "badgesDMs-Aw_p52", - "badgesMembers": "badgesMembers-8Kf3S1", - "badgesSettings": "badgesSettings-ychoGn", - "indicator": "indicator-8F4GGw" + "badges": "badges_XRnWAp", + "badgesChat": "badgesChat_f_cbR8", + "badgesDMs": "badgesDMs_Aw_p52", + "badgesMembers": "badgesMembers_8Kf3S1", + "badgesSettings": "badgesSettings_ychoGn", + "indicator": "indicator_8F4GGw" }, "ShowConnections": { - "connection": "connection-9Gh4sa", - "connectionIcon": "connectionIcon-888F4s", - "connections": "connections-pPr4as", - "verifiedBadge": "verifiedBadge-mH2YpO" + "connection": "connection_9Gh4sa", + "connectionIcon": "connectionIcon_888F4s", + "connections": "connections_pPr4as", + "verifiedBadge": "verifiedBadge_mH2YpO" }, "SpotifyControls": { - "activityButton": "activityButton-5Fs4Aa", - "bar": "bar-g2ZMIm", - "barGabber": "grabber-7sd5f5", - "barFill": "barFill-Dhkah7", - "barText": "barText-lmqc5O", - "buttonActive": "active-6TsW-_", - "container": "container-6sXIoE", - "containerInner": "inner-WRV6k5", - "containerMaximized": "maximized-vv2Wr0", - "containerWithTimeline": "withTimeline-824fT_", - "cover": "cover-SwJ-ck", - "coverMaximizer": "maximizer-RVu85p", - "coverWrapper": "coverWrapper-YAplwJ", - "details": "details-ntX2k5", - "interpret": "interpret-F93iqP", - "settingsIcon": "icon-F4SSra", - "settingsLabel": "label-3f00Sr", - "song": "song-tIdBpF", - "timeline": "timeline-UWmgAx", - "volumeSlider": "volumeSlider-sR5g00" + "activityButton": "activityButton_5Fs4Aa", + "bar": "bar_g2ZMIm", + "barGabber": "grabber_7sd5f5", + "barFill": "barFill_Dhkah7", + "barText": "barText_lmqc5O", + "buttonActive": "active_6TsW-_", + "container": "container_6sXIoE", + "containerInner": "inner_WRV6k5", + "containerMaximized": "maximized_vv2Wr0", + "containerPaused": "paused_l9f3As", + "containerWithTimeline": "withTimeline_824fT_", + "cover": "cover_SwJ-ck", + "coverMaximizer": "maximizer_RVu85p", + "coverWrapper": "coverWrapper_YAplwJ", + "details": "details_ntX2k5", + "interpret": "interpret_F93iqP", + "settingsIcon": "icon_F4SSra", + "settingsLabel": "label_3f00Sr", + "song": "song_tIdBpF", + "timeline": "timeline_UWmgAx", + "volumeSlider": "volumeSlider_sR5g00" }, "StaffTag": { - "adminIcon": "admin-Kv1Hp_", - "forumCreatorIcon": "forumCreator-5sOT2A", - "groupOwnerIcon": "groupOwner-g6FlmA", - "managementIcon": "management-3fF_o8", - "ownerIcon": "owner-FfFh3B", - "threadCreatorIcon": "threadCreator-lp5sXo" + "adminIcon": "admin_Kv1Hp_", + "forumCreatorIcon": "forumCreator_5sOT2A", + "groupOwnerIcon": "groupOwner_g6FlmA", + "managementIcon": "management_3fF_o8", + "ownerIcon": "owner_FfFh3B", + "threadCreatorIcon": "threadCreator_lp5sXo" }, "ThemeRepo": { - "dragBar": "dragBar-4FsRaa", - "dragCorner": "dragCorner-PgJJk2", - "dragInterface": "dragInterface-OT5s2A", - "failNotice": "failNotice-pZAzjZ", - "loadingIcon": "loadingIcon-h7OqHY", - "loadingTooltip": "loadingTooltip-YszEmb", - "moveBar": "moveBar-lZ555a", - "newEntriesNotice": "newEntriesNotice-abF6e1", - "preview": "preview-7Gh5tS", - "previewFullscreen": "fullscreen-h78TsW", - "previewMoving": "moving-Wa22fA", - "outdatedNotice": "outdatedNotice-fw8ams", - "repoNotice": "repoNotice-TV3RFr" + "dragBar": "dragBar_4FsRaa", + "dragCorner": "dragCorner_PgJJk2", + "dragInterface": "dragInterface_OT5s2A", + "failNotice": "failNotice_pZAzjZ", + "loadingIcon": "loadingIcon_h7OqHY", + "loadingTooltip": "loadingTooltip_YszEmb", + "moveBar": "moveBar_lZ555a", + "newEntriesNotice": "newEntriesNotice_abF6e1", + "preview": "preview_7Gh5tS", + "previewFullscreen": "fullscreen_h78TsW", + "previewMoving": "moving_Wa22fA", + "outdatedNotice": "outdatedNotice_fw8ams", + "repoNotice": "repoNotice_TV3RFr" }, "ThemeSettings": { - "card": "card-h4Rts2", - "cardName": "card-jdf7Rs", - "grid": "settingsButton-60jFra" + "card": "card_h4Rts2", + "cardName": "card_jdf7Rs", + "grid": "settingsButton_60jFra" }, "TimedLightDarkMode": { - "dateGrabber": "dateGrabber-QrRkIX", - "timerGrabber": "timerGrabber-zpRAIk", - "timerSettings": "timerSettings-wkvEfF" + "dateGrabber": "dateGrabber_QrRkIX", + "timerGrabber": "timerGrabber_zpRAIk", + "timerSettings": "timerSettings_wkvEfF" }, "TopRolesEverywhere": { - "badgeStyle": "badgeStyle-tFiEQ8", - "chatTag": "chatTag-Y-5TDc", - "memberTag": "memberTag-QVWzGc", - "roleStyle": "roleStyle-jQ7KI2", - "tag": "tag-wWVHyf", - "voiceTag": "voiceTag-0F4Ss0" + "badgeStyle": "badgeStyle_tFiEQ8", + "chatTag": "chatTag_Y-5TDc", + "memberTag": "memberTag_QVWzGc", + "roleStyle": "roleStyle_jQ7KI2", + "tag": "tag_wWVHyf", + "voiceTag": "voiceTag_0F4Ss0" }, "Translator": { - "configButton": "configButton-lLgMs2", - "translateButton": "translateButton-DhP9x8", - "translated": "translated-5YO8i3", - "translating": "translating-Yi-YxC" + "configButton": "configButton_lLgMs2", + "translateButton": "translateButton_DhP9x8", + "translated": "translated_5YO8i3", + "translating": "translating_Yi-YxC" }, "WriteUpperCase": { - "enabled": "enabled-7KI3Q2", - "quickToggleButton": "quickToggleButton-P2xDh8" + "enabled": "enabled_7KI3Q2", + "quickToggleButton": "quickToggleButton_P2xDh8" }, "NotFound": { "_": "", - "accountDetailsButton": "button-12Fmur", "emoji": "emoji", + "carouselModal": "carouselModal_c0d5b7", "highlight": "highlight", - "hoverCardButton": "button-1yVL_7", - "loginScreen": "wrapper-1f5byN", + "hoverCardButton": "button_1yVL_7", + "loginScreen": "wrapper_eebc2d", "mention": "mention", "mentionInteractive": "interactive", - "mentionWrapper": "wrapper-1ZcZW-", - "messagesLoadingWrapper": "wrapper-3HVHpV", - "nameContainer": "container-32HW5s", - "nameContainerNameContainer": "container-q97qHp", - "hueCursor": "hue-cursor", + "mentionWrapper": "wrapper_f46140", + "messagesLoadingWrapper": "wrapper_b8c724", + "nameContainer": "container__4f20e", + "nameContainerNameContainer": "container_de798d", + "hueCursor": "hue_cursor", "hueHorizontal": "hue-horizontal", "hueVertical": "hue-vertical", "saturationBlack": "saturation-black", "saturationColor": "saturation-color", "saturationCursor": "saturation-cursor", "saturationWhite": "saturation-white", - "searchResultsPagination": "container-1-h9mY", - "splashBackground": "splashBackground-1FRCko", + "searchResultsPagination": "container__68284", "stopAnimations": "stop-animations", - "subtext": "subtext-2HDqJ7", + "subtext": "subtext__8f869", + "themeCustomBackground": "custom-theme-background", "themeDark": "theme-dark", "themeLight": "theme-light", "themeUndefined": "theme-undefined", - "userPopoutNote": "note-6O4w9y", - "voiceDraggable": "draggable-1KoBzC" - }, - "ModalCarousel": { - "carouselModal": "carouselModal-1eUFoq", - "nav": "nav-3QIE8_", - "navNext": "navNext-1mR5ku nav-3QIE8_", - "navPrev": "navPrev-1L-o1J nav-3QIE8_" + "userPopoutNote": "note_6O4w9y" }, "Toast": { - "avatar": "avatar-3xmbmC", - "bar": "bar-95Sdw1", - "barInner": "barInner-u7Frsw", - "bg": "bg-8df5St", - "brand": "colorBrand-WfDfzD", - "center": "center-9SpJeg", - "closable": "closable-7ShrRt", - "closeIcon": "closeIcon-8R553s", - "closing": "closing-K489s7", - "custom": "colorCustom-WKsPgT", - "customBar": "customBar-3RsUzs", - "danger": "colorDanger-O5wq9n", - "default": "colorDefault-XdNdIp", - "icon": "icon-OZgBPQ", - "info": "colorInfo-ujWH4-", - "inner": "inner-6Fsw34", - "left": "left-IXnX5I", - "opening": "opening-3TzSw2", - "right": "right-Eka_pI", - "success": "colorSuccess-6GreWs", - "text": "text-28VADE", - "toast": "toast-g4bfgI", - "toasts": "toasts-tApoHv", - "warning": "colorWarning-qZNMsx" + "avatar": "avatar_3xmbmC", + "bar": "bar_95Sdw1", + "barInner": "barInner_u7Frsw", + "bg": "bg_8df5St", + "brand": "colorBrand_WfDfzD", + "center": "center_9SpJeg", + "closable": "closable_7ShrRt", + "closeIcon": "closeIcon_8R553s", + "closing": "closing_K489s7", + "custom": "colorCustom_WKsPgT", + "customBar": "customBar_3RsUzs", + "danger": "colorDanger_O5wq9n", + "default": "colorDefault_XdNdIp", + "icon": "icon_OZgBPQ", + "info": "colorInfo_ujWH4-", + "inner": "inner_6Fsw34", + "left": "left_IXnX5I", + "opening": "opening_3TzSw2", + "right": "right_Eka_pI", + "success": "colorSuccess_6GreWs", + "text": "text_28VADE", + "toast": "toast_g4bfgI", + "toasts": "toasts_tApoHv", + "warning": "colorWarning_qZNMsx" } }, "DiscordClassModules": { @@ -1383,7 +1309,7 @@ "AccountDetailsButtons": {"props": ["button", "enabled", "disabled"]}, "Anchor": {"props": ["anchor", "anchorUnderlineOnHover"]}, "AnimationContainer": {"props": ["animatorLeft", "didRender"]}, - "AppBase": {"props": ["container", "base"]}, + "AppBase": {"props": ["container", "base", "panels"]}, "AppInner": {"props": ["app", "layers"]}, "AppMount": {"props": ["appMount"]}, "ApplicationStore": {"props": ["applicationStore", "navigation"]}, @@ -1391,7 +1317,8 @@ "Attachment": {"props": ["wrapper", "video", "metadataDownload"]}, "AttachmentCover": {"props": ["cover", "icon", "iconWrapper"]}, "AuditLog": {"props": ["auditLog", "divider"]}, - "AuthBox": {"props": ["authBox"]}, + "AuthBox": {"props": ["authBox", "authBoxExpanded"]}, + "AuthBoxBackground": {"props": ["splashBackground", "characterBackground"]}, "Autocomplete": {"props": ["autocomplete", "autocompleteRow"]}, "AutocompleteAliases": {"props": ["autocomplete", "stickerAutoComplete"]}, "Avatar": {"props": ["avatar", "mask", "wrapper"]}, @@ -1403,11 +1330,12 @@ "CallCurrent": {"props": ["wrapper", "fullScreen"]}, "CallDetails": {"props": ["container", "hotspot"]}, "CallIncoming": {"props": ["wrapper", "mainChannelInfo"]}, + "CallScreenshare": {"props": ["videoControls", "topControls", "screenMessage"]}, "Card": {"props": ["card", "cardBrand"]}, "Category": {"props": ["wrapper", "children", "addButtonIcon"]}, "CategoryArrow": {"props": ["arrow", "open"]}, "ChangeLog": {"props": ["added", "fixed", "improved", "progress"]}, - "Channel": {"props": ["wrapper", "content", "modeSelected"]}, + "Channel": {"props": ["wrapper", "newBadge", "modeSelected"]}, "ChannelContainer": {"props": ["actionIcon", "containerDefault"]}, "ChannelContainerMentionsBadge": {"props": ["mentionsBadge", "iconBase"]}, "ChannelLimit": {"props": ["users", "total", "wrapper"]}, @@ -1436,6 +1364,7 @@ "Emoji": {"props": ["emoji"], "length": 1}, "EmojiButton": {"props": ["emojiButton", "sprite"]}, "EmojiPicker": {"props": ["emojiPicker", "inspector"]}, + "EmojiPickerCustomEmoji": {"props": ["image", "imageLoading"]}, "EmojiPickerDiversitySelector": {"props": ["diversityEmojiItemImage", "diversitySelectorOptions"]}, "EmojiPickerItem": {"props": ["emojiSpriteImage"]}, "EmojiPickerInspector": {"props": ["inspector", "graphicPrimary"]}, @@ -1463,7 +1392,7 @@ "GuildFolder": {"props": ["folder", "expandedFolderIconWrapper"]}, "GuildHeader": {"props": ["header", "name", "bannerImage"]}, "GuildHeaderButton": {"props": ["button", "open"]}, - "GuildItem": {"props": ["listItem", "participating"], "length": 10, "smaller": true}, + "GuildItem": {"props": ["listItem", "serverEmoji"]}, "GuildIcon": {"props": ["acronym", "selected", "wrapper"]}, "GuildInvite": {"props": ["wrapper", "guildIconJoined"]}, "GuildsButton": {"props": ["circleIconButton", "circleIcon"], "length": 6, "smaller": true}, @@ -1509,7 +1438,7 @@ "MembersWrapper": {"props": ["membersWrap", "membersGroup"]}, "Message": {"props": ["message", "mentioned"]}, "MessageAccessory": {"props": ["embedWrapper", "gifFavoriteButton"]}, - "MessageAttachment": {"props": ["hiddenSpoilers", "spoiler"]}, + "MessageAttachment": {"props": ["removeAttachmentButton", "inline"]}, "MessageBlocked": {"props": ["blockedMessageText", "expanded"]}, "MessageBody": {"props": ["markupRtl", "edited"]}, "MessageDivider": {"props": ["isUnread", "divider"]}, @@ -1524,7 +1453,7 @@ "MessageReply": {"props": ["container", "text", "closeButton"]}, "MessagesPopout": {"props": ["messagesPopoutWrap", "jumpButton"]}, "MessagesPopoutButtons": {"props": ["secondary", "tertiary", "button"]}, - "MessagesPopoutTabBar": {"props": ["header", "tabBar", "active"]}, + "MessagesPopoutTabBar": {"props": ["header", "tabBar", "active", "controls"]}, "MessagesLoading": {"props": ["attachment", "blob", "cozy"]}, "MessagesWelcome": {"props": ["emptyChannelIcon", "description", "header"]}, "MessagesWelcomeButton": {"props": ["button", "buttonIcon"], "length": 2}, @@ -1535,10 +1464,12 @@ "MessageToolbar": {"props": ["container", "icon", "isHeader"]}, "MessageToolbarItems": {"props": ["wrapper", "button", "separator"]}, "Modal": {"props": ["root", "small", "medium"]}, + "ModalCarouselNav": {"props": ["nav", "navNext"]}, "ModalCarouselWrapper": {"props": ["modalCarouselWrapper", "zoomedCarouselModalRoot"]}, "ModalDivider": {"props": ["divider"], "length": 1}, "ModalItems": {"props": ["guildName", "checkboxContainer"]}, - "ModalMiniContent": {"props": ["modal", "content", "maxModalWidth"]}, + "ModalLayer": {"props": ["layer", "hidden", "backdrop"]}, + "ModalMiniContent": {"props": ["modal", "content"], "length": 2}, "ModalSub": {"props": ["modal", "sizeLarge"]}, "NameContainer": {"props": ["nameAndDecorators", "name"]}, "NameContainerState": {"props": ["interactive", "selected", "muted"]}, @@ -1547,6 +1478,7 @@ "NoteTextarea": {"props": ["textarea"], "length": 1}, "Notice": {"props": ["notice", "platformIcon"]}, "NoticePlatform": {"props": ["iconAndroid", "textLink"]}, + "PageImage": {"props": ["title", "image", "wrapper", "text"], "length": 5, "smaller": true}, "Pagination": {"props": ["pageButton", "pageControl"]}, "PeopleItem": {"props": ["peopleListItem", "active"]}, "PeopleItemInfo": {"props": ["listItemContents", "actions"], "length": 2}, @@ -1581,9 +1513,8 @@ "SearchResultsElements": {"props": ["totalResults", "searchHeaderTabList"]}, "SearchResultsGroup": {"props": ["searchResultGroup", "channelNameContainer"]}, "SearchResultsMessage": {"props": ["message", "searchResult"]}, - "Select": {"props": ["select", "error", "errorMessage"]}, + "Select": {"props": ["searchable", "option", "selectedIcon"]}, "SelectFilterPopout": {"props": ["selectFilterPopout", "avatar", "row"]}, - "SelectSearchable": {"props": ["searchable", "option", "selectedIcon"]}, "SettingsCloseButton": {"props": ["closeButton", "keybind"]}, "SettingsItems": {"props": ["labelRow", "note"]}, "SettingsTable": {"props": ["headerOption", "headerName"]}, @@ -1595,6 +1526,7 @@ "Switch": {"props": ["container", "slider", "input"]}, "Table": {"props": ["stickyHeader", "sortIcon"]}, "Text": {"props": ["defaultColor", "defaultMarginh1"]}, + "Text2": {"props": ["defaultColor", "selectable", "lineClamp1"]}, "TextColor": {"props": ["colorStandard", "colorMuted", "colorError"]}, "TextColor2": {"props": ["muted", "wrapper", "base"]}, "TextSize": {"props": ["size10", "size14", "size20"]}, @@ -1612,7 +1544,7 @@ "UserPopoutFooter": {"props": ["wumpusTooltip", "messageInputContainer"]}, "UserPopoutHeader": {"props": ["avatarHint", "profileBadges", "avatarWrapper"]}, "UserPopoutSection": {"props": ["section", "lastSection"]}, - "UserPopoutSectionTitle": {"props": ["title", "body"], "length": 2}, + "UserPopoutSectionTitle": {"props": ["title", "body", "clydeMoreInfo"]}, "UserPopoutUsernameSection": {"props": ["userTagNoNickname", "nickname", "headerBotTag"]}, "UserProfile": {"props": ["root", "tabBarContainer"]}, "UserProfileHeader": {"props": ["additionalActionsIcon", "header", "relationshipButtons"]}, @@ -1765,6 +1697,7 @@ "_spotifycontrolscontainer": ["SpotifyControls", "container"], "_spotifycontrolscontainerinner": ["SpotifyControls", "containerInner"], "_spotifycontrolscontainermaximized": ["SpotifyControls", "containerMaximized"], + "_spotifycontrolscontainerpaused": ["SpotifyControls", "containerPaused"], "_spotifycontrolscontainerwithtimeline": ["SpotifyControls", "containerWithTimeline"], "_spotifycontrolscover": ["SpotifyControls", "cover"], "_spotifycontrolscovermaximizer": ["SpotifyControls", "coverMaximizer"], @@ -1858,9 +1791,9 @@ "accountinfo": ["AccountDetails", "container"], "accountinfoavatar": ["AccountDetails", "avatar"], "accountinfoavatarwrapper": ["AccountDetails", "avatarWrapper"], - "accountinfobutton": ["NotFound", "accountDetailsButton"], - "accountinfobuttondisabled": ["BDFDB", "accountDetailsButtonDisabled"], - "accountinfobuttonenabled": ["BDFDB", "accountDetailsButtonEnabled"], + "accountinfobutton": ["AccountDetailsButtons", "button"], + "accountinfobuttondisabled": ["AccountDetailsButtons", "disabled"], + "accountinfobuttonenabled": ["AccountDetailsButtons", "enabled"], "accountinfobuttonstrikethrough": ["AccountDetails", "strikethrough"], "accountinfodetails": ["AccountDetails", "usernameContainer"], "accountinfonametag": ["AccountDetails", "nameTag"], @@ -1895,6 +1828,8 @@ "auditlogtimestamp": ["AuditLog", "timestamp"], "auditloguserhook": ["AuditLog", "userHook"], "authbox": ["AuthBox", "authBox"], + "authboxcharacterbackground": ["AuthBoxBackground", "characterBackground"], + "authboxsplashbackground": ["AuthBoxBackground", "splashBackground"], "autocomplete": ["Autocomplete", "autocomplete"], "autocompletecontenttitle": ["Autocomplete", "contentTitle"], "autocompletedescriptiondiscriminator": ["Autocomplete", "descriptionDiscriminator"], @@ -2010,6 +1945,10 @@ "callincomingroot": ["CallIncoming", "root"], "callincomingtitle": ["CallIncoming", "title"], "callincomingwrapper": ["CallIncoming", "wrapper"], + "callscreensharebottomcontrols": ["CallScreenshare", "bottomControls"], + "callscreensharechatbutton": ["CallScreenshare", "chatButton"], + "callscreensharetopcontrols": ["CallScreenshare", "topControls"], + "callscreensharevideocontrols": ["CallScreenshare", "videoControls"], "card": ["Card", "card"], "cardbrand": ["Card", "cardBrand"], "cardbrandoutline": ["Card", "cardBrandOutline"], @@ -2051,8 +1990,8 @@ "channelchildiconbase": ["ChannelContainer", "iconBase"], "channelchildren": ["Channel", "children"], "channelcontainerdefault": ["ChannelContainer", "containerDefault"], - "channelcontent": ["Channel", "content"], - "channeldisabled": ["ChannelContainer", "disabled"], + "channelcontent": ["Channel", "link"], + "channelheaderavatar": ["ChatWindow", "avatar"], "channelheaderchannelname": ["ChatWindow", "channelName"], "channelheaderchildren": ["HeaderBar", "children"], "channelheadercursorpointer": ["ChatWindow", "cursorPointer"], @@ -2080,7 +2019,6 @@ "channeliconitem": ["ChannelContainer", "iconItem"], "channeliconvisibility": ["ChannelContainer", "iconVisibility"], "channelinfo": ["ChannelContainer", "channelInfo"], - "channelmaincontent": ["Channel", "mainContent"], "channelmentionsbadge": ["ChannelContainerMentionsBadge", "mentionsBadge"], "channelmentionsbadgebase": ["ChannelContainerMentionsBadge", "iconBase"], "channelmodeconnected": ["Channel", "modeConnected"], @@ -2089,7 +2027,6 @@ "channelmodeselected": ["Channel", "modeSelected"], "channelmodeunread": ["Channel", "modeUnread"], "channelname": ["Channel", "name"], - "channelnameinner": ["Channel", "channelName"], "channelpanel": ["AppBase", "activityPanel"], "channelpanels": ["AppBase", "panels"], "channels": ["AppBase", "sidebar"], @@ -2101,6 +2038,7 @@ "channelsunreadbarunread": ["GuildChannels", "unread"], "channelsunreadbartop": ["GuildChannels", "unreadTop"], "channelunread": ["Channel", "unread"], + "channelunreadrelevant": ["Channel", "unreadRelevant"], "channeluserlimit": ["ChannelLimit", "wrapper"], "channeluserlimittotal": ["ChannelLimit", "total"], "channeluserlimitusers": ["ChannelLimit", "users"], @@ -2307,14 +2245,17 @@ "emojibuttonhovered": ["EmojiButton", "emojiButtonHovered"], "emojibuttonnormal": ["EmojiButton", "emojiButtonNormal"], "emojibuttonsprite": ["EmojiButton", "sprite"], + "emojibuttonspritegreyscale": ["EmojiButton", "spriteGreyscale"], "emojiinput": ["CustomStatusModal", "input"], "emojiinputbutton": ["CustomStatusModal", "emojiButton"], "emojiinputbuttoncontainer": ["CustomStatusModal", "emojiButtonContainer"], + "emojiinputbuttonemoji": ["CustomStatusModal", "emoji"], "emojiinputclearbutton": ["CustomStatusModal", "clearButton"], "emojiinputclearicon": ["CustomStatusModal", "clearIcon"], "emojiinputcontainer": ["CustomStatusModal", "inputContainer"], "emojipickerbutton": ["Reactions", "reactionBtn"], "emojipicker": ["EmojiPicker", "emojiPicker"], + "emojipickercustomemoji": ["EmojiPickerCustomEmoji", "image"], "emojipickerdiversityemojiitem": ["EmojiPickerDiversitySelector", "diversityEmojiItem"], "emojipickerdiversityemojiitemimage": ["EmojiPickerDiversitySelector", "diversityEmojiItemImage"], "emojipickerdiversityselector": ["EmojiPicker", "diversitySelector"], @@ -2539,9 +2480,9 @@ "imageplaceholderoverlay": ["ImageWrapper", "imagePlaceholderOverlay"], "imagemodal": ["ImageModal", "modal"], "imagemodalimage": ["ImageModal", "image"], - "imagemodalnavbutton": ["ModalCarousel", "nav"], - "imagemodalnavbuttonprev": ["ModalCarousel", "navPrev"], - "imagemodalnavbuttonnext": ["ModalCarousel", "navNext"], + "imagemodalnavbutton": ["ModalCarouselNav", "nav"], + "imagemodalnavbuttonprev": ["ModalCarouselNav", "navPrev"], + "imagemodalnavbuttonnext": ["ModalCarouselNav", "navNext"], "imagemosaicattachmentscontainer": ["ImageMosaic", "mediaAttachmentsContainer"], "imagemosaiconebyonegridsingle": ["ImageMosaic", "oneByOneGridSingle"], "imagesticker": ["ImageAssets", "stickerAsset"], @@ -2622,6 +2563,7 @@ "layerbase": ["Layers", "baseLayer"], "layers": ["Layers", "layers"], "layersbg": ["Layers", "bg"], + "linedefaultcolor": ["Text2", "defaultColor"], "listavatar": ["UserProfileList", "listAvatar"], "listdiscriminator": ["UserProfileList", "listDiscriminator"], "listguildavatar": ["UserProfileListGuild", "guildAvatar"], @@ -2656,6 +2598,7 @@ "member": ["Member", "member"], "memberactivity": ["Member", "activity"], "membericon": ["Member", "icon"], + "memberinner": ["Member", "memberInner"], "memberoffline": ["Member", "offline"], "memberownericon": ["Member", "ownerIcon"], "memberpremiumicon": ["Member", "premiumIcon"], @@ -2884,8 +2827,7 @@ "messagezalgo": ["MessageBody", "zalgo"], "modal": ["Modal", "root"], "modalcancelbutton": ["CustomStatusModal", "cancelButton"], - "modalcarousel": ["ModalCarousel", "carousel"], - "modalcarouselmodal": ["ModalCarousel", "carouselModal"], + "modalcarouselmodal": ["NotFound", "carouselModal"], "modalcarouselmodalzoomed": ["ModalCarouselWrapper", "modalCarouselWrapper"], "modalcarouselwrapper": ["ModalCarouselWrapper", "modalCarouselWrapper"], "modalclose": ["Modal", "close"], @@ -2898,6 +2840,9 @@ "modalheaderhassibling": ["BDFDB", "modalHeaderHasSibling"], "modalheadershade": ["BDFDB", "modalHeaderShade"], "modallarge": ["Modal", "large"], + "modallayer": ["ModalLayer", "layer"], + "modallayerbackdrop": ["ModalLayer", "backdrop"], + "modallayerhidden": ["ModalLayer", "hidden"], "modalmedium": ["Modal", "medium"], "modalmini": ["ModalMiniContent", "modal"], "modalminicontent": ["ModalMiniContent", "content"], @@ -2973,6 +2918,9 @@ "noticewarning": ["Notice", "colorWarning"], "noticewrapper": ["BDFDB", "noticeWrapper"], "overflowellipsis": ["BDFDB", "overflowEllipsis"], + "pageimage": ["PageImage", "image"], + "pageimagetext": ["PageImage", "text"], + "pageimagewrapper": ["PageImage", "wrapper"], "pagination": ["BDFDB", "pagination"], "paginationbottom": ["BDFDB", "paginationBottom"], "paginationbutton": ["Pagination", "pageButton"], @@ -3105,13 +3053,14 @@ "searchresultspagination": ["NotFound", "searchResultsPagination"], "searchresultsresult": ["SearchResultsMessage", "searchResult"], "searchresultswrap": ["SearchResults", "searchResultsWrap"], - "select": ["SelectSearchable", "select"], + "select": ["Select", "select"], "selectable": ["TextColor2", "selectable"], "selectfilterpopout": ["SelectFilterPopout", "selectFilterPopout"], "selectfilterpopoutavatar": ["SelectFilterPopout", "avatar"], - "selectoption": ["SelectSearchable", "option"], - "selectsearchinput": ["SelectSearchable", "searchInput"], - "selectselectedicon": ["SelectSearchable", "selectedIcon"], + "selectoption": ["Select", "option"], + "selectouter": ["Select", "wrapper"], + "selectsearchinput": ["Select", "searchInput"], + "selectselectedicon": ["Select", "selectedIcon"], "selectwrapper": ["BDFDB", "selectWrapper"], "settingsclosebutton": ["SettingsCloseButton", "closeButton"], "settingsclosebuttoncontainer": ["SettingsCloseButton", "container"], @@ -3186,13 +3135,9 @@ "slidertrack": ["Slider", "track"], "spinner": ["Spinner", "spinner"], "spoilercontainer": ["Spoiler", "spoilerContainer"], - "spoilerembed": ["MessageAttachment", "spoiler"], - "spoilerembedhidden": ["MessageAttachment", "hiddenSpoilers"], - "spoilerembedinline": ["MessageAttachment", "inline"], "spoilerhidden": ["Spoiler", "hidden"], - "spoilertext": ["Spoiler", "spoilerText"], + "spoilertext": ["Spoiler", "spoilerContent"], "spoilerwarning": ["Spoiler", "spoilerWarning"], - "splashbackground": ["NotFound", "splashBackground"], "strikethrough": ["TextStyle", "strikethrough"], "status": ["Avatar", "status"], "stopanimations": ["NotFound", "stopAnimations"], @@ -3200,6 +3145,7 @@ "svgicon": ["BDFDB", "svgIcon"], "svgiconwrapper": ["BDFDB", "svgIconWrapper"], "switch": ["Switch", "container"], + "switchchecked": ["Switch", "checked"], "switchinner": ["Switch", "input"], "switchmini": ["BDFDB", "switchMini"], "switchslider": ["Switch", "slider"], @@ -3259,6 +3205,7 @@ "textareawrapdisabled": ["ChannelTextArea", "channelTextAreaDisabled"], "textrow": ["PopoutActivity", "textRow"], "textscroller": ["BDFDB", "textScroller"], + "themecustombackground": ["NotFound", "themeCustomBackground"], "themedark": ["NotFound", "themeDark"], "themelight": ["NotFound", "themeLight"], "themeundefined": ["NotFound", "themeUndefined"], @@ -3336,6 +3283,7 @@ "tooltiprowextra": ["BDFDB", "tooltipRowExtra"], "tooltiprowguildname": ["TooltipGuild", "rowGuildName"], "tooltiprowicon": ["TooltipGuild", "rowIcon"], + "tooltiprowiconv2": ["TooltipGuild", "rowIconV2"], "tooltiptop": ["Tooltip", "tooltipTop"], "tooltipyellow": ["Tooltip", "tooltipYellow"], "typing": ["Typing", "typing"], @@ -3450,7 +3398,6 @@ "voicedetailsstatusconnecting": ["VoiceDetailsPing", "rtcConnectionStatusConnecting"], "voicedetailsstatuserror": ["VoiceDetailsPing", "rtcConnectionStatusError"], "voicedetailsstatuswithpopout": ["VoiceDetails", "statusWithPopout"], - "voicedraggable": ["NotFound", "voiceDraggable"], "voiceflipped": ["VoiceChannel", "flipped"], "voiceicon": ["VoiceChannel", "icon"], "voiceicons": ["VoiceChannel", "icons"], @@ -3490,114 +3437,114 @@ }, "userBackgroundsUrl": "https://discord-custom-covers.github.io/usrbg/dist/usrbg.json", "Languages": { - "$discord": {"name":"Discord (English)", "id":"en", "ownlang":"English"}, - "af": {"name":"Afrikaans", "id":"af", "ownlang":"Afrikaans"}, + "$discord": {"name":"Discord (English)", "id":"en", "ownlang":"English"}, + "af": {"name":"Afrikaans", "id":"af", "ownlang":"Afrikaans"}, "sq": {"name":"Albanian", "id":"sq", "ownlang":"Shqip"}, "am": {"name":"Amharic", "id":"am", "ownlang":"አማርኛ"}, "ar": {"name":"Arabic", "id":"ar", "ownlang":"اللغة العربية"}, "hy": {"name":"Armenian", "id":"hy", "ownlang":"Հայերեն"}, - "az": {"name":"Azerbaijani", "id":"az", "ownlang":"آذربایجان دیلی"}, + "az": {"name":"Azerbaijani", "id":"az", "ownlang":"آذربایجان دیلی"}, "ba": {"name":"Bashkir", "id":"ba", "ownlang":"Башҡорт"}, "eu": {"name":"Basque", "id":"eu", "ownlang":"Euskara"}, - "be": {"name":"Belarusian", "id":"be", "ownlang":"Беларуская"}, + "be": {"name":"Belarusian", "id":"be", "ownlang":"Беларуская"}, "bn": {"name":"Bengali", "id":"bn", "ownlang":"বাংলা"}, "bs": {"name":"Bosnian", "id":"bs", "ownlang":"Босански"}, - "bg": {"name":"Bulgarian", "id":"bg", "ownlang":"български"}, + "bg": {"name":"Bulgarian", "id":"bg", "ownlang":"български"}, "my": {"name":"Burmese", "id":"my", "ownlang":"မြန်မာစာ"}, "ca": {"name":"Catalan", "id":"ca", "ownlang":"Català"}, "ceb": {"name":"Cebuano", "id":"ceb", "ownlang":"Bisaya"}, "ny": {"name":"Chichewa", "id":"ny", "ownlang":"Nyanja"}, "zh": {"name":"Chinese", "id":"zh", "ownlang":"中文"}, - "zh-CN": {"name":"Chinese (China)", "id":"zh-CN", "ownlang":"中文"}, - "zh-HK": {"name":"Chinese (Hong Kong)", "id":"zh-HK", "ownlang":"香港中文"}, - "zh-TW": {"name":"Chinese (Taiwan)", "id":"zh-TW", "ownlang":"繁體中文"}, + "zh-CN": {"name":"Chinese (China)", "id":"zh-CN", "ownlang":"中文"}, + "zh-HK": {"name":"Chinese (Hong Kong)", "id":"zh-HK", "ownlang":"香港中文"}, + "zh-TW": {"name":"Chinese (Taiwan)", "id":"zh-TW", "ownlang":"繁體中文"}, "co": {"name":"Corsican", "id":"co", "ownlang":"Corsu"}, "hr": {"name":"Croatian", "id":"hr", "ownlang":"Hrvatski"}, "cs": {"name":"Czech", "id":"cs", "ownlang":"Čeština"}, "da": {"name":"Danish", "id":"da", "ownlang":"Dansk"}, "nl": {"name":"Dutch", "id":"nl", "ownlang":"Nederlands"}, "en": {"name":"English", "id":"en", "ownlang":"English"}, - "en-GB": {"name":"English (UK)", "id":"en-GB", "ownlang":"English (UK)"}, - "en-US": {"name":"English (US)", "id":"en-US", "ownlang":"English (US)"}, - "eo": {"name":"Esperanto", "id":"eo", "ownlang":"Esperanto"}, + "en-GB": {"name":"English (UK)", "id":"en-GB", "ownlang":"English (UK)"}, + "en-US": {"name":"English (US)", "id":"en-US", "ownlang":"English (US)"}, + "eo": {"name":"Esperanto", "id":"eo", "ownlang":"Esperanto"}, "et": {"name":"Estonian", "id":"et", "ownlang":"Eesti"}, "fil": {"name":"Filipino", "id":"fil", "ownlang":"Wikang Filipino"}, - "tl": {"name":"Filipino (Tagalog)", "id":"tl", "ownlang":"Wikang Tagalog"}, + "tl": {"name":"Filipino (Tagalog)", "id":"tl", "ownlang":"Wikang Tagalog"}, "fi": {"name":"Finnish", "id":"fi", "ownlang":"Suomi"}, "fr": {"name":"French", "id":"fr", "ownlang":"Français"}, - "fr-CA": {"name":"French (Canadian)", "id":"fr-CA", "ownlang":"Français Canadien"}, + "fr-CA": {"name":"French (Canadian)", "id":"fr-CA", "ownlang":"Français Canadien"}, "fy": {"name":"Frisian", "id":"fy", "ownlang":"Frysk"}, "gl": {"name":"Galician", "id":"gl", "ownlang":"Galego"}, "ka": {"name":"Georgian", "id":"ka", "ownlang":"ქართული"}, "de": {"name":"German", "id":"de", "ownlang":"Deutsch"}, - "de-AT": {"name":"German (Austria)", "id":"de-AT", "ownlang":"Österreichisch Deutsch"}, - "de-CH": {"name":"German (Switzerland)", "id":"de-CH", "ownlang":"Schweizerdeutsch"}, + "de-AT": {"name":"German (Austria)", "id":"de-AT", "ownlang":"Österreichisch Deutsch"}, + "de-CH": {"name":"German (Switzerland)", "id":"de-CH", "ownlang":"Schweizerdeutsch"}, "el": {"name":"Greek", "id":"el", "ownlang":"Ελληνικά"}, "gu": {"name":"Gujarati", "id":"gu", "ownlang":"ગુજરાતી"}, - "ht": {"name":"Haitian Creole", "id":"ht", "ownlang":"Kreyòl Ayisyen"}, + "ht": {"name":"Haitian Creole", "id":"ht", "ownlang":"Kreyòl Ayisyen"}, "ha": {"name":"Hausa", "id":"ha", "ownlang":"حَوْسَ"}, "haw": {"name":"Hawaiian", "id":"haw", "ownlang":"ʻŌlelo Hawaiʻi"}, "he": {"name":"Hebrew", "id":"he", "ownlang":"עברית"}, - "iw": {"name":"Hebrew (Israel)", "id":"iw", "ownlang":"עברית"}, + "iw": {"name":"Hebrew (Israel)", "id":"iw", "ownlang":"עברית"}, "hi": {"name":"Hindi", "id":"hi", "ownlang":"हिन्दी"}, "hmn": {"name":"Hmong", "id":"hmn", "ownlang":"lol Hmongb"}, - "hu": {"name":"Hungarian", "id":"hu", "ownlang":"Magyar"}, - "is": {"name":"Icelandic", "id":"is", "ownlang":"Íslenska"}, + "hu": {"name":"Hungarian", "id":"hu", "ownlang":"Magyar"}, + "is": {"name":"Icelandic", "id":"is", "ownlang":"Íslenska"}, "ig": {"name":"Igbo", "id":"ig", "ownlang":"Asụsụ Igbo"}, - "id": {"name":"Indonesian", "id":"id", "ownlang":"Bahasa Indonesia"}, + "id": {"name":"Indonesian", "id":"id", "ownlang":"Bahasa Indonesia"}, "ga": {"name":"Irish", "id":"ga", "ownlang":"Gaeilge"}, "it": {"name":"Italian", "id":"it", "ownlang":"Italiano"}, "ja": {"name":"Japanese", "id":"ja", "ownlang":"日本語"}, "jv": {"name":"Javanese", "id":"jv", "ownlang":"ꦧꦱꦗꦮ"}, - "jw": {"name":"Javanese (Javanese)", "id":"jw", "ownlang":"ꦧꦱꦗꦮ"}, + "jw": {"name":"Javanese (Javanese)", "id":"jw", "ownlang":"ꦧꦱꦗꦮ"}, "kn": {"name":"Kannada", "id":"kn", "ownlang":"ಕನ್ನಡ"}, "kk": {"name":"Kazakh", "id":"kk", "ownlang":"Қазақ Tілі"}, "km": {"name":"Khmer", "id":"km", "ownlang":"ភាសាខ្មែរ"}, - "rw": {"name":"Kinyarwanda", "id":"rw", "ownlang":"Ikinyarwanda"}, + "rw": {"name":"Kinyarwanda", "id":"rw", "ownlang":"Ikinyarwanda"}, "ko": {"name":"Korean", "id":"ko", "ownlang":"한국어"}, "ku": {"name":"Kurdish", "id":"ku", "ownlang":"کوردی"}, "ky": {"name":"Kyrgyz", "id":"ky", "ownlang":"кыргызча"}, "lo": {"name":"Lao", "id":"lo", "ownlang":"ພາສາລາວ"}, "la": {"name":"Latin", "id":"la", "ownlang":"Latina"}, "lv": {"name":"Latvian", "id":"lv", "ownlang":"Latviešu"}, - "lt": {"name":"Lithuanian", "id":"lt", "ownlang":"Lietuvių"}, - "lb": {"name":"Luxembourgish", "id":"lb", "ownlang":"Lëtzebuergesch"}, - "mk": {"name":"Macedonian", "id":"mk", "ownlang":"Mакедонски"}, + "lt": {"name":"Lithuanian", "id":"lt", "ownlang":"Lietuvių"}, + "lb": {"name":"Luxembourgish", "id":"lb", "ownlang":"Lëtzebuergesch"}, + "mk": {"name":"Macedonian", "id":"mk", "ownlang":"Mакедонски"}, "mg": {"name":"Malagasy", "id":"mg", "ownlang":"Malagasy"}, "ms": {"name":"Malay", "id":"ms", "ownlang":"بهاس ملايو"}, - "ml": {"name":"Malayalam", "id":"ml", "ownlang":"മലയാളം"}, + "ml": {"name":"Malayalam", "id":"ml", "ownlang":"മലയാളം"}, "mt": {"name":"Maltese", "id":"mt", "ownlang":"Malti"}, "mi": {"name":"Maori", "id":"mi", "ownlang":"te Reo Māori"}, "mr": {"name":"Marathi", "id":"mr", "ownlang":"मराठी"}, "mhr": {"name":"Mari", "id":"mhr", "ownlang":"марий йылме"}, - "mn": {"name":"Mongolian", "id":"mn", "ownlang":"Монгол Хэл"}, - "my": {"name":"Myanmar (Burmese)", "id":"my", "ownlang":"မြန်မာл Хэл"}, + "mn": {"name":"Mongolian", "id":"mn", "ownlang":"Монгол Хэл"}, + "my": {"name":"Myanmar (Burmese)", "id":"my", "ownlang":"မြန်မာл Хэл"}, "ne": {"name":"Nepali", "id":"ne", "ownlang":"नेपाली"}, - "no": {"name":"Norwegian", "id":"no", "ownlang":"Norsk"}, + "no": {"name":"Norwegian", "id":"no", "ownlang":"Norsk"}, "or": {"name":"Odia", "id":"or", "ownlang":"ଓଡ଼ିଆ"}, - "pap": {"name":"Papiamento", "id":"pap", "ownlang":"Papiamentu"}, + "pap": {"name":"Papiamento", "id":"pap", "ownlang":"Papiamentu"}, "ps": {"name":"Pashto", "id":"ps", "ownlang":"پښتو"}, "fa": {"name":"Persian", "id":"fa", "ownlang":"فارسی"}, "pl": {"name":"Polish", "id":"pl", "ownlang":"Polski"}, - "pt": {"name":"Portuguese", "id":"pt", "ownlang":"Português"}, - "pt-BR": {"name":"Portuguese (Brazil)", "id":"pt-BR", "ownlang":"Português do Brasil"}, - "pt-PT": {"name":"Portuguese (Portugal)", "id":"pt-PT", "ownlang":"Português do Portugal"}, + "pt": {"name":"Portuguese", "id":"pt", "ownlang":"Português"}, + "pt-BR": {"name":"Portuguese (Brazil)", "id":"pt-BR", "ownlang":"Português do Brasil"}, + "pt-PT": {"name":"Portuguese (Portugal)", "id":"pt-PT", "ownlang":"Português do Portugal"}, "pa": {"name":"Punjabi", "id":"pa", "ownlang":"पंजाबी"}, "ro": {"name":"Romanian", "id":"ro", "ownlang":"Română"}, "ru": {"name":"Russian", "id":"ru", "ownlang":"Pусский"}, "sm": {"name":"Samoan", "id":"sm", "ownlang":"Gagana Sāmoa"}, - "gd": {"name":"Scottish Gaelic", "id":"gd", "ownlang":"Gàidhlig"}, + "gd": {"name":"Scottish Gaelic", "id":"gd", "ownlang":"Gàidhlig"}, "sr": {"name":"Serbian", "id":"sr", "ownlang":"Српски"}, "st": {"name":"Sesotho", "id":"st", "ownlang":"Sesotho"}, "sn": {"name":"Shona", "id":"sn", "ownlang":"Shona"}, "sd": {"name":"Sindhi", "id":"sd", "ownlang":"سنڌي"}, "si": {"name":"Sinhala", "id":"si", "ownlang":"සිංහල"}, "sk": {"name":"Slovak", "id":"sk", "ownlang":"Slovenčina"}, - "sl": {"name":"Slovenian", "id":"sl", "ownlang":"Slovenščina"}, + "sl": {"name":"Slovenian", "id":"sl", "ownlang":"Slovenščina"}, "so": {"name":"Somali", "id":"so", "ownlang":"Soomaali"}, "es": {"name":"Spanish", "id":"es", "ownlang":"Español"}, - "es-419": {"name":"Spanish (Latin America)", "id":"es-419", "ownlang":"Español latinoamericano"}, - "su": {"name":"Sundanese", "id":"su", "ownlang":"Basa Sunda"}, + "es-419": {"name":"Spanish (Latin America)", "id":"es-419", "ownlang":"Español latinoamericano"}, + "su": {"name":"Sundanese", "id":"su", "ownlang":"Basa Sunda"}, "sw": {"name":"Swahili", "id":"sw", "ownlang":"Kiswahili"}, "sv": {"name":"Swedish", "id":"sv", "ownlang":"Svenska"}, "tg": {"name":"Tajik", "id":"tg", "ownlang":"тоҷикӣ"}, @@ -3608,11 +3555,11 @@ "tr": {"name":"Turkish", "id":"tr", "ownlang":"Türkçe"}, "tk": {"name":"Turkmen", "id":"tk", "ownlang":"Türkmençe"}, "udm": {"name":"Udmurt", "id":"udm", "ownlang":"удмурт кыл"}, - "uk": {"name":"Ukrainian", "id":"uk", "ownlang":"Yкраїнський"}, + "uk": {"name":"Ukrainian", "id":"uk", "ownlang":"Yкраїнський"}, "ur": {"name":"Urdu", "id":"ur", "ownlang":"اُردُو"}, "ug": {"name":"Uyghur", "id":"ug", "ownlang":"ئۇيغۇر تىلى"}, "uz": {"name":"Uzbek", "id":"uz", "ownlang":"اوزبیک"}, - "vi": {"name":"Vietnamese", "id":"vi", "ownlang":"Tiếng Việt Nam"}, + "vi": {"name":"Vietnamese", "id":"vi", "ownlang":"Tiếng Việt Nam"}, "cy": {"name":"Welsh", "id":"cy", "ownlang":"Cymraeg"}, "xh": {"name":"Xhosa", "id":"xh", "ownlang":"Xhosa"}, "yi": {"name":"Yiddish", "id":"yi", "ownlang":"ייִדיש ייִדיש‬"}, @@ -3886,50 +3833,50 @@ }, "el": { "add_to": "Προσθήκη στο {{var0}}", - "ascending": "Ανερχόμενος", + "ascending": "Αύξουσα", "center": "Στο κέντρο", "changelog_added": "Νέα χαρακτηριστικά", - "changelog_fixed": "Αντιμετώπιση προβλημάτων", + "changelog_fixed": "Διορθώσεις σφαλμάτων", "changelog_improved": "Βελτιώσεις", "changelog_progress": "Πρόοδος", "check_for_updates": "Ελεγχος για ενημερώσεις", - "clipboard_success": "Αντιγράφηκε το {{var0}} στο Πρόχειρο", - "confirm": "Είσαι σίγουρος?", + "clipboard_success": "Αντιγραφή του {{var0}} στο Πρόχειρο", + "confirm": "Σίγουρα;", "copy": "Αντιγραφή {{var0}}", "delete_fail": "Δεν είναι δυνατή η διαγραφή του {{var0}}", "delete_success": "Το {{var0}} διαγράφηκε με επιτυχία", - "descending": "Φθίνων", + "descending": "Φθίνουσα", "developer": "Προγραμματιστής", "donate_message": "Υποστηρίξτε με για περισσότερες ενημερώσεις!", - "download": "Κατεβάστε", - "download_fail": "Δεν είναι δυνατή η λήψη του {{var0}}", + "download": "Λήψη", + "download_fail": "Αδυνατή η λήψη του {{var0}}", "download_success": "Η λήψη του {{var0}} ολοκληρώθηκε με επιτυχία", "file_navigator_text": "Αναζήτηση αρχείου", "first": "Πρώτα", "from": "Από", "gradient": "Βαθμίδα", - "guildbanner": "Πανό", - "guildicon": "Εικόνισμα", - "installed": "Εγκατασταθεί", + "guildbanner": "Διαφημιστικό", + "guildicon": "Εικονίδιο", + "installed": "Εγκατεστημένο", "last": "Τελευταίος", "left": "Αριστερά", "loading": "Φόρτωση {{var0}}", "location": "Τοποθεσία", - "order": "Αλληλουχία", - "outdated": "Απαρχαιωμένος", - "please_wait": "Ευχάριστη αναμονή", - "right": "Σωστά", - "save_fail": "Δεν είναι δυνατή η αποθήκευση του {{var0}}", + "order": "Ταξινόμηση", + "outdated": "Παλαιό", + "please_wait": "Αναμείνατε...", + "right": "Δεξιά", + "save_fail": "Αδυνατή η αποθήκευση του {{var0}}", "save_success": "Το {{var0}} αποθηκεύτηκε με επιτυχία", "send": "Αποστολή {{var0}}", - "server": "Υπηρέτης", - "settings_shareData_description": "Συγχρονίζει τις ρυθμίσεις παραμέτρων της προσθήκης μεταξύ λογαριασμών Discord", - "settings_showSupportBadges_description": "Εμφανίζει μικρά σήματα για χρήστες που υποστηρίζουν το Patreon μου", - "settings_showToasts_description": "Δείχνει τις προσθήκης έναρξης και διακοπής τοστ", - "settings_showToasts_note": "Απενεργοποιήστε τη γενική ρύθμιση '{{var0}}' των BD πριν απενεργοποιήσετε", - "settings_toastPosition_description": "Προεπιλεγμένη θέση τοστ", - "settings_toastPosition_note": "Αλλάζει μόνο τη θέση των Τοστ που δημιουργήθηκαν από τις προσθήκες μου", - "settings_useChromium_description": "Ανοίξτε τους συνδέσμους στο Discord αντί για το πρόγραμμα περιήγησής σας", + "server": "Διακομιστής", + "settings_shareData_description": "Συγχρ. ρύθμισης παραμέτρων Προσθέτου μεταξύ λογαριασμών Discord", + "settings_showSupportBadges_description": "Εμφανίζει μικρά παράσημα για χρήστες που υποστηρίζουν το Patreon μου", + "settings_showToasts_description": "Εμφάνιση επισημάνσεων έναρξης και τερματισμού Προσθέτου", + "settings_showToasts_note": "Απενεργοποιεί τη γενική ρύθμιση «{{var0}}» του BD πριν απενεργοποιηθεί", + "settings_toastPosition_description": "Προεπιλεγμένη Θέση Επεξήγησης", + "settings_toastPosition_note": "Αλλάζει μόνο τη Θέση των Επεξηγήσεων που δημιουργήθηκαν από τις προσθήκες μου", + "settings_useChromium_description": "Ανοίξτε τους Συνδέσμους στο Discord αντί για τον φυλλομετρητή σας", "sort_by": "Ταξινόμηση κατά", "status": "Κατάσταση", "time": "Χρόνος", @@ -3937,18 +3884,18 @@ "to": "Προς το", "toast_plugin_loaded": "Το {{var0}} έχει φορτωθεί", "toast_plugin_started": "Το {{var0}} έχει ξεκινήσει", - "toast_plugin_stopped": "Το {{var0}} έχει σταματήσει", + "toast_plugin_stopped": "Το {{var0}} έχει τερματιστεί", "toast_plugin_translated": "μεταφράστηκε σε {{var0}}", "toast_plugin_unloaded": "Το {{var0}} έχει εκφορτωθεί", "toast_plugin_update_failed": "Δεν είναι δυνατή η λήψη της ενημέρωσης για το {{var0}}", "toast_plugin_updated": "Το {{var0}} {{var1}} αντικαταστάθηκε από το {{var2}} {{var3}}", - "update_check_complete": "Ο έλεγχος ενημέρωσης προσθήκης ολοκληρώθηκε", - "update_check_complete_outdated": "Ο έλεγχος ενημέρωσης προσθήκης ολοκληρώθηκε - {{var0}} δεν είναι ενημερωμένος!", - "update_check_info": "Έλεγχος προσθήκες που υποστηρίζουν τον έλεγχο ενημέρωσης", - "update_notice_click": "Κάντε κλικ για ενημέρωση!", - "update_notice_reload": "Επαναλάβετε τη φόρτωση για να ολοκληρώσετε την ενημέρωση", - "update_notice_update": "Οι ακόλουθες προσθήκες πρέπει να ενημερωθούν: ", - "updated": "ΕΠΙΚΑΙΡΟΠΟΙΗΜΕΝΟ" + "update_check_complete": "Ο Έλεγχος Ενημέρωσης Πρόσθετου ολοκληρώθηκε", + "update_check_complete_outdated": "Ο Έλεγχος Ενημέρωσης Πρόσθετου ολοκληρώθηκε - {{var0}} δεν είναι ενημερωμένο!", + "update_check_info": "Έλεγχος Προσθέτων με υποστήριξη ενημέρωσης", + "update_notice_click": "Πατήστε για ενημέρωση!", + "update_notice_reload": "Επαναφορτώστε για ολοκλήρωση της ενημέρωσης", + "update_notice_update": "Τα ακόλουθα Πρόσθετα πρέπει να ενημερωθούν: ", + "updated": "Ενημερωμένο" }, "es": { "add_to": "Agregar a {{var0}}", @@ -5536,12 +5483,13 @@ } }, "BDFDB_Patrons": { - "220161488516546561": {"active": true, "tier": "t2", "text": "", "color": "", "id": "taimoor"}, - "148234730523852800": {"active": true, "tier": "t2", "text": "", "color": "", "id": "inbroso (MaEp)"}, - "105509397211406336": {"active": true, "tier": "t2", "text": "", "color": "", "id": "samtino (SgJeff)"}, - "323494393828999168": {"active": true, "tier": "t2", "text": "", "color": "", "id": "polak (SzKu)"}, - "620397524494057513": {"active": true, "tier": "t2", "text": "", "color": "", "id": "FUSL"}, - "798499176220327966": {"active": true, "tier": "t2", "text": "", "color": "", "id": "void (JaUt)"} + "864982372751245313": {"active": true, "tier": "t2", "text": "", "color": "", "id": "windowsuss (fynn)"}, + "148234730523852800": {"active": true, "tier": "t2", "text": "", "color": "", "id": "inbroso (MaEp)"}, + "105509397211406336": {"active": true, "tier": "t2", "text": "", "color": "", "id": "samtino (SgJeff)"}, + "323494393828999168": {"active": true, "tier": "t2", "text": "", "color": "", "id": "polak (SzKu)"}, + "507464069100601363": {"active": true, "tier": "t2", "text": "", "color": "", "id": "cracky (MiPo)"}, + "620397524494057513": {"active": true, "tier": "t2", "text": "", "color": "", "id": "FUSL"}, + "798499176220327966": {"active": true, "tier": "t2", "text": "", "color": "", "id": "void (JaUt)"} }, "BDFDB_Patron_Tiers": { "t1": { diff --git a/.config/BetterDiscord/plugins/0BDFDB.plugin.js b/.config/BetterDiscord/plugins/0BDFDB.plugin.js index eac61a4..35a468a 100644 --- a/.config/BetterDiscord/plugins/0BDFDB.plugin.js +++ b/.config/BetterDiscord/plugins/0BDFDB.plugin.js @@ -2,7 +2,7 @@ * @name BDFDB * @author DevilBro * @authorId 278543574059057154 - * @version 3.2.0 + * @version 3.5.9 * @description Required Library for DevilBro's Plugins * @invite Jx3TjNS * @donate https://www.paypal.me/MircoWittrien @@ -15,7 +15,7 @@ module.exports = (_ => { if (window.BDFDB_Global && window.BDFDB_Global.PluginUtils && typeof window.BDFDB_Global.PluginUtils.cleanUp == "function") window.BDFDB_Global.PluginUtils.cleanUp(window.BDFDB_Global); - const request = require("request"), fs = require("fs"), path = require("path"); + const fs = require("fs"), path = require("path"); var BDFDB, Internal; var LibraryRequires = {}; @@ -154,40 +154,78 @@ module.exports = (_ => { }; const requestFunction = function (...args) { - let {url, uIndex} = args[0] && typeof args[0] == "string" ? {url: args[0], uIndex: 0} : (args[1] && typeof args[1] == "object" && typeof args[1].url == "string" ? {url: args[1], uIndex: 1} : {url: null, uIndex: -1}); - if (!url || typeof url != "string") return; - let {callback, cIndex} = args[1] && typeof args[1] == "function" ? {callback: args[1], cIndex: 1} : (args[2] && typeof args[2] == "function" ? {callback: args[2], cIndex: 2} : {callback: null, cIndex: -1}); + let url = typeof args[0] == "string" && args[0]; + if (!url) return; + let callback = typeof args[1] == "function" && args[1] || typeof args[2] == "function" && args[2]; if (typeof callback != "function") return; - let config = args[0] && typeof args[0] == "object" ? args[0] : (args[1] && typeof args[1] == "object" && args[1]); - let timeout = 600000; - if (config && config.form && typeof config.form == "object") { - let query = Object.entries(config.form).map(n => n[0] + "=" + n[1]).join("&"); - if (query) { - if (uIndex == 0) args[0] += `?${query}`; - else if (uIndex == 1) args[1].url += `?${query}`; + if (url.indexOf("data:") == 0) callback(null, { + aborted: false, + complete: true, + end: undefined, + headers: {"content-type": url.slice(5).split(";")[0]}, + method: null, + rawHeaders: [], + statusCode: 200, + statusMessage: "OK", + url: "" + }, url); + else { + let config = args[1] && typeof args[1] == "object" ? args[1] : {}; + let timeout = 600000; + if (!isNaN(parseInt(config.timeout)) && config.timeout > 0) timeout = config.timeout; + if (config.form && typeof config.form == "object") { + let query = Object.entries(config.form).map(n => n[0] + "=" + n[1]).join("&"); + if (query) url += `?${query}`; } + if (config.method) config.method = config.method.toUpperCase(); + let killed = false, timeoutObj = BDFDB.TimeUtils.timeout(_ => { + killed = true; + BDFDB.TimeUtils.clear(timeoutObj); + callback(new Error(`Request Timeout after ${timeout}ms`), { + aborted: false, + complete: true, + end: undefined, + headers: {}, + method: null, + rawHeaders: [], + statusCode: 408, + statusMessage: "OK", + url: "" + }, null); + }, timeout); + let response = null, isFallback = false; + return (config.bdVersion && BdApi && BdApi.Net && BdApi.Net.fetch ? BdApi.Net.fetch : fetch)(url, config).catch(error => { + BDFDB.TimeUtils.clear(timeoutObj); + if (!config.bdVersion) return requestFunction(url, Object.assign({}, config, {bdVersion: true}), callback); + else callback(new Error(error), { + aborted: false, + complete: true, + end: undefined, + headers: {}, + method: null, + rawHeaders: [], + statusCode: 408, + statusMessage: "OK", + url: "" + }, null); + }).then(r => { + response = r; + if (!response) return; + response.statusCode = response.status; + if (response.headers) response.headers["content-type"] = response.headers.get("content-type"); + BDFDB.TimeUtils.clear(timeoutObj); + return config.toBase64 ? response.blob() : config.toBuffer ? response.arrayBuffer() : response.text(); + }).then(result => { + if (!killed && response) { + if (!config.toBase64 || response.status != 200) callback(response.status != 200 ? new Error(response.statusText || "Fetch Failed") : null, response, result); + else { + let reader = new FileReader(); + reader.onload = _ => callback(null, response, reader.result); + reader.readAsDataURL(result); + } + } + }); } - if (config && !isNaN(parseInt(config.timeout)) && config.timeout > 0) timeout = config.timeout; - let killed = false, timeoutObj = BDFDB.TimeUtils.timeout(_ => { - killed = true; - BDFDB.TimeUtils.clear(timeoutObj); - callback(new Error(`Request Timeout after ${timeout}ms`), { - aborted: false, - complete: true, - end: undefined, - headers: {}, - method: null, - rawHeaders: [], - statusCode: 408, - statusMessage: "OK", - url: "" - }, null); - }, timeout); - args[cIndex] = (...args2) => { - BDFDB.TimeUtils.clear(timeoutObj); - if (!killed) callback(...args2); - }; - return request(...args); }; BDFDB.LogUtils = {}; @@ -320,6 +358,11 @@ module.exports = (_ => { } return found; }; + BDFDB.ObjectUtils.invert = function (obj) { + let newObj = {}; + if (BDFDB.ObjectUtils.is(obj)) for (let entry of Object.entries(obj)) newObj[entry[1]] = entry[0]; + return newObj; + }; BDFDB.ObjectUtils.extract = function (obj, ...keys) { let newObj = {}; if (BDFDB.ObjectUtils.is(obj)) for (let key of keys.flat(10).filter(n => n)) if (obj[key] != null) newObj[key] = obj[key]; @@ -381,6 +424,13 @@ module.exports = (_ => { BDFDB.ObjectUtils.isEmpty = function (obj) { return !BDFDB.ObjectUtils.is(obj) || Object.getOwnPropertyNames(obj).length == 0; }; + BDFDB.ObjectUtils.copy = function (obj) { + if (!BDFDB.ObjectUtils.is(obj)) return obj; + let copy = {}; + for (let key in obj) copy[key] = obj[key]; + for (let key of Reflect.ownKeys(obj.constructor.prototype)) if (!copy[key] && obj[key] !== undefined) copy[key] = obj[key]; + return copy; + }; BDFDB.ArrayUtils = {}; BDFDB.ArrayUtils.is = function (array) { @@ -570,7 +620,7 @@ module.exports = (_ => { BDFDB.LogUtils.log(BDFDB.LanguageUtils.LibraryStringsFormat("toast_plugin_started", ""), plugin); if (Internal.settings.general.showToasts && !BDFDB.BDUtils.getSettings(BDFDB.BDUtils.settingsIds.showToasts)) BDFDB.NotificationUtils.toast(BDFDB.LanguageUtils.LibraryStringsFormat("toast_plugin_started", `${plugin.name} v${plugin.version}`), { disableInteractions: true, - barColor: "var(--status-positive)" + barColor: BDFDB.DiscordConstants.ColorsCSS.STATUS_POSITIVE }); if (plugin.css) BDFDB.DOMUtils.appendLocalStyle(plugin.name, plugin.css); @@ -587,7 +637,7 @@ module.exports = (_ => { BDFDB.LogUtils.log(BDFDB.LanguageUtils.LibraryStringsFormat("toast_plugin_stopped", ""), plugin); if (Internal.settings.general.showToasts && !BDFDB.BDUtils.getSettings(BDFDB.BDUtils.settingsIds.showToasts)) BDFDB.NotificationUtils.toast(BDFDB.LanguageUtils.LibraryStringsFormat("toast_plugin_stopped", `${plugin.name} v${plugin.version}`), { disableInteractions: true, - barColor: "var(--status-danger)" + barColor: BDFDB.DiscordConstants.ColorsCSS.STATUS_DANGER }); const url = Internal.getPluginURL(plugin); @@ -785,7 +835,7 @@ module.exports = (_ => { } else { let wasEnabled = BDFDB.BDUtils.isPluginEnabled(pluginName); - let newName = (body.match(/"name"\s*:\s*"([^"]+)"/) || [])[1] || pluginName; + let newName = (body.match(/@name ([^"^\n^\t^\t]+)|['"]([^"^\n^\t^\t]+)['"]/i) || []).filter(n => n)[1] || pluginName; let newVersion = (body.match(/@version ([0-9]+\.[0-9]+\.[0-9]+)|['"]([0-9]+\.[0-9]+\.[0-9]+)['"]/i) || []).filter(n => n)[1]; let oldVersion = PluginStores.updateData.plugins[url].version; let fileName = pluginName == "BDFDB" ? "0BDFDB" : pluginName; @@ -923,7 +973,7 @@ module.exports = (_ => { }; BDFDB.PluginUtils.createSettingsPanel = function (addon, props) { if (!window.BDFDB_Global.loaded) return BdApi.React.createElement("div", { - style: {"color": "var(--header-secondary)", "white-space": "pre-wrap"}, + style: {"color": BDFDB.DiscordConstants.ColorsCSS.HEADER_SECONDARY, "white-space": "pre-wrap"}, children: [ "Could not initiate BDFDB Library Plugin! Can not create Settings Panel!\n\nTry deleting the ", BdApi.React.createElement("strong", {children: dataFileName}), @@ -1092,7 +1142,7 @@ module.exports = (_ => { return {backup: fs.existsSync(path) && (fs.readFileSync(path) || "").toString(), hashIsSame: libHashes[fileName] && oldLibHashes[fileName] && libHashes[fileName] == oldLibHashes[fileName]}; }; const requestLibraryHashes = tryAgain => { - requestFunction("https://api.github.com/repos/mwittrien/BetterDiscordAddons/contents/Library/_res/", {headers: {"user-agent": "node.js"}, timeout: 60000}, (e, r, b) => { + requestFunction("https://api.github.com/repos/mwittrien/BetterDiscordAddons/contents/Library/_res/", {timeout: 60000}, (e, r, b) => { if ((e || !b || r.statusCode != 200) && tryAgain) return BDFDB.TimeUtils.timeout(_ => requestLibraryHashes(), 10000); else { try { @@ -1142,7 +1192,8 @@ module.exports = (_ => { Internal.getWebModuleReq = function () { if (!Internal.getWebModuleReq.req) { const id = "BDFDB-WebModules_" + Math.floor(Math.random() * 10000000000000000); - const req = webpackChunkdiscord_app.push([[id], {}, req => req]); + let req; + webpackChunkdiscord_app.push([[id], {}, r => {if (r.c) req = r;}]); delete req.m[id]; delete req.c[id]; Internal.getWebModuleReq.req = req; @@ -1259,14 +1310,26 @@ module.exports = (_ => { let all = typeof config.all != "boolean" ? false : config.all; const req = Internal.getWebModuleReq(); const found = []; - if (!onlySearchUnloaded) for (let i in req.c) if (req.c.hasOwnProperty(i)) { + if (!onlySearchUnloaded) for (let i in req.c) if (req.c.hasOwnProperty(i) && req.c[i].exports != window) { let m = req.c[i].exports, r = null; if (m && (typeof m == "object" || typeof m == "function")) { if (!!(r = filter(m))) { if (all) found.push(defaultExport ? r : req.c[i]); else return defaultExport ? r : req.c[i]; } - else for (let key of Object.keys(m)) if (key.length < 4 && m[key] && !!(r = filter(m[key]))) { + else if (Object.keys(m).length < 400) for (let key of Object.keys(m)) try { + if (m[key] && !!(r = filter(m[key]))) { + if (all) found.push(defaultExport ? r : req.c[i]); + else return defaultExport ? r : req.c[i]; + } + } catch (err) {} + } + if (config.moduleName && m && m[config.moduleName] && (typeof m[config.moduleName] == "object" || typeof m[config.moduleName] == "function")) { + if (!!(r = filter(m[config.moduleName]))) { + if (all) found.push(defaultExport ? r : req.c[i]); + else return defaultExport ? r : req.c[i]; + } + else if (m[config.moduleName].type && (typeof m[config.moduleName].type == "object" || typeof m[config.moduleName].type == "function") && !!(r = filter(m[config.moduleName].type))) { if (all) found.push(defaultExport ? r : req.c[i]); else return defaultExport ? r : req.c[i]; } @@ -1331,21 +1394,27 @@ module.exports = (_ => { return Internal.findModule("proto", JSON.stringify(protoProps), m => Internal.checkModuleProtos(m, protoProps) && m, config); }; BDFDB.ModuleUtils.findStringObject = function (props, config = {}) { - return BDFDB.ModuleUtils.find(m => { + let firstReturn = BDFDB.ModuleUtils.find(m => { let amount = Object.keys(m).length; return (!config.length || (config.smaller ? amount < config.length : amount == config.length)) && [props].flat(10).every(prop => typeof m[prop] == "string") && m; - }) || BDFDB.ModuleUtils.find(m => { + }, {all: config.all, defaultExport: config.defaultExport}); + if (!config.all && firstReturn) return firstReturn; + let secondReturn = BDFDB.ModuleUtils.find(m => { if (typeof m != "function") return false; let stringified = m.toString().replace(/\s/g, ""); - if (stringified.indexOf("e=>{e.exports={") != 0) return false; + if (stringified.indexOf(".exports={") == -1 || !/function\([A-z],[A-z],[A-z]\)\{"usestrict";[A-z]\.exports=\{/.test(stringified)) return false; let amount = stringified.split(":\"").length - 1; return (!config.length || (config.smaller ? amount < config.length : amount == config.length)) && [props].flat(10).every(string => stringified.indexOf(`${string}:`) > -1) && m; - }, {onlySearchUnloaded: true}); + }, {onlySearchUnloaded: true, all: config.all, defaultExport: config.defaultExport}); + if (!config.all) return secondReturn; + return BDFDB.ArrayUtils.removeCopies([firstReturn].concat(secondReturn).flat(10)); }; + const DiscordConstantsObject = BDFDB.ModuleUtils.findByProperties("AnalyticsSections", "ChannelTypes", "MessageTypes"); + if (InternalData.CustomDiscordConstants) DiscordConstants = Object.assign(DiscordConstants, InternalData.CustomDiscordConstants); + if (DiscordConstantsObject) DiscordConstants = Object.assign(DiscordConstants, DiscordConstantsObject); Internal.DiscordConstants = new Proxy(DiscordConstants, { get: function (_, item) { - if (InternalData.CustomDiscordConstants && InternalData.CustomDiscordConstants[item]) return InternalData.CustomDiscordConstants[item]; if (DiscordConstants[item]) return DiscordConstants[item]; if (!InternalData.DiscordConstants[item]) { BDFDB.LogUtils.warn([item, "Object not found in DiscordConstants"]); @@ -1970,8 +2039,8 @@ module.exports = (_ => { children: [ BDFDB.ReactUtils.createElement(Internal.LibraryComponents.GuildBadge, { guild: config.guild, - size: BDFDB.StringUtils.cssValueToNumber(Internal.DiscordClassModules.TooltipGuild.iconSize), - className: BDFDB.disCN.tooltiprowicon + size: 16, + className: BDFDB.disCN.tooltiprowiconv2 }), BDFDB.ReactUtils.createElement("span", { className: BDFDB.DOMUtils.formatClassName(BDFDB.disCN.tooltipguildnametext), @@ -2136,7 +2205,7 @@ module.exports = (_ => { if (InternalData.PatchModules[type]) { let found = false; if (!InternalData.PatchModules[type].noSearch && (patchType == "before" || patchType == "after")) { - let exports = (BDFDB.ModuleUtils.find(m => Internal.isCorrectModule(m, type) && m, {defaultExport: false}) || {}).exports; + let exports = (BDFDB.ModuleUtils.find(m => Internal.isCorrectModule(m, type) && m, {defaultExport: false, moduleName: type}) || {}).exports; if (exports && !exports.default) for (let key of Object.keys(exports)) if (typeof exports[key] == "function" && !(exports[key].prototype && exports[key].prototype.render) && Internal.isCorrectModule(exports[key], type, false) && exports[key].toString().length < 50000) { found = true; BDFDB.PatchUtils.patch(plugin, exports, key, {[patchType]: e => Internal.initiatePatch(plugin, type, { @@ -2224,52 +2293,54 @@ module.exports = (_ => { if (!module[methodName]) module[methodName] = _ => {return null}; let patches = module[methodName].BDFDB_Patches || {}; for (let type in patchMethods) { - if (!patches[type]) { - const originalMethod = module[methodName].__originalFunction || module[methodName]; - const internalData = (Object.entries(InternalData.LibraryModules).find(n => n && n[0] && LibraryModules[n[0]] == module && n[1] && n[1]._originalModule && n[1]._mappedItems[methodName]) || [])[1]; - const name = internalData && internalData[0] || config.name || (module.constructor ? (module.constructor.displayName || module.constructor.name) : "module"); - const mainCancel = BdApi.Patcher[type](Internal.name, internalData && internalData._originalModule || module, internalData && internalData._mappedItems[methodName] || methodName, function(...args) { - let callInsteadAfterwards = false, stopInsteadCall = false; - const data = { - component: module, - methodArguments: args[1], - returnValue: args[2], - originalMethod: originalMethod, - originalMethodName: methodName - }; - if (type == "instead") { - data.callOriginalMethod = _ => data.returnValue = data.originalMethod.apply(this && this !== window ? this : {}, data.methodArguments); - data.callOriginalMethodAfterwards = _ => (callInsteadAfterwards = true, data.returnValue); - data.stopOriginalMethodCall = _ => stopInsteadCall = true; + const internalData = (Object.entries(InternalData.LibraryModules).find(n => n && n[0] && LibraryModules[n[0]] == module && n[1] && n[1]._originalModule && n[1]._mappedItems[methodName]) || [])[1]; + const name = internalData && internalData[0] || config.name || (module.constructor ? (module.constructor.displayName || module.constructor.name) : "module"); + try { + if (!patches[type]) { + const originalMethod = module[methodName].__originalFunction || module[methodName]; + const mainCancel = BdApi.Patcher[type](Internal.name, internalData && internalData._originalModule || module, internalData && internalData._mappedItems[methodName] || methodName, function(...args) { + let callInsteadAfterwards = false, stopInsteadCall = false; + const data = { + component: module, + methodArguments: args[1], + returnValue: args[2], + originalMethod: originalMethod, + originalMethodName: methodName + }; + if (type == "instead") { + data.callOriginalMethod = _ => data.returnValue = data.originalMethod.apply(this && this !== window ? this : {}, data.methodArguments); + data.callOriginalMethodAfterwards = _ => (callInsteadAfterwards = true, data.returnValue); + data.stopOriginalMethodCall = _ => stopInsteadCall = true; + } + if (args[0] != module) data.instance = args[0] || {props: args[1][0]}; + for (let priority in patches[type].plugins) for (let id in BDFDB.ObjectUtils.sort(patches[type].plugins[priority])) { + let tempReturn = BDFDB.TimeUtils.suppress(patches[type].plugins[priority][id], `"${type}" callback of ${methodName} in ${name}`, {name: patches[type].plugins[priority][id].pluginName, version: patches[type].plugins[priority][id].pluginVersion})(data); + if (type != "before" && tempReturn !== undefined) data.returnValue = tempReturn; + } + if (type == "instead" && callInsteadAfterwards && !stopInsteadCall) BDFDB.TimeUtils.suppress(data.callOriginalMethod, `originalMethod of ${methodName} in ${name}`, {name: "Discord"})(); + + if (type != "before") return (methodName == "render" || methodName == "type") && data.returnValue === undefined ? null : data.returnValue; + }); + module[methodName].BDFDB_Patches = patches; + patches[type] = {plugins: {}, cancel: _ => { + if (!config.noCache) BDFDB.ArrayUtils.remove(Internal.patchCancels, patches[type].cancel, true); + delete patches[type]; + if (!config.noCache && BDFDB.ObjectUtils.isEmpty(patches)) delete module[methodName].BDFDB_Patches; + mainCancel(); + }}; + if (!config.noCache) { + if (!BDFDB.ArrayUtils.is(Internal.patchCancels)) Internal.patchCancels = []; + Internal.patchCancels.push(patches[type].cancel); } - if (args[0] != module) data.instance = args[0] || {props: args[1][0]}; - for (let priority in patches[type].plugins) for (let id in BDFDB.ObjectUtils.sort(patches[type].plugins[priority])) { - let tempReturn = BDFDB.TimeUtils.suppress(patches[type].plugins[priority][id], `"${type}" callback of ${methodName} in ${name}`, {name: patches[type].plugins[priority][id].pluginName, version: patches[type].plugins[priority][id].pluginVersion})(data); - if (type != "before" && tempReturn !== undefined) data.returnValue = tempReturn; - } - if (type == "instead" && callInsteadAfterwards && !stopInsteadCall) BDFDB.TimeUtils.suppress(data.callOriginalMethod, `originalMethod of ${methodName} in ${name}`, {name: "Discord"})(); - - if (type != "before") return (methodName == "render" || methodName == "type") && data.returnValue === undefined ? null : data.returnValue; - }); - module[methodName].BDFDB_Patches = patches; - patches[type] = {plugins: {}, cancel: _ => { - if (!config.noCache) BDFDB.ArrayUtils.remove(Internal.patchCancels, patches[type].cancel, true); - delete patches[type]; - if (!config.noCache && BDFDB.ObjectUtils.isEmpty(patches)) delete module[methodName].BDFDB_Patches; - mainCancel(); - }}; - if (!config.noCache) { - if (!BDFDB.ArrayUtils.is(Internal.patchCancels)) Internal.patchCancels = []; - Internal.patchCancels.push(patches[type].cancel); } - } - if (!patches[type].plugins[patchPriority]) patches[type].plugins[patchPriority] = {}; - patches[type].plugins[patchPriority][pluginId] = (...args) => { - if (config.once || !plugin.started) cancel(); - return patchMethods[type](...args); - }; - patches[type].plugins[patchPriority][pluginId].pluginName = pluginName; - patches[type].plugins[patchPriority][pluginId].pluginVersion = pluginVersion; + if (!patches[type].plugins[patchPriority]) patches[type].plugins[patchPriority] = {}; + patches[type].plugins[patchPriority][pluginId] = (...args) => { + if (config.once || !plugin.started) cancel(); + return patchMethods[type](...args); + }; + patches[type].plugins[patchPriority][pluginId].pluginName = pluginName; + patches[type].plugins[patchPriority][pluginId].pluginVersion = pluginVersion; + } catch (err) {BDFDB.LogUtils.error(["Could not patch Component!", `"${type}" Patch of ${methodName} in ${name}`, err], plugin);} } } if (BDFDB.ObjectUtils.is(plugin) && !config.once && !config.noCache) { @@ -2391,49 +2462,48 @@ module.exports = (_ => { return false; }; Internal.findModuleViaData = (moduleStorage, dataStorage, item) => { - if (dataStorage[item]) { - let defaultExport = typeof dataStorage[item].exported != "boolean" ? true : dataStorage[item].exported; - if (dataStorage[item].props) moduleStorage[item] = BDFDB.ModuleUtils.findByProperties(dataStorage[item].props, {defaultExport}); - else if (dataStorage[item].protos) moduleStorage[item] = BDFDB.ModuleUtils.findByPrototypes(dataStorage[item].protos, {defaultExport}); - else if (dataStorage[item].name) moduleStorage[item] = BDFDB.ModuleUtils.findByName(dataStorage[item].name, {defaultExport}); - else if (dataStorage[item].strings) { - if (dataStorage[item].nonStrings) { - moduleStorage[item] = Internal.findModule("strings + nonStrings", JSON.stringify([dataStorage[item].strings, dataStorage[item].nonStrings].flat(10)), m => Internal.checkModuleStrings(m, dataStorage[item].strings) && Internal.checkModuleStrings(m, dataStorage[item].nonStrings, {hasNot: true}) && m, {defaultExport}); - } - else moduleStorage[item] = BDFDB.ModuleUtils.findByString(dataStorage[item].strings, {defaultExport}); + if (!dataStorage[item]) return; + let defaultExport = typeof dataStorage[item].exported != "boolean" ? true : dataStorage[item].exported; + if (dataStorage[item].props) moduleStorage[item] = BDFDB.ModuleUtils.findByProperties(dataStorage[item].props, {defaultExport: defaultExport, moduleName: item}); + else if (dataStorage[item].protos) moduleStorage[item] = BDFDB.ModuleUtils.findByPrototypes(dataStorage[item].protos, {defaultExport: defaultExport, moduleName: item}); + else if (dataStorage[item].name) moduleStorage[item] = BDFDB.ModuleUtils.findByName(dataStorage[item].name, {defaultExport: defaultExport, moduleName: item}); + else if (dataStorage[item].strings) { + if (dataStorage[item].nonStrings) { + moduleStorage[item] = Internal.findModule("strings + nonStrings", JSON.stringify([dataStorage[item].strings, dataStorage[item].nonStrings].flat(10)), m => Internal.checkModuleStrings(m, dataStorage[item].strings) && Internal.checkModuleStrings(m, dataStorage[item].nonStrings, {hasNot: true}) && m, {defaultExport: defaultExport, moduleName: item}); } - if (dataStorage[item].value) moduleStorage[item] = (moduleStorage[item] || {})[dataStorage[item].value]; - if (dataStorage[item].assign) moduleStorage[item] = Object.assign({}, moduleStorage[item]); - if (moduleStorage[item]) { - if (dataStorage[item].funcStrings) moduleStorage[item] = (Object.entries(moduleStorage[item]).find(n => { - if (!n || !n[1]) return; - let funcString = typeof n[1] == "function" ? n[1].toString() : (_ => {try {return JSON.stringify(n[1])}catch(err){return n[1].toString()}})(); - let renderFuncString = typeof n[1].render == "function" && n[1].render.toString() || ""; - return [dataStorage[item].funcStrings].flat(10).filter(s => s && typeof s == "string").every(string => funcString.indexOf(string) > -1 || renderFuncString.indexOf(string) > -1); - }) || [])[1]; - if (dataStorage[item].map) { - dataStorage[item]._originalModule = moduleStorage[item]; - dataStorage[item]._mappedItems = {}; - moduleStorage[item] = new Proxy(Object.assign({}, dataStorage[item]._originalModule, dataStorage[item].map), { - get: function (_, item2) { - if (dataStorage[item]._originalModule[item2]) return dataStorage[item]._originalModule[item2]; - if (dataStorage[item]._mappedItems[item2]) return dataStorage[item]._originalModule[dataStorage[item]._mappedItems[item2]]; - if (!dataStorage[item].map[item2]) return dataStorage[item]._originalModule[item2]; - let foundFunc = Object.entries(dataStorage[item]._originalModule).find(n => { - if (!n || !n[1]) return; - let funcString = typeof n[1] == "function" ? n[1].toString() : (_ => {try {return JSON.stringify(n[1])}catch(err){return n[1].toString()}})(); - let renderFuncString = typeof n[1].render == "function" && n[1].render.toString() || ""; - return [dataStorage[item].map[item2]].flat(10).filter(s => s && typeof s == "string").every(string => funcString.indexOf(string) > -1 || renderFuncString.indexOf(string) > -1); - }); - if (foundFunc) { - dataStorage[item]._mappedItems[item2] = foundFunc[0]; - return foundFunc[1]; - } - return "div"; - } + else moduleStorage[item] = BDFDB.ModuleUtils.findByString(dataStorage[item].strings, {defaultExport: defaultExport, moduleName: item}); + } + if (dataStorage[item].value) moduleStorage[item] = (moduleStorage[item] || {})[dataStorage[item].value]; + if (dataStorage[item].assign) moduleStorage[item] = Object.assign({}, moduleStorage[item]); + if (!moduleStorage[item]) return; + if (moduleStorage[item][item]) moduleStorage[item] = moduleStorage[item][item]; + if (dataStorage[item].funcStrings) moduleStorage[item] = (Object.entries(moduleStorage[item]).find(n => { + if (!n || !n[1]) return; + let funcString = typeof n[1] == "function" ? n[1].toString() : (_ => {try {return JSON.stringify(n[1])}catch(err){return n[1].toString()}})(); + let renderFuncString = typeof n[1].render == "function" && n[1].render.toString() || ""; + return (funcString || renderFuncString) && [dataStorage[item].funcStrings].flat(10).filter(s => s && typeof s == "string").every(string => funcString && funcString.indexOf(string) > -1 || renderFuncString && renderFuncString.indexOf(string) > -1); + }) || [])[1]; + if (dataStorage[item].map) { + dataStorage[item]._originalModule = moduleStorage[item]; + dataStorage[item]._mappedItems = {}; + moduleStorage[item] = new Proxy(Object.assign({}, dataStorage[item]._originalModule, dataStorage[item].map), { + get: function (_, item2) { + if (dataStorage[item]._originalModule[item2]) return dataStorage[item]._originalModule[item2]; + if (dataStorage[item]._mappedItems[item2]) return dataStorage[item]._originalModule[dataStorage[item]._mappedItems[item2]]; + if (!dataStorage[item].map[item2]) return dataStorage[item]._originalModule[item2]; + let foundFunc = dataStorage[item].map[item2] && dataStorage[item].map[item2].length == 1 && dataStorage[item]._originalModule[dataStorage[item].map[item2][0]] ? [dataStorage[item].map[item2][0], dataStorage[item]._originalModule[dataStorage[item].map[item2][0]]] : Object.entries(dataStorage[item]._originalModule).find(n => { + if (!n || !n[1]) return; + let funcString = typeof n[1] == "function" ? n[1].toString() : (_ => {try {return JSON.stringify(n[1])}catch(err){return n[1].toString()}})(); + let renderFuncString = typeof n[1].render == "function" && n[1].render.toString() || ""; + return [dataStorage[item].map[item2]].flat(10).filter(s => s && typeof s == "string").every(string => funcString && funcString.replace(/[\n\t\r]/g, "").indexOf(string) > -1 || renderFuncString && renderFuncString.replace(/[\n\t\r]/g, "").indexOf(string) > -1); }); + if (foundFunc) { + dataStorage[item]._mappedItems[item2] = foundFunc[0]; + return foundFunc[1]; + } + return "div"; } - } + }); } }; @@ -2452,9 +2522,36 @@ module.exports = (_ => { }); BDFDB.LibraryModules = Internal.LibraryModules; - if (Internal.LibraryModules.KeyCodeUtils && InternalData.LibraryModules.KeyCodeUtils._originalModule) InternalData.LibraryModules.KeyCodeUtils._originalModule.getString = function (keyArray) { - return Internal.LibraryModules.KeyCodeUtils.toName([keyArray].flat(10).filter(n => n).map(keyCode => [Internal.DiscordConstants.KeyboardDeviceTypes.KEYBOARD_KEY, Internal.LibraryModules.KeyCodeUtils.keyToCode((Object.entries(Internal.LibraryModules.KeyEvents.codes).find(n => n[1] == keyCode && Internal.LibraryModules.KeyCodeUtils.keyToCode(n[0], null)) || [])[0], null) || keyCode]), true); - }; + if (Internal.LibraryModules.KeyCodeUtils) { + let originalModule = LibraryModules.KeyCodeUtils; + LibraryModules.KeyCodeUtils = new Proxy(originalModule, { + get: function (_, item) { + if (item == "getString") return getString; + else if (item == "_originalModule") return originalModule; + else if (originalModule[item]) return originalModule[item]; + else return null; + } + }); + + let codeMap = BDFDB.ObjectUtils.invert(Internal.LibraryModules.PlatformUtils.isLinux() ? Internal.DiscordConstants.LinuxKeyToCode : Internal.LibraryModules.PlatformUtils.isMac() ? Internal.DiscordConstants.MacosKeyToCode : Internal.LibraryModules.PlatformUtils.isWindows() ? Internal.DiscordConstants.WindowsKeyToCode : {}); + let keyMap = [["META", "⌘"], ["RIGHT META", "RIGHT ⌘"], ["SHIFT", "⇧"], ["RIGHT SHIFT", "RIGHT ⇧"], ["ALT", "⌥"], ["RIGHT ALT", "RIGHT ⌥"], ["CTRL", "⌃"], ["RIGHT CTRL", "RIGHT ⌃"], ["ENTER", "↵"], ["BACKSPACE", "⌫"], ["DEL", "⌦"], ["ESC", "⎋"], ["PAGEUP", "⇞"], ["PAGEDOWN", "⇟"], ["UP", "↑"], ["DOWN", "↓"], ["LEFT", "←"], ["RIGHT", "→"], ["HOME", "↖"], ["END", "↘"], ["TAB", "⇥"], ["SPACE", "␣"]]; + let mapKeys = key => { + let upperCaseKey = key.toUpperCase(); + for (let [name, mappedKey] of mapKeys) if (name === upperCaseKey) return mappedKey; + return key; + }; + const getString = function (keyArray, upperCase = true) { + let strings = [keyArray].flat(10).filter(n => n).map(keyCode => { + let code = Internal.LibraryModules.KeyCodeUtils.keyToCode((Object.entries(Internal.LibraryModules.KeyEvents.codes).find(n => n[1] == keyCode && Internal.LibraryModules.KeyCodeUtils.keyToCode(n[0], null)) || [])[0], null) || keyCode; + return codeMap[code] || "UNK".concat(code) + }).filter(n => n != null); + if (!upperCase) return strings.join("+"); + else { + strings = window.navigator.appVersion.indexOf("Mac OS X") != -1 ? strings.map(mapKeys) : strings; + return strings.join(" + ").toUpperCase(); + } + }; + } const MyReact = {}; MyReact.childrenToArray = function (parent) { @@ -2815,6 +2912,7 @@ module.exports = (_ => { return: config.up ? true : false, sibling: config.up ? false : true }; + let whitelistKeys = Object.keys(whitelist); let blacklist = { contextSection: true }; @@ -2826,7 +2924,7 @@ module.exports = (_ => { depth++; let result = undefined; if (instance && !Node.prototype.isPrototypeOf(instance) && !BDFDB.ReactUtils.getInstance(instance) && depth < maxDepth && performance.now() - start < maxTime) { - let keys = Object.keys(instance); + let keys = Object.keys(instance).sort((x, y) => whitelistKeys.indexOf(x) < whitelistKeys.indexOf(y) ? -1 : 1); for (let i = 0; result === undefined && i < keys.length; i++) { let key = keys[i]; if (key && !blacklist[key]) { @@ -2872,7 +2970,7 @@ module.exports = (_ => { BDFDB.ReactUtils.unmountComponentAtNode(tempNode); return returnValue; }; - BDFDB.ReactUtils = new Proxy(LibraryModules, { + BDFDB.ReactUtils = new Proxy({}, { get: function (_, item) { if (MyReact[item]) return MyReact[item]; else if (LibraryModules.React[item]) return LibraryModules.React[item]; @@ -2946,9 +3044,9 @@ module.exports = (_ => { status = typeof status == "string" ? status.toLowerCase() : null; let color = ""; switch (status) { - case "online": color = (useColor ? Internal.DiscordConstants.Colors.GREEN_360 : "var(--status-positive)"); break; - case "idle": color = (useColor ? Internal.DiscordConstants.Colors.YELLOW_300 : "var(--status-warning)"); break; - case "dnd": color = (useColor ? Internal.DiscordConstants.Colors.RED_400 : "var(--status-danger)"); break; + case "online": color = (useColor ? Internal.DiscordConstants.Colors.GREEN_360 : BDFDB.DiscordConstants.ColorsCSS.STATUS_POSITIVE); break; + case "idle": color = (useColor ? Internal.DiscordConstants.Colors.YELLOW_300 : BDFDB.DiscordConstants.ColorsCSS.STATUS_WARNING); break; + case "dnd": color = (useColor ? Internal.DiscordConstants.Colors.RED_400 : BDFDB.DiscordConstants.ColorsCSS.STATUS_DANGER); break; case "playing": color = (useColor ? Internal.DiscordConstants.Colors.BRAND : "var(--bdfdb-blurple)"); break; case "listening": color = Internal.DiscordConstants.Colors.SPOTIFY; break; case "streaming": color = Internal.DiscordConstants.Colors.TWITCH; break; @@ -2971,7 +3069,7 @@ module.exports = (_ => { }; BDFDB.UserUtils.getBanner = function (id = BDFDB.UserUtils.me.id, guildId = Internal.LibraryStores.SelectedGuildStore.getGuildId(), canAnimate = false) { let displayProfile = Internal.LibraryModules.MemberDisplayUtils.getDisplayProfile(id, guildId); - return (Internal.LibraryModules.IconUtils.getUserBannerURL(Object.assign({banner: displayProfile && displayProfile.banner, id: id}, {canAnimate})) || "").split("?")[0]; + return ((!guildId ? Internal.LibraryModules.IconUtils.getUserBannerURL({banner: displayProfile && displayProfile.banner, id, canAnimate}) : Internal.LibraryModules.IconUtils.getGuildMemberBannerURL({banner: displayProfile && displayProfile.banner, id, guildId, canAnimate})) || "").split("?")[0]; }; BDFDB.UserUtils.can = function (permission, id = BDFDB.UserUtils.me.id, channelId = Internal.LibraryStores.SelectedChannelStore.getChannelId()) { if (!Internal.DiscordConstants.Permissions[permission]) BDFDB.LogUtils.warn([permission, "not found in Permissions"]); @@ -3013,7 +3111,7 @@ module.exports = (_ => { return Internal.LibraryModules.IconUtils.getGuildBannerURL(guild).split("?")[0]; }; BDFDB.GuildUtils.getFolder = function (id) { - return Internal.LibraryModules.SortedGuildUtils.guildFolders.filter(n => n.folderId).find(n => n.guildIds.includes(id)); + return Internal.LibraryStores.SortedGuildStore.getGuildFolders().filter(n => n.folderId).find(n => n.guildIds.includes(id)); }; BDFDB.GuildUtils.openMenu = function (guild, e = mousePosition) { if (!guild) return; @@ -3048,7 +3146,7 @@ module.exports = (_ => { return BDFDB.ReactUtils.findValue(div, "folderId", {up: true}); }; BDFDB.FolderUtils.getDefaultName = function (folderId) { - let folder = Internal.LibraryModules.SortedGuildUtils.getGuildFolderById(folderId); + let folder = Internal.LibraryStores.SortedGuildStore.getGuildFolderById(folderId); if (!folder) return ""; let rest = 2 * Internal.DiscordConstants.MAX_GUILD_FOLDER_NAME_LENGTH; let names = [], allNames = folder.guildIds.map(guildId => (Internal.LibraryStores.GuildStore.getGuild(guildId) || {}).name).filter(n => n); @@ -3092,14 +3190,23 @@ module.exports = (_ => { BDFDB.ChannelUtils.rerenderAll = function (instant) { BDFDB.TimeUtils.clear(BDFDB.ChannelUtils.rerenderAll.timeout); BDFDB.ChannelUtils.rerenderAll.timeout = BDFDB.TimeUtils.timeout(_ => { - let ChannelsIns = BDFDB.ReactUtils.findOwner(document.querySelector(BDFDB.dotCN.guildchannels), {name: "Channels", unlimited: true}); - let ChannelsPrototype = BDFDB.ObjectUtils.get(ChannelsIns, `${BDFDB.ReactUtils.instanceKey}.type.prototype`); - if (ChannelsIns && ChannelsPrototype) { - BDFDB.PatchUtils.patch({name: "BDFDB ChannelUtils"}, ChannelsPrototype, "render", {after: e => { - e.returnValue.props.children = typeof e.returnValue.props.children == "function" ? (_ => {return null;}) : []; - BDFDB.ReactUtils.forceUpdate(ChannelsIns); - }}, {once: true}); - BDFDB.ReactUtils.forceUpdate(ChannelsIns); + let ChannelsIns = BDFDB.ReactUtils.findOwner(document.querySelector(BDFDB.dotCN.guildchannels), {name: "ChannelsList", unlimited: true}); + if (!ChannelsIns) return; + else { + if (ChannelsIns && ChannelsIns.props && ChannelsIns.props.guildChannels.categories && Object.keys(ChannelsIns.props.guildChannels.categories).length) { + let category = ChannelsIns.props.guildChannels.categories[Object.keys(ChannelsIns.props.guildChannels.categories)[0]]; + category.isCollapsed ? BDFDB.LibraryModules.CategoryCollapseUtils.categoryCollapse(category.id) : BDFDB.LibraryModules.CategoryCollapseUtils.categoryExpand(category.id); + } + else { + let ChannelsPrototype = BDFDB.ObjectUtils.get(ChannelsIns, `${BDFDB.ReactUtils.instanceKey}.type.prototype`); + if (ChannelsIns && ChannelsPrototype) { + BDFDB.PatchUtils.patch({name: "BDFDB ChannelUtils"}, ChannelsPrototype, "render", {after: e => { + e.returnValue.props.children = typeof e.returnValue.props.children == "function" ? (_ => {return null;}) : []; + BDFDB.ReactUtils.forceUpdate(ChannelsIns); + }}, {once: true}); + BDFDB.ReactUtils.forceUpdate(ChannelsIns); + } + } } }, instant ? 0 : 1000); }; @@ -3122,6 +3229,7 @@ module.exports = (_ => { BDFDB.ColorUtils = {}; BDFDB.ColorUtils.convert = function (color, conv, type) { + if (typeof color == "string" && color.indexOf("var(--") == 0) return color; if (BDFDB.ObjectUtils.is(color)) { let newColor = {}; for (let pos in color) newColor[pos] = BDFDB.ColorUtils.convert(color[pos], conv, type); @@ -3130,7 +3238,7 @@ module.exports = (_ => { else { if (typeof color == "string") color = color.replace(/calc\(.+\s*\*\s*([0-9\.\%]+)\)/g, "$1"); conv = conv === undefined || !conv ? conv = "RGBCOMP" : conv.toUpperCase(); - type = type === undefined || !type || !["RGB", "RGBA", "RGBCOMP", "HSL", "HSLA", "HSLCOMP", "HEX", "HEXA", "INT"].includes(type.toUpperCase()) ? BDFDB.ColorUtils.getType(color) : type.toUpperCase(); + type = type === undefined || !type || !["RGB", "RGBA", "RGBCOMP", "HSL", "HSLA", "HSLCOMP", "HSV", "HSVA", "HSVCOMP", "HEX", "HEXA", "INT"].includes(type.toUpperCase()) ? BDFDB.ColorUtils.getType(color) : type.toUpperCase(); if (conv == "RGBCOMP") { switch (type) { case "RGBCOMP": @@ -3149,14 +3257,14 @@ module.exports = (_ => { return processRGB(rgbComp).concat(a); case "HSLCOMP": var hslComp = [].concat(color); - if (hslComp.length == 3) return BDFDB.ColorUtils.convert(`hsl(${processHSL(hslComp).join(",")})`, "RGBCOMP"); + if (hslComp.length == 3) return BDFDB.ColorUtils.convert(`hsl(${processHSX(hslComp).join(",")})`, "RGBCOMP"); else if (hslComp.length == 4) { let a = processA(hslComp.pop()); - return BDFDB.ColorUtils.convert(`hsl(${processHSL(hslComp).join(",")})`, "RGBCOMP").concat(a); + return BDFDB.ColorUtils.convert(`hsl(${processHSX(hslComp).join(",")})`, "RGBCOMP").concat(a); } break; case "HSL": - var hslComp = processHSL(color.replace(/\s/g, "").slice(4, -1).split(",")); + var hslComp = processHSX(color.replace(/\s/g, "").slice(4, -1).split(",")); var r, g, b, m, c, x, p, q; var h = hslComp[0], s = processPercentage(hslComp[1]), l = processPercentage(hslComp[2]); var a = s * Math.min(l, 1-l); @@ -3165,6 +3273,32 @@ module.exports = (_ => { case "HSLA": var hslComp = color.replace(/\s/g, "").slice(5, -1).split(","); return BDFDB.ColorUtils.convert(`hsl(${hslComp.slice(0, 3).join(",")})`, "RGBCOMP").concat(processA(hslComp.pop())); + case "HSVCOMP": + var hsvComp = [].concat(color); + if (hsvComp.length == 3) return BDFDB.ColorUtils.convert(`hsv(${processHSX(hsvComp).join(",")})`, "RGBCOMP"); + else if (hsvComp.length == 4) { + let a = processA(hsvComp.pop()); + return BDFDB.ColorUtils.convert(`hsv(${processHSX(hsvComp).join(",")})`, "RGBCOMP").concat(a); + } + break; + case "HSV": + var hsvComp = processHSX(color.replace(/\s/g, "").slice(4, -1).split(",")); + var r, g, b, i, f, p, q, t; + var h = hsvComp[0] / 360, s = processPercentage(hsvComp[1]), v = processPercentage(hsvComp[2]); + i = Math.floor(h * 6), f = h * 6 - i, p = v * (1 - s), q = v * (1 - f * s), t = v * (1 - (1 - f) * s); + + switch (i % 6) { + case 0: r = v, g = t, b = p; break; + case 1: r = q, g = v, b = p; break; + case 2: r = p, g = v, b = t; break; + case 3: r = p, g = q, b = v; break; + case 4: r = t, g = p, b = v; break; + case 5: r = v, g = p, b = q; break; + } + return [Math.round(r * 255), Math.round(g * 255), Math.round(b * 255)]; + case "HSVA": + var hsvComp = color.replace(/\s/g, "").slice(5, -1).split(","); + return BDFDB.ColorUtils.convert(`hsv(${hsvComp.slice(0, 3).join(",")})`, "RGBCOMP").concat(processA(hsvComp.pop())); case "HEX": var hex = /^#([a-f\d]{1})([a-f\d]{1})([a-f\d]{1})$|^#([a-f\d]{2})([a-f\d]{2})([a-f\d]{2})$/i.exec(color); return [parseInt(hex[1] + hex[1] || hex[4], 16), parseInt(hex[2] + hex[2] || hex[5], 16), parseInt(hex[3] + hex[3] || hex[6], 16)]; @@ -3179,26 +3313,27 @@ module.exports = (_ => { } } else { - if (conv && type && conv.indexOf("HSL") == 0 && type.indexOf("HSL") == 0) { - if (type == "HSLCOMP") { - let hslComp = [].concat(color); + if (conv && type && (conv.indexOf("HSL") == 0 && type.indexOf("HSL") == 0 || conv.indexOf("HSV") == 0 && type.indexOf("HSV") == 0)) { + let name = type.indexOf("HSL") == 0 ? "HSL" : "HSV"; + if (type == `${name}COMP`) { + let comp = [].concat(color); switch (conv) { - case "HSLCOMP": - if (hslComp.length == 3) return processHSL(hslComp); - else if (hslComp.length == 4) { - var a = processA(hslComp.pop()); - return processHSL(hslComp).concat(a); + case `${name}COMP`: + if (comp.length == 3) return processHSX(comp); + else if (comp.length == 4) { + var a = processA(comp.pop()); + return processHSX(comp).concat(a); } break; - case "HSL": - return `hsl(${processHSL(hslComp.slice(0, 3)).join(",")})`; - case "HSLA": - hslComp = hslComp.slice(0, 4); - var a = hslComp.length == 4 ? processA(hslComp.pop()) : 1; - return `hsla(${processHSL(hslComp).concat(a).join(",")})`; + case name: + return `${name.toLowerCase()}(${processHSX(comp.slice(0, 3)).join(",")})`; + case `${name}A`: + comp = comp.slice(0, 4); + var a = comp.length == 4 ? processA(comp.pop()) : 1; + return `${name.toLowerCase()}a(${processHSX(comp).concat(a).join(",")})`; } } - return BDFDB.ColorUtils.convert(color.replace(/\s/g, "").slice(color.toUpperCase().indexOf("HSLA") == 0 ? 5 : 4, -1).split(","), conv, "HSLCOMP"); + return BDFDB.ColorUtils.convert(color.replace(/\s/g, "").slice(color.toUpperCase().indexOf("A") == 3 ? 5 : 4, -1).split(","), conv, `${name}COMP`); } else { let rgbComp = type == "RGBCOMP" ? [].concat(color) : BDFDB.ColorUtils.convert(color, "RGBCOMP", type); @@ -3211,21 +3346,45 @@ module.exports = (_ => { return `rgba(${processRGB(rgbComp).concat(a).join(",")})`; case "HSLCOMP": var a = rgbComp.length == 4 ? processA(rgbComp.pop()) : null; - var hslComp = processHSL(BDFDB.ColorUtils.convert(rgbComp, "HSL").replace(/\s/g, "").split(",")); + var hslComp = processHSX(BDFDB.ColorUtils.convert(rgbComp, "HSL").replace(/\s/g, "").split(",")); return a != null ? hslComp.concat(a) : hslComp; case "HSL": + var r = processC(rgbComp[0]) / 255, g = processC(rgbComp[1]) / 255, b = processC(rgbComp[2]) / 255; + var max = Math.max(r, g, b), min = Math.min(r, g, b); + + var h, s, l; + h = s = l = (max + min) / 2; + + if (max === min) return `hsl(${processHSX([0, 0, l * 100]).join(",")})`; + + var dif = max - min; + s = l >= 0.5 ? dif / (2 - (max + min)) : dif / (max + min); + switch (max) { + case r: h = ((g - b) / dif + 0) * 60; break; + case g: h = ((b - r) / dif + 2) * 60; break; + case b: h = ((r - g) / dif + 4) * 60; break; + } + return `hsl(${processHSX([Math.round(h * 360), s * 100, l * 100]).join(",")})`; + case "HSLA": + var a = rgbComp.length == 4 ? processA(rgbComp.pop()) : 1; + return `hsla(${BDFDB.ColorUtils.convert(rgbComp, "HSL").slice(4, -1).split(",").concat(a).join(",")})`; + case "HSVCOMP": + var a = rgbComp.length == 4 ? processA(rgbComp.pop()) : null; + var hsvComp = processHSX(BDFDB.ColorUtils.convert(rgbComp, "HSV").replace(/\s/g, "").split(",")); + return a != null ? hsvComp.concat(a) : hsvComp; + case "HSV": var r = processC(rgbComp[0]), g = processC(rgbComp[1]), b = processC(rgbComp[2]); - var max = Math.max(r, g, b), min = Math.min(r, g, b), dif = max - min, h, l = max === 0 ? 0 : dif / max, s = max / 255; + var max = Math.max(r, g, b), min = Math.min(r, g, b), dif = max - min, h, s = max === 0 ? 0 : dif / max, v = max / 255; switch (max) { case min: h = 0; break; case r: h = g - b + dif * (g < b ? 6 : 0); h /= 6 * dif; break; case g: h = b - r + dif * 2; h /= 6 * dif; break; case b: h = r - g + dif * 4; h /= 6 * dif; break; } - return `hsl(${processHSL([Math.round(h * 360), l * 100, s * 100]).join(",")})`; - case "HSLA": + return `hsv(${processHSX([Math.round(h * 360), s * 100, v * 100]).join(",")})`; + case "HSVA": var a = rgbComp.length == 4 ? processA(rgbComp.pop()) : 1; - return `hsla(${BDFDB.ColorUtils.convert(rgbComp, "HSL").slice(4, -1).split(",").concat(a).join(",")})`; + return `hsva(${BDFDB.ColorUtils.convert(rgbComp, "HSV").slice(4, -1).split(",").concat(a).join(",")})`; case "HEX": return ("#" + (0x1000000 + (rgbComp[2] | rgbComp[1] << 8 | rgbComp[0] << 16)).toString(16).slice(1)).toUpperCase(); case "HEXA": @@ -3268,7 +3427,7 @@ module.exports = (_ => { return (isNaN(sl) || sl > 100 ? 100 : sl < 0 ? 0 : sl) + "%"; } }; - function processHSL (comp) { + function processHSX (comp) { comp = [].concat(comp); let h = parseFloat(comp.shift().toString().replace(/[^0-9\.\-]/g, "")); h = isNaN(h) || h > 360 ? 360 : h < 0 ? 0 : h; @@ -3283,6 +3442,7 @@ module.exports = (_ => { }; }; BDFDB.ColorUtils.setAlpha = function (color, a, conv) { + if (typeof color == "string" && color.indexOf("var(--") == 0) return color; if (BDFDB.ObjectUtils.is(color)) { let newcolor = {}; for (let pos in color) newcolor[pos] = BDFDB.ColorUtils.setAlpha(color[pos], a, conv); @@ -3315,6 +3475,7 @@ module.exports = (_ => { return null; }; BDFDB.ColorUtils.change = function (color, value, conv) { + if (typeof color == "string" && color.indexOf("var(--") == 0) return color; value = parseFloat(value); if (color != null && typeof value == "number" && !isNaN(value)) { if (BDFDB.ObjectUtils.is(color)) { @@ -3345,6 +3506,7 @@ module.exports = (_ => { return null; }; BDFDB.ColorUtils.invert = function (color, conv) { + if (typeof color == "string" && color.indexOf("var(--") == 0) return color; if (BDFDB.ObjectUtils.is(color)) { let newColor = {}; for (let pos in color) newColor[pos] = BDFDB.ColorUtils.invert(color[pos], conv); @@ -3387,6 +3549,8 @@ module.exports = (_ => { else if (color.indexOf("RGBA(") == 0 && comp.length == 4 && isRGB(comp)) return "RGBA"; else if (color.indexOf("HSL(") == 0 && comp.length == 3 && isHSL(comp)) return "HSL"; else if (color.indexOf("HSLA(") == 0 && comp.length == 4 && isHSL(comp)) return "HSLA"; + else if (color.indexOf("HSV(") == 0 && comp.length == 3 && isHSL(comp)) return "HSV"; + else if (color.indexOf("HSVA(") == 0 && comp.length == 4 && isHSL(comp)) return "HSVA"; } } else if (typeof color === "number" && parseInt(color) == color && color > -1 && color < 16777216) return "INT"; @@ -3635,9 +3799,9 @@ module.exports = (_ => { }; BDFDB.DOMUtils.appendWebScript = function (url, container) { if (typeof url != "string") return; - if (!container && !document.head.querySelector("bd-head bd-scripts")) document.head.appendChild(BDFDB.DOMUtils.create(``)); - container = container || document.head.querySelector("bd-head bd-scripts") || document.head; - container = Node.prototype.isPrototypeOf(container) ? container : document.head; + if (!container && !document.body.querySelector("bd-head bd-scripts")) document.body.appendChild(BDFDB.DOMUtils.create(``)); + container = container || document.body.querySelector("bd-head bd-scripts") || document.body; + container = Node.prototype.isPrototypeOf(container) ? container : document.body; BDFDB.DOMUtils.removeWebScript(url, container); let script = document.createElement("script"); script.src = url; @@ -3645,36 +3809,36 @@ module.exports = (_ => { }; BDFDB.DOMUtils.removeWebScript = function (url, container) { if (typeof url != "string") return; - container = container || document.head.querySelector("bd-head bd-scripts") || document.head; - container = Node.prototype.isPrototypeOf(container) ? container : document.head; + container = container || document.body.querySelector("bd-head bd-scripts") || document.body; + container = Node.prototype.isPrototypeOf(container) ? container : document.body; BDFDB.DOMUtils.remove(container.querySelectorAll(`script[src="${url}"]`)); }; BDFDB.DOMUtils.appendWebStyle = function (url, container) { if (typeof url != "string") return; - if (!container && !document.head.querySelector("bd-head bd-styles")) document.head.appendChild(BDFDB.DOMUtils.create(``)); - container = container || document.head.querySelector("bd-head bd-styles") || document.head; - container = Node.prototype.isPrototypeOf(container) ? container : document.head; + if (!container && !document.body.querySelector("bd-head bd-styles")) document.body.appendChild(BDFDB.DOMUtils.create(``)); + container = container || document.body.querySelector("bd-head bd-styles") || document.body; + container = Node.prototype.isPrototypeOf(container) ? container : document.body; BDFDB.DOMUtils.removeWebStyle(url, container); container.appendChild(BDFDB.DOMUtils.create(``)); }; BDFDB.DOMUtils.removeWebStyle = function (url, container) { if (typeof url != "string") return; - container = container || document.head.querySelector("bd-head bd-styles") || document.head; - container = Node.prototype.isPrototypeOf(container) ? container : document.head; + container = container || document.body.querySelector("bd-head bd-styles") || document.body; + container = Node.prototype.isPrototypeOf(container) ? container : document.body; BDFDB.DOMUtils.remove(container.querySelectorAll(`link[href="${url}"]`)); }; BDFDB.DOMUtils.appendLocalStyle = function (id, css, container) { if (typeof id != "string" || typeof css != "string") return; - if (!container && !document.head.querySelector("bd-head bd-styles")) document.head.appendChild(BDFDB.DOMUtils.create(``)); - container = container || document.head.querySelector("bd-head bd-styles") || document.head; - container = Node.prototype.isPrototypeOf(container) ? container : document.head; + if (!container && !document.body.querySelector("bd-head bd-styles")) document.body.appendChild(BDFDB.DOMUtils.create(``)); + container = container || document.body.querySelector("bd-head bd-styles") || document.body; + container = Node.prototype.isPrototypeOf(container) ? container : document.body; BDFDB.DOMUtils.removeLocalStyle(id, container); container.appendChild(BDFDB.DOMUtils.create(``)); }; BDFDB.DOMUtils.removeLocalStyle = function (id, container) { if (typeof id != "string") return; - container = container || document.head.querySelector("bd-head bd-styles") || document.head; - container = Node.prototype.isPrototypeOf(container) ? container : document.head; + container = container || document.body.querySelector("bd-head bd-styles") || document.body; + container = Node.prototype.isPrototypeOf(container) ? container : document.body; BDFDB.DOMUtils.remove(container.querySelectorAll(`style[id="${id}CSS"]`)); }; @@ -3826,7 +3990,7 @@ module.exports = (_ => { oldTransitionState = props.transitionState; } componentWillUnmount() { - if (props.transitionState == 3) { + if (props.transitionState == 2) { for (let cancel of cancels) cancel(modalInstance); config.onClose(modalInstance); } @@ -3851,7 +4015,7 @@ module.exports = (_ => { }); }; - var MappedMenuItems = {}, RealMenuItems = BDFDB.ModuleUtils.find(m => { + var MappedMenuItems = {}, RealMenuItems = BDFDB.ModuleUtils.findByProperties("MenuCheckboxItem", "MenuItem") || BDFDB.ModuleUtils.find(m => { if (!m || typeof m != "function") return false; let string = m.toString(); return string.endsWith("{return null}}") && string.indexOf("(){return null}") > -1 && string.indexOf("catch(") == -1; @@ -3906,7 +4070,10 @@ module.exports = (_ => { let children = BDFDB.ArrayUtils.is(contextMenu.props.children) ? contextMenu.props.children : [contextMenu.props.children]; for (let i in children) if (children[i]) { if (check(children[i])) return [children, parseInt(i)]; - else if (children[i].props) { + else if (BDFDB.ArrayUtils.is(children[i])) { + for (let j in children[i]) if (check(children[i][j])) return [children[i], parseInt(j)]; + } + else if (children[i].props && children[i].props.children) { if (BDFDB.ArrayUtils.is(children[i].props.children) && children[i].props.children.length) { let [possibleChildren, possibleIndex] = BDFDB.ContextMenuUtils.findItem(children[i].props.children, config); if (possibleIndex > -1) return [possibleChildren, possibleIndex]; @@ -3918,6 +4085,19 @@ module.exports = (_ => { return [children[i].props.children, 0]; } } + else if (children[i].props.children.props && children[i].props.children.props.children) { + if (BDFDB.ArrayUtils.is(children[i].props.children.props.children) && children[i].props.children.props.children.length) { + let [possibleChildren, possibleIndex] = BDFDB.ContextMenuUtils.findItem(children[i].props.children.props.children, config); + if (possibleIndex > -1) return [possibleChildren, possibleIndex]; + } + else if (check(children[i].props.children.props.children)) { + if (config.group) return [children, parseInt(i)]; + else { + children[i].props.children.props.children = [children[i].props.children.props.children]; + return [children[i].props.children.props.children, 0]; + } + } + } } } return [children, -1]; @@ -3928,7 +4108,7 @@ module.exports = (_ => { if (!child) return false; let props = child.stateNode ? child.stateNode.props : child.props; if (!props) return false; - return config.id && config.id.some(key => props.id == key) || config.label && config.label.some(key => props.label == key); + return config.id && config.id.some(key => key == "devmode-copy-id" ? typeof props.id == "string" && props.id.startsWith(key) : props.id == key) || config.label && config.label.some(key => props.label == key); } }; @@ -3937,6 +4117,10 @@ module.exports = (_ => { if (typeof string != "string") return ""; else return "".concat(string.charAt(0).toUpperCase()).concat(string.slice(1)); }; + BDFDB.StringUtils.charIsUpperCase = function (string) { + if (typeof string != "string") return false; + else string[0].toUpperCase() === string[0] && string[0].toLowerCase() !== string[0]; + }; BDFDB.StringUtils.getAcronym = function (string) { if (typeof string != "string") return ""; return string.replace(/'s /g," ").replace(/\w+/g, n => n[0]).replace(/\s/g, ""); @@ -4086,25 +4270,6 @@ module.exports = (_ => { }; BDFDB.DiscordUtils = {}; - BDFDB.DiscordUtils.requestFileData = function (...args) { - let {url, uIndex} = args[0] && typeof args[0] == "string" ? {url: args[0], uIndex: 0} : (args[1] && typeof args[1] == "object" && typeof args[1].url == "string" ? {url: args[1], uIndex: 1} : {url: null, uIndex: -1}); - if (!url || typeof url != "string") return; - let {callback, cIndex} = args[1] && typeof args[1] == "function" ? {callback: args[1], cIndex: 1} : (args[2] && typeof args[2] == "function" ? {callback: args[2], cIndex: 2} : {callback: null, cIndex: -1}); - if (typeof callback != "function") return; - - let config = args[0] && typeof args[0] == "object" ? args[0] : (args[1] && typeof args[1] == "object" && args[1]); - - let timeoutMs = config && !isNaN(parseInt(config.timeout)) && config.timeout > 0 ? config.timeout : 600000; - let timedout = false, timeout = BDFDB.TimeUtils.timeout(_ => { - timedout = true; - callback(`Request Timeout after ${timeoutMs}ms`, null) - }, timeoutMs); - Internal.LibraryModules.FileRequestUtils.getFileData(url).then(buffer => { - BDFDB.TimeUtils.clear(timeout); - if (timedout) return; - callback(null, buffer); - }); - }; BDFDB.DiscordUtils.getSetting = function (category, key) { if (!category || !key) return; return BDFDB.LibraryStores.UserSettingsProtoStore && BDFDB.LibraryStores.UserSettingsProtoStore.settings[category] && BDFDB.LibraryStores.UserSettingsProtoStore.settings[category][key] && BDFDB.LibraryStores.UserSettingsProtoStore.settings[category][key].value; @@ -4244,7 +4409,7 @@ module.exports = (_ => { BDFDB.DiscordClasses = Object.assign({}, DiscordClasses); Internal.getDiscordClass = function (item, selector) { let className, fallbackClassName; - className = fallbackClassName = Internal.DiscordClassModules.BDFDB.BDFDBundefined + "-" + Internal.generateClassId(); + className = fallbackClassName = Internal.DiscordClassModules.BDFDB.BDFDBundefined + "_" + Internal.generateClassId(); if (DiscordClasses[item] === undefined) { BDFDB.LogUtils.warn([item, "not found in DiscordClasses"]); return className; @@ -4274,7 +4439,7 @@ module.exports = (_ => { return BDFDB.ArrayUtils.removeCopies(className.split(" ")).join(" ") || fallbackClassName; } }; - const generationChars = "0123456789ABCDEFGHIJKMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz-_".split(""); + const generationChars = "0123456789ABCDEFGHIJKMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz_-".split(""); Internal.generateClassId = function () { let id = ""; while (id.length < 6) id += generationChars[Math.floor(Math.random() * generationChars.length)]; @@ -4598,7 +4763,7 @@ module.exports = (_ => { style: { background: Internal.DiscordConstants.Colors.PRIMARY, borderRadius: 5, - color: "var(--status-danger)", + color: BDFDB.DiscordConstants.ColorsCSS.STATUS_DANGER, fontSize: 12, fontWeight: 600, padding: 6, @@ -4660,7 +4825,7 @@ module.exports = (_ => { return BDFDB.ReactUtils.createElement("div", { className: BDFDB.DOMUtils.formatClassName(this.props.className, BDFDB.disCN.badgeiconbadge, this.props.shape && Internal.LibraryComponents.Badges.BadgeShapes[this.props.shape] || Internal.LibraryComponents.Badges.BadgeShapes.ROUND), style: Object.assign({ - backgroundColor: this.props.disableColor ? null : (this.props.color || "var(--status-danger)") + backgroundColor: this.props.disableColor ? null : (this.props.color || BDFDB.DiscordConstants.ColorsCSS.STATUS_DANGER) }, this.props.style), children: BDFDB.ReactUtils.createElement(Internal.LibraryComponents.SvgIcon, { className: BDFDB.disCN.badgeicon, @@ -4680,7 +4845,7 @@ module.exports = (_ => { return BDFDB.ReactUtils.createElement("div", { className: BDFDB.DOMUtils.formatClassName(this.props.className, BDFDB.disCN.badgenumberbadge, this.props.shape && Internal.LibraryComponents.Badges.BadgeShapes[this.props.shape] || Internal.LibraryComponents.Badges.BadgeShapes.ROUND), style: Object.assign({ - backgroundColor: !this.props.disableColor && (this.props.color || "var(--status-danger)"), + backgroundColor: !this.props.disableColor && (this.props.color || BDFDB.DiscordConstants.ColorsCSS.STATUS_DANGER), width: this.getBadgeWidthForValue(this.props.count) }, this.props.style), onClick: this.handleClick.bind(this), @@ -4772,7 +4937,7 @@ module.exports = (_ => { children: [ !this.props.noRemove ? BDFDB.ReactUtils.createElement(Internal.LibraryComponents.Clickable, { "aria-label": BDFDB.LanguageUtils.LanguageStrings.REMOVE, - className: BDFDB.disCNS.hovercardremovebutton + BDFDB.disCN.hovercardremovebuttondefault, + className: BDFDB.disCNS.hovercardbutton + BDFDB.disCNS.hovercardremovebutton + BDFDB.disCN.hovercardremovebuttondefault, onClick: e => { if (typeof this.props.onRemove == "function") this.props.onRemove(e, this); BDFDB.ListenerUtils.stopEvent(e); @@ -5095,13 +5260,13 @@ module.exports = (_ => { render() { if (this.state.isGradient) this.props.color = Object.assign({}, this.props.color); - let hslFormat = this.props.alpha ? "HSLA" : "HSL"; + let colorFormat = this.props.alpha ? "HSVA" : "HSV"; let hexRegex = this.props.alpha ? /^#([a-f\d]{2})([a-f\d]{2})([a-f\d]{2})([a-f\d]{2})$/i : /^#([a-f\d]{2})([a-f\d]{2})([a-f\d]{2})$/i; - let selectedColor = BDFDB.ColorUtils.convert(this.state.isGradient ? this.props.color[this.state.selectedGradientCursor] : this.props.color, hslFormat) || BDFDB.ColorUtils.convert("#000000FF", hslFormat); - let currentGradient = (this.state.isGradient ? Object.entries(this.props.color, hslFormat) : [[0, selectedColor], [1, selectedColor]]); + let selectedColor = BDFDB.ColorUtils.convert(this.state.isGradient ? this.props.color[this.state.selectedGradientCursor] : this.props.color, colorFormat) || BDFDB.ColorUtils.convert("#000000FF", colorFormat); + let currentGradient = (this.state.isGradient ? Object.entries(this.props.color, colorFormat) : [[0, selectedColor], [1, selectedColor]]); - let [h, s, l] = BDFDB.ColorUtils.convert(selectedColor, "HSLCOMP"); + let [h, s, v] = BDFDB.ColorUtils.convert(selectedColor, "HSVCOMP"); let a = BDFDB.ColorUtils.getAlpha(selectedColor); a = a == null ? 1 : a; @@ -5118,10 +5283,10 @@ module.exports = (_ => { className: BDFDB.disCN.colorpickersaturation, children: BDFDB.ReactUtils.createElement("div", { className: BDFDB.disCN.colorpickersaturationcolor, - style: {position: "absolute", top: 0, right: 0, bottom: 0, left: 0, cursor: "crosshair", backgroundColor: BDFDB.ColorUtils.convert([h, "100%", "100%"], "RGB")}, + style: {position: "absolute", top: 0, right: 0, bottom: 0, left: 0, cursor: "crosshair", backgroundColor: BDFDB.ColorUtils.convert([h, "100%", "50%"], "RGB")}, onClick: event => { let rects = BDFDB.DOMUtils.getRects(BDFDB.DOMUtils.getParent(BDFDB.dotCN.colorpickersaturationcolor, event.target)); - this.handleColorChange(BDFDB.ColorUtils.convert([h, BDFDB.NumberUtils.mapRange([rects.left, rects.left + rects.width], [0, 100], event.clientX) + "%", BDFDB.NumberUtils.mapRange([rects.top, rects.top + rects.height], [100, 0], event.clientY) + "%", a], hslFormat)); + this.handleColorChange(BDFDB.ColorUtils.convert([h, BDFDB.NumberUtils.mapRange([rects.left, rects.left + rects.width], [0, 100], event.clientX) + "%", BDFDB.NumberUtils.mapRange([rects.top, rects.top + rects.height], [100, 0], event.clientY) + "%", a], colorFormat, "HSVCOMP")); }, onMouseDown: event => { let rects = BDFDB.DOMUtils.getRects(BDFDB.DOMUtils.getParent(BDFDB.dotCN.colorpickersaturationcolor, event.target)); @@ -5130,7 +5295,7 @@ module.exports = (_ => { document.removeEventListener("mousemove", mouseMove); }; let mouseMove = event2 => { - this.handleColorChange(BDFDB.ColorUtils.convert([h, BDFDB.NumberUtils.mapRange([rects.left, rects.left + rects.width], [0, 100], event2.clientX) + "%", BDFDB.NumberUtils.mapRange([rects.top, rects.top + rects.height], [100, 0], event2.clientY) + "%", a], hslFormat)); + this.handleColorChange(BDFDB.ColorUtils.convert([h, BDFDB.NumberUtils.mapRange([rects.left, rects.left + rects.width], [0, 100], event2.clientX) + "%", BDFDB.NumberUtils.mapRange([rects.top, rects.top + rects.height], [100, 0], event2.clientY) + "%", a], colorFormat, "HSVCOMP")); }; document.addEventListener("mouseup", mouseUp); document.addEventListener("mousemove", mouseMove); @@ -5149,7 +5314,7 @@ module.exports = (_ => { }), BDFDB.ReactUtils.createElement("div", { className: BDFDB.disCN.colorpickersaturationcursor, - style: {position: "absolute", cursor: "crosshair", left: s, top: `${BDFDB.NumberUtils.mapRange([0, 100], [100, 0], parseFloat(l))}%`}, + style: {position: "absolute", cursor: "crosshair", left: s, top: `${BDFDB.NumberUtils.mapRange([0, 100], [100, 0], parseFloat(v))}%`}, children: BDFDB.ReactUtils.createElement("div", { style: {width: 4, height: 4, boxShadow: "rgb(255, 255, 255) 0px 0px 0px 1.5px, rgba(0, 0, 0, 0.3) 0px 0px 1px 1px inset, rgba(0, 0, 0, 0.4) 0px 0px 1px 2px", borderRadius: "50%", transform: "translate(-2px, -2px)"} }) @@ -5168,7 +5333,7 @@ module.exports = (_ => { style: {padding: "0px 2px", position: "relative", height: "100%"}, onClick: event => { let rects = BDFDB.DOMUtils.getRects(BDFDB.DOMUtils.getParent(BDFDB.dotCN.colorpickerhuehorizontal, event.target)); - this.handleColorChange(BDFDB.ColorUtils.convert([BDFDB.NumberUtils.mapRange([rects.left, rects.left + rects.width], [0, 360], event.clientX), s, l, a], hslFormat)); + this.handleColorChange(BDFDB.ColorUtils.convert([BDFDB.NumberUtils.mapRange([rects.left, rects.left + rects.width], [0, 360], event.clientX), s, v, a], colorFormat, "HSVCOMP")); }, onMouseDown: event => { let rects = BDFDB.DOMUtils.getRects(BDFDB.DOMUtils.getParent(BDFDB.dotCN.colorpickerhuehorizontal, event.target)); @@ -5177,7 +5342,7 @@ module.exports = (_ => { document.removeEventListener("mousemove", mouseMove); }; let mouseMove = event2 => { - this.handleColorChange(BDFDB.ColorUtils.convert([BDFDB.NumberUtils.mapRange([rects.left, rects.left + rects.width], [0, 360], event2.clientX), s, l, a], hslFormat)); + this.handleColorChange(BDFDB.ColorUtils.convert([BDFDB.NumberUtils.mapRange([rects.left, rects.left + rects.width], [0, 360], event2.clientX), s, v, a], colorFormat, "HSVCOMP")); }; document.addEventListener("mouseup", mouseUp); document.addEventListener("mousemove", mouseMove); @@ -5211,10 +5376,10 @@ module.exports = (_ => { style: {position: "absolute", top: 0, right: 0, bottom: 0, left: 0}, children: BDFDB.ReactUtils.createElement("div", { className: BDFDB.disCN.colorpickeralphahorizontal, - style: {padding: "0px 2px", position: "relative", height: "100%", background: `linear-gradient(to right, ${BDFDB.ColorUtils.setAlpha([h, s, l], 0, "RGBA")}, ${BDFDB.ColorUtils.setAlpha([h, s, l], 1, "RGBA")}`}, + style: {padding: "0px 2px", position: "relative", height: "100%", background: `linear-gradient(to right, ${BDFDB.ColorUtils.setAlpha([h, s, v], 0, "RGBA")}, ${BDFDB.ColorUtils.setAlpha([h, s, v], 1, "RGBA")}`}, onClick: event => { let rects = BDFDB.DOMUtils.getRects(BDFDB.DOMUtils.getParent(BDFDB.dotCN.colorpickeralphahorizontal, event.target)); - this.handleColorChange(BDFDB.ColorUtils.setAlpha([h, s, l], BDFDB.NumberUtils.mapRange([rects.left, rects.left + rects.width], [0, 1], event.clientX), hslFormat)); + this.handleColorChange(BDFDB.ColorUtils.setAlpha([h, s, v], BDFDB.NumberUtils.mapRange([rects.left, rects.left + rects.width], [0, 1], event.clientX), colorFormat)); }, onMouseDown: event => { let rects = BDFDB.DOMUtils.getRects(BDFDB.DOMUtils.getParent(BDFDB.dotCN.colorpickeralphahorizontal, event.target)); @@ -5226,7 +5391,7 @@ module.exports = (_ => { }; let mouseMove = event2 => { this.state.draggingAlphaCursor = true; - this.handleColorChange(BDFDB.ColorUtils.setAlpha([h, s, l], BDFDB.NumberUtils.mapRange([rects.left, rects.left + rects.width], [0, 1], event2.clientX), hslFormat)); + this.handleColorChange(BDFDB.ColorUtils.setAlpha([h, s, v], BDFDB.NumberUtils.mapRange([rects.left, rects.left + rects.width], [0, 1], event2.clientX), colorFormat)); }; document.addEventListener("mouseup", mouseUp); document.addEventListener("mousemove", mouseMove); @@ -5268,7 +5433,7 @@ module.exports = (_ => { let rects = BDFDB.DOMUtils.getRects(event.target); let pos = BDFDB.NumberUtils.mapRange([rects.left, rects.left + rects.width], [0.01, 0.99], event.clientX); if (Object.keys(this.props.color).indexOf(pos) == -1) { - this.props.color[pos] = BDFDB.ColorUtils.convert("#000000FF", hslFormat); + this.props.color[pos] = BDFDB.ColorUtils.convert("#000000FF", colorFormat); this.state.selectedGradientCursor = pos; this.handleColorChange(); } @@ -5789,11 +5954,11 @@ module.exports = (_ => { .replace(/\$month/g, timeObj.toLocaleDateString(language, {month: "long"})) .replace(/\$dayS/g, timeObj.toLocaleDateString(language, {weekday: "short"})) .replace(/\$day/g, timeObj.toLocaleDateString(language, {weekday: "long"})) - .replace(/\$agoAmount/g, daysAgo < 0 ? "" : daysAgo > 1 ? Internal.DiscordObjects.Timestamp(timeObj.getTime()).fromNow() : BDFDB.LanguageUtils.LanguageStrings[`SEARCH_SHORTCUT_${daysAgo == 1 ? "YESTERDAY" : "TODAY"}`]) - .replace(/\$agoWeekdayS/g, daysAgo < 0 ? "" : daysAgo > 1 ? timeObj.toLocaleDateString(language, {weekday: "short"}) : BDFDB.LanguageUtils.LanguageStrings[`SEARCH_SHORTCUT_${daysAgo == 1 ? "YESTERDAY" : "TODAY"}`]) - .replace(/\$agoWeekday/g, daysAgo < 0 ? "" : daysAgo > 1 ? timeObj.toLocaleDateString(language, {weekday: "long"}) : BDFDB.LanguageUtils.LanguageStrings[`SEARCH_SHORTCUT_${daysAgo == 1 ? "YESTERDAY" : "TODAY"}`]) + .replace(/\$agoAmount/g, daysAgo < 0 || daysAgo > 1 ? Internal.DiscordObjects.Timestamp(timeObj.getTime()).fromNow() : BDFDB.LanguageUtils.LanguageStrings[`SEARCH_SHORTCUT_${daysAgo == 1 ? "YESTERDAY" : "TODAY"}`]) + .replace(/\$agoWeekdayS/g, daysAgo < 0 || daysAgo > 1 ? timeObj.toLocaleDateString(language, {weekday: "short"}) : BDFDB.LanguageUtils.LanguageStrings[`SEARCH_SHORTCUT_${daysAgo == 1 ? "YESTERDAY" : "TODAY"}`]) + .replace(/\$agoWeekday/g, daysAgo < 0 || daysAgo > 1 ? timeObj.toLocaleDateString(language, {weekday: "long"}) : BDFDB.LanguageUtils.LanguageStrings[`SEARCH_SHORTCUT_${daysAgo == 1 ? "YESTERDAY" : "TODAY"}`]) .replace(/\$agoDays/g, daysAgo < 0 ? "" : daysAgo > 1 ? BDFDB.LanguageUtils.LanguageStringsFormat(`GAME_LIBRARY_LAST_PLAYED_DAYS`, daysAgo) : BDFDB.LanguageUtils.LanguageStrings[`SEARCH_SHORTCUT_${daysAgo == 1 ? "YESTERDAY" : "TODAY"}`]) - .replace(/\$agoDate/g, daysAgo < 0 ? "" : daysAgo > 1 ? date : BDFDB.LanguageUtils.LanguageStrings[`SEARCH_SHORTCUT_${daysAgo == 1 ? "YESTERDAY" : "TODAY"}`]) + .replace(/\$agoDate/g, daysAgo < 0 || daysAgo > 1 ? date : BDFDB.LanguageUtils.LanguageStrings[`SEARCH_SHORTCUT_${daysAgo == 1 ? "YESTERDAY" : "TODAY"}`]) .replace(/\(\)|\[\]/g, "").replace(/,\s*$|^\s*,/g, "").replace(/ +/g, " ").trim(); }; CustomComponents.DateInput.formatDate = function (data, time) { @@ -5839,7 +6004,7 @@ module.exports = (_ => { .replace(/\$m/g, minutes) .replace(/\$ss/g, seconds < 10 ? `0${seconds}` : seconds) .replace(/\$s/g, seconds) - .replace(/\$uu/g, milli < 10 ? `00${seconds}` : milli < 100 ? `0${milli}` : milli) + .replace(/\$uu/g, milli < 10 ? `00${milli}` : milli < 100 ? `0${milli}` : milli) .replace(/\$u/g, milli) .trim(); @@ -5874,7 +6039,7 @@ module.exports = (_ => { children: BDFDB.ReactUtils.createElement(Internal.LibraryComponents.EmojiButton, { className: BDFDB.DOMUtils.formatClassName(this.props.className, BDFDB.disCN.emojiinputbutton), renderButtonContents: this.props.emoji ? _ => BDFDB.ReactUtils.createElement(Internal.LibraryComponents.Emoji, { - className: BDFDB.disCN.emoji, + className: BDFDB.disCN.emojiinputbuttonemoji, emojiId: this.props.emoji.id, emojiName: this.props.emoji.name }) : null @@ -5904,6 +6069,32 @@ module.exports = (_ => { }; Internal.setDefaultProps(CustomComponents.EmojiPickerButton, {allowManagedEmojis: false, allowManagedEmojisUsage: false}); + CustomComponents.EmptyStateImage = reactInitialized && class BDFDB_EmptyStateImage extends Internal.LibraryModules.React.Component { + render() { + let isLightTheme = BDFDB.DiscordUtils.getTheme() == BDFDB.disCN.themelight; + return BDFDB.ReactUtils.createElement(Internal.LibraryComponents.Flex, { + className: BDFDB.DOMUtils.formatClassName(BDFDB.disCN.pageimagewrapper, this.props.className), + direction: Internal.LibraryComponents.Flex.Direction.VERTICAL, + align: Internal.LibraryComponents.Flex.Align.CENTER, + children: [ + BDFDB.ReactUtils.createElement("div", { + className: BDFDB.DOMUtils.formatClassName(BDFDB.disCN.pageimage, BDFDB.disCN.margintop20, BDFDB.disCN.marginbottom20, this.props.imageClassName), + style: { + flex: "0 1 auto", + background: `url("${this.props.src || (isLightTheme ? this.props.lightSrc : this.props.darkSrc) || this.props.lightSrc || this.props.darkSrc || (isLightTheme ? "/assets/a72746e7108167af95c8.svg" : "/assets/01864c39871ce619d855.svg")}") center/contain no-repeat`, + width: this.props.width || "415px", + height: this.props.height || "200px" + } + }), + BDFDB.ReactUtils.createElement("div", { + className: BDFDB.disCN.pageimagetext, + children: this.props.text || BDFDB.LanguageUtils.LanguageStrings.AUTOCOMPLETE_NO_RESULTS_HEADER + }) + ] + }); + } + }; + CustomComponents.FavButton = reactInitialized && class BDFDB_FavButton extends Internal.LibraryModules.React.Component { handleClick() { this.props.isFavorite = !this.props.isFavorite; @@ -5947,7 +6138,7 @@ module.exports = (_ => { onChange: e => { let file = e.currentTarget.files[0]; if (this.refInput && file && (!filter.length || filter.some(n => file.type.indexOf(n) == 0))) { - this.refInput.props.value = this.props.searchFolders ? file.path.split(file.name).slice(0, -1).join(file.name) : `${this.props.mode == "url" ? "url('" : ""}${(this.props.useFilePath) ? file.path : `data:${file.type};base64,${Buffer.from(Internal.LibraryRequires.fs.readFileSync(file.path, "")).toString("base64")}`}${this.props.mode ? "')" : ""}`; + this.refInput.props.value = this.props.searchFolders ? file.path.split(file.name).slice(0, -1).join(file.name) : `${this.props.mode == "url" ? "url('" : ""}${(this.props.useFilePath) ? file.path : `data:${file.type};base64,${Internal.LibraryRequires.fs.readFileSync(file.path, "base64")}`}${this.props.mode ? "')" : ""}`; BDFDB.ReactUtils.forceUpdate(this.refInput); this.refInput.handleChange(this.refInput.props.value); } @@ -5991,12 +6182,12 @@ module.exports = (_ => { if (!guild) return BDFDB.ReactUtils.createElement("div", { className: BDFDB.disCN.guildsummaryemptyguild }); - let icon = BDFDB.ReactUtils.createElement(Internal.LibraryComponents.GuildIconComponents.Icon, { + let icon = BDFDB.ReactUtils.createElement(Internal.LibraryComponents.GuildIcon, { className: BDFDB.disCN.guildsummaryicon, guild: guild, showTooltip: this.props.showTooltip, tooltipPosition: "top", - size: Internal.LibraryComponents.GuildIconComponents.Icon.Sizes.SMALLER + size: Internal.LibraryComponents.GuildIcon.Sizes.SMALLER }); return this.props.switchOnClick ? BDFDB.ReactUtils.createElement(Internal.LibraryComponents.Clickable, { className: BDFDB.disCN.guildsummaryclickableicon, @@ -6748,7 +6939,9 @@ module.exports = (_ => { autoFocus: this.props.autoFocus ? this.props.autoFocus : false, maxVisibleItems: this.props.maxVisibleItems || 7, renderOptionLabel: this.props.optionRenderer, - onChange: this.handleChange.bind(this) + select: this.handleChange.bind(this), + serialize: typeof this.props.serialize == "function" ? this.props.serialize : _ => {}, + isSelected: typeof this.props.isSelected == "function" ? this.props.isSelected : (value => this.props.value == value) }), "inputClassName", "optionRenderer")) }); } @@ -6760,13 +6953,13 @@ module.exports = (_ => { return BDFDB.ReactUtils.createElement(Internal.LibraryComponents.Flex, { className: this.props.className, wrap: Internal.LibraryComponents.Flex.Wrap.WRAP, - children: [this.props.includeDMs && {name: BDFDB.LanguageUtils.LanguageStrings.DIRECT_MESSAGES, acronym: "DMs", id: Internal.DiscordConstants.ME, getIconURL: _ => {}}].concat(Internal.LibraryModules.SortedGuildUtils.getFlattenedGuilds()).filter(n => n).map(guild => BDFDB.ReactUtils.createElement(Internal.LibraryComponents.TooltipContainer, { + children: [this.props.includeDMs && {name: BDFDB.LanguageUtils.LanguageStrings.DIRECT_MESSAGES, acronym: "DMs", id: Internal.DiscordConstants.ME, getIconURL: _ => {}}].concat(Internal.LibraryStores.SortedGuildStore.getFlattenedGuildIds().map(Internal.LibraryStores.GuildStore.getGuild)).filter(n => n).map(guild => BDFDB.ReactUtils.createElement(Internal.LibraryComponents.TooltipContainer, { text: guild.name, children: BDFDB.ReactUtils.createElement("div", { className: BDFDB.DOMUtils.formatClassName(this.props.guildClassName, BDFDB.disCN.settingsguild, this.props.disabled.includes(guild.id) && BDFDB.disCN.settingsguilddisabled), - children: BDFDB.ReactUtils.createElement(Internal.LibraryComponents.GuildIconComponents.Icon, { + children: BDFDB.ReactUtils.createElement(Internal.LibraryComponents.GuildIcon, { guild: guild, - size: this.props.size || Internal.LibraryComponents.GuildIconComponents.Icon.Sizes.MEDIUM + size: this.props.size || Internal.LibraryComponents.GuildIcon.Sizes.MEDIUM }), onClick: e => { let isDisabled = this.props.disabled.includes(guild.id); @@ -7233,7 +7426,7 @@ module.exports = (_ => { let mini = props.size == Internal.LibraryComponents.Switch.Sizes.MINI; return BDFDB.ReactUtils.createElement(Internal.LibraryComponents.Animations.animated.div, { - className: BDFDB.DOMUtils.formatClassName(props.className, BDFDB.disCN.switch, mini && BDFDB.disCN.switchmini, "default-colors"), + className: BDFDB.DOMUtils.formatClassName(props.className, BDFDB.disCN.switch, props.value && BDFDB.disCN.switchchecked, mini && BDFDB.disCN.switchmini), onMouseDown: _ => { return !props.disabled && state[1](true); }, @@ -7433,6 +7626,7 @@ module.exports = (_ => { if (ele) { ele.style.setProperty("background-image", this.props.gradient, "important"); ele.style.setProperty("color", "transparent", "important"); + ele.style.setProperty("text-decoration-color", BDFDB.ColorUtils.convert(this.props.gradient[0], "RGBA"), "important"); ele.style.setProperty("-webkit-background-clip", "text", "important"); } } @@ -7483,7 +7677,7 @@ module.exports = (_ => { render() { let inputChildren = [ BDFDB.ReactUtils.createElement("input", BDFDB.ObjectUtils.exclude(Object.assign({}, this.props, { - className: BDFDB.DOMUtils.formatClassName(this.props.size && Internal.LibraryComponents.TextInput.Sizes[this.props.size.toUpperCase()] && BDFDB.disCN["input" + this.props.size.toLowerCase()] || BDFDB.disCN.inputdefault, this.props.inputClassName, this.props.focused && BDFDB.disCN.inputfocused, this.props.error || this.props.errorMessage ? BDFDB.disCN.inputerror : (this.props.success && BDFDB.disCN.inputsuccess), this.props.disabled && BDFDB.disCN.inputdisabled, this.props.editable && BDFDB.disCN.inputeditable), + className: BDFDB.DOMUtils.formatClassName(this.props.size || BDFDB.disCN.inputdefault, this.props.inputClassName, this.props.focused && BDFDB.disCN.inputfocused, this.props.error || this.props.errorMessage ? BDFDB.disCN.inputerror : (this.props.success && BDFDB.disCN.inputsuccess), this.props.disabled && BDFDB.disCN.inputdisabled, this.props.editable && BDFDB.disCN.inputeditable), type: this.props.type == "color" || this.props.type == "file" ? "text" : this.props.type, onChange: this.handleChange.bind(this), onInput: this.handleInput.bind(this), @@ -7772,30 +7966,6 @@ module.exports = (_ => { } }); - if (InternalData.LibraryComponents.Scrollers && Internal.LibraryComponents.Scrollers) { - InternalData.LibraryComponents.Scrollers._originalModule = Internal.LibraryComponents.Scrollers; - InternalData.LibraryComponents.Scrollers._mappedItems = {}; - for (let type of Object.keys(Internal.LibraryComponents.Scrollers)) if (Internal.LibraryComponents.Scrollers[type] && typeof Internal.LibraryComponents.Scrollers[type].render == "function") { - let scroller = BDFDB.ReactUtils.hookCall(Internal.LibraryComponents.Scrollers[type].render, {}); - if (scroller && scroller.props && scroller.props.className) { - let mappedType = ""; - switch (scroller.props.className) { - case BDFDB.disCN.scrollerthin: mappedType = "Thin"; break; - case BDFDB.disCN.scrollerauto: mappedType = "Auto"; break; - case BDFDB.disCN.scrollernone: mappedType = "None"; break; - } - if (mappedType) InternalData.LibraryComponents.Scrollers._mappedItems[mappedType] = type; - } - } - Internal.LibraryComponents.Scrollers = new Proxy(Object.assign({}, InternalData.LibraryComponents.Scrollers._originalModule), { - get: function (_, item) { - if (InternalData.LibraryComponents.Scrollers._originalModule[item]) return InternalData.LibraryComponents.Scrollers._originalModule[item]; - if (InternalData.LibraryComponents.Scrollers._mappedItems[item]) return InternalData.LibraryComponents.Scrollers._originalModule[InternalData.LibraryComponents.Scrollers._mappedItems[item]]; - return "div"; - } - }); - } - const RealFilteredMenuItems = Object.keys(RealMenuItems).filter(type => typeof RealMenuItems[type] == "function" && RealMenuItems[type].toString().replace(/[\n\t\r]/g, "").endsWith("{return null}")); for (let type of RealFilteredMenuItems) { let children = BDFDB.ObjectUtils.get(BDFDB.ReactUtils.hookCall(Internal.LibraryComponents.Menu, {hideScroller: true, children: BDFDB.ReactUtils.createElement(RealMenuItems[type], {})}, true), "props.children.props.children.props.children"); @@ -7822,8 +7992,8 @@ module.exports = (_ => { } LibraryComponents.MenuItems = new Proxy(RealFilteredMenuItems.reduce((a, v) => ({ ...a, [v]: v}), {}) , { get: function (_, item) { - if (RealMenuItems[item]) return RealMenuItems[item]; if (CustomComponents.MenuItems[item]) return CustomComponents.MenuItems[item]; + if (RealMenuItems[item]) return RealMenuItems[item]; if (MappedMenuItems[item] && RealMenuItems[MappedMenuItems[item]]) return RealMenuItems[MappedMenuItems[item]]; return null; } @@ -7863,27 +8033,24 @@ module.exports = (_ => { before: [ "BlobMask", "EmojiPickerListRow", + "MemberListItem", "Menu", "MessageActionsContextMenu", "MessageHeader", + "NameContainer", "SearchBar" ], after: [ "DiscordTag", - "UseCopyIdItem", "UserPopoutAvatar" ], componentDidMount: [ "Account", - "AnalyticsContext", - "MemberListItem", - "PrivateChannel" + "AnalyticsContext" ], componentDidUpdate: [ "Account", - "AnalyticsContext", - "MemberListItem", - "PrivateChannel" + "AnalyticsContext" ] }; @@ -8068,8 +8235,31 @@ module.exports = (_ => { Internal.processEmojiPickerListRow = function (e) { if (e.instance.props.emojiDescriptors && Internal.LibraryComponents.EmojiPickerButton.current && Internal.LibraryComponents.EmojiPickerButton.current.props && Internal.LibraryComponents.EmojiPickerButton.current.props.allowManagedEmojisUsage) for (let i in e.instance.props.emojiDescriptors) e.instance.props.emojiDescriptors[i] = Object.assign({}, e.instance.props.emojiDescriptors[i], {isDisabled: false}); }; + var memberStore = {}; Internal.processMemberListItem = function (e) { - Internal._processAvatarMount(e.instance.props.user, e.node.querySelector(BDFDB.dotCN.avatarwrapper), e.node); + if (!memberStore || !memberStore.channel || memberStore.channel.id != e.instance.props.channel.id) memberStore = {channel: e.instance.props.channel, members: {}}; + let src = BDFDB.UserUtils.getAvatar(e.instance.props.user.id); + if (!src) return; + memberStore.members[(src.split(".com")[1] || src).split("/").slice(0, 3).join("/").split(".")[0] + " " + e.instance.props.user.username] = e.instance.props.user; + }; + Internal.processNameContainer = function (e) { + if (e.instance.props.innerClassName != BDFDB.disCN.memberinner || !memberStore || !memberStore.members) return; + let avatar = BDFDB.ReactUtils.findChild(e.instance.props.avatar, {props: ["src"]}); + if (!avatar) return; + let src = avatar.props._originalSrc || avatar.props.src; + if (!src) return; + src = (src.split(".com")[1] || src).split("/").slice(0, 3).join("/").split(".")[0]; + let username = avatar.props["aria-label"]; + if (!memberStore.members[src + " " + username]) return; + e.instance.props.user = memberStore.members[src + " " + username]; + e.instance.props.channel = memberStore.channel; + e.instance.props.avatar = Internal._processAvatarRender(e.instance.props.user, e.instance.props.avatar) || e.instance.props.avatar; + }; + Internal.processMenu = function (e) { + if (e.instance.props && (e.instance.props.children || BDFDB.ArrayUtils.is(e.instance.props.children) && e.instance.props.children.length)) { + let patchCancel = BDFDB.PatchUtils.patch(BDFDB, Internal.LibraryModules.ContextMenuUtils, "closeContextMenu", {instead: e => {}}); + BDFDB.TimeUtils.timeout(_ => patchCancel()); + } }; Internal.processMessageActionsContextMenu = function (e) { e.instance.props.updatePosition = _ => {}; @@ -8085,15 +8275,9 @@ module.exports = (_ => { } } }; - Internal.processPrivateChannel = function (e) { - Internal._processAvatarMount(e.instance.props.user, e.node.querySelector(BDFDB.dotCN.avatarwrapper), e.node); - }; Internal.processSearchBar = function (e) { if (typeof e.instance.props.query != "string") e.instance.props.query = ""; }; - Internal.processUseCopyIdItem = function (e) { - if (!e.returnvalue) e.returnvalue = false; - }; Internal.processUserPopoutAvatar = function (e) { if (!e.instance.props.user) return; let [children, index] = BDFDB.ReactUtils.findParent(e.returnvalue, {props: [["className", BDFDB.disCN.userpopoutavatarwrapper]]}); diff --git a/.config/BetterDiscord/plugins/0BDFDB.raw.css b/.config/BetterDiscord/plugins/0BDFDB.raw.css index 2608755..8c083e2 100644 --- a/.config/BetterDiscord/plugins/0BDFDB.raw.css +++ b/.config/BetterDiscord/plugins/0BDFDB.raw.css @@ -565,6 +565,7 @@ img:not([src]), img[src=""], img[src="null"] { [REPLACE_CLASS_selectwrapper] [REPLACE_CLASS_select] { flex: 1 1 auto; } +[REPLACE_CLASS_selectwrapper] [REPLACE_CLASS_selectouter], [REPLACE_CLASS_selectwrapper] [REPLACE_CLASS_selectsearchinput] { width: 100%; } @@ -1061,7 +1062,7 @@ input[REPLACE_CLASS_input][REPLACE_CLASS_inputerror] { border-top: unset; border-bottom: 1px solid hsla(0,0%,100%,.1); } -[REPLACE_CLASS_modalwrapper] [REPLACE_CLASS_tabbarcontainer] { +[REPLACE_CLASS_modal] [REPLACE_CLASS_tabbarcontainer] { background: rgba(0, 0, 0, 0.1); border: none; box-shadow: 0 2px 3px 0 rgba(0, 0, 0, 0.05); @@ -1069,7 +1070,7 @@ input[REPLACE_CLASS_input][REPLACE_CLASS_inputerror] { margin: 0; padding: 16px 16px 0 16px; } -[REPLACE_CLASS_themedark] [REPLACE_CLASS_modalwrapper] [REPLACE_CLASS_tabbarcontainer] { +[REPLACE_CLASS_themedark] [REPLACE_CLASS_modal] [REPLACE_CLASS_tabbarcontainer] { background: rgba(0, 0, 0, 0.2); box-shadow: 0 2px 3px 0 rgba(0, 0, 0, 0.1); } @@ -1129,7 +1130,7 @@ input[REPLACE_CLASS_input][REPLACE_CLASS_inputerror] { pointer-events: none; } [REPLACE_CLASS__repomodalsettings] { - padding: 0 16px 16px 16px; + padding: 0 16px 16px 16px; } [REPLACE_CLASS__repochangelogbutton] { position: fixed; @@ -1158,6 +1159,13 @@ input[REPLACE_CLASS_input][REPLACE_CLASS_inputerror] { [REPLACE_CLASS__repolistscroller] { padding-top: 0; } +[REPLACE_CLASS__repolistheader] [REPLACE_CLASS_tabbarcontainer] { + display: flex; + align-items: flex-start; +} +[REPLACE_CLASS__repolistheader] [REPLACE_CLASS_quickselectwrapper] { + line-height: 20px; +} [REPLACE_CLASS__repoentry] [REPLACE_CLASS__repofooter] { display: flex; align-items: center; @@ -1260,6 +1268,9 @@ input[REPLACE_CLASS_input][REPLACE_CLASS_inputerror] { padding-top: 4px; } +[REPLACE_CLASS_tooltiprow]:has([REPLACE_CLASS_usersummarycontainer]:empty) { + display: none; +} [REPLACE_CLASS_tooltipnote] { color: var(--text-muted); font-size: 11px; @@ -1269,8 +1280,7 @@ input[REPLACE_CLASS_input][REPLACE_CLASS_inputerror] { [REPLACE_CLASS_tooltiplistitem][REPLACE_CLASS_tooltipcustom] { color: #fff; } -[REPLACE_CLASS_tooltip] [REPLACE_CLASS_tooltipcontent]:empty, -[REPLACE_CLASS_tooltip] [REPLACE_CLASS_tooltipcontent]:empty > * { +[REPLACE_CLASS_tooltip]:has([REPLACE_CLASS_tooltipcontent]:empty) { display: none !important; } [REPLACE_CLASS_tooltip][REPLACE_CLASS_tooltipcustom] [REPLACE_CLASS_tooltipnote], diff --git a/.config/BetterDiscord/plugins/EditRoles.plugin.js b/.config/BetterDiscord/plugins/EditRoles.plugin.js index 7a99a83..b314785 100755 --- a/.config/BetterDiscord/plugins/EditRoles.plugin.js +++ b/.config/BetterDiscord/plugins/EditRoles.plugin.js @@ -2,7 +2,7 @@ * @name EditRoles * @author DevilBro * @authorId 278543574059057154 - * @version 1.1.4 + * @version 1.1.7 * @description Allows you to locally edit Roles * @invite Jx3TjNS * @donate https://www.paypal.me/MircoWittrien @@ -91,8 +91,8 @@ module.exports = (_ => { if (guild) { let colorRole, iconRole; for (let id of e.returnValue.roles) { - if (guild.roles[id] && guild.roles[id].colorString && (!colorRole || colorRole.position < guild.roles[id].position)) colorRole = guild.roles[id]; - if (guild.roles[id] && guild.roles[id].icon && (!iconRole || iconRole.position < guild.roles[id].position)) iconRole = guild.roles[id]; + if (guild.roles[id] && (guild.roles[id].colorString || changedRoles[id] && changedRoles[id].color) && (!colorRole || colorRole.position < guild.roles[id].position)) colorRole = guild.roles[id]; + if (guild.roles[id] && (guild.roles[id].icon || changedRoles[id] && changedRoles[id].icon) && (!iconRole || iconRole.position < guild.roles[id].position)) iconRole = guild.roles[id]; } let color = colorRole && changedRoles[colorRole.id] && changedRoles[colorRole.id].color; if (color) e.returnValue = Object.assign({}, e.returnValue, {colorString: BDFDB.ColorUtils.convert(color, "HEX")}); @@ -177,6 +177,7 @@ module.exports = (_ => { } onDeveloperContextMenu (e) { + if (e.instance.props.label != BDFDB.LanguageUtils.LanguageStrings.COPY_ID_ROLE) return; let guild = this.getGuildFromRoleId(e.instance.props.id); if (guild) e.returnvalue.props.children = [ BDFDB.ContextMenuUtils.createItem(BDFDB.LibraryComponents.MenuItems.MenuGroup, { @@ -225,7 +226,7 @@ module.exports = (_ => { processRichRoleMention (e) { if (!e.instance.props.id || !changedRoles[e.instance.props.id]) return; e.returnvalue.props.color = changedRoles[e.instance.props.id].color ? BDFDB.ColorUtils.convert(changedRoles[e.instance.props.id].color, "int") : e.returnvalue.props.color; - e.returnvalue.props.children[1] = changedRoles[e.instance.props.id].name || e.returnvalue.props.children[1]; + e.returnvalue.props.children[2] = changedRoles[e.instance.props.id].name || e.returnvalue.props.children[1]; } processAutocompleteRoleResult (e) { @@ -260,7 +261,7 @@ module.exports = (_ => { } getGuildFromRoleId (roleId) { - return BDFDB.LibraryModules.SortedGuildUtils.getFlattenedGuilds().find(g => g.roles[roleId]); + return BDFDB.LibraryStores.SortedGuildStore.getFlattenedGuildIds().map(BDFDB.LibraryStores.GuildStore.getGuild).find(g => g.roles[roleId]); } changeRolesInGuild (guild, useNative) { @@ -289,7 +290,7 @@ module.exports = (_ => { BDFDB.DataUtils.remove(this, "roles", id); } else { - for (let guild of BDFDB.LibraryModules.SortedGuildUtils.getFlattenedGuilds()) if (cachedRoles[guild.id]) guild.roles = cachedRoles[guild.id]; + for (let guild of BDFDB.LibraryStores.SortedGuildStore.getFlattenedGuildIds().map(BDFDB.LibraryStores.GuildStore.getGuild)) if (cachedRoles[guild.id]) guild.roles = cachedRoles[guild.id]; cachedRoles = {}; BDFDB.DataUtils.remove(this, "roles"); } @@ -417,6 +418,11 @@ module.exports = (_ => { callback(""); BDFDB.ReactUtils.forceUpdate(instance); } + else if (url.indexOf("data:") == 0) { + instance.props.success = true; + delete instance.props.errorMessage; + callback(url); + } else instance.checkTimeout = BDFDB.TimeUtils.timeout(_ => { BDFDB.LibraryRequires.request(url, {agentOptions: {rejectUnauthorized: false}}, (error, response, result) => { delete instance.checkTimeout; @@ -474,10 +480,10 @@ module.exports = (_ => { return { confirm_reset: "Είστε βέβαιοι ότι θέλετε να επαναφέρετε αυτόν τον ρόλο;", confirm_resetall: "Είστε βέβαιοι ότι θέλετε να επαναφέρετε όλους τους ρόλους;", - context_localrolesettings: "Ρυθμίσεις τοπικού ρόλου", - modal_header: "Ρυθμίσεις τοπικού ρόλου", + context_localrolesettings: "Ρυθμίσεις ρόλου {τοπικά)", + modal_header: "Ρυθμίσεις ρόλου (τοπικά)", submenu_resetsettings: "Επαναφορά ρόλου", - submenu_rolesettings: "Αλλαξε ρυθμίσεις" + submenu_rolesettings: "Αλλαγή ρυθμίσεων" }; case "es": // Spanish return { diff --git a/.config/BetterDiscord/plugins/ImageUtilities.config.json b/.config/BetterDiscord/plugins/ImageUtilities.config.json index f597832..41d6f90 100755 --- a/.config/BetterDiscord/plugins/ImageUtilities.config.json +++ b/.config/BetterDiscord/plugins/ImageUtilities.config.json @@ -48,6 +48,7 @@ "userAvatars": true, "groupIcons": true, "guildIcons": true, + "streamPreviews": true, "emojis": true }, "rescaleSettings": { @@ -71,6 +72,7 @@ "jumpTo": true }, "zoomSettings": { + "clickMode": false, "lensSize": 1459, "pixelMode": false, "zoomLevel": 1.6000000000000014, diff --git a/.config/BetterDiscord/plugins/ImageUtilities.plugin.js b/.config/BetterDiscord/plugins/ImageUtilities.plugin.js index 205987d..b0c2a87 100755 --- a/.config/BetterDiscord/plugins/ImageUtilities.plugin.js +++ b/.config/BetterDiscord/plugins/ImageUtilities.plugin.js @@ -2,7 +2,7 @@ * @name ImageUtilities * @author DevilBro * @authorId 278543574059057154 - * @version 5.1.9 + * @version 5.4.0 * @description Adds several Utilities for Images/Videos (Gallery, Download, Reverse Search, Zoom, Copy, etc.) * @invite Jx3TjNS * @donate https://www.paypal.me/MircoWittrien @@ -25,9 +25,14 @@ module.exports = (_ => { getDescription () {return `The Library Plugin needed for ${this.name} is missing. Open the Plugin Settings to download it. \n\n${this.description}`;} downloadLibrary () { - require("request").get("https://mwittrien.github.io/BetterDiscordAddons/Library/0BDFDB.plugin.js", (e, r, b) => { - if (!e && b && r.statusCode == 200) require("fs").writeFile(require("path").join(BdApi.Plugins.folder, "0BDFDB.plugin.js"), b, _ => BdApi.showToast("Finished downloading BDFDB Library", {type: "success"})); - else BdApi.alert("Error", "Could not download BDFDB Library Plugin. Try again later or download it manually from GitHub: https://mwittrien.github.io/downloader/?library"); + BdApi.Net.fetch("https://mwittrien.github.io/BetterDiscordAddons/Library/0BDFDB.plugin.js").then(r => { + if (!r || r.status != 200) throw new Error(); + else return r.text(); + }).then(b => { + if (!b) throw new Error(); + else return require("fs").writeFile(require("path").join(BdApi.Plugins.folder, "0BDFDB.plugin.js"), b, _ => BdApi.showToast("Finished downloading BDFDB Library", {type: "success"})); + }).catch(error => { + BdApi.alert("Error", "Could not download BDFDB Library Plugin. Try again later or download it manually from GitHub: https://mwittrien.github.io/downloader/?library"); }); } @@ -65,8 +70,6 @@ module.exports = (_ => { var cachedImages; var eventTypes = {}; - const imgUrlReplaceString = "DEVILBRO_BD_REVERSEIMAGESEARCH_REPLACE_IMAGEURL"; - const rescaleOptions = { NONE: "No Resize", ORIGINAL: "Resize to Original Size", @@ -205,7 +208,7 @@ module.exports = (_ => { }, viewerSettings: { zoomMode: {value: true, description: "Enables Zoom Mode to zoom into Images while holding down your Mouse"}, - galleryMode: {value: true, description: "Enables Gallery Mode to quick-switch between Images"}, + galleryMode: {value: true, description: "Enables Gallery Mode to quick-switch between Images"}, details: {value: true, description: "Adds Image Details (Name, Size, Amount)"}, copyImage: {value: true, description: "Adds a 'Copy Image' Option"}, saveImage: {value: true, description: "Adds a 'Save Image as' Option"}, @@ -214,39 +217,41 @@ module.exports = (_ => { galleryFilter: {}, zoomSettings: { pixelMode: {value: false, label: "Uses Pixel Lens instead of a Blur Lens"}, + clickMode: {value: false, label: "Click Image to zoom instead of holding the Mouse Button"}, lensSize: {value: 200, digits: 0, minValue: 50, maxValue: 5000, unit: "px", label: "context_lenssize"}, - zoomLevel: {value: 2, digits: 1, minValue: 1, maxValue: 20, unit: "x", label: "ACCESSIBILITY_ZOOM_LEVEL_LABEL"}, + zoomLevel: {value: 2, digits: 1, minValue: 1, maxValue: 20, unit: "x", label: "ACCESSIBILITY_ZOOM_LEVEL_LABEL"}, zoomSpeed: {value: 0.1, digits: 2, minValue: 0.01, maxValue: 1, unit: "", label: "context_zoomspeed"} }, rescaleSettings: { messages: {value: "NONE", description: "Messages"}, - imageViewer: {value: "NONE", description: "Image Viewer"} + imageViewer: {value: "NONE", description: "Image Viewer"} }, detailsSettings: { footnote: {value: true, description: "in the Image Description"}, tooltip: {value: false, description: "as a Hover Tooltip"}, - tooltipDelay: {value: 0, min: 0, description: "Image Tooltip Delay (in ms)"} + tooltipDelay: {value: 0, min: 0, description: "Image Tooltip Delay (in ms)"} }, places: { - userAvatars: {value: true, description: "User Avatars"}, - groupIcons: {value: true, description: "Group Icons"}, - guildIcons: {value: true, description: "Server Icons"}, + userAvatars: {value: true, description: "User Avatars"}, + groupIcons: {value: true, description: "Group Icons"}, + guildIcons: {value: true, description: "Server Icons"}, + streamPreviews: {value: true, description: "Stream Previews"}, emojis: {value: true, description: "Custom Emojis/Emotes"} }, engines: { _all: {value: true, name: BDFDB.LanguageUtils.LanguageStrings.FORM_LABEL_ALL, url: null}, - Baidu: {value: true, name: "Baidu", url: "http://image.baidu.com/pcdutu?queryImageUrl=" + imgUrlReplaceString}, - Bing: {value: true, name: "Bing", url: "https://www.bing.com/images/search?q=imgurl:" + imgUrlReplaceString + "&view=detailv2&iss=sbi&FORM=IRSBIQ"}, - Google: {value: true, name: "Google", url: "https://www.google.com/searchbyimage?sbisrc=1&image_url=" + imgUrlReplaceString}, - GoogleLens: {value: true, name: "Google Lens", url: "https://lens.google.com/uploadbyurl?url=" + imgUrlReplaceString}, - ImgOps: {value: true, name: "ImgOps", raw: true, url: "https://imgops.com/specialized+reverse/" + imgUrlReplaceString}, - IQDB: {value: true, name: "IQDB", url: "https://iqdb.org/?url=" + imgUrlReplaceString}, - Reddit: {value: true, name: "Reddit", url: "http://karmadecay.com/search?q=" + imgUrlReplaceString}, - SauceNAO: {value: true, name: "SauceNAO", url: "https://saucenao.com/search.php?db=999&url=" + imgUrlReplaceString}, - Sogou: {value: true, name: "Sogou", url: "http://pic.sogou.com/ris?flag=1&drag=0&query=" + imgUrlReplaceString + "&flag=1"}, - TinEye: {value: true, name: "TinEye", url: "https://tineye.com/search?url=" + imgUrlReplaceString}, - WhatAnime: {value: true, name: "WhatAnime", url: "https://trace.moe/?url=" + imgUrlReplaceString}, - Yandex: {value: true, name: "Yandex", url: "https://yandex.com/images/search?url=" + imgUrlReplaceString + "&rpt=imageview"} + Baidu: {value: true, name: "Baidu", url: "http://image.baidu.com/pcdutu?queryImageUrl="}, + Bing: {value: true, name: "Bing", url: "https://www.bing.com/images/search?view=detailv2&iss=sbi&FORM=IRSBIQ&q=imgurl:"}, + Google: {value: true, name: "Google", url: "https://www.google.com/searchbyimage?sbisrc=cr_1&image_url="}, + GoogleLens: {value: true, name: "Google Lens", url: "https://lens.google.com/uploadbyurl?url="}, + ImgOps: {value: true, name: "ImgOps", raw: true, url: "https://imgops.com/specialized+reverse/"}, + IQDB: {value: true, name: "IQDB", url: "https://iqdb.org/?url="}, + Reddit: {value: true, name: "Reddit", url: "http://karmadecay.com/search?q="}, + SauceNAO: {value: true, name: "SauceNAO", url: "https://saucenao.com/search.php?db=999&url="}, + Sogou: {value: true, name: "Sogou", url: "http://pic.sogou.com/ris?flag=1&drag=0&flag=1&query="}, + TinEye: {value: true, name: "TinEye", url: "https://tineye.com/search?url="}, + WhatAnime: {value: true, name: "WhatAnime", url: "https://trace.moe/?url="}, + Yandex: {value: true, name: "Yandex", url: "https://yandex.com/images/search?rpt=imageview&url="} } }; @@ -280,10 +285,14 @@ module.exports = (_ => { }; this.css = ` + ${BDFDB.dotCN._imageutilitiesimagedetailsadded} { + max-height: unset !important; + } ${BDFDB.dotCNS._imageutilitiesimagedetailsadded + BDFDB.dotCN.imagewrapper} { border-radius: 8px !important; height: calc(100% - 1rem - 16px) !important; max-height: unset !important; + margin-left: unset !important; } ${BDFDB.dotCNS._imageutilitiesimagedetailsadded + BDFDB.dotCN.imagealttextcontainer} { bottom: calc(1rem + 16px) !important; @@ -695,16 +704,22 @@ module.exports = (_ => { if (!this.settings.places.guildIcons || !e.instance.props.guild) return; if (BDFDB.DOMUtils.getParent(BDFDB.dotCNC.guildheader + BDFDB.dotCN.guildchannels, e.instance.props.target) && (!e.instance.props.target.className && e.instance.props.target.parentElement.firstElementChild == e.instance.props.target) || (e.instance.props.target.className && e.instance.props.target.className.indexOf(BDFDB.disCN.guildheaderbanneranimatedhoverlayer) > -1)) { let banner = BDFDB.GuildUtils.getBanner(e.instance.props.guild.id); - if (banner) this.injectItem(e, [banner.replace(/\.webp|\.gif/, ".png"), e.instance.props.guild.banner && BDFDB.LibraryModules.IconUtils.isAnimatedIconHash(e.instance.props.guild.banner) && banner.replace(/\.webp|\.png/, ".gif")], BDFDB.LanguageUtils.LibraryStrings.guildbanner); + if (banner) this.injectItem(e, [banner.replace(/\.webp|\.gif/, ".png"), e.instance.props.guild.banner && BDFDB.LibraryModules.IconUtils.isAnimatedIconHash(e.instance.props.guild.banner) && banner.replace(/\.webp|\.png/, ".gif")], {prefix: BDFDB.LanguageUtils.LibraryStrings.guildbanner, id: "banner"}); } - else if (!BDFDB.DOMUtils.getParent(BDFDB.dotCN.channels, e.instance.props.target)) this.injectItem(e, [(e.instance.props.guild.getIconURL(4096) || "").replace(/\.webp|\.gif/, ".png"), e.instance.props.guild.icon && BDFDB.LibraryModules.IconUtils.isAnimatedIconHash(e.instance.props.guild.icon) && e.instance.props.guild.getIconURL(4096, true)], BDFDB.LanguageUtils.LibraryStrings.guildicon); + else if (!BDFDB.DOMUtils.getParent(BDFDB.dotCN.channels, e.instance.props.target)) this.injectItem(e, [(e.instance.props.guild.getIconURL(4096) || "").replace(/\.webp|\.gif/, ".png"), e.instance.props.guild.icon && BDFDB.LibraryModules.IconUtils.isAnimatedIconHash(e.instance.props.guild.icon) && e.instance.props.guild.getIconURL(4096, true)], {prefix: BDFDB.LanguageUtils.LibraryStrings.guildicon, id: "icon"}); } onUserContextMenu (e) { - if (!this.settings.places.userAvatars || !e.instance.props.user) return; - const guildId = BDFDB.LibraryStores.SelectedGuildStore.getGuildId(); - const member = BDFDB.LibraryStores.GuildMemberStore.getMember(guildId, e.instance.props.user.id); - this.injectItem(e, [(e.instance.props.user.getAvatarURL(null, 4096) || "").replace(/\.webp|\.gif/, ".png"), BDFDB.LibraryModules.IconUtils.isAnimatedIconHash(e.instance.props.user.avatar) && e.instance.props.user.getAvatarURL(null, 4096, true), (e.instance.props.user.getAvatarURL(guildId, 4096) || "").replace(/\.webp|\.gif/, ".png"), member && member.avatar && BDFDB.LibraryModules.IconUtils.isAnimatedIconHash(member.avatar) && e.instance.props.user.getAvatarURL(guildId, 4096, true)]); + if (this.settings.places.userAvatars && e.instance.props.user) { + const guildId = BDFDB.LibraryStores.SelectedGuildStore.getGuildId(); + const member = BDFDB.LibraryStores.GuildMemberStore.getMember(guildId, e.instance.props.user.id); + this.injectItem(e, [(e.instance.props.user.getAvatarURL(null, 4096) || "").replace(/\.webp|\.gif/, ".png"), BDFDB.LibraryModules.IconUtils.isAnimatedIconHash(e.instance.props.user.avatar) && e.instance.props.user.getAvatarURL(null, 4096, true), (e.instance.props.user.getAvatarURL(guildId, 4096) || "").replace(/\.webp|\.gif/, ".png"), member && member.avatar && BDFDB.LibraryModules.IconUtils.isAnimatedIconHash(member.avatar) && e.instance.props.user.getAvatarURL(guildId, 4096, true)]); + } + if (this.settings.places.streamPreviews && e.instance.props.user) { + let stream = BDFDB.LibraryStores.ApplicationStreamingStore.getAnyStreamForUser(e.instance.props.user.id); + let previewUrl = stream && BDFDB.LibraryStores.ApplicationStreamPreviewStore.getPreviewURL(stream.guildId, stream.channelId, stream.ownerId); + if (previewUrl) this.injectItem(e, [previewUrl], {id: "stream", label: this.labels.context_streamactions}); + } } onGroupDMContextMenu (e) { @@ -720,20 +735,20 @@ module.exports = (_ => { onMessageContextMenu (e) { if (!e.instance.props.message || !e.instance.props.channel || !e.instance.props.target) return; const target = e.instance.props.target.tagName == "A" && BDFDB.DOMUtils.containsClass(e.instance.props.target, BDFDB.disCN.imageoriginallink) && e.instance.props.target.parentElement.querySelector("img") || (BDFDB.DOMUtils.getParent(BDFDB.dotCN.messageattachment, e.instance.props.target) || e.instance.props.target).querySelector("img, video") || e.instance.props.target; - if (target.tagName == "A" && e.instance.props.message.embeds && e.instance.props.message.embeds[0] && (e.instance.props.message.embeds[0].type == "image" || e.instance.props.message.embeds[0].type == "video" || e.instance.props.message.embeds[0].type == "gifv")) this.injectItem(e, [target.href], null, true); + if (target.tagName == "A" && e.instance.props.message.embeds && e.instance.props.message.embeds[0] && (e.instance.props.message.embeds[0].type == "image" || e.instance.props.message.embeds[0].type == "video" || e.instance.props.message.embeds[0].type == "gifv")) this.injectItem(e, [target.href], {isNative: true}); else if (target.tagName == "IMG" && target.complete && target.naturalHeight) { - if (BDFDB.DOMUtils.getParent(BDFDB.dotCN.imagewrapper, target) || BDFDB.DOMUtils.containsClass(target, BDFDB.disCN.imagesticker)) this.injectItem(e, [{file: target.src, original: this.getTargetLink(e.instance.props.target) || this.getTargetLink(target)}], null, true); - else if (BDFDB.DOMUtils.containsClass(target, BDFDB.disCN.embedauthoricon) && this.settings.places.userAvatars) this.injectItem(e, [target.src], null, true); - else if (BDFDB.DOMUtils.containsClass(target, BDFDB.disCN.emojiold, "emote", false) && this.settings.places.emojis) this.injectItem(e, [{file: target.src, alternativeName: target.getAttribute("data-name")}], null, true); + if (BDFDB.DOMUtils.getParent(BDFDB.dotCN.imagewrapper, target) || BDFDB.DOMUtils.containsClass(target, BDFDB.disCN.imagesticker)) this.injectItem(e, [{file: target.src, original: this.getTargetLink(e.instance.props.target) || this.getTargetLink(target)}], {isNative: true}); + else if (BDFDB.DOMUtils.containsClass(target, BDFDB.disCN.embedauthoricon) && this.settings.places.userAvatars) this.injectItem(e, [target.src], {isNative: true}); + else if (BDFDB.DOMUtils.containsClass(target, BDFDB.disCN.emojiold, "emote", false) && this.settings.places.emojis) this.injectItem(e, [{file: target.src, alternativeName: target.getAttribute("data-name")}], {isNative: true}); } else if (target.tagName == "VIDEO") { - if (BDFDB.DOMUtils.containsClass(target, BDFDB.disCN.embedvideo) || BDFDB.DOMUtils.getParent(BDFDB.dotCN.attachmentvideo, target)) this.injectItem(e, [{file: target.src, original: this.getTargetLink(e.instance.props.target) || this.getTargetLink(target)}], null, true); + if (BDFDB.DOMUtils.containsClass(target, BDFDB.disCN.embedvideo) || BDFDB.DOMUtils.getParent(BDFDB.dotCN.attachmentvideo, target)) this.injectItem(e, [{file: target.src, original: this.getTargetLink(e.instance.props.target) || this.getTargetLink(target)}], {isNative: true}); } else { const reaction = BDFDB.DOMUtils.getParent(BDFDB.dotCN.messagereaction, target); if (reaction && this.settings.places.emojis) { const emoji = reaction.querySelector(BDFDB.dotCN.emojiold); - if (emoji) this.injectItem(e, [{file: emoji.src, alternativeName: emoji.getAttribute("data-name")}], null, true); + if (emoji) this.injectItem(e, [{file: emoji.src, alternativeName: emoji.getAttribute("data-name")}], {isNative: true}); } } } @@ -745,14 +760,13 @@ module.exports = (_ => { return href || src; } - injectItem (e, urls, prefix, isNative = false) { + injectItem (e, urls, config = {}) { let validUrls = this.filterUrls(...urls); if (!validUrls.length) return; let [nativeParent, nativeIndex] = BDFDB.ContextMenuUtils.findItem(e.returnvalue, {id: "copy-native-link", group: true}); if (nativeIndex > -1) { - if (validUrls.length == 1) isNative = true; + if (validUrls.length == 1) config.isNative = true; nativeParent.splice(nativeIndex, 1); - nativeIndex -= 1; } for (let id of ["open-native-link", "copy-image", "save-image"]) { let [removeParent, removeIndex] = BDFDB.ContextMenuUtils.findItem(e.returnvalue, {id: id, group: true}); @@ -762,15 +776,15 @@ module.exports = (_ => { let subMenu = this.createSubMenus({ instance: e.instance, urls: validUrls, - prefix: prefix, + prefix: config.prefix, target: e.instance.props.target }); - let [children, index] = isNative && nativeIndex > -1 ? [nativeParent, nativeIndex] : BDFDB.ContextMenuUtils.findItem(e.returnvalue, {id: "devmode-copy-id", group: true}); - children.splice(index > -1 ? index : children.length, 0, isNative ? subMenu : BDFDB.ContextMenuUtils.createItem(BDFDB.LibraryComponents.MenuItems.MenuGroup, { + let [children, index] = config.isNative && nativeIndex > -1 ? [nativeParent, nativeIndex] : BDFDB.ContextMenuUtils.findItem(e.returnvalue, {id: "devmode-copy-id", group: true}); + children.splice(index > -1 ? index : children.length, 0, config.isNative && nativeIndex > -1 ? subMenu : BDFDB.ContextMenuUtils.createItem(BDFDB.LibraryComponents.MenuItems.MenuGroup, { children: BDFDB.ContextMenuUtils.createItem(BDFDB.LibraryComponents.MenuItems.MenuItem, { - label: this.isValid(validUrls[0].file, "video") ? this.labels.context_videoactions : this.labels.context_imageactions, - id: BDFDB.ContextMenuUtils.createItemId(this.name, "main-subitem"), + label: config.label || (this.isValid(validUrls[0].file, "video") ? this.labels.context_videoactions : this.labels.context_imageactions), + id: BDFDB.ContextMenuUtils.createItemId(this.name, config.id, "main-subitem"), children: subMenu }) })); @@ -794,8 +808,14 @@ module.exports = (_ => { isValid (url, type) { if (!url) return false; - const file = url && (BDFDB.LibraryModules.URLParser.parse(url).pathname || "").split("%3A")[0].toLowerCase(); - return file && (!type && (url.indexOf("discord.com/streams/guild:") > -1 || url.indexOf("discordapp.com/streams/guild:") > -1 || url.indexOf("discordapp.net/streams/guild:") > -1 || url.startsWith("https://images-ext-1.discordapp.net/") || url.startsWith("https://images-ext-2.discordapp.net/") || Object.keys(fileTypes).some(t => file.endsWith(`/${t}`) || file.endsWith(`.${t}`))) || type && Object.keys(fileTypes).filter(t => fileTypes[t][type]).some(t => file.endsWith(`/${t}`) || file.endsWith(`.${t}`))); + if (url && url.indexOf("data:") == 0 && url.indexOf("base64") > -1) { + const fileType = (url.split("/")[1] || "").split(";")[0]; + return !type && fileTypes[fileType] || type && type != "searchable" && fileTypes[fileType] && fileTypes[fileType][type]; + } + else { + const file = url && (BDFDB.LibraryModules.URLParser.parse(url).pathname || "").split("%3A")[0].toLowerCase(); + return file && (!type && (url.indexOf("discord.com/streams/guild:") > -1 || url.indexOf("discordapp.com/streams/guild:") > -1 || url.indexOf("discordapp.net/streams/guild:") > -1 || url.startsWith("https://images-ext-1.discordapp.net/") || url.startsWith("https://images-ext-2.discordapp.net/") || Object.keys(fileTypes).some(t => file.endsWith(`/${t}`) || file.endsWith(`.${t}`))) || ((type == "copyable" || type == "searchable") && (url.indexOf("discord.com/streams/guild:") > -1 || url.indexOf("discordapp.com/streams/guild:") > -1 || url.indexOf("discordapp.net/streams/guild:") > -1)) || type && Object.keys(fileTypes).filter(t => fileTypes[t][type]).some(t => file.endsWith(`/${t}`) || file.endsWith(`.${t}`))); + } } getPosterUrl (url) { @@ -822,11 +842,12 @@ module.exports = (_ => { return BDFDB.ContextMenuUtils.createItem(BDFDB.LibraryComponents.MenuItems.MenuGroup, { children: [ - BDFDB.ContextMenuUtils.createItem(BDFDB.LibraryComponents.MenuItems.MenuItem, { + urlData.original && urlData.original.indexOf("data:") != 0 && BDFDB.ContextMenuUtils.createItem(BDFDB.LibraryComponents.MenuItems.MenuItem, { label: BDFDB.LanguageUtils.LanguageStrings.COPY_LINK, id: BDFDB.ContextMenuUtils.createItemId(this.name, "copy-link"), action: _ => { - let url = urlData.original.split("?width")[0].split("?height")[0].split("?size")[0]; + let url = this.removeSizeInUrl(urlData.original); + url = this.removeFormatInUrl(url); url = url.indexOf("discordapp.com/avatars/") > 0 || url.indexOf("discordapp.com/icons/") > 0 ? `${url}?size=4096` : url; BDFDB.LibraryModules.WindowUtils.copy(url); BDFDB.NotificationUtils.toast(BDFDB.LanguageUtils.LanguageStrings.LINK_COPIED, {type: "success"}); @@ -836,13 +857,14 @@ module.exports = (_ => { label: BDFDB.LanguageUtils.LanguageStrings.COPY_MEDIA_LINK, id: BDFDB.ContextMenuUtils.createItemId(this.name, "copy-media-link"), action: _ => { - let url = urlData.file.split("?width")[0].split("?height")[0].split("?size")[0]; + let url = this.removeSizeInUrl(urlData.file); + url = this.removeFormatInUrl(url); url = url.indexOf("discordapp.com/avatars/") > 0 || url.indexOf("discordapp.com/icons/") > 0 ? `${url}?size=4096` : url; BDFDB.LibraryModules.WindowUtils.copy(url); BDFDB.NotificationUtils.toast(BDFDB.LanguageUtils.LanguageStrings.LINK_COPIED, {type: "success"}); } }), - BDFDB.ContextMenuUtils.createItem(BDFDB.LibraryComponents.MenuItems.MenuItem, { + urlData.original && urlData.original.indexOf("data:") != 0 && BDFDB.ContextMenuUtils.createItem(BDFDB.LibraryComponents.MenuItems.MenuItem, { label: BDFDB.LanguageUtils.LanguageStrings.OPEN_LINK, id: BDFDB.ContextMenuUtils.createItemId(this.name, "open-link"), action: _ => BDFDB.DiscordUtils.openLink(urlData.original) @@ -850,7 +872,7 @@ module.exports = (_ => { !this.isValid(urlData.file, "copyable") ? null : BDFDB.ContextMenuUtils.createItem(BDFDB.LibraryComponents.MenuItems.MenuItem, { label: this.labels.context_copy.replace("{{var0}}", type), id: BDFDB.ContextMenuUtils.createItemId(this.name, "copy-file"), - action: _ => this.copyFile({url: urlData.src, fallbackUrl: urlData.file || urlData.original}) + action: _ => this.copyFile({url: urlData.original, fallbackUrl: urlData.src}) }), !document.querySelector(BDFDB.dotCN.imagemodal) && BDFDB.ContextMenuUtils.createItem(BDFDB.LibraryComponents.MenuItems.MenuItem, { label: this.labels.context_view.replace("{{var0}}", type), @@ -867,7 +889,7 @@ module.exports = (_ => { "aria-label": BDFDB.LanguageUtils.LanguageStrings.IMAGE, children: isVideo ? BDFDB.ReactUtils.createElement(BDFDB.LibraryComponents.ImageVideoModal, { src: imageThrowaway.src, - poster: this.getPosterUrl(imageThrowaway.src), + poster: _this.getPosterUrl(imageThrowaway.src), width: this.videoWidth, naturalWidth: this.videoWidth, height: this.videoHeight, @@ -890,12 +912,12 @@ module.exports = (_ => { BDFDB.ContextMenuUtils.createItem(BDFDB.LibraryComponents.MenuItems.MenuItem, { label: this.labels.context_saveas.replace("{{var0}}", type), id: BDFDB.ContextMenuUtils.createItemId(this.name, "download-file-as"), - action: _ => this.downloadFile({url: urlData.src, fallbackUrl: urlData.file || urlData.original}, null, urlData.alternativeName), + action: _ => this.downloadFile({url: urlData.original, fallbackUrl: urlData.src}, null, urlData.alternativeName), children: locations.length && BDFDB.ContextMenuUtils.createItem(BDFDB.LibraryComponents.MenuItems.MenuGroup, { children: locations.map((name, i) => BDFDB.ContextMenuUtils.createItem(BDFDB.LibraryComponents.MenuItems.MenuItem, { id: BDFDB.ContextMenuUtils.createItemId(this.name, "download", name, i), label: name, - action: _ => this.downloadFile({url: urlData.src, fallbackUrl: urlData.file || urlData.original}, ownLocations[name].location, urlData.alternativeName) + action: _ => this.downloadFile({url: urlData.original, fallbackUrl: urlData.src}, ownLocations[name].location, urlData.alternativeName) })) }) }), @@ -905,7 +927,7 @@ module.exports = (_ => { persisting: true, action: event => { if (!event.shiftKey) BDFDB.ContextMenuUtils.close(instance); - BDFDB.DiscordUtils.openLink(this.defaults.engines[engineKeys[0]].url.replace(imgUrlReplaceString, encodeURIComponent(urlData.original)), { + BDFDB.DiscordUtils.openLink(this.defaults.engines[engineKeys[0]].url + encodeURIComponent(urlData.original), { minimized: event.shiftKey }); } @@ -922,7 +944,7 @@ module.exports = (_ => { color: key == "_all" ? BDFDB.DiscordConstants.MenuItemColors.DANGER : BDFDB.DiscordConstants.MenuItemColors.DEFAULT, persisting: true, action: event => { - const open = (url, k) => BDFDB.DiscordUtils.openLink(this.defaults.engines[k].url.replace(imgUrlReplaceString, this.defaults.engines[k].raw ? url : encodeURIComponent(url)), {minimized: event.shiftKey}); + const open = (url, k) => BDFDB.DiscordUtils.openLink(this.defaults.engines[k].url + (this.defaults.engines[k].raw ? url : encodeURIComponent(url)), {minimized: event.shiftKey}); if (!event.shiftKey) BDFDB.ContextMenuUtils.close(instance); if (key == "_all") { for (let key2 in enginesWithoutAll) open(urlData.original, key2); @@ -1020,7 +1042,7 @@ module.exports = (_ => { children: this.labels.context_saveas.replace("{{var0}}", type), onClick: event => { BDFDB.ListenerUtils.stopEvent(event); - this.downloadFile({url: url}); + this.downloadFile({url: e.instance.props.original, fallbackUrl: url}); }, onContextMenu: event => { let locations = Object.keys(ownLocations).filter(n => ownLocations[n].enabled); @@ -1028,7 +1050,7 @@ module.exports = (_ => { children: locations.map((name, i) => BDFDB.ContextMenuUtils.createItem(BDFDB.LibraryComponents.MenuItems.MenuItem, { id: BDFDB.ContextMenuUtils.createItemId(this.name, "download", name, i), label: name, - action: _ => this.downloadFile({url: url}, ownLocations[name].location) + action: _ => this.downloadFile({url: e.instance.props.original, fallbackUrl: url}, ownLocations[name].location) })) })); } @@ -1045,7 +1067,7 @@ module.exports = (_ => { children: this.labels.context_copy.replace("{{var0}}", type), onClick: event => { BDFDB.ListenerUtils.stopEvent(event); - this.copyFile({url: url}); + this.copyFile({url: e.instance.props.original, fallbackUrl: url}); } }) ], @@ -1088,7 +1110,7 @@ module.exports = (_ => { className: BDFDB.disCN._imageutilitiesdetailswrapper, children: [ e.instance.props.alt && {label: "Alt", text: e.instance.props.alt}, - {label: "Source", text: url.split("?width")[0].split("?height")[0].split("?size")[0]}, + {label: "Source", text: this.removeSizeInUrl(this.removeFormatInUrl(url))}, {label: "Size", text: `${e.instance.props.width}x${e.instance.props.height}px`}, cachedImages && cachedImages.amount && cachedImages.amount > 1 && {label: filterForVideos ? "Video" : "Image", text: `${cachedImages.index + 1 || 1} of ${cachedImages.amount}`} ].filter(n => n).map(data => BDFDB.ReactUtils.createElement(BDFDB.LibraryComponents.TextElement, { @@ -1189,6 +1211,7 @@ module.exports = (_ => { processLazyImage (e) { if (e.node) { + if (!e.instance.props.src.split("?")[0].endsWith(".gif") && !e.instance.props.animated && !e.instance.props.children) for (let ele of [e.node.src && e.node, ...e.node.querySelectorAll("[src]")].filter(n => n)) ele.src = this.removeFormatInUrl(ele.src); if (e.instance.props.resized) { for (let selector of ["embedfull", "embedinlinemedia", "embedgridcontainer", "imagemosaicattachmentscontainer", "imagemosaiconebyonegridsingle"]) { let parent = BDFDB.DOMUtils.getParent(BDFDB.dotCN[selector], e.node); @@ -1201,9 +1224,9 @@ module.exports = (_ => { ele.style.setProperty("height", e.instance.props.height + "px"); ele.style.setProperty("max-height", e.instance.props.height + "px"); } - for (let ele of [e.node.src && e.node, ...e.node.querySelectorAll("[src]")].filter(n => n)) ele.src = ele.src.split("?width")[0].split("?height")[0].split("?size")[0]; - if (e.instance.state.readyState != BDFDB.LibraryComponents.ImageComponents.ImageReadyStates.READY) { - e.instance.state.readyState = BDFDB.LibraryComponents.ImageComponents.ImageReadyStates.READY; + for (let ele of [e.node.src && e.node, ...e.node.querySelectorAll("[src]")].filter(n => n)) ele.src = this.removeSizeInUrl(ele.src); + if (e.instance.state.readyState != BDFDB.DiscordConstants.ImageReadyStates.READY) { + e.instance.state.readyState = BDFDB.DiscordConstants.ImageReadyStates.READY; BDFDB.ReactUtils.forceUpdate(e.instance); } } @@ -1229,7 +1252,8 @@ module.exports = (_ => { if (this.isValid(e.instance.props.src, "gif")) e.node.style.setProperty("pointer-events", "none"); if (this.settings.viewerSettings.zoomMode && typeof e.instance.props.children != "function" && !BDFDB.DOMUtils.containsClass(e.node.parentElement, BDFDB.disCN._imageutilitiessibling)) { e.node.style.setProperty("cursor", "zoom-in"); - e.node.addEventListener("mousedown", event => { + e.node.addEventListener(this.settings.zoomSettings.clickMode ? "click" : "mousedown", event => { + BDFDB.ListenerUtils.stopEvent(event); if (event.which != 1 || e.node.querySelector("video")) return; let vanishObserver; @@ -1238,7 +1262,7 @@ module.exports = (_ => { let imgRects = BDFDB.DOMUtils.getRects(e.node.firstElementChild); let lens = BDFDB.DOMUtils.create(`
<${e.node.firstElementChild.tagName} src="${!this.isValid(e.instance.props.src, "video") ? e.instance.props.src : this.getPosterUrl(e.instance.props.src)}" style="width: ${imgRects.width * zoomLevel}px; height: ${imgRects.height * zoomLevel}px; position: fixed !important;${this.settings.zoomSettings.pixelMode ? " image-rendering: pixelated !important;" : ""}"${e.node.firstElementChild.tagName == "VIDEO" ? " loop autoplay" : ""}>
`); let pane = lens.firstElementChild.firstElementChild; - let backdrop = BDFDB.DOMUtils.create(`
`); + let backdrop = BDFDB.DOMUtils.create(`
`); let appMount = document.querySelector(BDFDB.dotCN.appmount); appMount.appendChild(lens); appMount.appendChild(backdrop); @@ -1265,15 +1289,12 @@ module.exports = (_ => { }; lens.update(); - for (let ele of [e.node, document.querySelector(BDFDB.dotCN.imagemodal)]) if (ele) ele.style.setProperty("pointer-events", "none", "important"); - let dragging = event2 => { event = event2; lens.update(); }; let releasing = event2 => { BDFDB.ListenerUtils.stopEvent(event2); - for (let ele of [e.node, document.querySelector(BDFDB.dotCN.imagemodal)]) if (ele) ele.style.removeProperty("pointer-events"); this.cleanupListeners("Zoom"); document.removeEventListener("mousemove", dragging); document.removeEventListener("mouseup", releasing); @@ -1340,7 +1361,7 @@ module.exports = (_ => { e.instance.props.resized = true; } } - if (this.settings.rescaleSettings.messages != "NONE" && (!e.instance.props.className || e.instance.props.className.indexOf(BDFDB.disCN.embedthumbnail) == -1) && (!e.instance.props.containerClassName || e.instance.props.containerClassName.indexOf(BDFDB.disCN.embedthumbnail) == -1 && e.instance.props.containerClassName.indexOf(BDFDB.disCN.embedvideoimagecomponent) == -1) && BDFDB.ReactUtils.findOwner(reactInstance, {name: "LazyImageZoomable", up: true}) && (e.instance.props.mediaLayoutType != "MOSAIC" || (BDFDB.ReactUtils.findValue(reactInstance, "attachments", {up: true}) || []).length < 2)) { + if (this.settings.rescaleSettings.messages != "NONE" && [e.instance.props.className, e.instance.props.containerClassName].every(n => [BDFDB.disCN.embedvideoimagecomponent, BDFDB.disCN.embedthumbnail].every(m => (n || "").indexOf(m) == -1)) && BDFDB.ReactUtils.findOwner(reactInstance, {name: "LazyImageZoomable", up: true}) && (e.instance.props.mediaLayoutType != "MOSAIC" || (BDFDB.ReactUtils.findValue(reactInstance, "message", {up: true}) || {attachments: []}).attachments.filter(n => n.content_type.startsWith("image")).length < 2)) { let aRects = BDFDB.DOMUtils.getRects(document.querySelector(BDFDB.dotCN.appmount)); let mRects = BDFDB.DOMUtils.getRects(document.querySelector(BDFDB.dotCNC.messageaccessory + BDFDB.dotCN.messagecontents)); let mwRects = BDFDB.DOMUtils.getRects(document.querySelector(BDFDB.dotCN.messagewrapper)); @@ -1370,7 +1391,7 @@ module.exports = (_ => { processLazyImageZoomable (e) { if (!e.instance.props.original || e.instance.props.src.indexOf("https://media.discordapp.net/attachments") != 0) return; - if (this.settings.detailsSettings.tooltip || this.settings.detailsSettings.footnote && e.instance.props.mediaLayoutType == "MOSAIC" && (BDFDB.ReactUtils.findValue(BDFDB.ObjectUtils.get(e, `instance.${BDFDB.ReactUtils.instanceKey}`), "attachments", {up: true}) || []).length > 1) { + if (this.settings.detailsSettings.tooltip || this.settings.detailsSettings.footnote && e.instance.props.mediaLayoutType == "MOSAIC" && (BDFDB.ReactUtils.findValue(BDFDB.ObjectUtils.get(e, `instance.${BDFDB.ReactUtils.instanceKey}`), "message", {up: true}) || {attachments: []}).attachments.filter(n => n.content_type.startsWith("image")).length > 1) { const attachment = BDFDB.ReactUtils.findValue(e.instance, "attachment", {up: true}); if (attachment) { const onMouseEnter = e.returnvalue.props.onMouseEnter; @@ -1387,7 +1408,7 @@ module.exports = (_ => { }, "Error in onMouseEnter of LazyImageZoomable!"); } } - if (this.settings.detailsSettings.footnote && (e.instance.props.className || "").indexOf(BDFDB.disCN.embedmedia) == -1 && (e.instance.props.className || "").indexOf(BDFDB.disCN.embedthumbnail) == -1 && (e.instance.props.mediaLayoutType != "MOSAIC" || (BDFDB.ReactUtils.findValue(BDFDB.ObjectUtils.get(e, `instance.${BDFDB.ReactUtils.instanceKey}`), "attachments", {up: true}) || []).length < 2)) { + if (this.settings.detailsSettings.footnote && [e.instance.props.className, e.instance.props.containerClassName].every(n => [BDFDB.disCN.embedmedia, BDFDB.disCN.embedthumbnail].every(m => (n || "").indexOf(m) == -1)) && (e.instance.props.mediaLayoutType != "MOSAIC" || (BDFDB.ReactUtils.findValue(BDFDB.ObjectUtils.get(e, `instance.${BDFDB.ReactUtils.instanceKey}`), "message", {up: true}) || {attachments: []}).attachments.filter(n => n.content_type.startsWith("image")).length < 2)) { e.returnvalue = BDFDB.ReactUtils.createElement("div", { children: [ e.returnvalue, @@ -1398,7 +1419,7 @@ module.exports = (_ => { width: 0, filename: "unknown.png" } - }) + }, true) ] }); } @@ -1478,20 +1499,16 @@ module.exports = (_ => { requestFile (urls, onLoad, onError, config = {}) { if (!urls || typeof onLoad != "function") return typeof onError == "function" && onError(); - let url = urls.url.startsWith("/assets") ? (window.location.origin + urls.url) : urls.url; + let url = (urls.url && urls.url.startsWith("/assets") ? (window.location.origin + urls.url) : urls.url || ""); let isResized = !config.orignalSizeChecked && (url.indexOf("?width=") > -1 || url.indexOf("?height=") > -1 || url.indexOf("?size=") > -1); - if (!config.fallbackToRequest) BDFDB.DiscordUtils.requestFileData(isResized ? url.split("?width")[0].split("?height")[0].split("?size")[0] : url, {timeout: 3000}, (error, buffer) => { - if (error || !buffer) { - if (isResized) this.requestFile(urls, onLoad, onError, {orignalSizeChecked: true}); - else if (urls.fallbackUrl && urls.url != urls.fallbackUrl) this.requestFile({url: urls.fallbackUrl, oldUrl: urls.url}, onLoad, onError); - else this.requestFile({url: urls.oldUrl || urls.url, fallbackUrl: urls.oldUrl ? urls.url : undefined}, onLoad, onError, {fallbackToRequest: true}); - } - else onLoad(url, buffer); - }); - else BDFDB.LibraryRequires.request(isResized ? url.split("?width")[0].split("?height")[0].split("?size")[0] : url, {agentOptions: {rejectUnauthorized: false}, headers: {"Content-Type": "application/json"}}, (error, response, buffer) => { + url = isResized ? this.removeSizeInUrl(url) : url; + let isFormatted = (url.indexOf("?format=") > -1); + url = isFormatted ? this.removeFormatInUrl(url) : url; + url = url.indexOf("discordapp.com/avatars/") > 0 || url.indexOf("discordapp.com/icons/") > 0 ? `${url}?size=4096` : url; + BDFDB.LibraryRequires.request(url, {toBuffer: true}, (error, response, buffer) => { if (error || response.statusCode != 200 || response.headers["content-type"].indexOf("text/html") > -1) { - if (isResized) this.requestFile(urls, onLoad, onError, {orignalSizeChecked: true, fallbackToRequest: true}); - else if (urls.fallbackUrl && urls.url != urls.fallbackUrl) this.requestFile({url: urls.fallbackUrl}, onLoad, onError, {fallbackToRequest: true}); + if (isResized) this.requestFile(urls, onLoad, onError, {orignalSizeChecked: true}); + else if (urls.fallbackUrl && urls.url != urls.fallbackUrl) this.requestFile({url: urls.fallbackUrl}, onLoad, onError); else if (typeof onError == "function") onError(); } else onLoad(url, buffer); @@ -1504,7 +1521,7 @@ module.exports = (_ => { if (!extension) BDFDB.NotificationUtils.toast(this.labels.toast_save_failed.replace("{{var0}}", BDFDB.LanguageUtils.LanguageStrings.IMAGE).replace("{{var1}}", path || "PC"), {type: "danger"}); else { let type = fileTypes[extension].video ? BDFDB.LanguageUtils.LanguageStrings.VIDEO : BDFDB.LanguageUtils.LanguageStrings.IMAGE; - if (path) BDFDB.LibraryRequires.fs.writeFile(this.getFileName(path, (alternativeName || url.split("/").pop().split(".").slice(0, -1).join(".") || "unknown").slice(0, 35), extension, 0), Buffer.from(buffer), error => { + if (path) BDFDB.LibraryRequires.fs.writeFile(this.getFileName(path, (alternativeName || url.split("/").pop().split(".").slice(0, -1).join(".") || "unknown").slice(0, 35), extension, 0), new Uint8Array(buffer), error => { if (error) BDFDB.NotificationUtils.toast(this.labels.toast_save_failed.replace("{{var0}}", type).replace("{{var1}}", path), {type: "danger"}); else BDFDB.NotificationUtils.toast(this.labels.toast_save_success.replace("{{var0}}", type).replace("{{var1}}", path), {type: "success"}); }); @@ -1523,7 +1540,7 @@ module.exports = (_ => { } copyFile (urls) { - this.requestFile(urls, (url, buffer) => { + this.requestFile(urls, url => { let type = this.isValid(url, "video") ? BDFDB.LanguageUtils.LanguageStrings.VIDEO : BDFDB.LanguageUtils.LanguageStrings.IMAGE; BDFDB.LibraryModules.WindowUtils.copyImage(url); BDFDB.NotificationUtils.toast(this.labels.toast_copy_success.replace("{{var0}}", type), {type: "success"}); @@ -1678,6 +1695,14 @@ module.exports = (_ => { return filtered; } + removeSizeInUrl (url) { + return (url || "").split(/[&?]width=/)[0].split(/[&?]height=/)[0].split(/[&?]size=/)[0].split(/[&?]width=/)[0].split(/[&?]height=/)[0].split(/[&?]size=/)[0]; + } + + removeFormatInUrl (url) { + return (url || "").replace(/format\=[A-z]+(\&){0,1}/g, ""); + } + addListener (eventType, type, callback) { if (!type || !eventType || typeof callback != "function") return; if (!eventTypes[type]) eventTypes[type] = []; @@ -1701,13 +1726,14 @@ module.exports = (_ => { case "bg": // Bulgarian return { context_copy: "Копирайте {{var0}}", - context_imageactions: "Действия с изображения", + context_imageactions: "Действия с изображения", context_lenssize: "Размер на обектива", - context_zoomspeed: "Скорост на мащабиране", context_saveas: "Запазете {{var0}} като ...", context_searchwith: "Търсете {{var0}} с ...", - context_videoactions: "Видео действия", + context_streamactions: "Действия за визуализация на потока", + context_videoactions: "Видео действия", context_view: "Преглед {{var0}}", + context_zoomspeed: "Скорост на мащабиране", submenu_disabled: "Всички инвалиди", toast_copy_failed: "{{var0}} не можа да бъде копиран в клипборда", toast_copy_success: "{{var0}} беше копиран в клипборда", @@ -1717,13 +1743,14 @@ module.exports = (_ => { case "cs": // Czech return { context_copy: "Zkopírovat {{var0}}", - context_imageactions: "Akce s obrázky", + context_imageactions: "Akce s obrázky", context_lenssize: "Velikost lupy", - context_zoomspeed: "Rychlost zoomu", context_saveas: "Uložit {{var0}} jako...", context_searchwith: "Hledat {{var0}} pomocí...", - context_videoactions: "Video akce", + context_streamactions: "Akce náhledu streamu", + context_videoactions: "Video akce", context_view: "Zobrazit {{var0}}", + context_zoomspeed: "Rychlost zoomu", submenu_disabled: "Vše zakázáno", toast_copy_failed: "{{var0}} nemohl být zkopírován do schránky", toast_copy_success: "{{var0}} byl zkopírován do schránky", @@ -1733,13 +1760,14 @@ module.exports = (_ => { case "da": // Danish return { context_copy: "Kopiér {{var0}}", - context_imageactions: "Billedhandlinger", + context_imageactions: "Billedhandlinger", context_lenssize: "Objektivstørrelse", - context_zoomspeed: "Zoomhastighed", context_saveas: "Gem {{var0}} som ...", context_searchwith: "Søg i {{var0}} med ...", - context_videoactions: "Videohandlinger", + context_streamactions: "Stream forhåndsvisningshandlinger", + context_videoactions: "Videohandlinger", context_view: "Se {{var0}}", + context_zoomspeed: "Zoomhastighed", submenu_disabled: "Alle handicappede", toast_copy_failed: "{{var0}} kunne ikke kopieres til udklipsholderen", toast_copy_success: "{{var0}} blev kopieret til udklipsholderen", @@ -1749,13 +1777,14 @@ module.exports = (_ => { case "de": // German return { context_copy: "{{var0}} kopieren", - context_imageactions: "Bildaktionen", + context_imageactions: "Bildaktionen", context_lenssize: "Linsengröße", - context_zoomspeed: "Zoomgeschwindigkeit", context_saveas: "{{var0}} speichern als ...", context_searchwith: "{{var0}} suchen mit ...", - context_videoactions: "Videoaktionen", + context_streamactions: "Stream-Vorschau-Aktionen", + context_videoactions: "Videoaktionen", context_view: "{{var0}} ansehen", + context_zoomspeed: "Zoomgeschwindigkeit", submenu_disabled: "Alle deaktiviert", toast_copy_failed: "{{var0}} konnte nicht in die Zwischenablage kopiert werden", toast_copy_success: "{{var0}} wurde in die Zwischenablage kopiert", @@ -1765,13 +1794,14 @@ module.exports = (_ => { case "el": // Greek return { context_copy: "Αντιγραφή {{var0}}", - context_imageactions: "Ενέργειες εικόνας", + context_imageactions: "Ενέργειες εικόνας", context_lenssize: "Μέγεθος φακού", - context_zoomspeed: "Ταχύτητα ζουμ", context_saveas: "Αποθήκευση {{var0}} ως ...", context_searchwith: "Αναζήτηση {{var0}} με ...", - context_videoactions: "Ενέργειες βίντεο", + context_streamactions: "Ενέργειες προεπισκόπησης ροής", + context_videoactions: "Ενέργειες βίντεο", context_view: "Προβολή {{var0}}", + context_zoomspeed: "Ταχύτητα ζουμ", submenu_disabled: "Όλα τα άτομα με ειδικές ανάγκες", toast_copy_failed: "Δεν ήταν δυνατή η αντιγραφή του {{var0}} στο πρόχειρο", toast_copy_success: "Το {{var0}} αντιγράφηκε στο πρόχειρο", @@ -1781,13 +1811,14 @@ module.exports = (_ => { case "es": // Spanish return { context_copy: "Copiar {{var0}}", - context_imageactions: "Acciones de imagen", + context_imageactions: "Acciones de imagen", context_lenssize: "Tamaño de la lente", - context_zoomspeed: "Velocidad de zoom", context_saveas: "Guardar {{var0}} como ...", context_searchwith: "Buscar {{var0}} con ...", - context_videoactions: "Acciones de vídeo", + context_streamactions: "Acciones de vista previa de transmisión", + context_videoactions: "Acciones de vídeo", context_view: "Ver {{var0}}", + context_zoomspeed: "Velocidad de zoom", submenu_disabled: "Todos discapacitados", toast_copy_failed: "{{var0}} no se pudo copiar al portapapeles", toast_copy_success: "{{var0}} se copió en el portapapeles", @@ -1797,13 +1828,14 @@ module.exports = (_ => { case "fi": // Finnish return { context_copy: "Kopioi {{var0}}", - context_imageactions: "Kuvatoiminnot", + context_imageactions: "Kuvatoiminnot", context_lenssize: "Linssin koko", - context_zoomspeed: "Zoomausnopeus", context_saveas: "Tallenna {{var0}} nimellä ...", context_searchwith: "Tee haku {{var0}} ...", - context_videoactions: "Videotoiminnot", + context_streamactions: "Streamin esikatselutoiminnot", + context_videoactions: "Videotoiminnot", context_view: "Näytä {{var0}}", + context_zoomspeed: "Zoomausnopeus", submenu_disabled: "Kaikki vammaiset", toast_copy_failed: "Kohdetta {{var0}} ei voitu kopioida leikepöydälle", toast_copy_success: "{{var0}} kopioitiin leikepöydälle", @@ -1813,13 +1845,14 @@ module.exports = (_ => { case "fr": // French return { context_copy: "Copier {{var0}}", - context_imageactions: "Actions sur les images", + context_imageactions: "Actions sur les images", context_lenssize: "Taille de l'objectif", - context_zoomspeed: "Vitesse de zoom", context_saveas: "Enregistrer {{var0}} sous ...", context_searchwith: "Rechercher {{var0}} avec ...", - context_videoactions: "Actions vidéo", + context_streamactions: "Actions d'aperçu de flux", + context_videoactions: "Actions vidéo", context_view: "Afficher {{var0}}", + context_zoomspeed: "Vitesse de zoom", submenu_disabled: "Tout désactivé", toast_copy_failed: "{{var0}} n'a pas pu être copié dans le presse-papiers", toast_copy_success: "{{var0}} a été copié dans le presse-papiers", @@ -1829,13 +1862,14 @@ module.exports = (_ => { case "hi": // Hindi return { context_copy: "कॉपी {{var0}}", - context_imageactions: "छवि क्रियाएँ", + context_imageactions: "छवि क्रियाएँ", context_lenssize: "लेंस का आकार", - context_zoomspeed: "ज़ूम गति", context_saveas: "{{var0}} को इस रूप में सेव करें...", context_searchwith: "इसके साथ {{var0}} खोजें ...", - context_videoactions: "वीडियो क्रिया", + context_streamactions: "स्ट्रीम पूर्वावलोकन क्रियाएं", + context_videoactions: "वीडियो क्रिया", context_view: "देखें {{var0}}", + context_zoomspeed: "ज़ूम गति", submenu_disabled: "सभी अक्षम", toast_copy_failed: "{{var0}} को क्लिपबोर्ड पर कॉपी नहीं किया जा सका", toast_copy_success: "{{var0}} को क्लिपबोर्ड पर कॉपी किया गया था", @@ -1845,13 +1879,14 @@ module.exports = (_ => { case "hr": // Croatian return { context_copy: "Kopiraj {{var0}}", - context_imageactions: "Radnje slike", + context_imageactions: "Radnje slike", context_lenssize: "Veličina leće", - context_zoomspeed: "Brzina zumiranja", context_saveas: "Spremi {{var0}} kao ...", context_searchwith: "Traži {{var0}} sa ...", - context_videoactions: "Video radnje", + context_streamactions: "Radnje pregleda streama", + context_videoactions: "Video radnje", context_view: "Pogledajte {{var0}}", + context_zoomspeed: "Brzina zumiranja", submenu_disabled: "Svi invalidi", toast_copy_failed: "{{var0}} nije moguće kopirati u međuspremnik", toast_copy_success: "{{var0}} je kopirano u međuspremnik", @@ -1861,13 +1896,14 @@ module.exports = (_ => { case "hu": // Hungarian return { context_copy: "{{var0}} másolása", - context_imageactions: "Képműveletek", + context_imageactions: "Képműveletek", context_lenssize: "Lencse mérete", - context_zoomspeed: "Zoom sebesség", context_saveas: "{{var0}} mentése másként ...", context_searchwith: "Keresés a következőben: {{var0}} a következővel:", - context_videoactions: "Videóműveletek", + context_streamactions: "Stream előnézeti műveletek", + context_videoactions: "Videóműveletek", context_view: "Megtekintés: {{var0}}", + context_zoomspeed: "Zoom sebesség", submenu_disabled: "Minden fogyatékkal él", toast_copy_failed: "A {{var0}} fájl nem másolható a vágólapra", toast_copy_success: "A {{var0}} elemet a vágólapra másolta", @@ -1877,13 +1913,14 @@ module.exports = (_ => { case "it": // Italian return { context_copy: "Copia {{var0}}", - context_imageactions: "Azioni immagine", + context_imageactions: "Azioni immagine", context_lenssize: "Dimensione della lente", - context_zoomspeed: "Velocità dello zoom", context_saveas: "Salva {{var0}} come ...", context_searchwith: "Cerca {{var0}} con ...", - context_videoactions: "Azioni video", + context_streamactions: "Azioni di anteprima del flusso", + context_videoactions: "Azioni video", context_view: "Visualizza {{var0}}", + context_zoomspeed: "Velocità dello zoom", submenu_disabled: "Tutti disabilitati", toast_copy_failed: "{{var0}} non può essere copiato negli appunti", toast_copy_success: "{{var0}} è stato copiato negli appunti", @@ -1893,13 +1930,14 @@ module.exports = (_ => { case "ja": // Japanese return { context_copy: "{{var0}} をコピーします", - context_imageactions: "画像アクション", + context_imageactions: "画像アクション", context_lenssize: "レンズサイズ", - context_zoomspeed: "ズーム速度", context_saveas: "{{var0}} を...として保存します", context_searchwith: "{{var0}} を...で検索", - context_videoactions: "ビデオ アクション", + context_streamactions: "ストリーム プレビュー アクション", + context_videoactions: "ビデオ アクション", context_view: "{{var0}} を表示", + context_zoomspeed: "ズーム速度", submenu_disabled: "すべて無効", toast_copy_failed: "{{var0}} をクリップボードにコピーできませんでした", toast_copy_success: "{{var0}} がクリップボードにコピーされました", @@ -1909,13 +1947,14 @@ module.exports = (_ => { case "ko": // Korean return { context_copy: "{{var0}} 복사", - context_imageactions: "이미지 작업", + context_imageactions: "이미지 작업", context_lenssize: "렌즈 크기", - context_zoomspeed: "줌 속도", context_saveas: "{{var0}} 을 다른 이름으로 저장 ...", context_searchwith: "{{var0}} 검색 ...", - context_videoactions: "비디오 작업", + context_streamactions: "스트림 미리보기 작업", + context_videoactions: "비디오 작업", context_view: "{{var0}} 보기", + context_zoomspeed: "줌 속도", submenu_disabled: "모두 비활성화 됨", toast_copy_failed: "{{var0}} 을 클립 보드에 복사 할 수 없습니다.", toast_copy_success: "{{var0}} 이 클립 보드에 복사되었습니다.", @@ -1925,13 +1964,14 @@ module.exports = (_ => { case "lt": // Lithuanian return { context_copy: "Kopijuoti {{var0}}", - context_imageactions: "Vaizdo veiksmai", + context_imageactions: "Vaizdo veiksmai", context_lenssize: "Objektyvo dydis", - context_zoomspeed: "Priartinimo greitis", context_saveas: "Išsaugoti '{{var0}}' kaip ...", context_searchwith: "Ieškoti {{var0}} naudojant ...", - context_videoactions: "Vaizdo įrašų veiksmai", + context_streamactions: "Srauto peržiūros veiksmai", + context_videoactions: "Vaizdo įrašų veiksmai", context_view: "Žiūrėti {{var0}}", + context_zoomspeed: "Priartinimo greitis", submenu_disabled: "Visi neįgalūs", toast_copy_failed: "{{var0}} nepavyko nukopijuoti į mainų sritį", toast_copy_success: "{{var0}} buvo nukopijuota į mainų sritį", @@ -1941,13 +1981,14 @@ module.exports = (_ => { case "nl": // Dutch return { context_copy: "Kopieer {{var0}}", - context_imageactions: "Afbeeldingsacties", + context_imageactions: "Afbeeldingsacties", context_lenssize: "Lens Maat", - context_zoomspeed: "Zoom snelheid", context_saveas: "Bewaar {{var0}} als ...", context_searchwith: "Zoek {{var0}} met ...", - context_videoactions: "Video-acties", + context_streamactions: "Stream Preview-acties", + context_videoactions: "Video-acties", context_view: "Bekijk {{var0}}", + context_zoomspeed: "Zoom snelheid", submenu_disabled: "Allemaal uitgeschakeld", toast_copy_failed: "{{var0}} kan niet naar het klembord worden gekopieerd", toast_copy_success: "{{var0}} is naar het klembord gekopieerd", @@ -1957,13 +1998,14 @@ module.exports = (_ => { case "no": // Norwegian return { context_copy: "Kopier {{var0}}", - context_imageactions: "Bildehandlinger", + context_imageactions: "Bildehandlinger", context_lenssize: "Linsestørrelse", - context_zoomspeed: "Zoomhastighet", context_saveas: "Lagre {{var0}} som ...", context_searchwith: "Søk på {{var0}} med ...", - context_videoactions: "Videohandlinger", + context_streamactions: "Strøm forhåndsvisningshandlinger", + context_videoactions: "Videohandlinger", context_view: "Vis {{var0}}", + context_zoomspeed: "Zoomhastighet", submenu_disabled: "Alle funksjonshemmede", toast_copy_failed: "{{var0}} kunne ikke kopieres til utklippstavlen", toast_copy_success: "{{var0}} ble kopiert til utklippstavlen", @@ -1973,13 +2015,14 @@ module.exports = (_ => { case "pl": // Polish return { context_copy: "Kopiuj {{var0}}", - context_imageactions: "Działania związane z obrazem", + context_imageactions: "Działania związane z obrazem", context_lenssize: "Rozmiar soczewki", - context_zoomspeed: "Szybkość zoomu", context_saveas: "Zapisz {{var0}} jako ...", context_searchwith: "Wyszukaj {{var0}} za pomocą ...", - context_videoactions: "Akcje wideo", + context_streamactions: "Akcje podglądu strumienia", + context_videoactions: "Akcje wideo", context_view: "Wyświetl {{var0}}", + context_zoomspeed: "Szybkość zoomu", submenu_disabled: "Wszystkie wyłączone", toast_copy_failed: "Nie można skopiować {{var0}} do schowka", toast_copy_success: "{{var0}} został skopiowany do schowka", @@ -1989,13 +2032,14 @@ module.exports = (_ => { case "pt-BR": // Portuguese (Brazil) return { context_copy: "Copiar {{var0}}", - context_imageactions: "Ações de imagem", + context_imageactions: "Ações de imagem", context_lenssize: "Tamanho da lente", - context_zoomspeed: "Velocidade do zoom", context_saveas: "Salvar {{var0}} como ...", context_searchwith: "Pesquisar {{var0}} com ...", - context_videoactions: "Ações de vídeo", + context_streamactions: "Ações de visualização de fluxo", + context_videoactions: "Ações de vídeo", context_view: "Visualizar {{var0}}", + context_zoomspeed: "Velocidade do zoom", submenu_disabled: "Todos desativados", toast_copy_failed: "{{var0}} não pôde ser copiado para a área de transferência", toast_copy_success: "{{var0}} foi copiado para a área de transferência", @@ -2005,13 +2049,14 @@ module.exports = (_ => { case "ro": // Romanian return { context_copy: "Copiați {{var0}}", - context_imageactions: "Acțiuni de imagine", + context_imageactions: "Acțiuni de imagine", context_lenssize: "Dimensiunea obiectivului", - context_zoomspeed: "Viteza de zoom", context_saveas: "Salvați {{var0}} ca ...", context_searchwith: "Căutați {{var0}} cu ...", - context_videoactions: "Acțiuni video", + context_streamactions: "Acțiuni de previzualizare în flux", + context_videoactions: "Acțiuni video", context_view: "Vizualizați {{var0}}", + context_zoomspeed: "Viteza de zoom", submenu_disabled: "Toate sunt dezactivate", toast_copy_failed: "{{var0}} nu a putut fi copiat în clipboard", toast_copy_success: "{{var0}} a fost copiat în clipboard", @@ -2021,13 +2066,14 @@ module.exports = (_ => { case "ru": // Russian return { context_copy: "Скопируйте {{var0}}", - context_imageactions: "Действия с изображением", + context_imageactions: "Действия с изображением", context_lenssize: "Размер линзы", - context_zoomspeed: "Скорость масштабирования", context_saveas: "Сохранить {{var0}} как ...", context_searchwith: "Искать {{var0}} с помощью ...", - context_videoactions: "Действия с видео", + context_streamactions: "Действия предварительного просмотра трансляции", + context_videoactions: "Действия с видео", context_view: "Посмотреть {{var0}}", + context_zoomspeed: "Скорость масштабирования", submenu_disabled: "Все отключены", toast_copy_failed: "{{var0}} не удалось скопировать в буфер обмена", toast_copy_success: "{{var0}} скопирован в буфер обмена", @@ -2037,13 +2083,14 @@ module.exports = (_ => { case "sv": // Swedish return { context_copy: "Kopiera {{var0}}", - context_imageactions: "Bildåtgärder", + context_imageactions: "Bildåtgärder", context_lenssize: "Linsstorlek", - context_zoomspeed: "Zoomhastighet", context_saveas: "Spara {{var0}} som ...", context_searchwith: "Sök {{var0}} med ...", - context_videoactions: "Videoåtgärder", + context_streamactions: "Streama förhandsgranskningsåtgärder", + context_videoactions: "Videoåtgärder", context_view: "Visa {{var0}}", + context_zoomspeed: "Zoomhastighet", submenu_disabled: "Alla funktionshindrade", toast_copy_failed: "{{var0}} kunde inte kopieras till Urklipp", toast_copy_success: "{{var0}} kopierades till Urklipp", @@ -2053,13 +2100,14 @@ module.exports = (_ => { case "th": // Thai return { context_copy: "คัดลอก{{var0}}", - context_imageactions: "การทำงานของรูปภาพ", + context_imageactions: "การทำงานของรูปภาพ", context_lenssize: "ขนาดเลนส์", - context_zoomspeed: "ความเร็วในการซูม", context_saveas: "บันทึก{{var0}}เป็น ...", context_searchwith: "ค้นหา{{var0}} ้วย ...", - context_videoactions: "การกระทำของวิดีโอ", + context_streamactions: "การดำเนินการแสดงตัวอย่างสตรีม", + context_videoactions: "การกระทำของวิดีโอ", context_view: "ดู{{var0}}", + context_zoomspeed: "ความเร็วในการซูม", submenu_disabled: "ปิดใช้งานทั้งหมด", toast_copy_failed: "ไม่สามารถคัดลอก{{var0}}ไปยังคลิปบอร์ดได้", toast_copy_success: "คัดลอก{{var0}}ไปยังคลิปบอร์ดแล้ว", @@ -2069,13 +2117,14 @@ module.exports = (_ => { case "tr": // Turkish return { context_copy: "{{var0}} kopyala", - context_imageactions: "Görüntü Eylemleri", + context_imageactions: "Görüntü Eylemleri", context_lenssize: "Lens Boyutu", - context_zoomspeed: "yakınlaştırma hızı", context_saveas: "{{var0}} farklı kaydet ...", context_searchwith: "{{var0}} şununla ara ...", - context_videoactions: "Video Eylemleri", + context_streamactions: "Akış Önizleme İşlemleri", + context_videoactions: "Video Eylemleri", context_view: "{{var0}} görüntüle", + context_zoomspeed: "yakınlaştırma hızı", submenu_disabled: "Hepsi devre dışı", toast_copy_failed: "{{var0}} panoya kopyalanamadı", toast_copy_success: "{{var0}} panoya kopyalandı", @@ -2085,13 +2134,14 @@ module.exports = (_ => { case "uk": // Ukrainian return { context_copy: "Копіювати {{var0}}", - context_imageactions: "Дії із зображеннями", + context_imageactions: "Дії із зображеннями", context_lenssize: "Розмір лінзи", - context_zoomspeed: "Швидкість масштабування", context_saveas: "Збережіть {{var0}} як ...", context_searchwith: "Шукати {{var0}} за допомогою ...", - context_videoactions: "Відео дії", + context_streamactions: "Дії попереднього перегляду потоку", + context_videoactions: "Відео дії", context_view: "Переглянути {{var0}}", + context_zoomspeed: "Швидкість масштабування", submenu_disabled: "Всі інваліди", toast_copy_failed: "Не вдалося скопіювати {{var0}} у буфер обміну", toast_copy_success: "{{var0}} скопійовано в буфер обміну", @@ -2101,13 +2151,14 @@ module.exports = (_ => { case "vi": // Vietnamese return { context_copy: "Sao chép {{var0}}", - context_imageactions: "Hành động hình ảnh", + context_imageactions: "Hành động hình ảnh", context_lenssize: "Kích thước ống kính", - context_zoomspeed: "tốc độ thu phóng", context_saveas: "Lưu {{var0}} dưới dạng ...", context_searchwith: "Tìm kiếm {{var0}} bằng ...", - context_videoactions: "Hành động video", + context_streamactions: "Tác vụ xem trước luồng", + context_videoactions: "Hành động video", context_view: "Xem {{var0}}", + context_zoomspeed: "tốc độ thu phóng", submenu_disabled: "Tất cả đã bị vô hiệu hóa", toast_copy_failed: "Không thể sao chép {{var0}} vào khay nhớ tạm", toast_copy_success: "{{var0}} đã được sao chép vào khay nhớ tạm", @@ -2117,13 +2168,14 @@ module.exports = (_ => { case "zh-CN": // Chinese (China) return { context_copy: "复制 {{var0}}", - context_imageactions: "图像动作", + context_imageactions: "图像动作", context_lenssize: "缩放尺寸", - context_zoomspeed: "变焦速度", context_saveas: "将 {{var0}} 另存到...", context_searchwith: "搜索 {{var0}} 使用...", - context_videoactions: "视频动作", + context_streamactions: "流预览操作", + context_videoactions: "视频动作", context_view: "查看 {{var0}}", + context_zoomspeed: "变焦速度", submenu_disabled: "全部禁用", toast_copy_failed: "{{var0}} 无法复制到剪贴板", toast_copy_success: "{{var0}} 已复制到剪贴板", @@ -2133,13 +2185,14 @@ module.exports = (_ => { case "zh-TW": // Chinese (Taiwan) return { context_copy: "複製 {{var0}}", - context_imageactions: "圖像動作", + context_imageactions: "圖像動作", context_lenssize: "縮放尺寸", - context_zoomspeed: "变焦速度", context_saveas: "將 {{var0}} 另存到...", context_searchwith: "搜尋 {{var0}} 使用...", - context_videoactions: "視頻動作", + context_streamactions: "流預覽操作", + context_videoactions: "視頻動作", context_view: "預覽 {{var0}}", + context_zoomspeed: "变焦速度", submenu_disabled: "全部關閉", toast_copy_failed: "{{var0}} 無法複製到剪貼簿", toast_copy_success: "{{var0}} 已複製到剪貼簿", @@ -2149,13 +2202,14 @@ module.exports = (_ => { default: // English return { context_copy: "Copy {{var0}}", - context_imageactions: "Image Actions", - context_lenssize: "Lens Size", - context_zoomspeed: "Zoom speed", + context_imageactions: "Image Actions", + context_lenssize: "Lens size", context_saveas: "Save {{var0}} as ...", context_searchwith: "Search {{var0}} with ...", - context_videoactions: "Video Actions", + context_streamactions: "Stream Preview Actions", + context_videoactions: "Video Actions", context_view: "View {{var0}}", + context_zoomspeed: "Zoom speed", submenu_disabled: "All disabled", toast_copy_failed: "{{var0}} could not be copied to the Clipboard", toast_copy_success: "{{var0}} was copied to the Clipboard", diff --git a/.config/BetterDiscord/plugins/InvisibleTyping.config.json b/.config/BetterDiscord/plugins/InvisibleTyping.config.json index 5ab6e1e..262d003 100644 --- a/.config/BetterDiscord/plugins/InvisibleTyping.config.json +++ b/.config/BetterDiscord/plugins/InvisibleTyping.config.json @@ -1,5 +1,8 @@ { "settings": { - "latestUsedVersion": "1.3.3" + "latestUsedVersion": "1.3.3", + "exclude": [ + "709081938622939166" + ] } } \ No newline at end of file diff --git a/.config/BetterDiscord/plugins/NotificationSounds.config.json b/.config/BetterDiscord/plugins/NotificationSounds.config.json index 7c3f508..fdc11f0 100755 --- a/.config/BetterDiscord/plugins/NotificationSounds.config.json +++ b/.config/BetterDiscord/plugins/NotificationSounds.config.json @@ -271,6 +271,94 @@ "mute": false, "sound": "---", "volume": 100 + }, + "clip_save": { + "category": "---", + "focus": false, + "mute": false, + "sound": "---", + "streamMute": false, + "volume": 100 + }, + "activities-rocket-time": { + "category": "---", + "focus": false, + "invisibleMute": false, + "mute": false, + "sound": "---", + "streamMute": false, + "volume": 100 + }, + "activity_end": { + "category": "---", + "focus": false, + "invisibleMute": false, + "mute": false, + "sound": "---", + "streamMute": false, + "volume": 100 + }, + "activity_launch": { + "category": "---", + "focus": false, + "invisibleMute": false, + "mute": false, + "sound": "---", + "streamMute": false, + "volume": 100 + }, + "activity_user_join": { + "category": "---", + "focus": false, + "invisibleMute": false, + "mute": false, + "sound": "---", + "streamMute": false, + "volume": 100 + }, + "activity_user_left": { + "category": "---", + "focus": false, + "invisibleMute": false, + "mute": false, + "sound": "---", + "streamMute": false, + "volume": 100 + }, + "clip_error": { + "category": "---", + "focus": false, + "invisibleMute": false, + "mute": false, + "sound": "---", + "streamMute": false, + "volume": 100 + }, + "hang_status_select": { + "category": "---", + "focus": false, + "invisibleMute": false, + "mute": false, + "sound": "---", + "streamMute": false, + "volume": 100 + }, + "call_ringing_snowsgiving": { + "category": "---", + "focus": false, + "invisibleMute": false, + "mute": null, + "sound": "---", + "streamMute": false, + "volume": 100 + }, + "message3": { + "category": "---", + "invisibleMute": false, + "mute": false, + "sound": "---", + "streamMute": false, + "volume": 100 } }, "volumes": { diff --git a/.config/BetterDiscord/plugins/NotificationSounds.plugin.js b/.config/BetterDiscord/plugins/NotificationSounds.plugin.js index 60d1c17..7e28e82 100644 --- a/.config/BetterDiscord/plugins/NotificationSounds.plugin.js +++ b/.config/BetterDiscord/plugins/NotificationSounds.plugin.js @@ -2,7 +2,7 @@ * @name NotificationSounds * @author DevilBro * @authorId 278543574059057154 - * @version 3.7.8 + * @version 3.9.2 * @description Allows you to replace the native Sounds with custom Sounds * @invite Jx3TjNS * @donate https://www.paypal.me/MircoWittrien @@ -14,7 +14,12 @@ module.exports = (_ => { const changeLog = { - + "added": { + "Current Channel": "Added Option to change the sound for the current channel notification, (note: Discord added an option in the THEIR notification settings to play a different sound when a message is sent in the current channel, you need to have this enabled in order to be able to change the sound in the plugin settings" + }, + "fixed": { + "Current Channel": "No longer plays notification sounds for current channels, if the option is disabled" + } }; return !window.BDFDB_Global || (!window.BDFDB_Global.loaded && !window.BDFDB_Global.started) ? class { @@ -25,9 +30,14 @@ module.exports = (_ => { getDescription () {return `The Library Plugin needed for ${this.name} is missing. Open the Plugin Settings to download it. \n\n${this.description}`;} downloadLibrary () { - require("request").get("https://mwittrien.github.io/BetterDiscordAddons/Library/0BDFDB.plugin.js", (e, r, b) => { - if (!e && b && r.statusCode == 200) require("fs").writeFile(require("path").join(BdApi.Plugins.folder, "0BDFDB.plugin.js"), b, _ => BdApi.showToast("Finished downloading BDFDB Library", {type: "success"})); - else BdApi.alert("Error", "Could not download BDFDB Library Plugin. Try again later or download it manually from GitHub: https://mwittrien.github.io/downloader/?library"); + BdApi.Net.fetch("https://mwittrien.github.io/BetterDiscordAddons/Library/0BDFDB.plugin.js").then(r => { + if (!r || r.status != 200) throw new Error(); + else return r.text(); + }).then(b => { + if (!b) throw new Error(); + else return require("fs").writeFile(require("path").join(BdApi.Plugins.folder, "0BDFDB.plugin.js"), b, _ => BdApi.showToast("Finished downloading BDFDB Library", {type: "success"})); + }).catch(error => { + BdApi.alert("Error", "Could not download BDFDB Library Plugin. Try again later or download it manually from GitHub: https://mwittrien.github.io/downloader/?library"); }); } @@ -67,13 +77,24 @@ module.exports = (_ => { let types = {}; const message1Types = { - dm: {src: "./message3.mp3", name: "Message (Direct Message)", force: null, focus: true}, - groupdm: {src: "./message3.mp3", name: "Message (Group Message)", force: null, focus: true}, - mentioned: {src: "./message2.mp3", name: "Message Mentioned", force: false, focus: true}, - reply: {src: "./message2.mp3", name: "Message Mentioned (reply)", force: false, focus: true}, - role: {src: "./mention1.mp3", name: "Message Mentioned (role)", force: false, focus: true}, - everyone: {src: "./mention2.mp3", name: "Message Mentioned (@everyone)", force: false, focus: true}, - here: {src: "./mention3.mp3", name: "Message Mentioned (@here)", force: false, focus: true} + dm: {src: "./message3.mp3", name: "Message (Direct Message)"}, + groupdm: {src: "./message3.mp3", name: "Message (Group Message)"}, + mentioned: {src: "./message2.mp3", name: "Message Mentioned"}, + reply: {src: "./message2.mp3", name: "Message Mentioned (reply)"}, + role: {src: "./mention1.mp3", name: "Message Mentioned (role)"}, + everyone: {src: "./mention2.mp3", name: "Message Mentioned (@everyone)"}, + here: {src: "./mention3.mp3", name: "Message Mentioned (@here)"} + }; + + const namePrefixes = { + "user_join": "Voice Channel", + "user_leave": "Voice Channel", + "user_moved": "Voice Channel" + }; + + const nameSynonymes = { + "message3": "Message (Current Channel)", + "reconnect": "Invited To Speak" }; const defaultAudios = { @@ -101,6 +122,16 @@ module.exports = (_ => { audio.play(); }); } + playWithListener (duration) { + return new Promise((callback, errorCallback) => { + this._ensureAudio().then(audio => { + if (!duration && duration !== 0) errorCallback(new Error("sound has no duration")); + audio.loop = false; + audio.play(); + setTimeout(_ => callback(true), duration); + }); + }); + } pause () { this._audio.then(audio => { audio.pause(); @@ -152,7 +183,7 @@ module.exports = (_ => { this.defaults = { volumes: { - globalVolume: {value: 100, description: "Global Notification Sounds Volume"} + globalVolume: {value: 100, description: "Global Notification Sounds Volume"} } }; @@ -163,7 +194,7 @@ module.exports = (_ => { const soundKeys = BDFDB.LibraryModules.SoundParser.keys(); for (let key of soundKeys) { const id = key.replace("./", "").replace(".mp3", ""); - const name = id == "reconnect" ? "Invited To Speak" : id.replace("ddr-", "HotKeys_").replace("ptt_", "Push2Talk_").split("_").map(BDFDB.StringUtils.upperCaseFirstChar).join(" ").replace(/1$/g, ""); + const name = [namePrefixes[id], (nameSynonymes[id] || id).replace("ddr-", "HotKeys_").replace("ptt_", "Push2Talk_").split(/[_-]/)].flat(10).filter(n => n).map(BDFDB.StringUtils.upperCaseFirstChar).join(" ").replace(/1$/g, ""); const src = BDFDB.LibraryModules.SoundParser(key); let soundPackName = id.split("_")[0]; @@ -179,19 +210,18 @@ module.exports = (_ => { src: src, mute: id.startsWith("call_") ? null : false, streamMute: false, - force: id == "message1" ? false : null, - focus: id == "message1" ? true : false + invisibleMute: false }; if (id == "message1") { types[id].mute = true; types[id].streamMute = false; + types[id].invisibleMute = false; for (let subType in message1Types) types[subType] = { name: message1Types[subType].name, src: BDFDB.LibraryModules.SoundParser(message1Types[subType].src), mute: true, streamMute: false, - force: message1Types[subType].force, - focus: message1Types[subType].focus + invisibleMute: false } } } @@ -225,53 +255,54 @@ module.exports = (_ => { const message = e.methodArguments[0].message; const guildId = message.guild_id || null; if (message.author.id != BDFDB.UserUtils.me.id && !BDFDB.LibraryStores.RelationshipStore.isBlocked(message.author.id)) { + const isCurrent = BDFDB.LibraryStores.SelectedChannelStore.getChannelId() == message.channel_id; const channel = BDFDB.LibraryStores.ChannelStore.getChannel(message.channel_id); const isGroupDM = channel.isGroupDM(); - const muted = BDFDB.ChannelUtils.isThread(channel) ? BDFDB.LibraryStores.JoinedThreadsStore.isMuted(channel.id) : BDFDB.LibraryStores.UserGuildSettingsStore.isGuildOrCategoryOrChannelMuted(guildId, channel.id); - const focused = document.hasFocus() && BDFDB.LibraryStores.SelectedChannelStore.getChannelId() == channel.id; - if (!guildId && !muted && !(choices[isGroupDM ? "groupdm" : "dm"].focus && focused)) { + const isThread = BDFDB.ChannelUtils.isThread(channel); + if (isThread && BDFDB.LibraryStores.JoinedThreadsStore.isMuted(channel.id) || !isThread && BDFDB.LibraryStores.UserGuildSettingsStore.isGuildOrCategoryOrChannelMuted(guildId, channel.id)) return; + if (!guildId) { this.fireEvent(isGroupDM ? "groupdm" : "dm"); - this.playAudio(isGroupDM ? "groupdm" : "dm"); + !BDFDB.LibraryStores.NotificationSettingsStore.getNotifyMessagesInSelectedChannel() && !document.hasFocus() && this.playAudio(isGroupDM ? "groupdm" : "dm"); return; } else if (guildId) { if (BDFDB.LibraryModules.MentionUtils.isRawMessageMentioned({rawMessage: message, userId: BDFDB.UserUtils.me.id})) { if (message.mentions.length && !this.isSuppressMentionsEnabled(guildId, channel.id)) for (const mention of message.mentions) if (mention.id == BDFDB.UserUtils.me.id) { - if (message.message_reference && !message.interaction && (!muted || choices.reply.force) && !(choices.reply.focus && focused)) { + if (message.message_reference && !message.interaction) { this.fireEvent("reply"); - this.playAudio("reply"); + !isCurrent && this.playAudio("reply"); return; } - if (!message.message_reference && (!muted || choices.mentioned.force) && !(choices.mentioned.focus && focused)) { + if (!message.message_reference) { this.fireEvent("mentioned"); - this.playAudio("mentioned"); + !isCurrent && this.playAudio("mentioned"); return; } } - if (message.mention_roles.length && !BDFDB.LibraryStores.UserGuildSettingsStore.isSuppressRolesEnabled(guildId, channel.id) && (!muted || choices.role.force) && !(choices.role.focus && focused)) { + if (message.mention_roles.length && !BDFDB.LibraryStores.UserGuildSettingsStore.isSuppressRolesEnabled(guildId, channel.id)) { const member = BDFDB.LibraryStores.GuildMemberStore.getMember(guildId, BDFDB.UserUtils.me.id); if (member && member.roles.length) for (const roleId of message.mention_roles) if (member.roles.includes(roleId)) { this.fireEvent("role"); - this.playAudio("role"); + !isCurrent && this.playAudio("role"); return; } } if (message.mention_everyone && !BDFDB.LibraryStores.UserGuildSettingsStore.isSuppressEveryoneEnabled(guildId, channel.id)) { - if (message.content.indexOf("@everyone") > -1 && (!muted || choices.everyone.force) && !(choices.everyone.focus && focused)) { + if (message.content.indexOf("@everyone") > -1) { this.fireEvent("everyone"); - this.playAudio("everyone"); + !isCurrent && this.playAudio("everyone"); return; } - if (message.content.indexOf("@here") > -1 && (!muted || choices.here.force) && !(choices.here.focus && focused)) { + if (message.content.indexOf("@here") > -1) { this.fireEvent("here"); - this.playAudio("here"); + !isCurrent && this.playAudio("here"); return; } } } - if (BDFDB.LibraryStores.UserGuildSettingsStore.allowAllMessages(channel) && (!muted || choices.message1.force) && !(choices.message1.focus && focused)) { + if (BDFDB.LibraryStores.UserGuildSettingsStore.allowAllMessages(channel) && !(isThread && !BDFDB.LibraryStores.JoinedThreadsStore.hasJoined(channel.id))) { this.fireEvent("message1"); - this.playAudio("message1"); + !isCurrent && this.playAudio("message1"); return; } } @@ -287,25 +318,22 @@ module.exports = (_ => { let cancel = BDFDB.PatchUtils.patch(this, BDFDB.LibraryModules.SoundUtils, "createSound", {after: e => { if (e.returnValue && e.returnValue.constructor && e.returnValue.constructor.prototype && typeof e.returnValue.constructor.prototype.play == "function") { cancel(); - BDFDB.PatchUtils.patch(this, e.returnValue.constructor.prototype, ["play", "loop"], {instead: e2 => { + BDFDB.PatchUtils.patch(this, e.returnValue.constructor.prototype, ["play", "loop", "playWithListener"], {instead: e2 => { let type = e2.instance && e2.instance.name; - let loop = e2.originalMethodName == "loop"; if (type && choices[type]) { e2.stopOriginalMethodCall(); - BDFDB.TimeUtils.timeout(_ => { - if (type == "message1") { - let called = false; - for (let subType of [type].concat(Object.keys(message1Types))) if (firedEvents[subType]) { - delete firedEvents[subType]; - called = true; - break; - } - if (!called) this.playAudio(type, loop); + if (type == "message1") BDFDB.TimeUtils.timeout(_ => { + let called = false; + for (let subType of [type].concat(Object.keys(message1Types))) if (firedEvents[subType]) { + delete firedEvents[subType]; + called = true; + break; } - else this.playAudio(type, loop); + if (!called) return this.playAudio(type, e2.originalMethodName, e2.instance.duration); }); + else return this.playAudio(type, e2.originalMethodName, e2.instance.duration); } - else this.playAudio(type, loop); + else return this.playAudio(type, e2.originalMethodName, e2.instance.duration); }}); BDFDB.PatchUtils.patch(this, e.returnValue.constructor.prototype, "stop", {after: e2 => { let type = e2.instance && e2.instance.name; @@ -404,7 +432,7 @@ module.exports = (_ => { BDFDB.ReactUtils.createElement(BDFDB.LibraryComponents.Button, { style: {marginBottom: 1}, onClick: _ => { - for (let input of settingsPanel.props._node.querySelectorAll(".input-newsound " + BDFDB.dotCN.input)) if (!input.value || input.value.length == 0 || input.value.trim().length == 0) return BDFDB.NotificationUtils.toast("Fill out all fields to add a new sound", {type: "danger"}); + for (let input of settingsPanel.props._node.querySelectorAll(".input-newsound " + BDFDB.dotCN.input)) if (!input.value || input.value.length == 0 || input.value.trim().length == 0) return BDFDB.NotificationUtils.toast("Fill out all Fields to add a new Sound", {type: "danger"}); let category = settingsPanel.props._node.querySelector(".input-category " + BDFDB.dotCN.input).value.trim(); let sound = settingsPanel.props._node.querySelector(".input-sound " + BDFDB.dotCN.input).value.trim(); let source = settingsPanel.props._node.querySelector(".input-source " + BDFDB.dotCN.input).value.trim(); @@ -415,9 +443,9 @@ module.exports = (_ => { } BDFDB.NotificationUtils.toast("Use a valid direct link to a video or audio source, they usually end on something like .mp3, .mp4 or .wav", {type: "danger"}); }); - else BDFDB.LibraryRequires.fs.readFile(source, "", (error, buffer) => { - if (error) BDFDB.NotificationUtils.toast("Could not fetch file. Please make sure the file exists", {type: "danger"}); - else return successSavedAudio({category, sound, source: `data:audio/mpeg;base64,${Buffer.from(buffer).toString("base64")}`}); + else BDFDB.LibraryRequires.fs.readFile(source, "base64", (error, body) => { + if (error) BDFDB.NotificationUtils.toast("Could not fetch file. Please make sure the file exists.", {type: "danger"}); + else return successSavedAudio({category, sound, source: `data:audio/mpeg;base64,${body}`}); }); }, children: BDFDB.LanguageUtils.LanguageStrings.SAVE @@ -430,7 +458,7 @@ module.exports = (_ => { settingsItems.push(BDFDB.ReactUtils.createElement(BDFDB.LibraryComponents.CollapseContainer, { title: "Sound Configuration", collapseStates: collapseStates, - children: Object.keys(types).map(type => [ + children: Object.keys(types).map(type => type == "message3" && !BDFDB.LibraryStores.NotificationSettingsStore.getNotifyMessagesInSelectedChannel() ? null : [ BDFDB.ReactUtils.createElement(BDFDB.LibraryComponents.Flex, { className: BDFDB.disCN.marginbottom8, align: BDFDB.LibraryComponents.Flex.Align.CENTER, @@ -439,34 +467,20 @@ module.exports = (_ => { BDFDB.ReactUtils.createElement(BDFDB.LibraryComponents.SettingsLabel, { label: types[type].name }), - ["force", "focus", "mute", "streamMute"].some(n => types[type][n] !== null) && BDFDB.ReactUtils.createElement(BDFDB.LibraryComponents.Clickable, { + ["mute", "streamMute", "invisibleMute"].some(n => types[type][n] !== null) && BDFDB.ReactUtils.createElement(BDFDB.LibraryComponents.Clickable, { onClick: event => BDFDB.ContextMenuUtils.open(this, event, BDFDB.ContextMenuUtils.createItem(BDFDB.LibraryComponents.MenuItems.MenuGroup, { children: [ - {key: "force", label: "Force Play", hint: BDFDB.ReactUtils.createElement(BDFDB.LibraryComponents.TooltipContainer, { - text: "Plays the Message Sound even if the Channel of the Message is muted", - children: BDFDB.ReactUtils.createElement(BDFDB.LibraryComponents.SvgIcon, { - name: BDFDB.LibraryComponents.SvgIcon.Names.QUESTIONMARK, - width: 18, - height: 18 - }) - })}, - {key: "focus", label: "Focus Mute", hint: BDFDB.ReactUtils.createElement(BDFDB.LibraryComponents.TooltipContainer, { - text: "Does not play the Message Sound when the Channel of the Message is currently opened", - children: BDFDB.ReactUtils.createElement(BDFDB.LibraryComponents.SvgIcon, { - name: BDFDB.LibraryComponents.SvgIcon.Names.QUESTIONMARK, - width: 18, - height: 18 - }) - })}, {key: "mute", label: ["Mute in", BDFDB.ReactUtils.createElement(BDFDB.LibraryComponents.StatusComponents.Status, {style: {marginLeft: 6}, size: 12, status: BDFDB.LibraryComponents.StatusComponents.Types.DND})]}, - {key: "streamMute", label: ["Mute while", BDFDB.ReactUtils.createElement(BDFDB.LibraryComponents.StatusComponents.Status, {style: {marginLeft: 6}, size: 12, status: BDFDB.LibraryComponents.StatusComponents.Types.STREAMING})]}, + {key: "invisibleMute", label: ["Mute in", BDFDB.ReactUtils.createElement(BDFDB.LibraryComponents.StatusComponents.Status, {style: {marginLeft: 6}, size: 12, status: BDFDB.LibraryComponents.StatusComponents.Types.INVISIBLE})]}, + {key: "streamMute", label: ["Mute while", BDFDB.ReactUtils.createElement(BDFDB.LibraryComponents.StatusComponents.Status, {style: {marginLeft: 6}, size: 12, status: BDFDB.LibraryComponents.StatusComponents.Types.STREAMING})]} ].map(n => types[type][n.key] !== null && BDFDB.ContextMenuUtils.createItem(BDFDB.LibraryComponents.MenuItems.MenuCheckboxItem, { label: BDFDB.ReactUtils.createElement(BDFDB.LibraryComponents.Flex, { + align: BDFDB.LibraryComponents.Flex.Align.CENTER, children: n.label }), hint: n.hint, id: BDFDB.ContextMenuUtils.createItemId(this.name, type, n.key), - checked: types[type][n.key], + checked: choices[type][n.key], action: state => { choices[type][n.key] = state; this.saveChoice(type, false); @@ -676,7 +690,7 @@ module.exports = (_ => { volume: 100, mute: types[type].mute, streamMute: types[type].streamMute, - focus: types[type].focus + invisibleMute: types[type].invisibleMute }; choices[type] = choice; this.saveChoice(type, false); @@ -692,11 +706,11 @@ module.exports = (_ => { } } - playAudio (type, loop = false) { + playAudio (type, functionCall = "play", duration = 0) { if (this.dontPlayAudio(type) || BDFDB.LibraryStores.StreamerModeStore.disableSounds) return; if (createdAudios[type]) createdAudios[type].stop(); createdAudios[type] = new WebAudioSound(type); - createdAudios[type][loop ? "loop" : "play"](); + return createdAudios[type][typeof createdAudios[type][functionCall] == "function" ? functionCall : "play"](duration); } isSuppressMentionsEnabled (guildId, channelId) { @@ -706,7 +720,7 @@ module.exports = (_ => { dontPlayAudio (type) { let status = BDFDB.UserUtils.getStatus(); - return choices[type] && (choices[type].mute && status == "dnd" || choices[type].streamMute && status == "streaming"); + return choices[type] && (choices[type].mute && status == "dnd" || choices[type].streamMute && status == "streaming" || choices[type].invisibleMute && (status == "offline" || status == "invisible")); } fireEvent (type) { @@ -715,7 +729,7 @@ module.exports = (_ => { } isSoundUsedAnywhere (type) { - return type && type.indexOf("poggermode_") != 0 && type != "human_man" && type != "robot_man" && type != "discodo" && type != "overlayunlock" && type != "call_ringing_beat" && !(type != "message1" && /\d$/.test(type)); + return type && type.indexOf("poggermode_") != 0 && type != "human_man" && type != "robot_man" && type != "discodo" && type != "overlayunlock" && type != "call_ringing_beat" && !(type != "message1" && type != "message3" && /\d$/.test(type)); } }; })(window.BDFDB_Global.PluginUtils.buildPlugin(changeLog)); diff --git a/.config/BetterDiscord/plugins/PinDMs.config.json b/.config/BetterDiscord/plugins/PinDMs.config.json index a94e274..147ef0e 100644 --- a/.config/BetterDiscord/plugins/PinDMs.config.json +++ b/.config/BetterDiscord/plugins/PinDMs.config.json @@ -10,7 +10,7 @@ "channelList": { "1741875717362926": { "id": "1741875717362926", - "name": "Pinned Direct Messages #1", + "name": "", "dms": [ "815678838809296926", "740325591684874305", diff --git a/.config/BetterDiscord/plugins/PinDMs.plugin.js b/.config/BetterDiscord/plugins/PinDMs.plugin.js index 1dd8cd9..e7acd00 100644 --- a/.config/BetterDiscord/plugins/PinDMs.plugin.js +++ b/.config/BetterDiscord/plugins/PinDMs.plugin.js @@ -2,7 +2,7 @@ * @name PinDMs * @author DevilBro * @authorId 278543574059057154 - * @version 1.9.7 + * @version 2.0.3 * @description Allows you to pin DMs, making them appear at the top of your DMs/ServerList * @invite Jx3TjNS * @donate https://www.paypal.me/MircoWittrien @@ -59,6 +59,8 @@ module.exports = (_ => { var hoveredCategory, draggedCategory, releasedCategory; var hoveredChannel, draggedChannel, releasedChannel; + var channelListIsRenderendering; + return class PinDMs extends Plugin { onLoad () { this.defaults = { @@ -89,8 +91,7 @@ module.exports = (_ => { "PrivateChannelsList" ], componentDidMount: [ - "DirectMessage", - "PrivateChannel" + "DirectMessage" ], componentWillUnmount: [ "DirectMessage" @@ -259,7 +260,7 @@ module.exports = (_ => { onUserContextMenu (e) { if (e.instance.props.channel && !e.instance.props.channel.guild_id) { let [children, index] = BDFDB.ContextMenuUtils.findItem(e.returnvalue, {id: "close-dm"}); - children.splice(index > -1 ? index : children.length, 0, this.createItem(e.instance.props.channel.id)); + children.splice(index > -1 ? index : children.length, 0, this.createItem(e.instance, e.instance.props.channel.id)); } } @@ -267,12 +268,12 @@ module.exports = (_ => { if (e.instance.props.channel) { let [children, index] = BDFDB.ContextMenuUtils.findItem(e.returnvalue, {id: "change-icon", group: true}); children.splice(index > -1 ? index + 1 : children.length, 0, BDFDB.ContextMenuUtils.createItem(BDFDB.LibraryComponents.MenuItems.MenuGroup, { - children: this.createItem(e.instance.props.channel.id) + children: this.createItem(e.instance, e.instance.props.channel.id) })); } } - createItem (id) { + createItem (instance, id) { if (!id) return; let pinnedInGuild = this.isPinnedInGuilds(id); @@ -312,6 +313,7 @@ module.exports = (_ => { label: category.name || this.labels.header_pinneddms, id: BDFDB.ContextMenuUtils.createItemId(this.name, "pin-channellist", category.id), action: _ => { + BDFDB.ContextMenuUtils.close(instance); if (currentCategory) this.removeFromCategory(id, currentCategory, "channelList"); this.addToCategory(id, category, "channelList"); } @@ -324,6 +326,7 @@ module.exports = (_ => { id: BDFDB.ContextMenuUtils.createItemId(this.name, pinnedInGuild ? "unpin-serverlist" : "pin-serverlist"), color: pinnedInGuild ? BDFDB.DiscordConstants.MenuItemColors.DANGER : BDFDB.DiscordConstants.MenuItemColors.DEFAULT, action: _ => { + BDFDB.ContextMenuUtils.close(instance); if (!pinnedInGuild) this.addPin(id, "guildList"); else this.removePin(id, "guildList"); } @@ -381,7 +384,7 @@ module.exports = (_ => { }, after: e2 => { if (e2.methodArguments[0] != 0) { let id = e.instance.props.privateChannelIds[e2.methodArguments[1]]; - e2.returnValue = e.instance.props.channels[id] ? BDFDB.ReactUtils.createElement(BDFDB.LibraryComponents.PrivateChannelItems[e.instance.props.channels[id].isMultiUserDM() ? "GroupDM" : "DirectMessage"], Object.assign({ + e2.returnValue = e.instance.props.channels[id] ? BDFDB.ReactUtils.createElement(BDFDB.LibraryComponents.PrivateChannelItems.DirectMessage, Object.assign({ key: id, channel: e.instance.props.channels[id], selected: e.instance.props.selectedChannelId == id @@ -522,7 +525,7 @@ module.exports = (_ => { if (!this.settings.preCategories[category.id]) return; this.settings.preCategories[category.id].enabled = false; BDFDB.DataUtils.save(this.settings.preCategories, this, "preCategories"); - this.updateContainer("channelList"); + this.updateContainer("channelList", true); } }) : [ BDFDB.ContextMenuUtils.createItem(BDFDB.LibraryComponents.MenuItems.MenuItem, { @@ -538,7 +541,7 @@ module.exports = (_ => { let newData = this.getPinnedChannels("channelList"); delete newData[category.id]; this.savePinnedChannels(newData, "channelList"); - this.updateContainer("channelList"); + this.updateContainer("channelList", true); } }) ] @@ -606,65 +609,6 @@ module.exports = (_ => { if (!e.instance.props.channel || this.getPredefinedCategory(e.instance.props.channel.id)) return; let category = this.getChannelListCategory(e.instance.props.channel.id); if (!category) return; - if (e.node) { - BDFDB.DOMUtils.addClass(e.node, BDFDB.disCN._pindmsdmchannelpinned); - e.node.removeEventListener("mousedown", e.node.PinDMsMouseDownListener); - if (this.settings.recentOrder.channelList) return; - e.node.setAttribute("draggable", false); - e.node.PinDMsMouseDownListener = event => { - if (!this.started) e.node.removeEventListener("mousedown", e.node.PinDMsMouseDownListener); - else { - event = event.nativeEvent || event; - let mouseMove = event2 => { - if (Math.sqrt((event.pageX - event2.pageX)**2) > 20 || Math.sqrt((event.pageY - event2.pageY)**2) > 20) { - BDFDB.ListenerUtils.stopEvent(event); - draggedChannel = e.instance.props.channel.id; - this.updateContainer("channelList"); - let dragPreview = this.createDragPreview(e.node, event2); - document.removeEventListener("mousemove", mouseMove); - document.removeEventListener("mouseup", mouseUp); - let dragging = event3 => { - this.updateDragPreview(dragPreview, event3); - let maybeHoveredChannel = null; - let categoryNode = BDFDB.DOMUtils.getParent(BDFDB.dotCN._pindmspinnedchannelsheadercontainer, event3.target); - if (categoryNode) { - let hoveredCategoryId = categoryNode.getAttribute("categoryid"); - if (hoveredCategoryId && hoveredCategoryId == category.id) maybeHoveredChannel = "header_" + category.id; - } - else { - let placeholder = BDFDB.DOMUtils.getParent(BDFDB.dotCN._pindmsdmchannelplaceholder, event3.target); - maybeHoveredChannel = (BDFDB.ReactUtils.findValue(BDFDB.DOMUtils.getParent(BDFDB.dotCN._pindmsdmchannelpinned, placeholder ? placeholder.previousSibling : event3.target), "channel", {up: true}) || {}).id; - let maybeHoveredCategory = maybeHoveredChannel && this.getChannelListCategory(maybeHoveredChannel); - if (!maybeHoveredCategory || maybeHoveredCategory.id != category.id) maybeHoveredChannel = null; - }; - let update = maybeHoveredChannel != hoveredChannel; - if (maybeHoveredChannel) hoveredChannel = maybeHoveredChannel; - else hoveredChannel = null; - if (update) this.updateContainer("channelList"); - }; - let releasing = event3 => { - BDFDB.DOMUtils.remove(dragPreview); - if (hoveredChannel) releasedChannel = hoveredChannel; - else draggedChannel = null; - hoveredChannel = null; - this.updateContainer("channelList"); - document.removeEventListener("mousemove", dragging); - document.removeEventListener("mouseup", releasing); - }; - document.addEventListener("mousemove", dragging); - document.addEventListener("mouseup", releasing); - } - }; - let mouseUp = _ => { - document.removeEventListener("mousemove", mouseMove); - document.removeEventListener("mouseup", mouseUp); - }; - document.addEventListener("mousemove", mouseMove); - document.addEventListener("mouseup", mouseUp); - } - }; - e.node.addEventListener("mousedown", e.node.PinDMsMouseDownListener); - } if (e.returnvalue) { let process = returnvalue => { let [children, index] = BDFDB.ReactUtils.findParent(returnvalue, {name: "CloseButton"}); @@ -717,7 +661,6 @@ module.exports = (_ => { icon: BDFDB.LibraryComponents.SvgIcon.Names.NOVA_PIN }); } - if (this.getChannelListCategory(e.instance.props.channel.id)) this.updateContainer("channelList"); } } } @@ -751,7 +694,7 @@ module.exports = (_ => { if (!category.dms.includes(id)) category.dms.unshift(id); this.savePinnedChannels(Object.assign({}, this.getPinnedChannels(type), {[category.id]: category}), type); if (wasEmpty && category.dms.length) category.collapsed = false; - this.updateContainer(type); + this.updateContainer(type, true); } removeFromCategory (id, category, type) { @@ -759,7 +702,7 @@ module.exports = (_ => { BDFDB.ArrayUtils.remove(category.dms, id, true); if (!this.filterDMs(category.dms).length) category.collapsed = true; this.savePinnedChannels(Object.assign({}, this.getPinnedChannels(type), {[category.id]: category}), type); - this.updateContainer(type); + this.updateContainer(type, true); } getChannelListCategory (id) { @@ -819,7 +762,7 @@ module.exports = (_ => { if (dms.length > 1 && this.settings.recentOrder[type]) { let timestamps = BDFDB.LibraryStores.PrivateChannelSortStore.getPrivateChannelIds().reduce((newObj, channelId) => (newObj[channelId] = BDFDB.LibraryStores.ReadStateStore.lastMessageId(channelId), newObj), {}); return [].concat(dms).sort(function (x, y) { - const xT = parseFloat(timestamps[x]), yT = parseFloat(timestamps[y]); + const xT = !timestamps[x] ? 0 : parseFloat(timestamps[x]), yT = !timestamps[y] ? 0 : parseFloat(timestamps[y]); return xT > yT ? -1 : xT < yT ? 1 : 0; }); } @@ -900,11 +843,15 @@ module.exports = (_ => { return this.getPinnedChannels("guildList")[id] != undefined; } - updateContainer (type) { + updateContainer (type, force) { switch (type) { case "channelList": - BDFDB.PatchUtils.forceAllUpdates(this, "PrivateChannelsList"); /* DOES NOT WORK */ - if (!Object.keys(this.settings.preCategories).every(type => this.settings.preCategories[type].enabled) && BDFDB.ObjectUtils.isEmpty(this.getPinnedChannels(type))) this.forceUpdateAll(); + if (force) { + if (!channelListIsRenderendering) BDFDB.DiscordUtils.rerenderAll(true); + channelListIsRenderendering = true; + BDFDB.TimeUtils.timeout(_ => channelListIsRenderendering = false, 3000); + } + else BDFDB.PatchUtils.forceAllUpdates(this, "PrivateChannelsList"); break; case "guildList": BDFDB.DiscordUtils.rerenderAll(true); @@ -1007,10 +954,10 @@ module.exports = (_ => { context_addtonewcategory: "Προσθήκη σε νέα κατηγορία", context_disablepredefined: "Απενεργοποίηση προκαθορισμένης κατηγορίας", context_pinchannel: "Καρφίτσωμα στη λίστα καναλιών", - context_pindm: "Καρφιτσώστε το άμεσο μήνυμα", + context_pindm: "Καρφίτσωμα του άμεσου μηνύματος", context_pinguild: "Καρφίτσωμα στη λίστα διακομιστών", - context_unpinchannel: "Αποσύνδεση από τη λίστα καναλιών", - context_unpinguild: "Αποσύνδεση από τη λίστα διακομιστών", + context_unpinchannel: "Ξεκαρφίτσωμα από τη λίστα καναλιών", + context_unpinguild: "Ξεκαρφίτσωμα από τη λίστα διακομιστών", header_pinneddms: "Καρφιτσωμένα άμεσα μηνύματα", modal_colorpicker1: "Χρώμα κατηγορίας" }; diff --git a/.config/BetterDiscord/plugins/PluginRepo.config.json b/.config/BetterDiscord/plugins/PluginRepo.config.json index 063f3d7..a454e7d 100755 --- a/.config/BetterDiscord/plugins/PluginRepo.config.json +++ b/.config/BetterDiscord/plugins/PluginRepo.config.json @@ -1,6 +1,6 @@ { "all": { - "cached": "2 7 8 9 11 14 15 17 28 29 30 59 60 61 62 63 64 65 66 67 68 70 71 73 74 75 76 77 80 81 82 83 85 86 87 88 89 91 92 93 94 95 96 97 98 99 100 101 102 104 105 106 108 109 110 111 116 120 122 126 127 131 132 133 134 137 138 139 146 157 158 159 160 162 164 171 173 176 179 181 182 183 184 185 186 188 189 190 193 195 196 197 200 201 220 228 234 237 238 240 245 247 253 262 272 274 278 284 287 291 292 293 295 301 306 312 314 317 318 323 331 336 337 338 340 344 349 350 351 352 353 354 356 364 366 368 377 379 381 382 383 390 395 401 404 420 421 429 438 442 476 479 489 509 518 520 523 525 535 538 539 547 554 566 577 579 589 592 593 598 599 606 608 611 614 620 621 627 638 644 645 669 670 671 679 686 692 693 694 699 708 760 762 772 798 802 805 806 807 819 827 843 856 859 867", + "cached": "2 7 8 9 11 14 15 17 28 29 30 59 60 61 62 63 64 65 66 67 70 71 73 74 75 76 77 80 81 82 83 85 86 87 88 89 91 92 93 94 95 96 97 98 99 100 101 102 104 105 106 108 109 110 111 120 126 127 131 132 134 137 138 139 146 157 158 159 160 162 171 173 176 179 181 182 183 184 185 186 188 189 190 193 195 196 197 200 201 228 237 238 240 245 262 274 278 287 291 292 293 295 306 312 314 317 318 323 331 344 350 351 352 353 354 356 366 368 377 379 381 382 383 390 395 401 404 420 421 429 438 442 476 479 489 509 518 520 523 525 535 539 547 554 577 579 589 592 593 598 599 606 608 611 614 620 621 627 638 644 645 670 671 679 686 692 693 694 699 708 760 762 772 798 802 805 806 807 819 827 843 845 850 856 859 867 878 881 882 883 930 936 938 953 954 970 971 979 989 990 996 1000 1005 1010 1016 1023", "filters": { "updated": true, "outdated": true, diff --git a/.config/BetterDiscord/plugins/PluginRepo.plugin.js b/.config/BetterDiscord/plugins/PluginRepo.plugin.js index d72000d..e843b57 100644 --- a/.config/BetterDiscord/plugins/PluginRepo.plugin.js +++ b/.config/BetterDiscord/plugins/PluginRepo.plugin.js @@ -2,7 +2,7 @@ * @name PluginRepo * @author DevilBro * @authorId 278543574059057154 - * @version 2.4.6 + * @version 2.5.5 * @description Allows you to download all Plugins from BD's Website within Discord * @invite Jx3TjNS * @donate https://www.paypal.me/MircoWittrien @@ -25,9 +25,14 @@ module.exports = (_ => { getDescription () {return `The Library Plugin needed for ${this.name} is missing. Open the Plugin Settings to download it. \n\n${this.description}`;} downloadLibrary () { - require("request").get("https://mwittrien.github.io/BetterDiscordAddons/Library/0BDFDB.plugin.js", (e, r, b) => { - if (!e && b && r.statusCode == 200) require("fs").writeFile(require("path").join(BdApi.Plugins.folder, "0BDFDB.plugin.js"), b, _ => BdApi.showToast("Finished downloading BDFDB Library", {type: "success"})); - else BdApi.alert("Error", "Could not download BDFDB Library Plugin. Try again later or download it manually from GitHub: https://mwittrien.github.io/downloader/?library"); + BdApi.Net.fetch("https://mwittrien.github.io/BetterDiscordAddons/Library/0BDFDB.plugin.js").then(r => { + if (!r || r.status != 200) throw new Error(); + else return r.text(); + }).then(b => { + if (!b) throw new Error(); + else return require("fs").writeFile(require("path").join(BdApi.Plugins.folder, "0BDFDB.plugin.js"), b, _ => BdApi.showToast("Finished downloading BDFDB Library", {type: "success"})); + }).catch(error => { + BdApi.alert("Error", "Could not download BDFDB Library Plugin. Try again later or download it manually from GitHub: https://mwittrien.github.io/downloader/?library"); }); } @@ -60,7 +65,7 @@ module.exports = (_ => { var list; - var loading, cachedPlugins, grabbedPlugins, updateInterval; + var loading, cachedPlugins, grabbedPlugins, updateInterval, errorState; var searchString, searchTimeout, forcedSort, forcedOrder, showOnlyOutdated; var favorites = []; @@ -94,8 +99,8 @@ module.exports = (_ => { NAME: "Name", AUTHORNAME: "Author", VERSION: "Version", - DESCRIPTION: "Description", - RELEASEDATE: "Release Date", + DESCRIPTION: "Description", + RELEASEDATE: "Release Date", STATE: "Update State", DOWNLOADS: "Downloads", LIKES: "Likes", @@ -124,7 +129,7 @@ module.exports = (_ => { let plugins = grabbedPlugins.map(plugin => { if (plugin.failed) return; const installedPlugin = _this.getInstalledPlugin(plugin); - const state = installedPlugin ? (plugin.version && _this.compareVersions(plugin.version, _this.getString(installedPlugin.version)) ? pluginStates.OUTDATED : pluginStates.INSTALLED) : pluginStates.DOWNLOADABLE; + const state = installedPlugin ? (plugin.version && _this.compareVersions(plugin.version, _this.getString(installedPlugin.plugin && installedPlugin.plugin.version || installedPlugin.version)) ? pluginStates.OUTDATED : pluginStates.INSTALLED) : pluginStates.DOWNLOADABLE; return Object.assign(plugin, { search: [plugin.name, plugin.version, plugin.authorname, plugin.description, plugin.tags].flat(10).filter(n => typeof n == "string").join(" ").toUpperCase(), description: plugin.description || "No Description found", @@ -133,10 +138,10 @@ module.exports = (_ => { state: state }); }).filter(n => n); - if (!this.props.updated) plugins = plugins.filter(plugin => plugin.state != pluginStates.INSTALLED); - if (!this.props.outdated) plugins = plugins.filter(plugin => plugin.state != pluginStates.OUTDATED); - if (!this.props.downloadable) plugins = plugins.filter(plugin => plugin.state != pluginStates.DOWNLOADABLE); - if (searchString) { + if (!this.props.updated) plugins = plugins.filter(plugin => plugin.state != pluginStates.INSTALLED); + if (!this.props.outdated) plugins = plugins.filter(plugin => plugin.state != pluginStates.OUTDATED); + if (!this.props.downloadable) plugins = plugins.filter(plugin => plugin.state != pluginStates.DOWNLOADABLE); + if (searchString) { let usedSearchString = searchString.toUpperCase(); let spacelessUsedSearchString = usedSearchString.replace(/\s/g, ""); plugins = plugins.filter(plugin => plugin.search.indexOf(usedSearchString) > -1 || plugin.search.indexOf(spacelessUsedSearchString) > -1); @@ -151,6 +156,16 @@ module.exports = (_ => { if (!this.props.tab) this.props.tab = "Plugins"; const entries = (!loading.is && grabbedPlugins.length ? this.filterPlugins() : []); + const emptyState = errorState ? { + lightSrc: "/assets/d6dfb89ab06b62044dbb.svg", + darkSrc: "/assets/8eeb59bba0a61cbffc41.svg", + text: "Could not load Plugin Store due to an Issue with the BD Website" + } : !entries.length && !this.props.updated && !this.props.outdated && !this.props.downloadable ? { + text: `You disabled all Filter Options in the "${BDFDB.LanguageUtils.LanguageStrings.SETTINGS}" Tab` + } : !entries.length && searchString ? { + lightSrc: "/assets/75081bdaad2d359c1469.svg", + darkSrc: "/assets/45cd76fed34c8e398cc8.svg" + } : !entries.length ? {} : null; return BDFDB.ReactUtils.createElement("div", { className: BDFDB.disCN._repo, @@ -196,7 +211,7 @@ module.exports = (_ => { onClick: _ => { if (loading.is) return; loading = {is: false, timeout: null, amount: 0}; - _this.loadPlugins(); + _this.loadPlugins(true); } }) ] @@ -277,7 +292,7 @@ module.exports = (_ => { children: `${BDFDB.LanguageUtils.LibraryStringsFormat("loading", "Plugin Repo")} - ${BDFDB.LanguageUtils.LibraryStrings.please_wait}` }) ] - }) : BDFDB.ReactUtils.createElement("div", { + }) : emptyState ? BDFDB.ReactUtils.createElement(BDFDB.LibraryComponents.EmptyStateImage, emptyState) : BDFDB.ReactUtils.createElement("div", { className: BDFDB.disCN.discoverycards, children: entries.map(plugin => BDFDB.ReactUtils.createElement(RepoCardComponent, { data: plugin @@ -290,7 +305,7 @@ module.exports = (_ => { render: false, children: [ BDFDB.ReactUtils.createElement(BDFDB.LibraryComponents.SettingsPanelList, { - title: "Show following Plugins", + title: "Shows following Plugins", children: Object.keys(_this.defaults.filters).map(key => BDFDB.ReactUtils.createElement(BDFDB.LibraryComponents.SettingsSaveItem, { type: "Switch", plugin: _this, @@ -484,13 +499,13 @@ module.exports = (_ => { this.props.downloading = true; let loadingToast = BDFDB.NotificationUtils.toast(`${BDFDB.LanguageUtils.LibraryStringsFormat("loading", this.props.data.name)} - ${BDFDB.LanguageUtils.LibraryStrings.please_wait}`, {timeout: 0, ellipsis: true}); let autoloadKey = this.props.data.state == pluginStates.OUTDATED ? "startUpdated" : "startDownloaded"; - BDFDB.DiscordUtils.requestFileData(this.props.data.rawSourceUrl, {timeout: 10000}, (error, buffer) => { - if (error || !buffer) { + BDFDB.LibraryRequires.request(this.props.data.rawSourceUrl, (error, response, body) => { + if (error || !body) { delete this.props.downloading; loadingToast.close(); BDFDB.NotificationUtils.toast(BDFDB.LanguageUtils.LibraryStringsFormat("download_fail", `Plugin "${this.props.data.name}"`), {type: "danger"}); } - else BDFDB.LibraryRequires.fs.writeFile(BDFDB.LibraryRequires.path.join(BDFDB.BDUtils.getPluginsFolder(), this.props.data.rawSourceUrl.split("/").pop()), Buffer.from(buffer).toString(), error2 => { + else BDFDB.LibraryRequires.fs.writeFile(BDFDB.LibraryRequires.path.join(BDFDB.BDUtils.getPluginsFolder(), this.props.data.rawSourceUrl.split("/").pop()), body, error2 => { delete this.props.downloading; loadingToast.close(); if (error2) BDFDB.NotificationUtils.toast(BDFDB.LanguageUtils.LibraryStringsFormat("save_fail", `Plugin "${this.props.data.name}"`), {type: "danger"}); @@ -584,8 +599,8 @@ module.exports = (_ => { startUpdated: {value: false, autoload: true, description: "Starts updated Plugins after Download"} }, filters: { - updated: {value: true, description: "Updated"}, - outdated: {value: true, description: "Outdated"}, + updated: {value: true, description: "Updated"}, + outdated: {value: true, description: "Outdated"}, downloadable: {value: true, description: "Downloadable"}, } }; @@ -636,13 +651,15 @@ module.exports = (_ => { onUserSettingsCogContextMenu (e) { BDFDB.TimeUtils.timeout(_ => { let [children, index] = BDFDB.ReactUtils.findParent(e.returnvalue, {props: [["label", ["BandagedBD", "BetterDiscord"]]]}); - if (index > -1 && BDFDB.ArrayUtils.is(children[index].props.children)) children[index].props.children.push(BDFDB.ContextMenuUtils.createItem(BDFDB.LibraryComponents.MenuItems.MenuItem, { - label: "Plugin Repo", - id: BDFDB.ContextMenuUtils.createItemId(this.name, "repo"), - action: _ => { - BDFDB.LibraryModules.UserSettingsUtils.open("pluginrepo"); - } - })); + if (index > -1 && BDFDB.ArrayUtils.is(children[index].props.children)) { + let item = BDFDB.ContextMenuUtils.createItem(BDFDB.LibraryComponents.MenuItems.MenuItem, { + label: "Plugin Repo", + id: BDFDB.ContextMenuUtils.createItemId(this.name, "repo"), + action: _ => BDFDB.LibraryModules.UserSettingsUtils.open("pluginrepo") + }); + if (children[index].props.children.find(n => n && n.props && n.props.id == "themerepo-repo")) children[index].props.children.splice(children[index].props.children.length-1, 0, item); + else children[index].props.children.push(item); + } }); } @@ -680,7 +697,7 @@ module.exports = (_ => { if (e.instance.props && e.instance.props.section == "pluginrepo") e.instance.props.contentType = "custom"; } - loadPlugins () { + loadPlugins (forceBanner) { BDFDB.DOMUtils.remove(BDFDB.dotCN._pluginrepoloadingicon); cachedPlugins = BDFDB.DataUtils.load(this, "cached"); cachedPlugins = (typeof cachedPlugins == "string" ? cachedPlugins.split(" ") : []).map(n => parseInt(n)).filter(n => !isNaN(n)); @@ -701,7 +718,7 @@ module.exports = (_ => { BDFDB.LogUtils.log("Finished fetching Plugins", this); BDFDB.ReactUtils.forceUpdate(list); - if (this.settings.general.notifyOutdated && outdatedEntries > 0) { + if ((this.settings.general.notifyOutdated || forceBanner) && outdatedEntries > 0) { let notice = document.querySelector(BDFDB.dotCN._pluginrepooutdatednotice); if (notice) notice.close(); BDFDB.NotificationUtils.notice(this.labels.notice_outdated_plugins.replace("{{var0}}", outdatedEntries), { @@ -754,20 +771,17 @@ module.exports = (_ => { delete plugin.release_date; delete plugin.latest_source_url; delete plugin.thumbnail_url; - BDFDB.DiscordUtils.requestFileData(plugin.rawSourceUrl, {timeout: 10000}, (error, buffer) => { - if (error || !buffer) plugin.failed = true; + BDFDB.LibraryRequires.request(plugin.rawSourceUrl, (error, response, body) => { + if (error || !body || body.indexOf("404: Not Found") == 0) plugin.failed = true; else { - let body = Buffer.from(buffer).toString(); - if (body && body.indexOf("404: Not Found") != 0) { - const META = body.split("*/")[0]; - plugin.name = BDFDB.StringUtils.upperCaseFirstChar((/@name\s+([^\t^\r^\n]+)|\/\/\**META.*["']name["']\s*:\s*["'](.+?)["']/i.exec(META) || []).filter(n => n)[1] || plugin.name || ""); - plugin.authorname = (/@author\s+(.+)|\/\/\**META.*["']author["']\s*:\s*["'](.+?)["']/i.exec(META) || []).filter(n => n)[1] || plugin.author.display_name || plugin.author; - const version = (/@version\s+(.+)|\/\/\**META.*["']version["']\s*:\s*["'](.+?)["']/i.exec(META) || []).filter(n => n)[1]; - if (version) { - plugin.version = version; - const installedPlugin = this.getInstalledPlugin(plugin); - if (installedPlugin && this.compareVersions(version, this.getString(installedPlugin.version))) outdatedEntries++; - } + const META = body.split("*/")[0]; + plugin.name = BDFDB.StringUtils.upperCaseFirstChar((/@name\s+([^\t^\r^\n]+)|\/\/\**META.*["']name["']\s*:\s*["'](.+?)["']/i.exec(META) || []).filter(n => n)[1] || plugin.name || ""); + plugin.authorname = (/@author\s+(.+)|\/\/\**META.*["']author["']\s*:\s*["'](.+?)["']/i.exec(META) || []).filter(n => n)[1] || plugin.author.display_name || plugin.author; + const version = (/@version\s+(.+)|\/\/\**META.*["']version["']\s*:\s*["'](.+?)["']/i.exec(META) || []).filter(n => n)[1]; + if (version) { + plugin.version = version; + const installedPlugin = this.getInstalledPlugin(plugin); + if (installedPlugin && this.compareVersions(version, this.getString(installedPlugin.plugin && installedPlugin.plugin.version || installedPlugin.version))) outdatedEntries++; } if (!cachedPlugins.includes(plugin.id)) newEntries++; } @@ -783,7 +797,7 @@ module.exports = (_ => { } }; - BDFDB.LibraryRequires.request("https://api.betterdiscord.app/v1/store/plugins", (error, response, body) => { + BDFDB.TimeUtils.timeout(_ => BDFDB.LibraryRequires.request("https://api.betterdiscord.app/v1/store/plugins", {bdVersion: true}, (error, response, body) => { if (!error && body && response.statusCode == 200) try { grabbedPlugins = BDFDB.ArrayUtils.keySort(JSON.parse(body).filter(n => n), "name"); BDFDB.DataUtils.save(BDFDB.ArrayUtils.numSort(grabbedPlugins.map(n => n.id)).join(" "), this, "cached"); @@ -813,9 +827,16 @@ module.exports = (_ => { for (let i = 0; i <= 20; i++) checkPlugin(); } catch (err) {BDFDB.NotificationUtils.toast("Failed to load Plugin Store", {type: "danger"});} - if (response && response.statusCode == 403) BDFDB.NotificationUtils.toast("Failed to fetch Plugin Store from the Website Api due to DDoS Protection", {type: "danger"}); - else if (response && response.statusCode == 404) BDFDB.NotificationUtils.toast("Failed to fetch Plugin Store from the Website Api due to Connection Issue", {type: "danger"}); - }); + let status = {}; + if (response && response.statusCode == 403) status = {code: response.statusCode, reason: " due to DDoS Protection"}; + else if (response && response.statusCode == 404) status = {code: response.statusCode, reason: " due to DDoS Protection"}; + else if (response && response.statusCode == 502) status = {code: response.statusCode, reason: ", because the API is down"}; + if (status.code) { + BDFDB.NotificationUtils.toast("Failed to fetch Plugin Store from the Website API" + status.reason, {type: "danger"}); + errorState = status.code; + } + else errorState = null; + }), 10000); } getLoadingTooltipText () { @@ -839,15 +860,15 @@ module.exports = (_ => { getInstalledPlugin (plugin) { if (!plugin || typeof plugin.authorname != "string") return; const iPlugin = BDFDB.BDUtils.getPlugin(plugin.name, false, true); - if (iPlugin && plugin.authorname.toUpperCase() == this.getString(iPlugin.author).toUpperCase()) return iPlugin; + if (iPlugin && (plugin.authorname.toUpperCase().indexOf(this.getString(iPlugin.author).toUpperCase()) > -1 || this.getString(iPlugin.author).toUpperCase().indexOf(plugin.authorname.toUpperCase()) > -1)) return iPlugin; else if (plugin.rawSourceUrl && window.BdApi && BdApi.Plugins && typeof BdApi.Plugins.getAll == "function") { const filename = plugin.rawSourceUrl.split("/").pop(); - for (let p of BdApi.Plugins.getAll()) if (p.filename == filename && plugin.authorname.toUpperCase() == this.getString(p.author).toUpperCase()) return p; + for (let p of BdApi.Plugins.getAll()) if (p.filename == filename && (plugin.authorname.toUpperCase().indexOf(this.getString(p.author).toUpperCase()) > -1 || this.getString(p.author).toUpperCase().indexOf(plugin.authorname.toUpperCase()) > -1)) return p; } } checkForNewPlugins () { - BDFDB.LibraryRequires.request("https://api.betterdiscord.app/v1/store/plugins", (error, response, body) => { + BDFDB.LibraryRequires.request("https://api.betterdiscord.app/v1/store/plugins", {bdVersion: true}, (error, response, body) => { if (!error && body) try { if (JSON.parse(body).filter(n => n).length != grabbedPlugins.length) { loading = {is: false, timeout: null, amount: 0}; @@ -884,9 +905,9 @@ module.exports = (_ => { case "el": // Greek return { list: "Λίστα", - notice_failed_plugins: "Δεν ήταν δυνατή η φόρτωση ορισμένων Plugins [{{var0}}] ", - notice_new_plugins: "Προστέθηκαν νέα Plugins [{{var0}}] στο Plugin Repo", - notice_outdated_plugins: "Ορισμένα Plugins [{{var0}}] είναι παλιά" + notice_failed_plugins: "Δεν ήταν δυνατή η φόρτωση ορισμένων Πρόσθετων [{{var0}}] ", + notice_new_plugins: "Προστέθηκαν νέα Πρόσθετα [{{var0}}] στο Αποθετήριο Προσθέτων", + notice_outdated_plugins: "Ορισμένα Πρόσθετα [{{var0}}] είναι παλαιά" }; case "es": // Spanish return { diff --git a/.config/BetterDiscord/themes/PinkNord.theme.css b/.config/BetterDiscord/themes/PinkNord.theme.css index de55951..096a8a4 100644 --- a/.config/BetterDiscord/themes/PinkNord.theme.css +++ b/.config/BetterDiscord/themes/PinkNord.theme.css @@ -7,7 +7,7 @@ * @Source https://github.com/ClearVision/ClearVision-v6 * @website https://betterdiscord.app/theme/ClearVision */ -@import url("https://clearvision.gitlab.io/v6/main.css"); +@import url("https://clearvision.github.io/ClearVision-v6/main.css"); @import url('https://fonts.googleapis.com/css2?family=Consolas'); @import url('https://fonts.googleapis.com/css2?family=Whitney'); :root { diff --git a/.config/i3/config b/.config/i3/config index 9207704..eaec251 100644 --- a/.config/i3/config +++ b/.config/i3/config @@ -87,7 +87,7 @@ bindsym $mod+Return exec --no-startup-id alacritty bindsym $mod+Shift+q kill # start dmenu (a program launcher) -bindsym $mod+d exec --no-startup-id rofi -display-run ">" -show run +bindsym $mod+d exec --no-startup-id rofi -display-drun ">" -modi drun -show drun # A more modern dmenu replacement is rofi: # bindcode $mod+40 exec "rofi -modi drun,run -show drun" diff --git a/.config/oomox/export_config/gtk_theme_oomox.json b/.config/oomox/export_config/gtk_theme_oomox.json index d35ee07..cbffb35 100644 --- a/.config/oomox/export_config/gtk_theme_oomox.json +++ b/.config/oomox/export_config/gtk_theme_oomox.json @@ -1 +1 @@ -{"gtk2_hidpi": true, "OPTION_GTK3_CURRENT_VERSION_ONLY": false, "OPTION_EXPORT_CINNAMON_THEME": false, "default_path": "/home/poslop/.themes"} \ No newline at end of file +{"gtk2_hidpi": true, "self.OPTIONS.GTK3_CURRENT_VERSION_ONLY": true, "self.OPTIONS.EXPORT_CINNAMON_THEME": false, "default_path": "/home/poslop/.themes", "OPTION_GTK3_CURRENT_VERSION_ONLY": false, "OPTION_EXPORT_CINNAMON_THEME": false} \ No newline at end of file diff --git a/.config/oomox/ui_config.json b/.config/oomox/ui_config.json index 2d06789..e7c02d6 100644 --- a/.config/oomox/ui_config.json +++ b/.config/oomox/ui_config.json @@ -1 +1 @@ -{"window_width": 1892, "window_height": 962, "preset_list_minimal_width": 150, "preset_list_width": 150, "preset_list_sections_expanded": {"presets": true, "plugins": true, "user": true}} \ No newline at end of file +{"window_width": 936, "window_height": 958, "preset_list_minimal_width": 150, "preset_list_width": 150, "preset_list_sections_expanded": {"presets": true, "plugins": true, "user": true}} \ No newline at end of file diff --git a/.config/polybar/config.ini b/.config/polybar/config.ini index 493540a..acb70b1 100644 --- a/.config/polybar/config.ini +++ b/.config/polybar/config.ini @@ -84,7 +84,7 @@ type = internal/battery ; format-low once this charge percentage is reached ; Default: 10 ; New in version 3.6.0 -low-at = 20 +low-at = 25 ; Use the following command to list batteries and adapters: ; $ ls -1 /sys/class/power_supply/ @@ -93,17 +93,24 @@ adapter = ACAD format-charging = format-discharging = +format-low = label-charging = %percentage_raw%% label-discharging = %percentage_raw%% -label-low = %percentage_raw%% +label-low = %percentage%% -format-charging-prefix = "BAT " +format-charging-prefix = "CHRG " format-charging-prefix-foreground = ${colors.primary} format-discharging-prefix = "BAT " format-discharging-prefix-foreground = ${colors.primary} +format-full-prefix = "BAT " +format-full-prefix-foreground = ${colors.primary} + +format-low-prefix = "LOW " +format-low-prefix-foreground = ff8585 + poll-interval = 5 [module/xworkspaces] @@ -209,7 +216,7 @@ format-prefix-foreground = ${colors.primary} [module/backlight] type = internal/backlight ; $ ls -1 /sys/class/backlight/ -card = amdgpu_bl0 +card = amdgpu_bl1 use-actual-brightness = true diff --git a/.config/qt5ct/qt5ct.conf b/.config/qt5ct/qt5ct.conf index 6842207..6e9087b 100644 --- a/.config/qt5ct/qt5ct.conf +++ b/.config/qt5ct/qt5ct.conf @@ -28,7 +28,7 @@ wheel_scroll_lines=3 geometry="@ByteArray(\x1\xd9\xd0\xcb\0\x3\0\0\0\0\x5\0\0\0\x1*\0\0\ax\0\0\x3<\0\0\x5\x1\0\0\x1+\0\0\aw\0\0\x3;\0\0\0\0\0\0\0\0\a\x80\0\0\x5\x1\0\0\x1+\0\0\aw\0\0\x3;)" [SettingsWindow] -geometry="@ByteArray(\x1\xd9\xd0\xcb\0\x3\0\0\0\0\x5\a\0\0\0=\0\0\aq\0\0\x4)\0\0\x5\b\0\0\0>\0\0\ap\0\0\x4(\0\0\0\0\0\0\0\0\a\x80\0\0\x5\b\0\0\0>\0\0\ap\0\0\x4()" +geometry=@ByteArray(\x1\xd9\xd0\xcb\0\x3\0\0\0\0\x3\xc7\0\0\0>\0\0\ap\0\0\x4(\0\0\x3\xc8\0\0\0?\0\0\ao\0\0\x4'\0\0\0\0\0\0\0\0\a\x80\0\0\x3\xc8\0\0\0?\0\0\ao\0\0\x4') [Troubleshooting] force_raster_widgets=1 diff --git a/.config/rofi/config.rasi b/.config/rofi/config.rasi index cf17edd..83fb49a 100644 --- a/.config/rofi/config.rasi +++ b/.config/rofi/config.rasi @@ -18,7 +18,7 @@ configuration { /* drun-match-fields: "name,generic,exec,categories,keywords";*/ /* drun-categories: ;*/ /* drun-show-actions: false;*/ -/* drun-display-format: "{name} [({generic})]";*/ + drun-display-format: "{name}"; /* drun-url-launcher: "xdg-open";*/ /* disable-history: false;*/ /* ignored-prefixes: "";*/ diff --git a/.profile b/.profile index 4630bb2..ea9351b 100644 --- a/.profile +++ b/.profile @@ -6,3 +6,4 @@ export QSYS_ROOTDIR="/home/poslop/.cache/yay/quartus-free/pkg/quartus-free-quart export DISCORD_TOKEN=ODAwNDQ2NDI4NTU1OTAzMDE3.Gp5hQe.lRy1jG5BBFwSjPmRJ36gs1dKciuR4L6xc4lgZg +. "$HOME/.cargo/env" diff --git a/.zshrc b/.zshrc index c06e864..861c031 100644 --- a/.zshrc +++ b/.zshrc @@ -99,18 +99,24 @@ source $ZSH/oh-my-zsh.sh # Example aliases # alias zshconfig="mate ~/.zshrc" # alias ohmyzsh="mate ~/.oh-my-zsh" + export PATH=$PATH:/home/poslop/.spicetify -alias bctl=bluetoothctl alias dots='/usr/bin/git --git-dir=$HOME/.git --work-tree=$HOME' + +alias bctl=bluetoothctl export wf='94:DB:56:1A:FB:7F' export wh='94:DB:56:F7:8A:40' +export sony='AC:BF:71:48:4D:D9' -export QSYS_ROOTDIR="/home/poslop/.cache/yay/quartus-free/pkg/quartus-free-quartus/opt/intelFPGA/21.1/quartus/sopc_builder/bin" export PATH="/home/poslop/.cargo/bin:$PATH" - alias ecan="ssh -p 60052 poslop@goku.ecansol.com" + alias ecan="ssh -p 60052 mindustry@goku.ecansol.com" # Spoons!21 export X86_64_UNKNOWN_LINUX_MUSL_OPENSSL_LIB_DIR="/usr/bin/openssl" export X86_64_UNKNOWN_LINUX_MUSL_OPENSSL_INCLUDE_DIR="/usr/include/openssl/" +alias rm='rmtrash' +alias rmdir='rmdirtrash' +alias sudo='sudo ' +