From fc7f3f4c95f09f8b6d7782ec436aab4ff7d267a8 Mon Sep 17 00:00:00 2001 From: Sam Reid Date: Fri, 1 Mar 2024 16:29:35 -0700 Subject: [PATCH] Prevent overlap for the combo box and distance label, see https://github.com/phetsims/projectile-data-lab/issues/204 --- js/common/view/BinControlNode.ts | 12 ++++-------- 1 file changed, 4 insertions(+), 8 deletions(-) diff --git a/js/common/view/BinControlNode.ts b/js/common/view/BinControlNode.ts index ab2e99dc..d10ebcc9 100644 --- a/js/common/view/BinControlNode.ts +++ b/js/common/view/BinControlNode.ts @@ -44,7 +44,7 @@ export default class BinControlNode extends HBox { createNode: () => new PDLText( new PatternStringProperty( ProjectileDataLabStrings.binWidthMPatternStringProperty, { binWidth: binWidth } ), { - maxWidth: 120 + maxWidth: 70 } ), tandemName: `binWidth${binWidthName}Item` }; @@ -63,7 +63,7 @@ export default class BinControlNode extends HBox { return { value: totalBins, createNode: () => new PDLText( Utils.toFixed( totalBins, 0 ), { - maxWidth: 120 + maxWidth: 70 } ), tandemName: `totalBins${totalBins}Item` }; @@ -84,14 +84,10 @@ export default class BinControlNode extends HBox { // strategies new ToggleNode( PDLPreferences.binStrategyProperty, [ { value: 'binWidth', - createNode: () => new PDLText( ProjectileDataLabStrings.binWidthStringProperty, { - maxWidth: 120 - } ) + createNode: () => new PDLText( ProjectileDataLabStrings.binWidthStringProperty, { maxWidth: 90 } ) }, { value: 'totalBins', - createNode: () => new PDLText( ProjectileDataLabStrings.totalBinsStringProperty, { - maxWidth: 120 - } ) + createNode: () => new PDLText( ProjectileDataLabStrings.totalBinsStringProperty, { maxWidth: 90 } ) } ], { alignChildren: ToggleNode.RIGHT, layoutOptions: {