From 9fa1b265700473b9da14d198e0a00b8e74c4ee67 Mon Sep 17 00:00:00 2001 From: Vance Ingalls Date: Thu, 16 Jul 2026 01:06:11 -0700 Subject: [PATCH 1/3] fix(studio): reserve a gutter for the promote-to-variable badge MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit PromotableControl absolutely-positions its "◇ var" / "◆ {id}" badge over the wrapped control without reserving any space, so on rows where the value renders flush to the right edge (flat Font/Color rows) the badge sat directly on top of the value text instead of beside it. Add a right-padding gutter on the wrapper sized to each badge state, and cap the bound chip to a fixed max-width so it always fits inside its gutter. --- .../src/components/editor/PromotableControl.tsx | 12 ++++++++++-- 1 file changed, 10 insertions(+), 2 deletions(-) diff --git a/packages/studio/src/components/editor/PromotableControl.tsx b/packages/studio/src/components/editor/PromotableControl.tsx index b9644fbbd..cdfaee4bb 100644 --- a/packages/studio/src/components/editor/PromotableControl.tsx +++ b/packages/studio/src/components/editor/PromotableControl.tsx @@ -76,12 +76,20 @@ export function PromotableControl({ : { bound: false }, ); + // The badge is absolutely positioned over the wrapped control, so its own + // width doesn't push anything — without a matching right-padding reserve on + // the wrapper, a control whose value renders flush to the row's right edge + // (e.g. flat Font/Color rows) sits directly underneath it instead of beside it. + const gutterClass = bound ? "pr-16" : canPromote ? "pr-9" : ""; + return ( -
+
{rendered} {bound && ( ◆ {promote.boundId} From 5f045b6bdff145f0e0ec4b32aae475cefea989c1 Mon Sep 17 00:00:00 2001 From: Vance Ingalls Date: Thu, 16 Jul 2026 01:11:30 -0700 Subject: [PATCH 2/3] fix(studio): move the promote-to-variable badge above the row instead of a padding gutter Shrinking the wrapped control's width to make room for the badge (previous commit) fixed the overlap but pushed the value left unnecessarily. Move the badge to sit above the row instead, clearing the value without touching its layout. --- .../src/components/editor/PromotableControl.tsx | 16 +++++----------- 1 file changed, 5 insertions(+), 11 deletions(-) diff --git a/packages/studio/src/components/editor/PromotableControl.tsx b/packages/studio/src/components/editor/PromotableControl.tsx index cdfaee4bb..0ac6e1557 100644 --- a/packages/studio/src/components/editor/PromotableControl.tsx +++ b/packages/studio/src/components/editor/PromotableControl.tsx @@ -76,20 +76,14 @@ export function PromotableControl({ : { bound: false }, ); - // The badge is absolutely positioned over the wrapped control, so its own - // width doesn't push anything — without a matching right-padding reserve on - // the wrapper, a control whose value renders flush to the row's right edge - // (e.g. flat Font/Color rows) sits directly underneath it instead of beside it. - const gutterClass = bound ? "pr-16" : canPromote ? "pr-9" : ""; - return ( -
+
{rendered} {bound && ( ◆ {promote.boundId} @@ -103,7 +97,7 @@ export function PromotableControl({ e.stopPropagation(); promote.promote(); }} - className="absolute right-1.5 top-0 z-10 inline-flex items-center gap-1 rounded bg-neutral-800/80 px-1 py-px font-mono text-[8px] font-medium text-neutral-400 opacity-70 transition-colors hover:bg-studio-accent/20 hover:text-studio-accent hover:opacity-100" + className="absolute -top-2 right-1.5 z-10 inline-flex items-center gap-1 rounded bg-neutral-800/80 px-1 py-px font-mono text-[8px] font-medium text-neutral-400 opacity-70 transition-colors hover:bg-studio-accent/20 hover:text-studio-accent hover:opacity-100" > ◇ var From 14dbfca5a7ee80450070551e494ae12c5677ee43 Mon Sep 17 00:00:00 2001 From: Vance Ingalls Date: Thu, 16 Jul 2026 01:17:04 -0700 Subject: [PATCH 3/3] fix(studio): give flat Text section rows more vertical breathing room 6px between rows left little clearance above a row's value for the promote-to-variable badge (now positioned above the row). Widen the row gap to 10px. --- .../src/components/editor/propertyPanelFlatTextSection.tsx | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/packages/studio/src/components/editor/propertyPanelFlatTextSection.tsx b/packages/studio/src/components/editor/propertyPanelFlatTextSection.tsx index 646dc0da7..1bf88c664 100644 --- a/packages/studio/src/components/editor/propertyPanelFlatTextSection.tsx +++ b/packages/studio/src/components/editor/propertyPanelFlatTextSection.tsx @@ -267,7 +267,7 @@ export function FlatTextSection({ if (textFields.length > 1) { return ( -
+
+