Skip to content

Commit

Permalink
TextPanels use same font size, see #240
Browse files Browse the repository at this point in the history
  • Loading branch information
jessegreenberg committed Apr 30, 2020
1 parent 680f8ba commit 7386140
Show file tree
Hide file tree
Showing 2 changed files with 1 addition and 7 deletions.
6 changes: 0 additions & 6 deletions js/energy-skate-park/common/view/EnergySkateParkGridNode.js
Original file line number Diff line number Diff line change
Expand Up @@ -12,15 +12,11 @@
*/

import GridNode from '../../../../../scenery-phet/js/GridNode.js';
import PhetFont from '../../../../../scenery-phet/js/PhetFont.js';
import Node from '../../../../../scenery/js/nodes/Node.js';
import energySkatePark from '../../../energySkatePark.js';
import energySkateParkStrings from '../../../energySkateParkStrings.js';
import TextPanel from './TextPanel.js';

// constants
const FONT = new PhetFont( 12 );

class EnergySkateParkGridNode extends Node {

/**
Expand Down Expand Up @@ -62,7 +58,6 @@ class EnergySkateParkGridNode extends Node {

// @private {TextPanel} - a unique label for the zero meter reference height position
this.zeroMeterLabel = new TextPanel( energySkateParkStrings.heightLabels.zeroM, {
font: FONT,
bottom: this.modelViewTransform.modelToViewY( 0 ) - 2,
right: this.labelXPosition - 2
} );
Expand Down Expand Up @@ -137,7 +132,6 @@ class EnergySkateParkGridNode extends Node {
// only major grid lines are labeled, and 0 meters has a unique label
if ( y % 2 === 0 && y !== 0 ) {
const gridLineLabel = new TextPanel( '' + y, {
font: FONT,
bottom: viewY - 2,
right: this.labelXPosition - 2
} );
Expand Down
2 changes: 1 addition & 1 deletion js/energy-skate-park/common/view/TextPanel.js
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@ class TextPanel extends Panel {
options = merge( {

// Text options
font: new PhetFont( 10 ),
font: new PhetFont( 12 ),
textMaxWidth: 150,

// panel options
Expand Down

0 comments on commit 7386140

Please sign in to comment.