; text: ReactNode; }) => {
+ if (settings.store.displayStyle === DisplayStyle.Tooltip) return ;
return (
-
-
+
{renderTimeout(message, true)} timeout remaining
diff --git a/src/plugins/showTimeoutDuration/styles.css b/src/plugins/showTimeoutDuration/styles.css
index 70a826e1..a6f830c3 100644
--- a/src/plugins/showTimeoutDuration/styles.css
+++ b/src/plugins/showTimeoutDuration/styles.css
@@ -2,3 +2,7 @@
display: flex;
align-items: center;
}
+
+.vc-std-wrapper [class*="communicationDisabled"] {
+ margin-right: 0;
+}
diff --git a/src/plugins/viewIcons/index.tsx b/src/plugins/viewIcons/index.tsx
index f71777ad..104252f6 100644
--- a/src/plugins/viewIcons/index.tsx
+++ b/src/plugins/viewIcons/index.tsx
@@ -36,6 +36,10 @@ interface GuildContextProps {
guild?: Guild;
}
+interface GroupDMContextProps {
+ channel: Channel;
+}
+
const settings = definePluginSettings({
format: {
type: OptionType.SELECT,
@@ -145,10 +149,27 @@ const GuildContext: NavContextMenuPatchCallback = (children, { guild }: GuildCon
));
};
+const GroupDMContext: NavContextMenuPatchCallback = (children, { channel }: GroupDMContextProps) => {
+ if (!channel) return;
+
+ children.splice(-1, 0, (
+
+
+ openImage(IconUtils.getChannelIconURL(channel)!)
+ }
+ icon={ImageIcon}
+ />
+
+ ));
+};
+
export default definePlugin({
name: "ViewIcons",
- authors: [Devs.Ven, Devs.TheKodeToad, Devs.Nuckyz],
- description: "Makes avatars and banners in user profiles clickable, and adds View Icon/Banner entries in the user and server context menu",
+ authors: [Devs.Ven, Devs.TheKodeToad, Devs.Nuckyz, Devs.nyx],
+ description: "Makes avatars and banners in user profiles clickable, adds View Icon/Banner entries in the user, server and group channel context menu.",
tags: ["ImageUtilities"],
settings,
@@ -157,11 +178,12 @@ export default definePlugin({
contextMenus: {
"user-context": UserContext,
- "guild-context": GuildContext
+ "guild-context": GuildContext,
+ "gdm-context": GroupDMContext
},
patches: [
- // Make pfps clickable
+ // Profiles Modal pfp
{
find: "User Profile Modal - Context Menu",
replacement: {
@@ -169,7 +191,7 @@ export default definePlugin({
replace: "{src:$1,onClick:()=>$self.openImage($1)"
}
},
- // Make banners clickable
+ // Banners
{
find: ".NITRO_BANNER,",
replacement: {
@@ -180,12 +202,38 @@ export default definePlugin({
'onClick:ev=>$1&&ev.target.style.backgroundImage&&$self.openImage($2),style:{cursor:$1?"pointer":void 0,'
}
},
+ // User DMs "User Profile" popup in the right
{
find: ".avatarPositionPanel",
replacement: {
match: /(?<=avatarWrapperNonUserBot.{0,50})onClick:(\i\|\|\i)\?void 0(?<=,avatarSrc:(\i).+?)/,
replace: "style:($1)?{cursor:\"pointer\"}:{},onClick:$1?()=>{$self.openImage($2)}"
}
+ },
+ // Group DMs top small & large icon
+ {
+ find: ".recipients.length>=2",
+ all: true,
+ replacement: {
+ match: /null==\i\.icon\?.+?src:(\(0,\i\.getChannelIconURL\).+?\))(?=[,}])/,
+ replace: (m, iconUrl) => `${m},onClick:()=>$self.openImage(${iconUrl})`
+ }
+ },
+ // User DMs top small icon
+ {
+ find: ".cursorPointer:null,children",
+ replacement: {
+ match: /.Avatar,.+?src:(.+?\))(?=[,}])/,
+ replace: (m, avatarUrl) => `${m},onClick:()=>$self.openImage(${avatarUrl})`
+ }
+ },
+ // User Dms top large icon
+ {
+ find: 'experimentLocation:"empty_messages"',
+ replacement: {
+ match: /.Avatar,.+?src:(.+?\))(?=[,}])/,
+ replace: (m, avatarUrl) => `${m},onClick:()=>$self.openImage(${avatarUrl})`
+ }
}
]
});
diff --git a/src/utils/constants.ts b/src/utils/constants.ts
index 7f82f4d2..7a9fdb28 100644
--- a/src/utils/constants.ts
+++ b/src/utils/constants.ts
@@ -444,6 +444,10 @@ export const Devs = /* #__PURE__*/ Object.freeze({
name: "newwares",
id: 421405303951851520n
},
+ JohnyTheCarrot: {
+ name: "JohnyTheCarrot",
+ id: 132819036282159104n
+ },
puv: {
name: "puv",
id: 469441552251355137n
@@ -492,6 +496,18 @@ export const Devs = /* #__PURE__*/ Object.freeze({
name: "ScattrdBlade",
id: 678007540608532491n
},
+ Moxxie: {
+ name: "Moxxie",
+ id: 712653921692155965n,
+ },
+ Ethan: {
+ name: "Ethan",
+ id: 721717126523781240n,
+ },
+ nyx: {
+ name: "verticalsync",
+ id: 328165170536775680n
+ },
} satisfies Record);
export const EquicordDevs = Object.freeze({
diff --git a/src/webpack/common/types/stores.d.ts b/src/webpack/common/types/stores.d.ts
index 27715b5e..059924f5 100644
--- a/src/webpack/common/types/stores.d.ts
+++ b/src/webpack/common/types/stores.d.ts
@@ -63,7 +63,7 @@ export interface CustomEmoji {
originalName?: string;
require_colons: boolean;
roles: string[];
- url: string;
+ type: "GUILD_EMOJI";
}
export interface UnicodeEmoji {
@@ -75,6 +75,7 @@ export interface UnicodeEmoji {
};
index: number;
surrogates: string;
+ type: "UNICODE";
uniqueName: string;
useSpriteSheet: boolean;
get allNamesString(): string;
diff --git a/src/webpack/webpack.ts b/src/webpack/webpack.ts
index cccfa7c2..a9f3273b 100644
--- a/src/webpack/webpack.ts
+++ b/src/webpack/webpack.ts
@@ -16,7 +16,7 @@
* along with this program. If not, see .
*/
-import { proxyLazy } from "@utils/lazy";
+import { makeLazy, proxyLazy } from "@utils/lazy";
import { LazyComponent } from "@utils/lazyReact";
import { Logger } from "@utils/Logger";
import { canonicalizeMatch } from "@utils/patches";
@@ -462,7 +462,7 @@ export async function extractAndLoadChunks(code: string[], matcher: RegExp = Def
export function extractAndLoadChunksLazy(code: string[], matcher: RegExp = DefaultExtractAndLoadChunksRegex) {
if (IS_DEV) lazyWebpackSearchHistory.push(["extractAndLoadChunks", [code, matcher]]);
- return () => extractAndLoadChunks(code, matcher);
+ return makeLazy(() => extractAndLoadChunks(code, matcher));
}
/**