Skip to content

Commit

Permalink
Add tandemSuffix option, specify and match conventions, see phetsims/…
Browse files Browse the repository at this point in the history
  • Loading branch information
samreid committed Aug 26, 2022
1 parent 60e0bdc commit f6f9038
Show file tree
Hide file tree
Showing 3 changed files with 4 additions and 3 deletions.
3 changes: 2 additions & 1 deletion js/common/view/ForcesAndMotionBasicsIconFactory.js
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,7 @@

import Property from '../../../../axon/js/Property.js';
import Range from '../../../../dot/js/Range.js';
import Tandem from '../../../../tandem/js/Tandem.js';
import GaugeNode from '../../../../scenery-phet/js/GaugeNode.js';
import forcesAndMotionBasics from '../../forcesAndMotionBasics.js';
import forcesAndMotionBasicsStrings from '../../forcesAndMotionBasicsStrings.js';
Expand All @@ -24,7 +25,7 @@ const ForcesAndMotionBasicsIconFactory = {
// the 'speed' option requires the text and a speedometer icon
const speedometerIconValueProperty = new Property( 0 );
return new GaugeNode( speedometerIconValueProperty, speedString, new Range( 0, MotionConstants.MAX_SPEED ),
{ radius: 67, scale: 0.2, tandem: tandem.createTandem( 'speedometerIcon' ) } );
{ radius: 67, scale: 0.2, tandem: Tandem.OPT_OUT } );
}
};

Expand Down
2 changes: 1 addition & 1 deletion js/motion/view/MotionControlPanel.js
Original file line number Diff line number Diff line change
Expand Up @@ -88,7 +88,7 @@ class MotionControlPanel extends Node {
const speedometerIcon = () => {
const speedometerIconValueProperty = new Property( 0 );
return new GaugeNode( speedometerIconValueProperty, speedString, new Range( 0, MotionConstants.MAX_SPEED ),
{ radius: 67, scale: 0.2, tandem: tandem.createTandem( 'speedometerIcon' ) } );
{ radius: 67, scale: 0.2, tandem: tandem.createTandem( 'speedometerIconNode' ) } );
};
const accelerometerIcon = () => {
const accelerometerIconValueProperty = new Property( 5 ); // the acclerometer icon looks best with ~5 m/s^2 filled in
Expand Down
2 changes: 1 addition & 1 deletion js/netforce/view/NetForceControlPanel.js
Original file line number Diff line number Diff line change
Expand Up @@ -41,7 +41,7 @@ class NetForceControlPanel extends Node {
const fontOptions = { font: new PhetFont( 18 ), maxWidth: 230 };

// the content for "show speed" is a label with an icon
const speedometerIcon = ForcesAndMotionBasicsIconFactory.speedometerIcon( tandem.createTandem( 'speedometerIcon' ) );
const speedometerIcon = ForcesAndMotionBasicsIconFactory.speedometerIcon( tandem.createTandem( 'speedometerIconNode' ) );
const showSpeedTextNode = new Text( speedString, merge( { tandem: tandem.createTandem( 'showSpeedTextNode' ) }, fontOptions ) );
const showSpeedContent = new HBox( {
children: [ showSpeedTextNode, speedometerIcon ],
Expand Down

0 comments on commit f6f9038

Please sign in to comment.