From 359ed2e0d06573c7463f9cf3b968ce27b6c4b4cf Mon Sep 17 00:00:00 2001 From: Ally Founder Date: Tue, 11 Aug 2026 18:29:07 -0400 Subject: [PATCH] ServerDrawer: match the quest dock card by shape, not exact color string --- .../src/patches/transparentBackground.ts | 11 +++++++---- 1 file changed, 7 insertions(+), 4 deletions(-) diff --git a/plugins/server-drawer/src/patches/transparentBackground.ts b/plugins/server-drawer/src/patches/transparentBackground.ts index 454b636..a7e5d8a 100644 --- a/plugins/server-drawer/src/patches/transparentBackground.ts +++ b/plugins/server-drawer/src/patches/transparentBackground.ts @@ -3,9 +3,12 @@ import { registerPropsTransform } from "./createElementIntercept"; const TAG = "[ServerDrawer]"; // Confirmed live: the quest dock's outer "island" wrapper - a ReanimatedView ten levels above the -// drawer's own grid - carries this exact opaque card background via useAnimatedStyle. It's not -// anything our own code renders, so there's no component reference to intercept - matching the -// static part of its computed style is the only way to reach it. +// drawer's own grid - carries an opaque card background (borderRadius: 24) via useAnimatedStyle. +// It's not anything our own code renders, so there's no component reference to intercept - matching +// the static part of its computed style is the only way to reach it. The color itself showed up as +// two different string formats (rgba(...) vs hex) across two live reads of the same element, so +// matching on the exact color string is unreliable - borderRadius plus "has some background color +// at all" is the stable signal. function flatten(style: any): Record { if (!style) return {}; if (Array.isArray(style)) return Object.assign({}, ...style.map(flatten)); @@ -14,7 +17,7 @@ function flatten(style: any): Record { function isQuestDockCard(props: any): boolean { const s = flatten(props?.style); - return s.backgroundColor === "rgba(10,10,14,1)" && s.borderRadius === 24; + return s.borderRadius === 24 && typeof s.backgroundColor === "string"; } export function patchTransparentBackground(cleanups: (() => void)[]): boolean {