diff --git a/js/common/view/population/PopulationPanel.js b/js/common/view/population/PopulationPanel.js index f0f0ab22..1762c0f5 100644 --- a/js/common/view/population/PopulationPanel.js +++ b/js/common/view/population/PopulationPanel.js @@ -7,9 +7,8 @@ */ import merge from '../../../../../phet-core/js/merge.js'; -import { AlignBox, AlignGroup, Text, VBox } from '../../../../../scenery/js/imports.js'; +import { AlignBox, AlignGroup, HSeparator, Text, VBox } from '../../../../../scenery/js/imports.js'; import Checkbox from '../../../../../sun/js/Checkbox.js'; -import HSeparatorDeprecated from '../../../../../sun/js/HSeparatorDeprecated.js'; import Tandem from '../../../../../tandem/js/Tandem.js'; import naturalSelection from '../../../naturalSelection.js'; import NaturalSelectionStrings from '../../../NaturalSelectionStrings.js'; @@ -119,7 +118,7 @@ class PopulationPanel extends NaturalSelectionPanel { children: checkboxes } ) ); - const separator = new HSeparatorDeprecated( options.fixedWidth - 2 * options.xMargin, { + const separator = new HSeparator( { stroke: NaturalSelectionColors.SEPARATOR_STROKE, tandem: options.tandem.createTandem( 'separator' ) } ); @@ -142,6 +141,7 @@ class PopulationPanel extends NaturalSelectionPanel { dataProbeCheckbox.mouseArea = dataProbeCheckbox.localBounds.dilatedXY( xDilation, yDilation ); const content = new VBox( merge( {}, NaturalSelectionConstants.VBOX_OPTIONS, { + preferredWidth: options.fixedWidth - ( 2 * options.xMargin ), children: [ checkboxesVBox, separator, diff --git a/js/common/view/proportions/ProportionsPanel.js b/js/common/view/proportions/ProportionsPanel.js index 79740ce2..088843a5 100644 --- a/js/common/view/proportions/ProportionsPanel.js +++ b/js/common/view/proportions/ProportionsPanel.js @@ -8,9 +8,8 @@ import merge from '../../../../../phet-core/js/merge.js'; import AssertUtils from '../../../../../phetcommon/js/AssertUtils.js'; -import { Text, VBox } from '../../../../../scenery/js/imports.js'; +import { HSeparator, Text, VBox } from '../../../../../scenery/js/imports.js'; import Checkbox from '../../../../../sun/js/Checkbox.js'; -import HSeparatorDeprecated from '../../../../../sun/js/HSeparatorDeprecated.js'; import Tandem from '../../../../../tandem/js/Tandem.js'; import naturalSelection from '../../../naturalSelection.js'; import NaturalSelectionStrings from '../../../NaturalSelectionStrings.js'; @@ -44,7 +43,7 @@ class ProportionsPanel extends NaturalSelectionPanel { tandem: options.tandem.createTandem( 'legendNode' ) } ); - const separator = new HSeparatorDeprecated( options.fixedWidth - 2 * options.xMargin, { + const separator = new HSeparator( { stroke: NaturalSelectionColors.SEPARATOR_STROKE, tandem: options.tandem.createTandem( 'separator' ) } ); @@ -65,6 +64,7 @@ class ProportionsPanel extends NaturalSelectionPanel { valuesCheckbox.mouseArea = valuesCheckbox.localBounds.dilatedXY( xDilation, yDilation ); const content = new VBox( merge( {}, NaturalSelectionConstants.VBOX_OPTIONS, { + preferredWidth: options.fixedWidth - ( 2 * options.xMargin ), children: [ legendNode, separator,