Fix(InvisibleChat) Fix chatbar icon patch (closes #560) (#566)

Co-authored-by: Ven <vendicated@riseup.net>
This commit is contained in:
Sammy 2023-03-05 22:05:46 +01:00 committed by GitHub
parent e219aaa062
commit abbd298b31
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

@ -91,8 +91,8 @@ function ChatBarIcon() {
<svg <svg
aria-hidden aria-hidden
role="img" role="img"
width="24" width="32"
height="24" height="32"
viewBox={"0 0 64 64"} viewBox={"0 0 64 64"}
style={{ scale: "1.1" }} style={{ scale: "1.1" }}
> >
@ -131,8 +131,8 @@ export default definePlugin({
{ {
find: ".activeCommandOption", find: ".activeCommandOption",
replacement: { replacement: {
match: /.=.\.activeCommand,.=.\.activeCommandOption,.{1,133}(.)=\[\];/, match: /(.)\.push.{1,50}\(\i,\{.{1,30}\},"gift"\)\)/,
replace: "$&;$1.push($self.chatBarIcon());", replace: "$&;try{$1.push($self.chatBarIcon())}catch{}",
} }
}, },
], ],