From 295a0657215a9e2cb3b518469a965616c703b141 Mon Sep 17 00:00:00 2001 From: thororen1234 <78185467+thororen1234@users.noreply.github.com> Date: Thu, 6 Jun 2024 02:54:52 -0400 Subject: [PATCH] Done For Now --- src/plugins/usrbg/index.tsx | 15 ++++++++++++--- src/plugins/viewIcons/index.tsx | 2 +- 2 files changed, 13 insertions(+), 4 deletions(-) diff --git a/src/plugins/usrbg/index.tsx b/src/plugins/usrbg/index.tsx index bf9905fe..3c442085 100644 --- a/src/plugins/usrbg/index.tsx +++ b/src/plugins/usrbg/index.tsx @@ -73,8 +73,8 @@ export default definePlugin({ } ] }, - ...[/profileType:\i,pendingBanner:\i/, /profileType:\i,overrideBannerSrc:\i/].map(find => ({ - find, + { + find: /profileType:\i,overrideBannerSrc:\i/, replacement: [ { match: /(\i)\.premiumType/, @@ -83,13 +83,22 @@ export default definePlugin({ { match: /(?<=function \i\((\i)\)\{)(?=var.+?,overrideBannerSrc:)/, replace: "$1.overrideBannerSrc=$self.useBannerHook($1);" + } + ] + }, + { + find: /profileType:\i,pendingBanner:\i/, + replacement: [ + { + match: /(\i)\.premiumType/, + replace: "$self.premiumHook($1)||$&" }, { match: /(?<=function \i\((\i)\)\{)(?=var.+?,pendingBanner:)/, replace: "$1.pendingBanner=$self.useBannerHook($1);" } ] - })), + }, { find: "\"data-selenium-video-tile\":", predicate: () => settings.store.voiceBackground, diff --git a/src/plugins/viewIcons/index.tsx b/src/plugins/viewIcons/index.tsx index a772598e..5c9f8892 100644 --- a/src/plugins/viewIcons/index.tsx +++ b/src/plugins/viewIcons/index.tsx @@ -192,7 +192,7 @@ export default definePlugin({ } })), // Banners - ...[".NITRO_BANNER,", /profileType:\i,overrideBannerSrc:\i/].map(find => ({ + ...[".NITRO_BANNER,", /profileType:\i,overrideBannerSrc:\i/, /profileType:\i,pendingBanner:\i/].map(find => ({ find, replacement: { // style: { backgroundImage: shouldShowBanner ? "url(".concat(bannerUrl,