From 971e1863358ed4b9ac458cc582e9c1c15a9d57ed Mon Sep 17 00:00:00 2001 From: Tomsoz Date: Tue, 4 Feb 2025 19:29:35 +0000 Subject: [PATCH 01/13] CopyEmojiMarkdown: Fix copying animated emojis (#3179) --- src/plugins/copyEmojiMarkdown/index.tsx | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/src/plugins/copyEmojiMarkdown/index.tsx b/src/plugins/copyEmojiMarkdown/index.tsx index a9c018a91..58e7303a3 100644 --- a/src/plugins/copyEmojiMarkdown/index.tsx +++ b/src/plugins/copyEmojiMarkdown/index.tsx @@ -33,11 +33,11 @@ function getEmojiMarkdown(target: Target, copyUnicode: boolean): string { : `:${emojiName}:`; } - const extension = target?.firstChild.src.match( - /https:\/\/cdn\.discordapp\.com\/emojis\/\d+\.(\w+)/ - )?.[1]; + const url = new URL(target.firstChild.src); + const hasParam = url.searchParams.get("animated") === "true"; + const isGif = url.pathname.endsWith(".gif"); - return `<${extension === "gif" ? "a" : ""}:${emojiName.replace(/~\d+$/, "")}:${emojiId}>`; + return `<${(hasParam || isGif) ? "a" : ""}:${emojiName.replace(/~\d+$/, "")}:${emojiId}>`; } const settings = definePluginSettings({ @@ -55,7 +55,7 @@ export default definePlugin({ settings, contextMenus: { - "expression-picker"(children, { target }: { target: Target }) { + "expression-picker"(children, { target }: { target: Target; }) { if (target.dataset.type !== "emoji") return; children.push( From 1e426b4253932b54606b6e183982db70ec83661a Mon Sep 17 00:00:00 2001 From: sadan4 <117494111+sadan4@users.noreply.github.com> Date: Wed, 5 Feb 2025 15:53:47 -0500 Subject: [PATCH 02/13] arRPC: Fix find (#3203) --- src/plugins/arRPC.web/index.tsx | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/plugins/arRPC.web/index.tsx b/src/plugins/arRPC.web/index.tsx index 61e048dce..94c507f33 100644 --- a/src/plugins/arRPC.web/index.tsx +++ b/src/plugins/arRPC.web/index.tsx @@ -23,7 +23,7 @@ import definePlugin, { ReporterTestable } from "@utils/types"; import { findByCodeLazy } from "@webpack"; import { ApplicationAssetUtils, FluxDispatcher, Forms, Toasts } from "@webpack/common"; -const fetchApplicationsRPC = findByCodeLazy("APPLICATION_RPC(", "Client ID"); +const fetchApplicationsRPC = findByCodeLazy('"Invalid Origin"', ".application"); async function lookupAsset(applicationId: string, key: string): Promise { return (await ApplicationAssetUtils.fetchAssetIds(applicationId, [key]))[0]; From 848c2299d22478dfb3e6f8c012a7d6edaa13f9aa Mon Sep 17 00:00:00 2001 From: Vendicated Date: Wed, 5 Feb 2025 21:54:43 +0100 Subject: [PATCH 03/13] Bump to v1.11.4 --- package.json | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/package.json b/package.json index 057175f9c..dca52a16f 100644 --- a/package.json +++ b/package.json @@ -1,7 +1,7 @@ { "name": "vencord", "private": "true", - "version": "1.11.3", + "version": "1.11.4", "description": "The cutest Discord client mod", "homepage": "https://github.com/Vendicated/Vencord#readme", "bugs": { From 4a447c74ef0a865a2426deb2dcd2abc7577c2376 Mon Sep 17 00:00:00 2001 From: khcrysalis Date: Thu, 6 Feb 2025 11:37:18 -0800 Subject: [PATCH 04/13] feat: add donor and contributor cards in vencord settings (#3049) Co-authored-by: Cookie <52550063+Covkie@users.noreply.github.com> Co-authored-by: v --- src/components/DonateButton.tsx | 12 ++- src/components/Heart.tsx | 10 +- .../VencordSettings/SpecialCard.tsx | 77 ++++++++++++++++ src/components/VencordSettings/VencordTab.tsx | 90 ++++++++++++------ .../VencordSettings/quickActions.css | 21 +++-- .../VencordSettings/specialCard.css | 92 +++++++++++++++++++ src/components/iconStyles.css | 5 + src/plugins/_core/supportHelper.tsx | 11 +-- src/utils/constants.ts | 10 ++ src/webpack/common/types/components.d.ts | 6 +- 10 files changed, 286 insertions(+), 48 deletions(-) create mode 100644 src/components/VencordSettings/SpecialCard.tsx create mode 100644 src/components/VencordSettings/specialCard.css diff --git a/src/components/DonateButton.tsx b/src/components/DonateButton.tsx index c027fcf27..ee2f3ed38 100644 --- a/src/components/DonateButton.tsx +++ b/src/components/DonateButton.tsx @@ -17,16 +17,22 @@ */ import { Button } from "@webpack/common"; +import { ButtonProps } from "@webpack/types"; import { Heart } from "./Heart"; -export default function DonateButton(props: any) { +export default function DonateButton({ + look = Button.Looks.LINK, + color = Button.Colors.TRANSPARENT, + ...props +}: Partial) { return (