aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--src/plugins/ignoreActivities.tsx7
1 files changed, 5 insertions, 2 deletions
diff --git a/src/plugins/ignoreActivities.tsx b/src/plugins/ignoreActivities.tsx
index 56a0a8d..3d53bbc 100644
--- a/src/plugins/ignoreActivities.tsx
+++ b/src/plugins/ignoreActivities.tsx
@@ -145,8 +145,11 @@ export default definePlugin({
patches: [{
find: ".Messages.SETTINGS_GAMES_TOGGLE_OVERLAY",
replacement: {
- match: /var .=(?<props>.)\.overlay.+?"aria-label":.\..\.Messages\.SETTINGS_GAMES_TOGGLE_OVERLAY.+?}}\)/,
- replace: "$&,$self.renderToggleGameActivityButton($<props>)"
+ match: /!(\i)\|\|(null==\i\)return null;var \i=(\i)\.overlay.+?children:)(\[.{0,70}overlayStatusText.+?\])(?=}\)}\(\))/,
+ replace: (_, platformCheck, restWithoutPlatformCheck, props, children) => ""
+ + `${restWithoutPlatformCheck}`
+ + `(${platformCheck}?${children}:[])`
+ + `.concat(Vencord.Plugins.plugins.IgnoreActivities.renderToggleGameActivityButton(${props}))`
}
}, {
find: ".overlayBadge",