Some Fixes For Merge

This commit is contained in:
thororen 2026-08-23 09:35:06 -04:00
parent 961b9b2cad
commit 9c543bad54
No known key found for this signature in database
3 changed files with 4 additions and 17 deletions

View file

@ -23,6 +23,7 @@ import { normalize as posixNormalize, sep as posixSep } from "path/posix";
import { BigIntLiteral, createSourceFile, Identifier, isArrayLiteralExpression, isCallExpression, isExportAssignment, isIdentifier, isObjectLiteralExpression, isPropertyAccessExpression, isPropertyAssignment, isSatisfiesExpression, isStringLiteral, isVariableStatement, NamedDeclaration, NodeArray, ObjectLiteralExpression, PropertyAssignment, ScriptTarget, StringLiteral, SyntaxKind } from "typescript";
import { getPluginTarget } from "./utils.mjs";
import { PluginTarget, PluginTargets } from "@utils/pluginTargets";
export interface Dev {
name: string;
@ -46,7 +47,7 @@ export interface PluginData {
commands: Command[];
required: boolean;
enabledByDefault: boolean;
target: "discordDesktop" | "vesktop" | "equibop" | "desktop" | "web" | "browser" | "dev";
target?: PluginTarget;
filePath: string;
dirName: string;
isModified: boolean;
@ -235,7 +236,7 @@ export async function parseFile(fileName: string) {
const target = getPluginTarget(fileName);
if (target) {
if (!["web", "browser", "discordDesktop", "vesktop", "equibop", "desktop", "dev"].includes(target)) throw fail(`invalid target ${target}`);
if (!PluginTargets.includes(target as PluginTarget)) throw fail(`invalid target ${target}`);
data.target = target as any;
}

View file

@ -45,19 +45,5 @@ export default definePlugin({
replace: "decorators:[Vencord.Api.MemberListDecorators.__getDecorators(arguments[0],'dm'),$1]"
}
},
// fix discords styling for now
{
find: '"AvatarWithText"',
replacement: [
{
match: /(?<=className:.{0,10}),\{.{0,10}\}\)(?=,children:)/,
replace: ')+" vc-member-list-decorators-display-names"'
},
{
match: /(?<=className:\i\.\i)(?=,children:\i\}\))/,
replace: '+" vc-member-list-decorators-display-names"'
}
]
}
]
});

View file

@ -4,5 +4,5 @@
* SPDX-License-Identifier: GPL-3.0-or-later
*/
export const PluginTargets = ["web", "browser", "discordDesktop", "vesktop", "desktop", "dev"] as const;
export const PluginTargets = ["web", "browser", "discordDesktop", "vesktop", "equibop", "desktop", "dev"] as const;
export type PluginTarget = typeof PluginTargets[number];