diff options
author | Justice Almanzar <superdash993@gmail.com> | 2022-12-19 17:59:54 -0500 |
---|---|---|
committer | GitHub <noreply@github.com> | 2022-12-19 22:59:54 +0000 |
commit | 989bd36eeb6dd6c4b391900765847cdcf87484d9 (patch) | |
tree | 86b15ce6804500b56f9f3c6b807d5fbb8aa6dad4 /src/plugins/shikiCodeblocks/index.ts | |
parent | 4974c53f9cc3a3adccfa11f4af68ac4f190b0fc8 (diff) | |
download | Vencord-989bd36eeb6dd6c4b391900765847cdcf87484d9.tar.gz Vencord-989bd36eeb6dd6c4b391900765847cdcf87484d9.tar.bz2 Vencord-989bd36eeb6dd6c4b391900765847cdcf87484d9.zip |
refactor: identifier escapes + "self" group (#339)
Co-authored-by: Ven <vendicated@riseup.net>
Diffstat (limited to 'src/plugins/shikiCodeblocks/index.ts')
-rw-r--r-- | src/plugins/shikiCodeblocks/index.ts | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/src/plugins/shikiCodeblocks/index.ts b/src/plugins/shikiCodeblocks/index.ts index fd6b04b..58e0048 100644 --- a/src/plugins/shikiCodeblocks/index.ts +++ b/src/plugins/shikiCodeblocks/index.ts @@ -22,7 +22,7 @@ import { wordsFromPascal, wordsToTitle } from "@utils/text"; import definePlugin, { OptionType } from "@utils/types"; import previewExampleText from "~fileContent/previewExample.tsx"; -import cssText from "~fileContent/style.css"; +import cssText from "~fileContent/shiki.css"; import { Settings } from "../../Vencord"; import { shiki } from "./api/shiki"; @@ -44,8 +44,8 @@ export default definePlugin({ { find: "codeBlock:{react:function", replacement: { - match: /codeBlock:\{react:function\((.),(.),(.)\)\{/, - replace: "$&return Vencord.Plugins.plugins.ShikiCodeblocks.renderHighlighter($1,$2,$3);", + match: /codeBlock:\{react:function\((\i),(\i),(\i)\)\{/, + replace: "$&return $self.renderHighlighter($1,$2,$3);", }, }, ], |