Skip to content

Commit

Permalink
nested NumberControl options, see phetsims/scenery-phet#451
Browse files Browse the repository at this point in the history
  • Loading branch information
mbarlow12 committed Feb 3, 2019
1 parent 704d50b commit 984b9d9
Showing 1 changed file with 20 additions and 17 deletions.
37 changes: 20 additions & 17 deletions js/gravity-force-lab/view/MassControl.js
Original file line number Diff line number Diff line change
Expand Up @@ -47,24 +47,27 @@ define( function( require ) {
yMargin: 10,

numberControlOptions: {
sliderOptions: {
thumbSize: THUMB_SIZE,
trackSize: TRACK_SIZE,
majorTickLength: ( THUMB_SIZE.height / 2 ) + ( TRACK_SIZE.height / 2 ) + 2,
minorTickSpacing: 0,
thumbFillEnabled: thumbColor.colorUtilsBrighter( 0.15 ),
thumbFillHighlighted: thumbColor.colorUtilsBrighter( 0.35 ),

thumbSize: THUMB_SIZE,
trackSize: TRACK_SIZE,
titleFont: new PhetFont( 24 ),
valueFont: new PhetFont( 18 ),
valueXMargin: 20,
valueYMargin: 4,
majorTickLength: ( THUMB_SIZE.height / 2 ) + ( TRACK_SIZE.height / 2 ) + 2,
minorTickSpacing: 0,
thumbFillEnabled: thumbColor.colorUtilsBrighter( 0.15 ),
thumbFillHighlighted: thumbColor.colorUtilsBrighter( 0.35 ),

// a11y
keyboardStep: 50,
pageKeyboardStep: 100,
accessibleName: titleString,
// accessibleValuePattern: valueKilogramsPatternString, // {{value}} kilograms
createAriaValueText: massDescriber.getAriaValueTextCreator( massEnum )
// a11y
keyboardStep: 50,
pageKeyboardStep: 100,
accessibleName: titleString,
// accessibleValuePattern: valueKilogramsPatternString, // {{value}} kilograms
createAriaValueText: massDescriber.getAriaValueTextCreator( massEnum )
},
titleNodeOptions: { font: new PhetFont( 24 ) },
numberDisplayOptions: {
font: new PhetFont( 18 ),
xMargin: 20,
yMargin: 4
}

},

Expand Down

0 comments on commit 984b9d9

Please sign in to comment.