From 7c898ebff97a3e1951957148f806e70d8e439ff0 Mon Sep 17 00:00:00 2001 From: zepumph Date: Thu, 19 Sep 2019 13:54:18 -0800 Subject: [PATCH] var -> const in require statements, use arrow function in define require call, https://github.com/phetsims/tasks/issues/1010 --- js/common/ProportionPlaygroundConstants.js | 8 ++-- .../ProportionPlaygroundQueryParameters.js | 4 +- js/common/model/ProportionModel.js | 18 +++---- js/common/model/Scene.js | 12 ++--- js/common/model/SceneRatio.js | 10 ++-- js/common/model/Side.js | 4 +- js/common/model/apples/AppleGroup.js | 12 ++--- js/common/model/apples/AppleScene.js | 12 ++--- js/common/model/billiards/BilliardsScene.js | 10 ++-- js/common/model/billiards/BilliardsTable.js | 22 ++++----- js/common/model/necklace/Necklace.js | 16 +++---- js/common/model/necklace/NecklaceLayout.js | 20 ++++---- js/common/model/necklace/NecklaceScene.js | 10 ++-- js/common/model/necklace/RoundBead.js | 6 +-- js/common/model/necklace/SquareBead.js | 6 +-- js/common/model/paint/PaintBalloon.js | 6 +-- js/common/model/paint/PaintChoice.js | 14 +++--- js/common/model/paint/PaintDrip.js | 6 +-- js/common/model/paint/PaintQuantity.js | 8 ++-- js/common/model/paint/PaintScene.js | 16 +++---- js/common/model/paint/Splotch.js | 22 ++++----- .../view/ProportionPlaygroundColorProfile.js | 12 ++--- js/common/view/ProportionScreenView.js | 26 +++++----- js/common/view/RevealButton.js | 14 +++--- js/common/view/SceneNode.js | 22 ++++----- js/common/view/SceneRatioControl.js | 24 +++++----- js/common/view/SceneRatioNode.js | 8 ++-- js/common/view/SceneSelectionControls.js | 18 +++---- js/common/view/TriangleNode.js | 14 +++--- js/common/view/apples/AppleGraphNode.js | 30 ++++++------ js/common/view/apples/AppleGroupControl.js | 20 ++++---- js/common/view/apples/AppleGroupNode.js | 48 +++++++++---------- js/common/view/apples/AppleSceneNode.js | 28 +++++------ js/common/view/billiards/BilliardTableIcon.js | 12 ++--- js/common/view/billiards/BilliardsPath.js | 14 +++--- .../view/billiards/BilliardsSceneNode.js | 16 +++---- .../view/billiards/BilliardsTableControl.js | 22 ++++----- .../view/billiards/BilliardsTableNode.js | 44 ++++++++--------- js/common/view/necklace/NecklaceControl.js | 16 +++---- .../view/necklace/NecklaceGraphicNode.js | 22 ++++----- js/common/view/necklace/NecklaceNode.js | 10 ++-- js/common/view/necklace/NecklaceSceneNode.js | 16 +++---- js/common/view/necklace/PatternNode.js | 22 ++++----- js/common/view/necklace/PatternPanel.js | 30 ++++++------ js/common/view/necklace/RoundBeadNode.js | 20 ++++---- js/common/view/necklace/SquareBeadNode.js | 22 ++++----- js/common/view/paint/GradientIndicatorNode.js | 18 +++---- js/common/view/paint/PaintBalloonNode.js | 46 +++++++++--------- .../view/paint/PaintChoiceGradientNode.js | 16 +++---- js/common/view/paint/PaintDripNode.js | 18 +++---- js/common/view/paint/PaintSceneNode.js | 36 +++++++------- js/common/view/paint/SplotchControl.js | 24 +++++----- js/common/view/paint/SplotchNode.js | 30 ++++++------ js/explore/ExploreScreen.js | 36 +++++++------- js/predict/PredictScreen.js | 36 +++++++------- js/proportion-playground-main.js | 12 ++--- js/proportionPlayground.js | 4 +- 57 files changed, 524 insertions(+), 524 deletions(-) diff --git a/js/common/ProportionPlaygroundConstants.js b/js/common/ProportionPlaygroundConstants.js index 0aad6ee..e0dee37 100644 --- a/js/common/ProportionPlaygroundConstants.js +++ b/js/common/ProportionPlaygroundConstants.js @@ -5,12 +5,12 @@ * * @author Sam Reid (PhET Interactive Simulations) */ -define( function( require ) { +define( require => { 'use strict'; - var PhetFont = require( 'SCENERY_PHET/PhetFont' ); - var proportionPlayground = require( 'PROPORTION_PLAYGROUND/proportionPlayground' ); - var Range = require( 'DOT/Range' ); + const PhetFont = require( 'SCENERY_PHET/PhetFont' ); + const proportionPlayground = require( 'PROPORTION_PLAYGROUND/proportionPlayground' ); + const Range = require( 'DOT/Range' ); var ProportionPlaygroundConstants = { // @public {number} - Diameter/width of the beads in the necklace scene diff --git a/js/common/ProportionPlaygroundQueryParameters.js b/js/common/ProportionPlaygroundQueryParameters.js index 1eb42bc..e08978d 100644 --- a/js/common/ProportionPlaygroundQueryParameters.js +++ b/js/common/ProportionPlaygroundQueryParameters.js @@ -5,11 +5,11 @@ * * @author Sam Reid (PhET Interactive Simulations) */ -define( function( require ) { +define( require => { 'use strict'; // modules - var proportionPlayground = require( 'PROPORTION_PLAYGROUND/proportionPlayground' ); + const proportionPlayground = require( 'PROPORTION_PLAYGROUND/proportionPlayground' ); var ProportionPlaygroundQueryParameters = QueryStringMachine.getAll( { diff --git a/js/common/model/ProportionModel.js b/js/common/model/ProportionModel.js index 171ce3d..d55caa1 100644 --- a/js/common/model/ProportionModel.js +++ b/js/common/model/ProportionModel.js @@ -5,18 +5,18 @@ * * @author Sam Reid (PhET Interactive Simulations) */ -define( function( require ) { +define( require => { 'use strict'; // modules - var AppleScene = require( 'PROPORTION_PLAYGROUND/common/model/apples/AppleScene' ); - var BilliardsScene = require( 'PROPORTION_PLAYGROUND/common/model/billiards/BilliardsScene' ); - var inherit = require( 'PHET_CORE/inherit' ); - var NecklaceScene = require( 'PROPORTION_PLAYGROUND/common/model/necklace/NecklaceScene' ); - var PaintScene = require( 'PROPORTION_PLAYGROUND/common/model/paint/PaintScene' ); - var Property = require( 'AXON/Property' ); - var proportionPlayground = require( 'PROPORTION_PLAYGROUND/proportionPlayground' ); - var ProportionPlaygroundQueryParameters = require( 'PROPORTION_PLAYGROUND/common/ProportionPlaygroundQueryParameters' ); + const AppleScene = require( 'PROPORTION_PLAYGROUND/common/model/apples/AppleScene' ); + const BilliardsScene = require( 'PROPORTION_PLAYGROUND/common/model/billiards/BilliardsScene' ); + const inherit = require( 'PHET_CORE/inherit' ); + const NecklaceScene = require( 'PROPORTION_PLAYGROUND/common/model/necklace/NecklaceScene' ); + const PaintScene = require( 'PROPORTION_PLAYGROUND/common/model/paint/PaintScene' ); + const Property = require( 'AXON/Property' ); + const proportionPlayground = require( 'PROPORTION_PLAYGROUND/proportionPlayground' ); + const ProportionPlaygroundQueryParameters = require( 'PROPORTION_PLAYGROUND/common/ProportionPlaygroundQueryParameters' ); /** * @constructor diff --git a/js/common/model/Scene.js b/js/common/model/Scene.js index fd065b3..06c83f3 100644 --- a/js/common/model/Scene.js +++ b/js/common/model/Scene.js @@ -5,15 +5,15 @@ * * @author Sam Reid (PhET Interactive Simulations) */ -define( function( require ) { +define( require => { 'use strict'; // modules - var BooleanProperty = require( 'AXON/BooleanProperty' ); - var DerivedProperty = require( 'AXON/DerivedProperty' ); - var inherit = require( 'PHET_CORE/inherit' ); - var Property = require( 'AXON/Property' ); - var proportionPlayground = require( 'PROPORTION_PLAYGROUND/proportionPlayground' ); + const BooleanProperty = require( 'AXON/BooleanProperty' ); + const DerivedProperty = require( 'AXON/DerivedProperty' ); + const inherit = require( 'PHET_CORE/inherit' ); + const Property = require( 'AXON/Property' ); + const proportionPlayground = require( 'PROPORTION_PLAYGROUND/proportionPlayground' ); /** * @constructor diff --git a/js/common/model/SceneRatio.js b/js/common/model/SceneRatio.js index f3badfc..57ac632 100644 --- a/js/common/model/SceneRatio.js +++ b/js/common/model/SceneRatio.js @@ -5,14 +5,14 @@ * * @author Jonathan Olson */ -define( function( require ) { +define( require => { 'use strict'; // modules - var Emitter = require( 'AXON/Emitter' ); - var inherit = require( 'PHET_CORE/inherit' ); - var proportionPlayground = require( 'PROPORTION_PLAYGROUND/proportionPlayground' ); - var Side = require( 'PROPORTION_PLAYGROUND/common/model/Side' ); + const Emitter = require( 'AXON/Emitter' ); + const inherit = require( 'PHET_CORE/inherit' ); + const proportionPlayground = require( 'PROPORTION_PLAYGROUND/proportionPlayground' ); + const Side = require( 'PROPORTION_PLAYGROUND/common/model/Side' ); /** * @constructor diff --git a/js/common/model/Side.js b/js/common/model/Side.js index 66b906f..91bb0d4 100644 --- a/js/common/model/Side.js +++ b/js/common/model/Side.js @@ -5,11 +5,11 @@ * * @author Jonathan Olson */ -define( function( require ) { +define( require => { 'use strict'; // modules - var proportionPlayground = require( 'PROPORTION_PLAYGROUND/proportionPlayground' ); + const proportionPlayground = require( 'PROPORTION_PLAYGROUND/proportionPlayground' ); var Side = { LEFT: 'LEFT', diff --git a/js/common/model/apples/AppleGroup.js b/js/common/model/apples/AppleGroup.js index a8be9a6..5d23429 100644 --- a/js/common/model/apples/AppleGroup.js +++ b/js/common/model/apples/AppleGroup.js @@ -5,15 +5,15 @@ * * @author Sam Reid (PhET Interactive Simulations) */ -define( function( require ) { +define( require => { 'use strict'; // modules - var inherit = require( 'PHET_CORE/inherit' ); - var NumberProperty = require( 'AXON/NumberProperty' ); - var proportionPlayground = require( 'PROPORTION_PLAYGROUND/proportionPlayground' ); - var ProportionPlaygroundConstants = require( 'PROPORTION_PLAYGROUND/common/ProportionPlaygroundConstants' ); - var SceneRatio = require( 'PROPORTION_PLAYGROUND/common/model/SceneRatio' ); + const inherit = require( 'PHET_CORE/inherit' ); + const NumberProperty = require( 'AXON/NumberProperty' ); + const proportionPlayground = require( 'PROPORTION_PLAYGROUND/proportionPlayground' ); + const ProportionPlaygroundConstants = require( 'PROPORTION_PLAYGROUND/common/ProportionPlaygroundConstants' ); + const SceneRatio = require( 'PROPORTION_PLAYGROUND/common/model/SceneRatio' ); /** * @constructor diff --git a/js/common/model/apples/AppleScene.js b/js/common/model/apples/AppleScene.js index 9ee0a04..9f2693c 100644 --- a/js/common/model/apples/AppleScene.js +++ b/js/common/model/apples/AppleScene.js @@ -5,15 +5,15 @@ * * @author Sam Reid (PhET Interactive Simulations) */ -define( function( require ) { +define( require => { 'use strict'; // modules - var AppleGroup = require( 'PROPORTION_PLAYGROUND/common/model/apples/AppleGroup' ); - var BooleanProperty = require( 'AXON/BooleanProperty' ); - var inherit = require( 'PHET_CORE/inherit' ); - var proportionPlayground = require( 'PROPORTION_PLAYGROUND/proportionPlayground' ); - var Scene = require( 'PROPORTION_PLAYGROUND/common/model/Scene' ); + const AppleGroup = require( 'PROPORTION_PLAYGROUND/common/model/apples/AppleGroup' ); + const BooleanProperty = require( 'AXON/BooleanProperty' ); + const inherit = require( 'PHET_CORE/inherit' ); + const proportionPlayground = require( 'PROPORTION_PLAYGROUND/proportionPlayground' ); + const Scene = require( 'PROPORTION_PLAYGROUND/common/model/Scene' ); /** * @constructor diff --git a/js/common/model/billiards/BilliardsScene.js b/js/common/model/billiards/BilliardsScene.js index e82f486..304de2a 100644 --- a/js/common/model/billiards/BilliardsScene.js +++ b/js/common/model/billiards/BilliardsScene.js @@ -5,14 +5,14 @@ * * @author Sam Reid (PhET Interactive Simulations) */ -define( function( require ) { +define( require => { 'use strict'; // modules - var BilliardsTable = require( 'PROPORTION_PLAYGROUND/common/model/billiards/BilliardsTable' ); - var inherit = require( 'PHET_CORE/inherit' ); - var proportionPlayground = require( 'PROPORTION_PLAYGROUND/proportionPlayground' ); - var Scene = require( 'PROPORTION_PLAYGROUND/common/model/Scene' ); + const BilliardsTable = require( 'PROPORTION_PLAYGROUND/common/model/billiards/BilliardsTable' ); + const inherit = require( 'PHET_CORE/inherit' ); + const proportionPlayground = require( 'PROPORTION_PLAYGROUND/proportionPlayground' ); + const Scene = require( 'PROPORTION_PLAYGROUND/common/model/Scene' ); /** * @constructor diff --git a/js/common/model/billiards/BilliardsTable.js b/js/common/model/billiards/BilliardsTable.js index 7bbd94c..725d885 100644 --- a/js/common/model/billiards/BilliardsTable.js +++ b/js/common/model/billiards/BilliardsTable.js @@ -5,20 +5,20 @@ * * @author Sam Reid (PhET Interactive Simulations) */ -define( function( require ) { +define( require => { 'use strict'; // modules - var BooleanProperty = require( 'AXON/BooleanProperty' ); - var Emitter = require( 'AXON/Emitter' ); - var inherit = require( 'PHET_CORE/inherit' ); - var NumberProperty = require( 'AXON/NumberProperty' ); - var ObservableArray = require( 'AXON/ObservableArray' ); - var proportionPlayground = require( 'PROPORTION_PLAYGROUND/proportionPlayground' ); - var ProportionPlaygroundConstants = require( 'PROPORTION_PLAYGROUND/common/ProportionPlaygroundConstants' ); - var SceneRatio = require( 'PROPORTION_PLAYGROUND/common/model/SceneRatio' ); - var Vector2 = require( 'DOT/Vector2' ); - var Vector2Property = require( 'DOT/Vector2Property' ); + const BooleanProperty = require( 'AXON/BooleanProperty' ); + const Emitter = require( 'AXON/Emitter' ); + const inherit = require( 'PHET_CORE/inherit' ); + const NumberProperty = require( 'AXON/NumberProperty' ); + const ObservableArray = require( 'AXON/ObservableArray' ); + const proportionPlayground = require( 'PROPORTION_PLAYGROUND/proportionPlayground' ); + const ProportionPlaygroundConstants = require( 'PROPORTION_PLAYGROUND/common/ProportionPlaygroundConstants' ); + const SceneRatio = require( 'PROPORTION_PLAYGROUND/common/model/SceneRatio' ); + const Vector2 = require( 'DOT/Vector2' ); + const Vector2Property = require( 'DOT/Vector2Property' ); // constants var scratchVector = new Vector2( 0, 0 ); diff --git a/js/common/model/necklace/Necklace.js b/js/common/model/necklace/Necklace.js index dd794e0..0d7674b 100644 --- a/js/common/model/necklace/Necklace.js +++ b/js/common/model/necklace/Necklace.js @@ -6,17 +6,17 @@ * * @author Sam Reid (PhET Interactive Simulations) */ -define( function( require ) { +define( require => { 'use strict'; // modules - var DerivedProperty = require( 'AXON/DerivedProperty' ); - var inherit = require( 'PHET_CORE/inherit' ); - var NecklaceLayout = require( 'PROPORTION_PLAYGROUND/common/model/necklace/NecklaceLayout' ); - var NumberProperty = require( 'AXON/NumberProperty' ); - var proportionPlayground = require( 'PROPORTION_PLAYGROUND/proportionPlayground' ); - var ProportionPlaygroundConstants = require( 'PROPORTION_PLAYGROUND/common/ProportionPlaygroundConstants' ); - var SceneRatio = require( 'PROPORTION_PLAYGROUND/common/model/SceneRatio' ); + const DerivedProperty = require( 'AXON/DerivedProperty' ); + const inherit = require( 'PHET_CORE/inherit' ); + const NecklaceLayout = require( 'PROPORTION_PLAYGROUND/common/model/necklace/NecklaceLayout' ); + const NumberProperty = require( 'AXON/NumberProperty' ); + const proportionPlayground = require( 'PROPORTION_PLAYGROUND/proportionPlayground' ); + const ProportionPlaygroundConstants = require( 'PROPORTION_PLAYGROUND/common/ProportionPlaygroundConstants' ); + const SceneRatio = require( 'PROPORTION_PLAYGROUND/common/model/SceneRatio' ); /** * @constructor diff --git a/js/common/model/necklace/NecklaceLayout.js b/js/common/model/necklace/NecklaceLayout.js index 1476890..c91be97 100644 --- a/js/common/model/necklace/NecklaceLayout.js +++ b/js/common/model/necklace/NecklaceLayout.js @@ -8,19 +8,19 @@ * @author Sam Reid (PhET Interactive Simulations) * @author Andrea Lin */ -define( function( require ) { +define( require => { 'use strict'; // modules - var inherit = require( 'PHET_CORE/inherit' ); - var proportionPlayground = require( 'PROPORTION_PLAYGROUND/proportionPlayground' ); - var ProportionPlaygroundConstants = require( 'PROPORTION_PLAYGROUND/common/ProportionPlaygroundConstants' ); - var Random = require( 'DOT/Random' ); - var RoundBead = require( 'PROPORTION_PLAYGROUND/common/model/necklace/RoundBead' ); - var Shape = require( 'KITE/Shape' ); - var SquareBead = require( 'PROPORTION_PLAYGROUND/common/model/necklace/SquareBead' ); - var Util = require( 'DOT/Util' ); - var Vector2 = require( 'DOT/Vector2' ); + const inherit = require( 'PHET_CORE/inherit' ); + const proportionPlayground = require( 'PROPORTION_PLAYGROUND/proportionPlayground' ); + const ProportionPlaygroundConstants = require( 'PROPORTION_PLAYGROUND/common/ProportionPlaygroundConstants' ); + const Random = require( 'DOT/Random' ); + const RoundBead = require( 'PROPORTION_PLAYGROUND/common/model/necklace/RoundBead' ); + const Shape = require( 'KITE/Shape' ); + const SquareBead = require( 'PROPORTION_PLAYGROUND/common/model/necklace/SquareBead' ); + const Util = require( 'DOT/Util' ); + const Vector2 = require( 'DOT/Vector2' ); // {number} - The diameter of beads (for the square bead, it's from the center of the bead to the center of a side) var BEAD_DIAMETER = ProportionPlaygroundConstants.BEAD_DIAMETER; diff --git a/js/common/model/necklace/NecklaceScene.js b/js/common/model/necklace/NecklaceScene.js index a8bd2ef..dfad169 100644 --- a/js/common/model/necklace/NecklaceScene.js +++ b/js/common/model/necklace/NecklaceScene.js @@ -5,14 +5,14 @@ * * @author Sam Reid (PhET Interactive Simulations) */ -define( function( require ) { +define( require => { 'use strict'; // modules - var inherit = require( 'PHET_CORE/inherit' ); - var Necklace = require( 'PROPORTION_PLAYGROUND/common/model/necklace/Necklace' ); - var proportionPlayground = require( 'PROPORTION_PLAYGROUND/proportionPlayground' ); - var Scene = require( 'PROPORTION_PLAYGROUND/common/model/Scene' ); + const inherit = require( 'PHET_CORE/inherit' ); + const Necklace = require( 'PROPORTION_PLAYGROUND/common/model/necklace/Necklace' ); + const proportionPlayground = require( 'PROPORTION_PLAYGROUND/proportionPlayground' ); + const Scene = require( 'PROPORTION_PLAYGROUND/common/model/Scene' ); /** * @constructor diff --git a/js/common/model/necklace/RoundBead.js b/js/common/model/necklace/RoundBead.js index 1897f0e..deb00b7 100644 --- a/js/common/model/necklace/RoundBead.js +++ b/js/common/model/necklace/RoundBead.js @@ -5,12 +5,12 @@ * * @author Jonathan Olson */ -define( function( require ) { +define( require => { 'use strict'; // modules - var inherit = require( 'PHET_CORE/inherit' ); - var proportionPlayground = require( 'PROPORTION_PLAYGROUND/proportionPlayground' ); + const inherit = require( 'PHET_CORE/inherit' ); + const proportionPlayground = require( 'PROPORTION_PLAYGROUND/proportionPlayground' ); /** * @constructor diff --git a/js/common/model/necklace/SquareBead.js b/js/common/model/necklace/SquareBead.js index 356b044..df400d9 100644 --- a/js/common/model/necklace/SquareBead.js +++ b/js/common/model/necklace/SquareBead.js @@ -5,12 +5,12 @@ * * @author Jonathan Olson */ -define( function( require ) { +define( require => { 'use strict'; // modules - var inherit = require( 'PHET_CORE/inherit' ); - var proportionPlayground = require( 'PROPORTION_PLAYGROUND/proportionPlayground' ); + const inherit = require( 'PHET_CORE/inherit' ); + const proportionPlayground = require( 'PROPORTION_PLAYGROUND/proportionPlayground' ); /** * @constructor diff --git a/js/common/model/paint/PaintBalloon.js b/js/common/model/paint/PaintBalloon.js index f2ece9c..a25874e 100644 --- a/js/common/model/paint/PaintBalloon.js +++ b/js/common/model/paint/PaintBalloon.js @@ -5,12 +5,12 @@ * * @author Sam Reid (PhET Interactive Simulations) */ -define( function( require ) { +define( require => { 'use strict'; // modules - var inherit = require( 'PHET_CORE/inherit' ); - var proportionPlayground = require( 'PROPORTION_PLAYGROUND/proportionPlayground' ); + const inherit = require( 'PHET_CORE/inherit' ); + const proportionPlayground = require( 'PROPORTION_PLAYGROUND/proportionPlayground' ); // {number} - In seconds, the time from "launch" to when the balloon "hits" the splotch. var TIME_TO_HIT = 0.5; diff --git a/js/common/model/paint/PaintChoice.js b/js/common/model/paint/PaintChoice.js index 9b27c01..20f4b52 100644 --- a/js/common/model/paint/PaintChoice.js +++ b/js/common/model/paint/PaintChoice.js @@ -7,16 +7,16 @@ * @author Sam Reid (PhET Interactive Simulations) * @author Jonathan Olson */ -define( function( require ) { +define( require => { 'use strict'; // modules - var Color = require( 'SCENERY/util/Color' ); - var DerivedProperty = require( 'AXON/DerivedProperty' ); - var inherit = require( 'PHET_CORE/inherit' ); - var proportionPlayground = require( 'PROPORTION_PLAYGROUND/proportionPlayground' ); - var ProportionPlaygroundColorProfile = require( 'PROPORTION_PLAYGROUND/common/view/ProportionPlaygroundColorProfile' ); - var Side = require( 'PROPORTION_PLAYGROUND/common/model/Side' ); + const Color = require( 'SCENERY/util/Color' ); + const DerivedProperty = require( 'AXON/DerivedProperty' ); + const inherit = require( 'PHET_CORE/inherit' ); + const proportionPlayground = require( 'PROPORTION_PLAYGROUND/proportionPlayground' ); + const ProportionPlaygroundColorProfile = require( 'PROPORTION_PLAYGROUND/common/view/ProportionPlaygroundColorProfile' ); + const Side = require( 'PROPORTION_PLAYGROUND/common/model/Side' ); /** * Models mixing of watercolor paints with the weighted geometric mean, then with an applied gamma correction. diff --git a/js/common/model/paint/PaintDrip.js b/js/common/model/paint/PaintDrip.js index e357929..aefd916 100644 --- a/js/common/model/paint/PaintDrip.js +++ b/js/common/model/paint/PaintDrip.js @@ -5,12 +5,12 @@ * * @author Sam Reid (PhET Interactive Simulations) */ -define( function( require ) { +define( require => { 'use strict'; // modules - var inherit = require( 'PHET_CORE/inherit' ); - var proportionPlayground = require( 'PROPORTION_PLAYGROUND/proportionPlayground' ); + const inherit = require( 'PHET_CORE/inherit' ); + const proportionPlayground = require( 'PROPORTION_PLAYGROUND/proportionPlayground' ); /** * @constructor diff --git a/js/common/model/paint/PaintQuantity.js b/js/common/model/paint/PaintQuantity.js index 4aef4d3..4d76dff 100644 --- a/js/common/model/paint/PaintQuantity.js +++ b/js/common/model/paint/PaintQuantity.js @@ -5,13 +5,13 @@ * * @author Jonathan Olson */ -define( function( require ) { +define( require => { 'use strict'; // modules - var inherit = require( 'PHET_CORE/inherit' ); - var NumberProperty = require( 'AXON/NumberProperty' ); - var proportionPlayground = require( 'PROPORTION_PLAYGROUND/proportionPlayground' ); + const inherit = require( 'PHET_CORE/inherit' ); + const NumberProperty = require( 'AXON/NumberProperty' ); + const proportionPlayground = require( 'PROPORTION_PLAYGROUND/proportionPlayground' ); /** * @constructor diff --git a/js/common/model/paint/PaintScene.js b/js/common/model/paint/PaintScene.js index c1826c1..5601b0d 100644 --- a/js/common/model/paint/PaintScene.js +++ b/js/common/model/paint/PaintScene.js @@ -5,17 +5,17 @@ * * @author Sam Reid (PhET Interactive Simulations) */ -define( function( require ) { +define( require => { 'use strict'; // modules - var inherit = require( 'PHET_CORE/inherit' ); - var PaintChoice = require( 'PROPORTION_PLAYGROUND/common/model/paint/PaintChoice' ); - var Property = require( 'AXON/Property' ); - var proportionPlayground = require( 'PROPORTION_PLAYGROUND/proportionPlayground' ); - var Scene = require( 'PROPORTION_PLAYGROUND/common/model/Scene' ); - var SceneRatio = require( 'PROPORTION_PLAYGROUND/common/model/SceneRatio' ); - var Splotch = require( 'PROPORTION_PLAYGROUND/common/model/paint/Splotch' ); + const inherit = require( 'PHET_CORE/inherit' ); + const PaintChoice = require( 'PROPORTION_PLAYGROUND/common/model/paint/PaintChoice' ); + const Property = require( 'AXON/Property' ); + const proportionPlayground = require( 'PROPORTION_PLAYGROUND/proportionPlayground' ); + const Scene = require( 'PROPORTION_PLAYGROUND/common/model/Scene' ); + const SceneRatio = require( 'PROPORTION_PLAYGROUND/common/model/SceneRatio' ); + const Splotch = require( 'PROPORTION_PLAYGROUND/common/model/paint/Splotch' ); /** * @constructor diff --git a/js/common/model/paint/Splotch.js b/js/common/model/paint/Splotch.js index 3e3c30d..dc2fe32 100644 --- a/js/common/model/paint/Splotch.js +++ b/js/common/model/paint/Splotch.js @@ -5,20 +5,20 @@ * * @author Sam Reid (PhET Interactive Simulations) */ -define( function( require ) { +define( require => { 'use strict'; // modules - var DerivedProperty = require( 'AXON/DerivedProperty' ); - var inherit = require( 'PHET_CORE/inherit' ); - var ObservableArray = require( 'AXON/ObservableArray' ); - var PaintBalloon = require( 'PROPORTION_PLAYGROUND/common/model/paint/PaintBalloon' ); - var PaintDrip = require( 'PROPORTION_PLAYGROUND/common/model/paint/PaintDrip' ); - var PaintQuantity = require( 'PROPORTION_PLAYGROUND/common/model/paint/PaintQuantity' ); - var proportionPlayground = require( 'PROPORTION_PLAYGROUND/proportionPlayground' ); - var ProportionPlaygroundConstants = require( 'PROPORTION_PLAYGROUND/common/ProportionPlaygroundConstants' ); - var SceneRatio = require( 'PROPORTION_PLAYGROUND/common/model/SceneRatio' ); - var Side = require( 'PROPORTION_PLAYGROUND/common/model/Side' ); + const DerivedProperty = require( 'AXON/DerivedProperty' ); + const inherit = require( 'PHET_CORE/inherit' ); + const ObservableArray = require( 'AXON/ObservableArray' ); + const PaintBalloon = require( 'PROPORTION_PLAYGROUND/common/model/paint/PaintBalloon' ); + const PaintDrip = require( 'PROPORTION_PLAYGROUND/common/model/paint/PaintDrip' ); + const PaintQuantity = require( 'PROPORTION_PLAYGROUND/common/model/paint/PaintQuantity' ); + const proportionPlayground = require( 'PROPORTION_PLAYGROUND/proportionPlayground' ); + const ProportionPlaygroundConstants = require( 'PROPORTION_PLAYGROUND/common/ProportionPlaygroundConstants' ); + const SceneRatio = require( 'PROPORTION_PLAYGROUND/common/model/SceneRatio' ); + const Side = require( 'PROPORTION_PLAYGROUND/common/model/Side' ); /** * @constructor diff --git a/js/common/view/ProportionPlaygroundColorProfile.js b/js/common/view/ProportionPlaygroundColorProfile.js index e4e1f43..f9a5549 100644 --- a/js/common/view/ProportionPlaygroundColorProfile.js +++ b/js/common/view/ProportionPlaygroundColorProfile.js @@ -5,15 +5,15 @@ * * @author Jonathan Olson */ -define( function( require ) { +define( require => { 'use strict'; // modules - var Color = require( 'SCENERY/util/Color' ); - var ColorProfile = require( 'SCENERY_PHET/ColorProfile' ); - var DerivedProperty = require( 'AXON/DerivedProperty' ); - var PhetColorScheme = require( 'SCENERY_PHET/PhetColorScheme' ); - var proportionPlayground = require( 'PROPORTION_PLAYGROUND/proportionPlayground' ); + const Color = require( 'SCENERY/util/Color' ); + const ColorProfile = require( 'SCENERY_PHET/ColorProfile' ); + const DerivedProperty = require( 'AXON/DerivedProperty' ); + const PhetColorScheme = require( 'SCENERY_PHET/PhetColorScheme' ); + const proportionPlayground = require( 'PROPORTION_PLAYGROUND/proportionPlayground' ); // Initial colors for each profile, by string key. Only profile currently is default (still helpful for making color // tweaks with the top-level proportion-playground-colors.html) diff --git a/js/common/view/ProportionScreenView.js b/js/common/view/ProportionScreenView.js index 3b483ce..09dc70c 100644 --- a/js/common/view/ProportionScreenView.js +++ b/js/common/view/ProportionScreenView.js @@ -6,22 +6,22 @@ * * @author Sam Reid (PhET Interactive Simulations) */ -define( function( require ) { +define( require => { 'use strict'; // modules - var AppleSceneNode = require( 'PROPORTION_PLAYGROUND/common/view/apples/AppleSceneNode' ); - var BilliardsSceneNode = require( 'PROPORTION_PLAYGROUND/common/view/billiards/BilliardsSceneNode' ); - var Bounds2 = require( 'DOT/Bounds2' ); - var inherit = require( 'PHET_CORE/inherit' ); - var NecklaceSceneNode = require( 'PROPORTION_PLAYGROUND/common/view/necklace/NecklaceSceneNode' ); - var Node = require( 'SCENERY/nodes/Node' ); - var PaintSceneNode = require( 'PROPORTION_PLAYGROUND/common/view/paint/PaintSceneNode' ); - var proportionPlayground = require( 'PROPORTION_PLAYGROUND/proportionPlayground' ); - var ProportionPlaygroundConstants = require( 'PROPORTION_PLAYGROUND/common/ProportionPlaygroundConstants' ); - var ResetAllButton = require( 'SCENERY_PHET/buttons/ResetAllButton' ); - var SceneSelectionControls = require( 'PROPORTION_PLAYGROUND/common/view/SceneSelectionControls' ); - var ScreenView = require( 'JOIST/ScreenView' ); + const AppleSceneNode = require( 'PROPORTION_PLAYGROUND/common/view/apples/AppleSceneNode' ); + const BilliardsSceneNode = require( 'PROPORTION_PLAYGROUND/common/view/billiards/BilliardsSceneNode' ); + const Bounds2 = require( 'DOT/Bounds2' ); + const inherit = require( 'PHET_CORE/inherit' ); + const NecklaceSceneNode = require( 'PROPORTION_PLAYGROUND/common/view/necklace/NecklaceSceneNode' ); + const Node = require( 'SCENERY/nodes/Node' ); + const PaintSceneNode = require( 'PROPORTION_PLAYGROUND/common/view/paint/PaintSceneNode' ); + const proportionPlayground = require( 'PROPORTION_PLAYGROUND/proportionPlayground' ); + const ProportionPlaygroundConstants = require( 'PROPORTION_PLAYGROUND/common/ProportionPlaygroundConstants' ); + const ResetAllButton = require( 'SCENERY_PHET/buttons/ResetAllButton' ); + const SceneSelectionControls = require( 'PROPORTION_PLAYGROUND/common/view/SceneSelectionControls' ); + const ScreenView = require( 'JOIST/ScreenView' ); /** * @constructor diff --git a/js/common/view/RevealButton.js b/js/common/view/RevealButton.js index 4488429..0c24960 100644 --- a/js/common/view/RevealButton.js +++ b/js/common/view/RevealButton.js @@ -5,16 +5,16 @@ * * @author Sam Reid (PhET Interactive Simulations) */ -define( function( require ) { +define( require => { 'use strict'; // modules - var BooleanRoundToggleButton = require( 'SUN/buttons/BooleanRoundToggleButton' ); - var FontAwesomeNode = require( 'SUN/FontAwesomeNode' ); - var inherit = require( 'PHET_CORE/inherit' ); - var MutableOptionsNode = require( 'SUN/MutableOptionsNode' ); - var proportionPlayground = require( 'PROPORTION_PLAYGROUND/proportionPlayground' ); - var ProportionPlaygroundColorProfile = require( 'PROPORTION_PLAYGROUND/common/view/ProportionPlaygroundColorProfile' ); + const BooleanRoundToggleButton = require( 'SUN/buttons/BooleanRoundToggleButton' ); + const FontAwesomeNode = require( 'SUN/FontAwesomeNode' ); + const inherit = require( 'PHET_CORE/inherit' ); + const MutableOptionsNode = require( 'SUN/MutableOptionsNode' ); + const proportionPlayground = require( 'PROPORTION_PLAYGROUND/proportionPlayground' ); + const ProportionPlaygroundColorProfile = require( 'PROPORTION_PLAYGROUND/common/view/ProportionPlaygroundColorProfile' ); /** * @constructor diff --git a/js/common/view/SceneNode.js b/js/common/view/SceneNode.js index 854447c..b428cd9 100644 --- a/js/common/view/SceneNode.js +++ b/js/common/view/SceneNode.js @@ -5,20 +5,20 @@ * * @author Sam Reid (PhET Interactive Simulations) */ -define( function( require ) { +define( require => { 'use strict'; // modules - var ABSwitch = require( 'SUN/ABSwitch' ); - var AlignGroup = require( 'SCENERY/nodes/AlignGroup' ); - var inherit = require( 'PHET_CORE/inherit' ); - var MutableOptionsNode = require( 'SUN/MutableOptionsNode' ); - var Node = require( 'SCENERY/nodes/Node' ); - var proportionPlayground = require( 'PROPORTION_PLAYGROUND/proportionPlayground' ); - var ProportionPlaygroundColorProfile = require( 'PROPORTION_PLAYGROUND/common/view/ProportionPlaygroundColorProfile' ); - var ProportionPlaygroundConstants = require( 'PROPORTION_PLAYGROUND/common/ProportionPlaygroundConstants' ); - var ResetButton = require( 'SCENERY_PHET/buttons/ResetButton' ); - var RevealButton = require( 'PROPORTION_PLAYGROUND/common/view/RevealButton' ); + const ABSwitch = require( 'SUN/ABSwitch' ); + const AlignGroup = require( 'SCENERY/nodes/AlignGroup' ); + const inherit = require( 'PHET_CORE/inherit' ); + const MutableOptionsNode = require( 'SUN/MutableOptionsNode' ); + const Node = require( 'SCENERY/nodes/Node' ); + const proportionPlayground = require( 'PROPORTION_PLAYGROUND/proportionPlayground' ); + const ProportionPlaygroundColorProfile = require( 'PROPORTION_PLAYGROUND/common/view/ProportionPlaygroundColorProfile' ); + const ProportionPlaygroundConstants = require( 'PROPORTION_PLAYGROUND/common/ProportionPlaygroundConstants' ); + const ResetButton = require( 'SCENERY_PHET/buttons/ResetButton' ); + const RevealButton = require( 'PROPORTION_PLAYGROUND/common/view/RevealButton' ); // left and right labels for the switches should all share var switchAlignGroup = new AlignGroup(); diff --git a/js/common/view/SceneRatioControl.js b/js/common/view/SceneRatioControl.js index a7014da..07e1ab2 100644 --- a/js/common/view/SceneRatioControl.js +++ b/js/common/view/SceneRatioControl.js @@ -6,21 +6,21 @@ * * @author Jonathan Olson */ -define( function( require ) { +define( require => { 'use strict'; // modules - var HBox = require( 'SCENERY/nodes/HBox' ); - var inherit = require( 'PHET_CORE/inherit' ); - var MutableOptionsNode = require( 'SUN/MutableOptionsNode' ); - var Node = require( 'SCENERY/nodes/Node' ); - var NumberPicker = require( 'SCENERY_PHET/NumberPicker' ); - var Property = require( 'AXON/Property' ); - var proportionPlayground = require( 'PROPORTION_PLAYGROUND/proportionPlayground' ); - var ProportionPlaygroundConstants = require( 'PROPORTION_PLAYGROUND/common/ProportionPlaygroundConstants' ); - var Side = require( 'PROPORTION_PLAYGROUND/common/model/Side' ); - var Text = require( 'SCENERY/nodes/Text' ); - var VBox = require( 'SCENERY/nodes/VBox' ); + const HBox = require( 'SCENERY/nodes/HBox' ); + const inherit = require( 'PHET_CORE/inherit' ); + const MutableOptionsNode = require( 'SUN/MutableOptionsNode' ); + const Node = require( 'SCENERY/nodes/Node' ); + const NumberPicker = require( 'SCENERY_PHET/NumberPicker' ); + const Property = require( 'AXON/Property' ); + const proportionPlayground = require( 'PROPORTION_PLAYGROUND/proportionPlayground' ); + const ProportionPlaygroundConstants = require( 'PROPORTION_PLAYGROUND/common/ProportionPlaygroundConstants' ); + const Side = require( 'PROPORTION_PLAYGROUND/common/model/Side' ); + const Text = require( 'SCENERY/nodes/Text' ); + const VBox = require( 'SCENERY/nodes/VBox' ); // Bottom y value in layoutBounds for the pickers var PICKER_BOTTOM = 540; diff --git a/js/common/view/SceneRatioNode.js b/js/common/view/SceneRatioNode.js index b68a9db..0a49695 100644 --- a/js/common/view/SceneRatioNode.js +++ b/js/common/view/SceneRatioNode.js @@ -5,13 +5,13 @@ * * @author Jonathan Olson */ -define( function( require ) { +define( require => { 'use strict'; // modules - var inherit = require( 'PHET_CORE/inherit' ); - var Node = require( 'SCENERY/nodes/Node' ); - var proportionPlayground = require( 'PROPORTION_PLAYGROUND/proportionPlayground' ); + const inherit = require( 'PHET_CORE/inherit' ); + const Node = require( 'SCENERY/nodes/Node' ); + const proportionPlayground = require( 'PROPORTION_PLAYGROUND/proportionPlayground' ); /** * @constructor diff --git a/js/common/view/SceneSelectionControls.js b/js/common/view/SceneSelectionControls.js index 2ab6065..13316fe 100644 --- a/js/common/view/SceneSelectionControls.js +++ b/js/common/view/SceneSelectionControls.js @@ -5,18 +5,18 @@ * * @author Sam Reid (PhET Interactive Simulations) */ -define( function( require ) { +define( require => { 'use strict'; // modules - var AlignBox = require( 'SCENERY/nodes/AlignBox' ); - var AlignGroup = require( 'SCENERY/nodes/AlignGroup' ); - var inherit = require( 'PHET_CORE/inherit' ); - var MutableOptionsNode = require( 'SUN/MutableOptionsNode' ); - var Node = require( 'SCENERY/nodes/Node' ); - var proportionPlayground = require( 'PROPORTION_PLAYGROUND/proportionPlayground' ); - var ProportionPlaygroundColorProfile = require( 'PROPORTION_PLAYGROUND/common/view/ProportionPlaygroundColorProfile' ); - var RadioButtonGroup = require( 'SUN/buttons/RadioButtonGroup' ); + const AlignBox = require( 'SCENERY/nodes/AlignBox' ); + const AlignGroup = require( 'SCENERY/nodes/AlignGroup' ); + const inherit = require( 'PHET_CORE/inherit' ); + const MutableOptionsNode = require( 'SUN/MutableOptionsNode' ); + const Node = require( 'SCENERY/nodes/Node' ); + const proportionPlayground = require( 'PROPORTION_PLAYGROUND/proportionPlayground' ); + const ProportionPlaygroundColorProfile = require( 'PROPORTION_PLAYGROUND/common/view/ProportionPlaygroundColorProfile' ); + const RadioButtonGroup = require( 'SUN/buttons/RadioButtonGroup' ); /** * @constructor diff --git a/js/common/view/TriangleNode.js b/js/common/view/TriangleNode.js index 62e879f..910437a 100644 --- a/js/common/view/TriangleNode.js +++ b/js/common/view/TriangleNode.js @@ -5,16 +5,16 @@ * * @author Sam Reid (PhET Interactive Simulations) */ -define( function( require ) { +define( require => { 'use strict'; // modules - var inherit = require( 'PHET_CORE/inherit' ); - var Matrix3 = require( 'DOT/Matrix3' ); - var Path = require( 'SCENERY/nodes/Path' ); - var proportionPlayground = require( 'PROPORTION_PLAYGROUND/proportionPlayground' ); - var Shape = require( 'KITE/Shape' ); - var Side = require( 'PROPORTION_PLAYGROUND/common/model/Side' ); + const inherit = require( 'PHET_CORE/inherit' ); + const Matrix3 = require( 'DOT/Matrix3' ); + const Path = require( 'SCENERY/nodes/Path' ); + const proportionPlayground = require( 'PROPORTION_PLAYGROUND/proportionPlayground' ); + const Shape = require( 'KITE/Shape' ); + const Side = require( 'PROPORTION_PLAYGROUND/common/model/Side' ); // constants var TRIANGLE_LENGTH = 17; diff --git a/js/common/view/apples/AppleGraphNode.js b/js/common/view/apples/AppleGraphNode.js index 616d3e3..30e3268 100644 --- a/js/common/view/apples/AppleGraphNode.js +++ b/js/common/view/apples/AppleGraphNode.js @@ -6,26 +6,26 @@ * * @author Sam Reid (PhET Interactive Simulations) */ -define( function( require ) { +define( require => { 'use strict'; // modules - var ArrowNode = require( 'SCENERY_PHET/ArrowNode' ); - var inherit = require( 'PHET_CORE/inherit' ); - var Node = require( 'SCENERY/nodes/Node' ); - var Path = require( 'SCENERY/nodes/Path' ); - var Property = require( 'AXON/Property' ); - var proportionPlayground = require( 'PROPORTION_PLAYGROUND/proportionPlayground' ); - var ProportionPlaygroundColorProfile = require( 'PROPORTION_PLAYGROUND/common/view/ProportionPlaygroundColorProfile' ); - var ProportionPlaygroundConstants = require( 'PROPORTION_PLAYGROUND/common/ProportionPlaygroundConstants' ); - var Shape = require( 'KITE/Shape' ); - var Side = require( 'PROPORTION_PLAYGROUND/common/model/Side' ); - var Text = require( 'SCENERY/nodes/Text' ); - var TriangleNode = require( 'PROPORTION_PLAYGROUND/common/view/TriangleNode' ); - var Util = require( 'DOT/Util' ); + const ArrowNode = require( 'SCENERY_PHET/ArrowNode' ); + const inherit = require( 'PHET_CORE/inherit' ); + const Node = require( 'SCENERY/nodes/Node' ); + const Path = require( 'SCENERY/nodes/Path' ); + const Property = require( 'AXON/Property' ); + const proportionPlayground = require( 'PROPORTION_PLAYGROUND/proportionPlayground' ); + const ProportionPlaygroundColorProfile = require( 'PROPORTION_PLAYGROUND/common/view/ProportionPlaygroundColorProfile' ); + const ProportionPlaygroundConstants = require( 'PROPORTION_PLAYGROUND/common/ProportionPlaygroundConstants' ); + const Shape = require( 'KITE/Shape' ); + const Side = require( 'PROPORTION_PLAYGROUND/common/model/Side' ); + const Text = require( 'SCENERY/nodes/Text' ); + const TriangleNode = require( 'PROPORTION_PLAYGROUND/common/view/TriangleNode' ); + const Util = require( 'DOT/Util' ); // strings - var appleCostString = require( 'string!PROPORTION_PLAYGROUND/appleCost' ); + const appleCostString = require( 'string!PROPORTION_PLAYGROUND/appleCost' ); // constants var ARROW_OVERSHOOT = 30; // how far the arrowhead goes past the top tick diff --git a/js/common/view/apples/AppleGroupControl.js b/js/common/view/apples/AppleGroupControl.js index 95fb577..15bb6f7 100644 --- a/js/common/view/apples/AppleGroupControl.js +++ b/js/common/view/apples/AppleGroupControl.js @@ -5,21 +5,21 @@ * * @author Sam Reid (PhET Interactive Simulations) */ -define( function( require ) { +define( require => { 'use strict'; // modules - var AppleGroupNode = require( 'PROPORTION_PLAYGROUND/common/view/apples/AppleGroupNode' ); - var inherit = require( 'PHET_CORE/inherit' ); - var proportionPlayground = require( 'PROPORTION_PLAYGROUND/proportionPlayground' ); - var ProportionPlaygroundColorProfile = require( 'PROPORTION_PLAYGROUND/common/view/ProportionPlaygroundColorProfile' ); - var SceneRatioControl = require( 'PROPORTION_PLAYGROUND/common/view/SceneRatioControl' ); - var StringUtils = require( 'PHETCOMMON/util/StringUtils' ); + const AppleGroupNode = require( 'PROPORTION_PLAYGROUND/common/view/apples/AppleGroupNode' ); + const inherit = require( 'PHET_CORE/inherit' ); + const proportionPlayground = require( 'PROPORTION_PLAYGROUND/proportionPlayground' ); + const ProportionPlaygroundColorProfile = require( 'PROPORTION_PLAYGROUND/common/view/ProportionPlaygroundColorProfile' ); + const SceneRatioControl = require( 'PROPORTION_PLAYGROUND/common/view/SceneRatioControl' ); + const StringUtils = require( 'PHETCOMMON/util/StringUtils' ); // strings - var applesString = require( 'string!PROPORTION_PLAYGROUND/apples' ); - var pricePatternString = require( 'string!PROPORTION_PLAYGROUND/pricePattern' ); - var totalCostString = require( 'string!PROPORTION_PLAYGROUND/totalCost' ); + const applesString = require( 'string!PROPORTION_PLAYGROUND/apples' ); + const pricePatternString = require( 'string!PROPORTION_PLAYGROUND/pricePattern' ); + const totalCostString = require( 'string!PROPORTION_PLAYGROUND/totalCost' ); /** * @constructor diff --git a/js/common/view/apples/AppleGroupNode.js b/js/common/view/apples/AppleGroupNode.js index 237833f..f1037df 100644 --- a/js/common/view/apples/AppleGroupNode.js +++ b/js/common/view/apples/AppleGroupNode.js @@ -5,37 +5,37 @@ * * @author Sam Reid (PhET Interactive Simulations) */ -define( function( require ) { +define( require => { 'use strict'; // modules - var AlignBox = require( 'SCENERY/nodes/AlignBox' ); - var Image = require( 'SCENERY/nodes/Image' ); - var inherit = require( 'PHET_CORE/inherit' ); - var Line = require( 'SCENERY/nodes/Line' ); - var Node = require( 'SCENERY/nodes/Node' ); - var Path = require( 'SCENERY/nodes/Path' ); - var Property = require( 'AXON/Property' ); - var proportionPlayground = require( 'PROPORTION_PLAYGROUND/proportionPlayground' ); - var ProportionPlaygroundColorProfile = require( 'PROPORTION_PLAYGROUND/common/view/ProportionPlaygroundColorProfile' ); - var ProportionPlaygroundConstants = require( 'PROPORTION_PLAYGROUND/common/ProportionPlaygroundConstants' ); - var SceneRatioNode = require( 'PROPORTION_PLAYGROUND/common/view/SceneRatioNode' ); - var Shape = require( 'KITE/Shape' ); - var StringUtils = require( 'PHETCOMMON/util/StringUtils' ); - var Text = require( 'SCENERY/nodes/Text' ); - var Util = require( 'DOT/Util' ); - var VBox = require( 'SCENERY/nodes/VBox' ); - var Vector2 = require( 'DOT/Vector2' ); + const AlignBox = require( 'SCENERY/nodes/AlignBox' ); + const Image = require( 'SCENERY/nodes/Image' ); + const inherit = require( 'PHET_CORE/inherit' ); + const Line = require( 'SCENERY/nodes/Line' ); + const Node = require( 'SCENERY/nodes/Node' ); + const Path = require( 'SCENERY/nodes/Path' ); + const Property = require( 'AXON/Property' ); + const proportionPlayground = require( 'PROPORTION_PLAYGROUND/proportionPlayground' ); + const ProportionPlaygroundColorProfile = require( 'PROPORTION_PLAYGROUND/common/view/ProportionPlaygroundColorProfile' ); + const ProportionPlaygroundConstants = require( 'PROPORTION_PLAYGROUND/common/ProportionPlaygroundConstants' ); + const SceneRatioNode = require( 'PROPORTION_PLAYGROUND/common/view/SceneRatioNode' ); + const Shape = require( 'KITE/Shape' ); + const StringUtils = require( 'PHETCOMMON/util/StringUtils' ); + const Text = require( 'SCENERY/nodes/Text' ); + const Util = require( 'DOT/Util' ); + const VBox = require( 'SCENERY/nodes/VBox' ); + const Vector2 = require( 'DOT/Vector2' ); // images - var coinImage = require( 'mipmap!PROPORTION_PLAYGROUND/coin.png' ); - var crateBackImage = require( 'mipmap!PROPORTION_PLAYGROUND/crate-back.png' ); - var crateFrontImage = require( 'mipmap!PROPORTION_PLAYGROUND/crate-front.png' ); - var redAppleImage = require( 'mipmap!PROPORTION_PLAYGROUND/apple-red.png' ); + const coinImage = require( 'mipmap!PROPORTION_PLAYGROUND/coin.png' ); + const crateBackImage = require( 'mipmap!PROPORTION_PLAYGROUND/crate-back.png' ); + const crateFrontImage = require( 'mipmap!PROPORTION_PLAYGROUND/crate-front.png' ); + const redAppleImage = require( 'mipmap!PROPORTION_PLAYGROUND/apple-red.png' ); // strings - var appleString = require( 'string!PROPORTION_PLAYGROUND/apple' ); - var pricePatternString = require( 'string!PROPORTION_PLAYGROUND/pricePattern' ); + const appleString = require( 'string!PROPORTION_PLAYGROUND/apple' ); + const pricePatternString = require( 'string!PROPORTION_PLAYGROUND/pricePattern' ); // constants var APPLE_IMAGE_SCALE = 0.35; // Reduction factor for showing the image diff --git a/js/common/view/apples/AppleSceneNode.js b/js/common/view/apples/AppleSceneNode.js index 858aefe..e54a327 100644 --- a/js/common/view/apples/AppleSceneNode.js +++ b/js/common/view/apples/AppleSceneNode.js @@ -5,27 +5,27 @@ * * @author Sam Reid (PhET Interactive Simulations) */ -define( function( require ) { +define( require => { 'use strict'; // modules - var AppleGraphNode = require( 'PROPORTION_PLAYGROUND/common/view/apples/AppleGraphNode' ); - var AppleGroupControl = require( 'PROPORTION_PLAYGROUND/common/view/apples/AppleGroupControl' ); - var Checkbox = require( 'SUN/Checkbox' ); - var HBox = require( 'SCENERY/nodes/HBox' ); - var Image = require( 'SCENERY/nodes/Image' ); - var inherit = require( 'PHET_CORE/inherit' ); - var Node = require( 'SCENERY/nodes/Node' ); - var proportionPlayground = require( 'PROPORTION_PLAYGROUND/proportionPlayground' ); - var ProportionPlaygroundConstants = require( 'PROPORTION_PLAYGROUND/common/ProportionPlaygroundConstants' ); - var SceneNode = require( 'PROPORTION_PLAYGROUND/common/view/SceneNode' ); - var Text = require( 'SCENERY/nodes/Text' ); + const AppleGraphNode = require( 'PROPORTION_PLAYGROUND/common/view/apples/AppleGraphNode' ); + const AppleGroupControl = require( 'PROPORTION_PLAYGROUND/common/view/apples/AppleGroupControl' ); + const Checkbox = require( 'SUN/Checkbox' ); + const HBox = require( 'SCENERY/nodes/HBox' ); + const Image = require( 'SCENERY/nodes/Image' ); + const inherit = require( 'PHET_CORE/inherit' ); + const Node = require( 'SCENERY/nodes/Node' ); + const proportionPlayground = require( 'PROPORTION_PLAYGROUND/proportionPlayground' ); + const ProportionPlaygroundConstants = require( 'PROPORTION_PLAYGROUND/common/ProportionPlaygroundConstants' ); + const SceneNode = require( 'PROPORTION_PLAYGROUND/common/view/SceneNode' ); + const Text = require( 'SCENERY/nodes/Text' ); // images - var redAppleImage = require( 'mipmap!PROPORTION_PLAYGROUND/apple-red.png' ); + const redAppleImage = require( 'mipmap!PROPORTION_PLAYGROUND/apple-red.png' ); // strings - var costPerAppleString = require( 'string!PROPORTION_PLAYGROUND/costPerApple' ); + const costPerAppleString = require( 'string!PROPORTION_PLAYGROUND/costPerApple' ); /** * @constructor diff --git a/js/common/view/billiards/BilliardTableIcon.js b/js/common/view/billiards/BilliardTableIcon.js index 03ad3b7..5a775af 100644 --- a/js/common/view/billiards/BilliardTableIcon.js +++ b/js/common/view/billiards/BilliardTableIcon.js @@ -5,15 +5,15 @@ * * @author Sam Reid (PhET Interactive Simulations) */ -define( function( require ) { +define( require => { 'use strict'; // modules - var inherit = require( 'PHET_CORE/inherit' ); - var Node = require( 'SCENERY/nodes/Node' ); - var proportionPlayground = require( 'PROPORTION_PLAYGROUND/proportionPlayground' ); - var ProportionPlaygroundColorProfile = require( 'PROPORTION_PLAYGROUND/common/view/ProportionPlaygroundColorProfile' ); - var Rectangle = require( 'SCENERY/nodes/Rectangle' ); + const inherit = require( 'PHET_CORE/inherit' ); + const Node = require( 'SCENERY/nodes/Node' ); + const proportionPlayground = require( 'PROPORTION_PLAYGROUND/proportionPlayground' ); + const ProportionPlaygroundColorProfile = require( 'PROPORTION_PLAYGROUND/common/view/ProportionPlaygroundColorProfile' ); + const Rectangle = require( 'SCENERY/nodes/Rectangle' ); /** * @constructor diff --git a/js/common/view/billiards/BilliardsPath.js b/js/common/view/billiards/BilliardsPath.js index 7752629..334fa1e 100644 --- a/js/common/view/billiards/BilliardsPath.js +++ b/js/common/view/billiards/BilliardsPath.js @@ -5,16 +5,16 @@ * * @author Jonathan Olson */ -define( function( require ) { +define( require => { 'use strict'; // modules - var inherit = require( 'PHET_CORE/inherit' ); - var Line = require( 'SCENERY/nodes/Line' ); - var Node = require( 'SCENERY/nodes/Node' ); - var proportionPlayground = require( 'PROPORTION_PLAYGROUND/proportionPlayground' ); - var ProportionPlaygroundColorProfile = require( 'PROPORTION_PLAYGROUND/common/view/ProportionPlaygroundColorProfile' ); - var Vector2 = require( 'DOT/Vector2' ); + const inherit = require( 'PHET_CORE/inherit' ); + const Line = require( 'SCENERY/nodes/Line' ); + const Node = require( 'SCENERY/nodes/Node' ); + const proportionPlayground = require( 'PROPORTION_PLAYGROUND/proportionPlayground' ); + const ProportionPlaygroundColorProfile = require( 'PROPORTION_PLAYGROUND/common/view/ProportionPlaygroundColorProfile' ); + const Vector2 = require( 'DOT/Vector2' ); // constants var LINE_OPTIONS = { diff --git a/js/common/view/billiards/BilliardsSceneNode.js b/js/common/view/billiards/BilliardsSceneNode.js index dbfa81c..972a7f2 100644 --- a/js/common/view/billiards/BilliardsSceneNode.js +++ b/js/common/view/billiards/BilliardsSceneNode.js @@ -5,17 +5,17 @@ * * @author Sam Reid (PhET Interactive Simulations) */ -define( function( require ) { +define( require => { 'use strict'; // modules - var BilliardsTableControl = require( 'PROPORTION_PLAYGROUND/common/view/billiards/BilliardsTableControl' ); - var BilliardTableIcon = require( 'PROPORTION_PLAYGROUND/common/view/billiards/BilliardTableIcon' ); - var HBox = require( 'SCENERY/nodes/HBox' ); - var inherit = require( 'PHET_CORE/inherit' ); - var proportionPlayground = require( 'PROPORTION_PLAYGROUND/proportionPlayground' ); - var SceneNode = require( 'PROPORTION_PLAYGROUND/common/view/SceneNode' ); - var Side = require( 'PROPORTION_PLAYGROUND/common/model/Side' ); + const BilliardsTableControl = require( 'PROPORTION_PLAYGROUND/common/view/billiards/BilliardsTableControl' ); + const BilliardTableIcon = require( 'PROPORTION_PLAYGROUND/common/view/billiards/BilliardTableIcon' ); + const HBox = require( 'SCENERY/nodes/HBox' ); + const inherit = require( 'PHET_CORE/inherit' ); + const proportionPlayground = require( 'PROPORTION_PLAYGROUND/proportionPlayground' ); + const SceneNode = require( 'PROPORTION_PLAYGROUND/common/view/SceneNode' ); + const Side = require( 'PROPORTION_PLAYGROUND/common/model/Side' ); // constants var ICON_SCALE_OPTIONS = { scale: 0.3 }; diff --git a/js/common/view/billiards/BilliardsTableControl.js b/js/common/view/billiards/BilliardsTableControl.js index bae81e9..1861f38 100644 --- a/js/common/view/billiards/BilliardsTableControl.js +++ b/js/common/view/billiards/BilliardsTableControl.js @@ -5,22 +5,22 @@ * * @author Sam Reid (PhET Interactive Simulations) */ -define( function( require ) { +define( require => { 'use strict'; // modules - var BilliardsTableNode = require( 'PROPORTION_PLAYGROUND/common/view/billiards/BilliardsTableNode' ); - var HBox = require( 'SCENERY/nodes/HBox' ); - var inherit = require( 'PHET_CORE/inherit' ); - var proportionPlayground = require( 'PROPORTION_PLAYGROUND/proportionPlayground' ); - var ProportionPlaygroundColorProfile = require( 'PROPORTION_PLAYGROUND/common/view/ProportionPlaygroundColorProfile' ); - var SceneRatioControl = require( 'PROPORTION_PLAYGROUND/common/view/SceneRatioControl' ); - var Side = require( 'PROPORTION_PLAYGROUND/common/model/Side' ); - var VBox = require( 'SCENERY/nodes/VBox' ); + const BilliardsTableNode = require( 'PROPORTION_PLAYGROUND/common/view/billiards/BilliardsTableNode' ); + const HBox = require( 'SCENERY/nodes/HBox' ); + const inherit = require( 'PHET_CORE/inherit' ); + const proportionPlayground = require( 'PROPORTION_PLAYGROUND/proportionPlayground' ); + const ProportionPlaygroundColorProfile = require( 'PROPORTION_PLAYGROUND/common/view/ProportionPlaygroundColorProfile' ); + const SceneRatioControl = require( 'PROPORTION_PLAYGROUND/common/view/SceneRatioControl' ); + const Side = require( 'PROPORTION_PLAYGROUND/common/model/Side' ); + const VBox = require( 'SCENERY/nodes/VBox' ); // strings - var lengthString = require( 'string!PROPORTION_PLAYGROUND/length' ); - var widthString = require( 'string!PROPORTION_PLAYGROUND/width' ); + const lengthString = require( 'string!PROPORTION_PLAYGROUND/length' ); + const widthString = require( 'string!PROPORTION_PLAYGROUND/width' ); /** * @constructor diff --git a/js/common/view/billiards/BilliardsTableNode.js b/js/common/view/billiards/BilliardsTableNode.js index 71f3272..4e330db 100644 --- a/js/common/view/billiards/BilliardsTableNode.js +++ b/js/common/view/billiards/BilliardsTableNode.js @@ -7,31 +7,31 @@ * @author Sam Reid (PhET Interactive Simulations) * @author Andrea Lin */ -define( function( require ) { +define( require => { 'use strict'; // modules - var BilliardsPath = require( 'PROPORTION_PLAYGROUND/common/view/billiards/BilliardsPath' ); - var Bounds2 = require( 'DOT/Bounds2' ); - var Circle = require( 'SCENERY/nodes/Circle' ); - var DragListener = require( 'SCENERY/listeners/DragListener' ); - var HBox = require( 'SCENERY/nodes/HBox' ); - var inherit = require( 'PHET_CORE/inherit' ); - var Matrix3 = require( 'DOT/Matrix3' ); - var ModelViewTransform2 = require( 'PHETCOMMON/view/ModelViewTransform2' ); - var MutableOptionsNode = require( 'SUN/MutableOptionsNode' ); - var Node = require( 'SCENERY/nodes/Node' ); - var Path = require( 'SCENERY/nodes/Path' ); - var Property = require( 'AXON/Property' ); - var proportionPlayground = require( 'PROPORTION_PLAYGROUND/proportionPlayground' ); - var ProportionPlaygroundColorProfile = require( 'PROPORTION_PLAYGROUND/common/view/ProportionPlaygroundColorProfile' ); - var ProportionPlaygroundConstants = require( 'PROPORTION_PLAYGROUND/common/ProportionPlaygroundConstants' ); - var Rectangle = require( 'SCENERY/nodes/Rectangle' ); - var SceneRatioNode = require( 'PROPORTION_PLAYGROUND/common/view/SceneRatioNode' ); - var ShadedSphereNode = require( 'SCENERY_PHET/ShadedSphereNode' ); - var Shape = require( 'KITE/Shape' ); - var Util = require( 'DOT/Util' ); - var Vector2 = require( 'DOT/Vector2' ); + const BilliardsPath = require( 'PROPORTION_PLAYGROUND/common/view/billiards/BilliardsPath' ); + const Bounds2 = require( 'DOT/Bounds2' ); + const Circle = require( 'SCENERY/nodes/Circle' ); + const DragListener = require( 'SCENERY/listeners/DragListener' ); + const HBox = require( 'SCENERY/nodes/HBox' ); + const inherit = require( 'PHET_CORE/inherit' ); + const Matrix3 = require( 'DOT/Matrix3' ); + const ModelViewTransform2 = require( 'PHETCOMMON/view/ModelViewTransform2' ); + const MutableOptionsNode = require( 'SUN/MutableOptionsNode' ); + const Node = require( 'SCENERY/nodes/Node' ); + const Path = require( 'SCENERY/nodes/Path' ); + const Property = require( 'AXON/Property' ); + const proportionPlayground = require( 'PROPORTION_PLAYGROUND/proportionPlayground' ); + const ProportionPlaygroundColorProfile = require( 'PROPORTION_PLAYGROUND/common/view/ProportionPlaygroundColorProfile' ); + const ProportionPlaygroundConstants = require( 'PROPORTION_PLAYGROUND/common/ProportionPlaygroundConstants' ); + const Rectangle = require( 'SCENERY/nodes/Rectangle' ); + const SceneRatioNode = require( 'PROPORTION_PLAYGROUND/common/view/SceneRatioNode' ); + const ShadedSphereNode = require( 'SCENERY_PHET/ShadedSphereNode' ); + const Shape = require( 'KITE/Shape' ); + const Util = require( 'DOT/Util' ); + const Vector2 = require( 'DOT/Vector2' ); // constants var MODEL_VIEW_SCALE = 18; diff --git a/js/common/view/necklace/NecklaceControl.js b/js/common/view/necklace/NecklaceControl.js index 29c93a7..cdce37f 100644 --- a/js/common/view/necklace/NecklaceControl.js +++ b/js/common/view/necklace/NecklaceControl.js @@ -5,17 +5,17 @@ * * @author Sam Reid (PhET Interactive Simulations) */ -define( function( require ) { +define( require => { 'use strict'; // modules - var inherit = require( 'PHET_CORE/inherit' ); - var NecklaceNode = require( 'PROPORTION_PLAYGROUND/common/view/necklace/NecklaceNode' ); - var proportionPlayground = require( 'PROPORTION_PLAYGROUND/proportionPlayground' ); - var ProportionPlaygroundColorProfile = require( 'PROPORTION_PLAYGROUND/common/view/ProportionPlaygroundColorProfile' ); - var RoundBeadNode = require( 'PROPORTION_PLAYGROUND/common/view/necklace/RoundBeadNode' ); - var SceneRatioControl = require( 'PROPORTION_PLAYGROUND/common/view/SceneRatioControl' ); - var SquareBeadNode = require( 'PROPORTION_PLAYGROUND/common/view/necklace/SquareBeadNode' ); + const inherit = require( 'PHET_CORE/inherit' ); + const NecklaceNode = require( 'PROPORTION_PLAYGROUND/common/view/necklace/NecklaceNode' ); + const proportionPlayground = require( 'PROPORTION_PLAYGROUND/proportionPlayground' ); + const ProportionPlaygroundColorProfile = require( 'PROPORTION_PLAYGROUND/common/view/ProportionPlaygroundColorProfile' ); + const RoundBeadNode = require( 'PROPORTION_PLAYGROUND/common/view/necklace/RoundBeadNode' ); + const SceneRatioControl = require( 'PROPORTION_PLAYGROUND/common/view/SceneRatioControl' ); + const SquareBeadNode = require( 'PROPORTION_PLAYGROUND/common/view/necklace/SquareBeadNode' ); /** * @constructor diff --git a/js/common/view/necklace/NecklaceGraphicNode.js b/js/common/view/necklace/NecklaceGraphicNode.js index f7befff..712c96e 100644 --- a/js/common/view/necklace/NecklaceGraphicNode.js +++ b/js/common/view/necklace/NecklaceGraphicNode.js @@ -7,20 +7,20 @@ * @author Sam Reid (PhET Interactive Simulations) * @author Andrea Lin */ -define( function( require ) { +define( require => { 'use strict'; // modules - var inherit = require( 'PHET_CORE/inherit' ); - var NecklaceLayout = require( 'PROPORTION_PLAYGROUND/common/model/necklace/NecklaceLayout' ); - var Node = require( 'SCENERY/nodes/Node' ); - var Path = require( 'SCENERY/nodes/Path' ); - var Property = require( 'AXON/Property' ); - var proportionPlayground = require( 'PROPORTION_PLAYGROUND/proportionPlayground' ); - var ProportionPlaygroundColorProfile = require( 'PROPORTION_PLAYGROUND/common/view/ProportionPlaygroundColorProfile' ); - var RoundBeadNode = require( 'PROPORTION_PLAYGROUND/common/view/necklace/RoundBeadNode' ); - var SquareBeadNode = require( 'PROPORTION_PLAYGROUND/common/view/necklace/SquareBeadNode' ); - var Vector2 = require( 'DOT/Vector2' ); + const inherit = require( 'PHET_CORE/inherit' ); + const NecklaceLayout = require( 'PROPORTION_PLAYGROUND/common/model/necklace/NecklaceLayout' ); + const Node = require( 'SCENERY/nodes/Node' ); + const Path = require( 'SCENERY/nodes/Path' ); + const Property = require( 'AXON/Property' ); + const proportionPlayground = require( 'PROPORTION_PLAYGROUND/proportionPlayground' ); + const ProportionPlaygroundColorProfile = require( 'PROPORTION_PLAYGROUND/common/view/ProportionPlaygroundColorProfile' ); + const RoundBeadNode = require( 'PROPORTION_PLAYGROUND/common/view/necklace/RoundBeadNode' ); + const SquareBeadNode = require( 'PROPORTION_PLAYGROUND/common/view/necklace/SquareBeadNode' ); + const Vector2 = require( 'DOT/Vector2' ); /** * @constructor diff --git a/js/common/view/necklace/NecklaceNode.js b/js/common/view/necklace/NecklaceNode.js index 637c3d0..0faa4ea 100644 --- a/js/common/view/necklace/NecklaceNode.js +++ b/js/common/view/necklace/NecklaceNode.js @@ -5,14 +5,14 @@ * * @author Sam Reid (PhET Interactive Simulations) */ -define( function( require ) { +define( require => { 'use strict'; // modules - var inherit = require( 'PHET_CORE/inherit' ); - var NecklaceGraphicNode = require( 'PROPORTION_PLAYGROUND/common/view/necklace/NecklaceGraphicNode' ); - var proportionPlayground = require( 'PROPORTION_PLAYGROUND/proportionPlayground' ); - var SceneRatioNode = require( 'PROPORTION_PLAYGROUND/common/view/SceneRatioNode' ); + const inherit = require( 'PHET_CORE/inherit' ); + const NecklaceGraphicNode = require( 'PROPORTION_PLAYGROUND/common/view/necklace/NecklaceGraphicNode' ); + const proportionPlayground = require( 'PROPORTION_PLAYGROUND/proportionPlayground' ); + const SceneRatioNode = require( 'PROPORTION_PLAYGROUND/common/view/SceneRatioNode' ); /** * @constructor diff --git a/js/common/view/necklace/NecklaceSceneNode.js b/js/common/view/necklace/NecklaceSceneNode.js index 149f9e8..221b97f 100644 --- a/js/common/view/necklace/NecklaceSceneNode.js +++ b/js/common/view/necklace/NecklaceSceneNode.js @@ -5,17 +5,17 @@ * * @author Sam Reid (PhET Interactive Simulations) */ -define( function( require ) { +define( require => { 'use strict'; // modules - var HBox = require( 'SCENERY/nodes/HBox' ); - var inherit = require( 'PHET_CORE/inherit' ); - var NecklaceControl = require( 'PROPORTION_PLAYGROUND/common/view/necklace/NecklaceControl' ); - var NecklaceGraphicNode = require( 'PROPORTION_PLAYGROUND/common/view/necklace/NecklaceGraphicNode' ); - var PatternPanel = require( 'PROPORTION_PLAYGROUND/common/view/necklace/PatternPanel' ); - var proportionPlayground = require( 'PROPORTION_PLAYGROUND/proportionPlayground' ); - var SceneNode = require( 'PROPORTION_PLAYGROUND/common/view/SceneNode' ); + const HBox = require( 'SCENERY/nodes/HBox' ); + const inherit = require( 'PHET_CORE/inherit' ); + const NecklaceControl = require( 'PROPORTION_PLAYGROUND/common/view/necklace/NecklaceControl' ); + const NecklaceGraphicNode = require( 'PROPORTION_PLAYGROUND/common/view/necklace/NecklaceGraphicNode' ); + const PatternPanel = require( 'PROPORTION_PLAYGROUND/common/view/necklace/PatternPanel' ); + const proportionPlayground = require( 'PROPORTION_PLAYGROUND/proportionPlayground' ); + const SceneNode = require( 'PROPORTION_PLAYGROUND/common/view/SceneNode' ); // constants var ICON_OPTIONS = { diff --git a/js/common/view/necklace/PatternNode.js b/js/common/view/necklace/PatternNode.js index cbf373a..846a4c8 100644 --- a/js/common/view/necklace/PatternNode.js +++ b/js/common/view/necklace/PatternNode.js @@ -6,20 +6,20 @@ * * @author Jonathan Olson */ -define( function( require ) { +define( require => { 'use strict'; // modules - var Circle = require( 'SCENERY/nodes/Circle' ); - var inherit = require( 'PHET_CORE/inherit' ); - var Node = require( 'SCENERY/nodes/Node' ); - var Property = require( 'AXON/Property' ); - var proportionPlayground = require( 'PROPORTION_PLAYGROUND/proportionPlayground' ); - var ProportionPlaygroundColorProfile = require( 'PROPORTION_PLAYGROUND/common/view/ProportionPlaygroundColorProfile' ); - var ProportionPlaygroundConstants = require( 'PROPORTION_PLAYGROUND/common/ProportionPlaygroundConstants' ); - var Rectangle = require( 'SCENERY/nodes/Rectangle' ); - var Util = require( 'DOT/Util' ); - var Vector2 = require( 'DOT/Vector2' ); + const Circle = require( 'SCENERY/nodes/Circle' ); + const inherit = require( 'PHET_CORE/inherit' ); + const Node = require( 'SCENERY/nodes/Node' ); + const Property = require( 'AXON/Property' ); + const proportionPlayground = require( 'PROPORTION_PLAYGROUND/proportionPlayground' ); + const ProportionPlaygroundColorProfile = require( 'PROPORTION_PLAYGROUND/common/view/ProportionPlaygroundColorProfile' ); + const ProportionPlaygroundConstants = require( 'PROPORTION_PLAYGROUND/common/ProportionPlaygroundConstants' ); + const Rectangle = require( 'SCENERY/nodes/Rectangle' ); + const Util = require( 'DOT/Util' ); + const Vector2 = require( 'DOT/Vector2' ); // constants var BEAD_SIZE = 9; diff --git a/js/common/view/necklace/PatternPanel.js b/js/common/view/necklace/PatternPanel.js index b2fbfb5..5bfe1f1 100644 --- a/js/common/view/necklace/PatternPanel.js +++ b/js/common/view/necklace/PatternPanel.js @@ -6,25 +6,25 @@ * * @author Jonathan Olson */ -define( function( require ) { +define( require => { 'use strict'; // modules - var AlignBox = require( 'SCENERY/nodes/AlignBox' ); - var inherit = require( 'PHET_CORE/inherit' ); - var Necklace = require( 'PROPORTION_PLAYGROUND/common/model/necklace/Necklace' ); - var Node = require( 'SCENERY/nodes/Node' ); - var Panel = require( 'SUN/Panel' ); - var PatternNode = require( 'PROPORTION_PLAYGROUND/common/view/necklace/PatternNode' ); - var Property = require( 'AXON/Property' ); - var proportionPlayground = require( 'PROPORTION_PLAYGROUND/proportionPlayground' ); - var ProportionPlaygroundColorProfile = require( 'PROPORTION_PLAYGROUND/common/view/ProportionPlaygroundColorProfile' ); - var ProportionPlaygroundConstants = require( 'PROPORTION_PLAYGROUND/common/ProportionPlaygroundConstants' ); - var Side = require( 'PROPORTION_PLAYGROUND/common/model/Side' ); - var Text = require( 'SCENERY/nodes/Text' ); - var VBox = require( 'SCENERY/nodes/VBox' ); + const AlignBox = require( 'SCENERY/nodes/AlignBox' ); + const inherit = require( 'PHET_CORE/inherit' ); + const Necklace = require( 'PROPORTION_PLAYGROUND/common/model/necklace/Necklace' ); + const Node = require( 'SCENERY/nodes/Node' ); + const Panel = require( 'SUN/Panel' ); + const PatternNode = require( 'PROPORTION_PLAYGROUND/common/view/necklace/PatternNode' ); + const Property = require( 'AXON/Property' ); + const proportionPlayground = require( 'PROPORTION_PLAYGROUND/proportionPlayground' ); + const ProportionPlaygroundColorProfile = require( 'PROPORTION_PLAYGROUND/common/view/ProportionPlaygroundColorProfile' ); + const ProportionPlaygroundConstants = require( 'PROPORTION_PLAYGROUND/common/ProportionPlaygroundConstants' ); + const Side = require( 'PROPORTION_PLAYGROUND/common/model/Side' ); + const Text = require( 'SCENERY/nodes/Text' ); + const VBox = require( 'SCENERY/nodes/VBox' ); - var patternString = require( 'string!PROPORTION_PLAYGROUND/pattern' ); + const patternString = require( 'string!PROPORTION_PLAYGROUND/pattern' ); /** * @constructor diff --git a/js/common/view/necklace/RoundBeadNode.js b/js/common/view/necklace/RoundBeadNode.js index 663d3bc..95cee50 100644 --- a/js/common/view/necklace/RoundBeadNode.js +++ b/js/common/view/necklace/RoundBeadNode.js @@ -5,19 +5,19 @@ * * @author Sam Reid (PhET Interactive Simulations) */ -define( function( require ) { +define( require => { 'use strict'; // modules - var Circle = require( 'SCENERY/nodes/Circle' ); - var inherit = require( 'PHET_CORE/inherit' ); - var MutableOptionsNode = require( 'SUN/MutableOptionsNode' ); - var Node = require( 'SCENERY/nodes/Node' ); - var proportionPlayground = require( 'PROPORTION_PLAYGROUND/proportionPlayground' ); - var ProportionPlaygroundColorProfile = require( 'PROPORTION_PLAYGROUND/common/view/ProportionPlaygroundColorProfile' ); - var ProportionPlaygroundConstants = require( 'PROPORTION_PLAYGROUND/common/ProportionPlaygroundConstants' ); - var ShadedSphereNode = require( 'SCENERY_PHET/ShadedSphereNode' ); - var Vector2 = require( 'DOT/Vector2' ); + const Circle = require( 'SCENERY/nodes/Circle' ); + const inherit = require( 'PHET_CORE/inherit' ); + const MutableOptionsNode = require( 'SUN/MutableOptionsNode' ); + const Node = require( 'SCENERY/nodes/Node' ); + const proportionPlayground = require( 'PROPORTION_PLAYGROUND/proportionPlayground' ); + const ProportionPlaygroundColorProfile = require( 'PROPORTION_PLAYGROUND/common/view/ProportionPlaygroundColorProfile' ); + const ProportionPlaygroundConstants = require( 'PROPORTION_PLAYGROUND/common/ProportionPlaygroundConstants' ); + const ShadedSphereNode = require( 'SCENERY_PHET/ShadedSphereNode' ); + const Vector2 = require( 'DOT/Vector2' ); // constants var DIAMETER = ProportionPlaygroundConstants.BEAD_DIAMETER; diff --git a/js/common/view/necklace/SquareBeadNode.js b/js/common/view/necklace/SquareBeadNode.js index 231fade..24e5e1b 100644 --- a/js/common/view/necklace/SquareBeadNode.js +++ b/js/common/view/necklace/SquareBeadNode.js @@ -5,20 +5,20 @@ * * @author Sam Reid (PhET Interactive Simulations) */ -define( function( require ) { +define( require => { 'use strict'; // modules - var DerivedProperty = require( 'AXON/DerivedProperty' ); - var inherit = require( 'PHET_CORE/inherit' ); - var Matrix3 = require( 'DOT/Matrix3' ); - var Node = require( 'SCENERY/nodes/Node' ); - var proportionPlayground = require( 'PROPORTION_PLAYGROUND/proportionPlayground' ); - var ProportionPlaygroundColorProfile = require( 'PROPORTION_PLAYGROUND/common/view/ProportionPlaygroundColorProfile' ); - var ProportionPlaygroundConstants = require( 'PROPORTION_PLAYGROUND/common/ProportionPlaygroundConstants' ); - var RadialGradient = require( 'SCENERY/util/RadialGradient' ); - var Rectangle = require( 'SCENERY/nodes/Rectangle' ); - var Vector2 = require( 'DOT/Vector2' ); + const DerivedProperty = require( 'AXON/DerivedProperty' ); + const inherit = require( 'PHET_CORE/inherit' ); + const Matrix3 = require( 'DOT/Matrix3' ); + const Node = require( 'SCENERY/nodes/Node' ); + const proportionPlayground = require( 'PROPORTION_PLAYGROUND/proportionPlayground' ); + const ProportionPlaygroundColorProfile = require( 'PROPORTION_PLAYGROUND/common/view/ProportionPlaygroundColorProfile' ); + const ProportionPlaygroundConstants = require( 'PROPORTION_PLAYGROUND/common/ProportionPlaygroundConstants' ); + const RadialGradient = require( 'SCENERY/util/RadialGradient' ); + const Rectangle = require( 'SCENERY/nodes/Rectangle' ); + const Vector2 = require( 'DOT/Vector2' ); // constants var DIAMETER = ProportionPlaygroundConstants.BEAD_DIAMETER; diff --git a/js/common/view/paint/GradientIndicatorNode.js b/js/common/view/paint/GradientIndicatorNode.js index f712835..759d3fd 100644 --- a/js/common/view/paint/GradientIndicatorNode.js +++ b/js/common/view/paint/GradientIndicatorNode.js @@ -6,18 +6,18 @@ * * @author Sam Reid (PhET Interactive Simulations) */ -define( function( require ) { +define( require => { 'use strict'; // modules - var inherit = require( 'PHET_CORE/inherit' ); - var Node = require( 'SCENERY/nodes/Node' ); - var PaintChoice = require( 'PROPORTION_PLAYGROUND/common/model/paint/PaintChoice' ); - var PaintChoiceGradientNode = require( 'PROPORTION_PLAYGROUND/common/view/paint/PaintChoiceGradientNode' ); - var Property = require( 'AXON/Property' ); - var proportionPlayground = require( 'PROPORTION_PLAYGROUND/proportionPlayground' ); - var Side = require( 'PROPORTION_PLAYGROUND/common/model/Side' ); - var TriangleNode = require( 'PROPORTION_PLAYGROUND/common/view/TriangleNode' ); + const inherit = require( 'PHET_CORE/inherit' ); + const Node = require( 'SCENERY/nodes/Node' ); + const PaintChoice = require( 'PROPORTION_PLAYGROUND/common/model/paint/PaintChoice' ); + const PaintChoiceGradientNode = require( 'PROPORTION_PLAYGROUND/common/view/paint/PaintChoiceGradientNode' ); + const Property = require( 'AXON/Property' ); + const proportionPlayground = require( 'PROPORTION_PLAYGROUND/proportionPlayground' ); + const Side = require( 'PROPORTION_PLAYGROUND/common/model/Side' ); + const TriangleNode = require( 'PROPORTION_PLAYGROUND/common/view/TriangleNode' ); // constants var GRADIENT_WIDTH = 20; diff --git a/js/common/view/paint/PaintBalloonNode.js b/js/common/view/paint/PaintBalloonNode.js index 4e7c2d9..cfbf239 100644 --- a/js/common/view/paint/PaintBalloonNode.js +++ b/js/common/view/paint/PaintBalloonNode.js @@ -5,34 +5,34 @@ * * @author Jonathan Olson */ -define( function( require ) { +define( require => { 'use strict'; // modules - var Image = require( 'SCENERY/nodes/Image' ); - var inherit = require( 'PHET_CORE/inherit' ); - var Node = require( 'SCENERY/nodes/Node' ); - var PaintChoice = require( 'PROPORTION_PLAYGROUND/common/model/paint/PaintChoice' ); - var proportionPlayground = require( 'PROPORTION_PLAYGROUND/proportionPlayground' ); - var SplotchNode = require( 'PROPORTION_PLAYGROUND/common/view/paint/SplotchNode' ); - var Vector2 = require( 'DOT/Vector2' ); + const Image = require( 'SCENERY/nodes/Image' ); + const inherit = require( 'PHET_CORE/inherit' ); + const Node = require( 'SCENERY/nodes/Node' ); + const PaintChoice = require( 'PROPORTION_PLAYGROUND/common/model/paint/PaintChoice' ); + const proportionPlayground = require( 'PROPORTION_PLAYGROUND/proportionPlayground' ); + const SplotchNode = require( 'PROPORTION_PLAYGROUND/common/view/paint/SplotchNode' ); + const Vector2 = require( 'DOT/Vector2' ); // Balloon images (color and orientation) - var blackBalloon1Image = require( 'mipmap!PROPORTION_PLAYGROUND/black-balloon-1.png' ); - var blackBalloon2Image = require( 'mipmap!PROPORTION_PLAYGROUND/black-balloon-2.png' ); - var blackBalloon3Image = require( 'mipmap!PROPORTION_PLAYGROUND/black-balloon-3.png' ); - var blueBalloon1Image = require( 'mipmap!PROPORTION_PLAYGROUND/blue-balloon-1.png' ); - var blueBalloon2Image = require( 'mipmap!PROPORTION_PLAYGROUND/blue-balloon-2.png' ); - var blueBalloon3Image = require( 'mipmap!PROPORTION_PLAYGROUND/blue-balloon-3.png' ); - var redBalloon1Image = require( 'mipmap!PROPORTION_PLAYGROUND/red-balloon-1.png' ); - var redBalloon2Image = require( 'mipmap!PROPORTION_PLAYGROUND/red-balloon-2.png' ); - var redBalloon3Image = require( 'mipmap!PROPORTION_PLAYGROUND/red-balloon-3.png' ); - var whiteBalloon1Image = require( 'mipmap!PROPORTION_PLAYGROUND/white-balloon-1.png' ); - var whiteBalloon2Image = require( 'mipmap!PROPORTION_PLAYGROUND/white-balloon-2.png' ); - var whiteBalloon3Image = require( 'mipmap!PROPORTION_PLAYGROUND/white-balloon-3.png' ); - var yellowBalloon1Image = require( 'mipmap!PROPORTION_PLAYGROUND/yellow-balloon-1.png' ); - var yellowBalloon2Image = require( 'mipmap!PROPORTION_PLAYGROUND/yellow-balloon-2.png' ); - var yellowBalloon3Image = require( 'mipmap!PROPORTION_PLAYGROUND/yellow-balloon-3.png' ); + const blackBalloon1Image = require( 'mipmap!PROPORTION_PLAYGROUND/black-balloon-1.png' ); + const blackBalloon2Image = require( 'mipmap!PROPORTION_PLAYGROUND/black-balloon-2.png' ); + const blackBalloon3Image = require( 'mipmap!PROPORTION_PLAYGROUND/black-balloon-3.png' ); + const blueBalloon1Image = require( 'mipmap!PROPORTION_PLAYGROUND/blue-balloon-1.png' ); + const blueBalloon2Image = require( 'mipmap!PROPORTION_PLAYGROUND/blue-balloon-2.png' ); + const blueBalloon3Image = require( 'mipmap!PROPORTION_PLAYGROUND/blue-balloon-3.png' ); + const redBalloon1Image = require( 'mipmap!PROPORTION_PLAYGROUND/red-balloon-1.png' ); + const redBalloon2Image = require( 'mipmap!PROPORTION_PLAYGROUND/red-balloon-2.png' ); + const redBalloon3Image = require( 'mipmap!PROPORTION_PLAYGROUND/red-balloon-3.png' ); + const whiteBalloon1Image = require( 'mipmap!PROPORTION_PLAYGROUND/white-balloon-1.png' ); + const whiteBalloon2Image = require( 'mipmap!PROPORTION_PLAYGROUND/white-balloon-2.png' ); + const whiteBalloon3Image = require( 'mipmap!PROPORTION_PLAYGROUND/white-balloon-3.png' ); + const yellowBalloon1Image = require( 'mipmap!PROPORTION_PLAYGROUND/yellow-balloon-1.png' ); + const yellowBalloon2Image = require( 'mipmap!PROPORTION_PLAYGROUND/yellow-balloon-2.png' ); + const yellowBalloon3Image = require( 'mipmap!PROPORTION_PLAYGROUND/yellow-balloon-3.png' ); // Persistent {Vector2} instances, so that we don't churn GC as much var scratchStartVector = new Vector2( 0, 0 ); diff --git a/js/common/view/paint/PaintChoiceGradientNode.js b/js/common/view/paint/PaintChoiceGradientNode.js index 8c2e73a..aecf8cb 100644 --- a/js/common/view/paint/PaintChoiceGradientNode.js +++ b/js/common/view/paint/PaintChoiceGradientNode.js @@ -6,17 +6,17 @@ * @author Sam Reid (PhET Interactive Simulations) * @author Chris Malley (PixelZoom, Inc.) */ -define( function( require ) { +define( require => { 'use strict'; // modules - var DerivedProperty = require( 'AXON/DerivedProperty' ); - var Image = require( 'SCENERY/nodes/Image' ); - var inherit = require( 'PHET_CORE/inherit' ); - var Node = require( 'SCENERY/nodes/Node' ); - var proportionPlayground = require( 'PROPORTION_PLAYGROUND/proportionPlayground' ); - var Rectangle = require( 'SCENERY/nodes/Rectangle' ); - var Util = require( 'DOT/Util' ); + const DerivedProperty = require( 'AXON/DerivedProperty' ); + const Image = require( 'SCENERY/nodes/Image' ); + const inherit = require( 'PHET_CORE/inherit' ); + const Node = require( 'SCENERY/nodes/Node' ); + const proportionPlayground = require( 'PROPORTION_PLAYGROUND/proportionPlayground' ); + const Rectangle = require( 'SCENERY/nodes/Rectangle' ); + const Util = require( 'DOT/Util' ); /** * Rectangle that shows a given spectrum diff --git a/js/common/view/paint/PaintDripNode.js b/js/common/view/paint/PaintDripNode.js index e003c17..92d870f 100644 --- a/js/common/view/paint/PaintDripNode.js +++ b/js/common/view/paint/PaintDripNode.js @@ -5,18 +5,18 @@ * * @author Jonathan Olson */ -define( function( require ) { +define( require => { 'use strict'; // modules - var inherit = require( 'PHET_CORE/inherit' ); - var Node = require( 'SCENERY/nodes/Node' ); - var PaintChoice = require( 'PROPORTION_PLAYGROUND/common/model/paint/PaintChoice' ); - var Path = require( 'SCENERY/nodes/Path' ); - var proportionPlayground = require( 'PROPORTION_PLAYGROUND/proportionPlayground' ); - var ProportionPlaygroundColorProfile = require( 'PROPORTION_PLAYGROUND/common/view/ProportionPlaygroundColorProfile' ); - var Shape = require( 'KITE/Shape' ); - var SplotchNode = require( 'PROPORTION_PLAYGROUND/common/view/paint/SplotchNode' ); + const inherit = require( 'PHET_CORE/inherit' ); + const Node = require( 'SCENERY/nodes/Node' ); + const PaintChoice = require( 'PROPORTION_PLAYGROUND/common/model/paint/PaintChoice' ); + const Path = require( 'SCENERY/nodes/Path' ); + const proportionPlayground = require( 'PROPORTION_PLAYGROUND/proportionPlayground' ); + const ProportionPlaygroundColorProfile = require( 'PROPORTION_PLAYGROUND/common/view/ProportionPlaygroundColorProfile' ); + const Shape = require( 'KITE/Shape' ); + const SplotchNode = require( 'PROPORTION_PLAYGROUND/common/view/paint/SplotchNode' ); // {number} - Area of a single splotch (view coordinates) var SPLOTCH_AREA = SplotchNode.getSingleSplotchArea(); diff --git a/js/common/view/paint/PaintSceneNode.js b/js/common/view/paint/PaintSceneNode.js index 88f408e..f536961 100644 --- a/js/common/view/paint/PaintSceneNode.js +++ b/js/common/view/paint/PaintSceneNode.js @@ -5,29 +5,29 @@ * * @author Sam Reid (PhET Interactive Simulations) */ -define( function( require ) { +define( require => { 'use strict'; // modules - var AlignBox = require( 'SCENERY/nodes/AlignBox' ); - var BooleanProperty = require( 'AXON/BooleanProperty' ); - var GradientIndicatorNode = require( 'PROPORTION_PLAYGROUND/common/view/paint/GradientIndicatorNode' ); - var HBox = require( 'SCENERY/nodes/HBox' ); - var Image = require( 'SCENERY/nodes/Image' ); - var inherit = require( 'PHET_CORE/inherit' ); - var PaintChoice = require( 'PROPORTION_PLAYGROUND/common/model/paint/PaintChoice' ); - var PaintChoiceGradientNode = require( 'PROPORTION_PLAYGROUND/common/view/paint/PaintChoiceGradientNode' ); - var proportionPlayground = require( 'PROPORTION_PLAYGROUND/proportionPlayground' ); - var ProportionPlaygroundConstants = require( 'PROPORTION_PLAYGROUND/common/ProportionPlaygroundConstants' ); - var SceneNode = require( 'PROPORTION_PLAYGROUND/common/view/SceneNode' ); - var Side = require( 'PROPORTION_PLAYGROUND/common/model/Side' ); - var Splotch = require( 'PROPORTION_PLAYGROUND/common/model/paint/Splotch' ); - var SplotchControl = require( 'PROPORTION_PLAYGROUND/common/view/paint/SplotchControl' ); - var SplotchNode = require( 'PROPORTION_PLAYGROUND/common/view/paint/SplotchNode' ); - var VerticalAquaRadioButtonGroup = require( 'SUN/VerticalAquaRadioButtonGroup' ); + const AlignBox = require( 'SCENERY/nodes/AlignBox' ); + const BooleanProperty = require( 'AXON/BooleanProperty' ); + const GradientIndicatorNode = require( 'PROPORTION_PLAYGROUND/common/view/paint/GradientIndicatorNode' ); + const HBox = require( 'SCENERY/nodes/HBox' ); + const Image = require( 'SCENERY/nodes/Image' ); + const inherit = require( 'PHET_CORE/inherit' ); + const PaintChoice = require( 'PROPORTION_PLAYGROUND/common/model/paint/PaintChoice' ); + const PaintChoiceGradientNode = require( 'PROPORTION_PLAYGROUND/common/view/paint/PaintChoiceGradientNode' ); + const proportionPlayground = require( 'PROPORTION_PLAYGROUND/proportionPlayground' ); + const ProportionPlaygroundConstants = require( 'PROPORTION_PLAYGROUND/common/ProportionPlaygroundConstants' ); + const SceneNode = require( 'PROPORTION_PLAYGROUND/common/view/SceneNode' ); + const Side = require( 'PROPORTION_PLAYGROUND/common/model/Side' ); + const Splotch = require( 'PROPORTION_PLAYGROUND/common/model/paint/Splotch' ); + const SplotchControl = require( 'PROPORTION_PLAYGROUND/common/view/paint/SplotchControl' ); + const SplotchNode = require( 'PROPORTION_PLAYGROUND/common/view/paint/SplotchNode' ); + const VerticalAquaRadioButtonGroup = require( 'SUN/VerticalAquaRadioButtonGroup' ); // images - var paintSceneImage = require( 'mipmap!PROPORTION_PLAYGROUND/paint-scene.png' ); + const paintSceneImage = require( 'mipmap!PROPORTION_PLAYGROUND/paint-scene.png' ); // constants var SPLOTCH_ICON_OPTIONS = { diff --git a/js/common/view/paint/SplotchControl.js b/js/common/view/paint/SplotchControl.js index 89c7a19..26baad4 100644 --- a/js/common/view/paint/SplotchControl.js +++ b/js/common/view/paint/SplotchControl.js @@ -5,21 +5,21 @@ * * @author Sam Reid (PhET Interactive Simulations) */ -define( function( require ) { +define( require => { 'use strict'; // modules - var inherit = require( 'PHET_CORE/inherit' ); - var Node = require( 'SCENERY/nodes/Node' ); - var PaintBalloonNode = require( 'PROPORTION_PLAYGROUND/common/view/paint/PaintBalloonNode' ); - var PaintChoice = require( 'PROPORTION_PLAYGROUND/common/model/paint/PaintChoice' ); - var PaintDripNode = require( 'PROPORTION_PLAYGROUND/common/view/paint/PaintDripNode' ); - var proportionPlayground = require( 'PROPORTION_PLAYGROUND/proportionPlayground' ); - var ProportionPlaygroundConstants = require( 'PROPORTION_PLAYGROUND/common/ProportionPlaygroundConstants' ); - var SceneRatioControl = require( 'PROPORTION_PLAYGROUND/common/view/SceneRatioControl' ); - var Side = require( 'PROPORTION_PLAYGROUND/common/model/Side' ); - var SplotchNode = require( 'PROPORTION_PLAYGROUND/common/view/paint/SplotchNode' ); - var Vector2 = require( 'DOT/Vector2' ); + const inherit = require( 'PHET_CORE/inherit' ); + const Node = require( 'SCENERY/nodes/Node' ); + const PaintBalloonNode = require( 'PROPORTION_PLAYGROUND/common/view/paint/PaintBalloonNode' ); + const PaintChoice = require( 'PROPORTION_PLAYGROUND/common/model/paint/PaintChoice' ); + const PaintDripNode = require( 'PROPORTION_PLAYGROUND/common/view/paint/PaintDripNode' ); + const proportionPlayground = require( 'PROPORTION_PLAYGROUND/proportionPlayground' ); + const ProportionPlaygroundConstants = require( 'PROPORTION_PLAYGROUND/common/ProportionPlaygroundConstants' ); + const SceneRatioControl = require( 'PROPORTION_PLAYGROUND/common/view/SceneRatioControl' ); + const Side = require( 'PROPORTION_PLAYGROUND/common/model/Side' ); + const SplotchNode = require( 'PROPORTION_PLAYGROUND/common/view/paint/SplotchNode' ); + const Vector2 = require( 'DOT/Vector2' ); // Used as scratch vectors below var startVector = new Vector2( 0, 0 ); diff --git a/js/common/view/paint/SplotchNode.js b/js/common/view/paint/SplotchNode.js index 639dd7e..088589f 100644 --- a/js/common/view/paint/SplotchNode.js +++ b/js/common/view/paint/SplotchNode.js @@ -5,24 +5,24 @@ * * @author Sam Reid (PhET Interactive Simulations) */ -define( function( require ) { +define( require => { 'use strict'; // modules - var Color = require( 'SCENERY/util/Color' ); - var DerivedProperty = require( 'AXON/DerivedProperty' ); - var inherit = require( 'PHET_CORE/inherit' ); - var Matrix3 = require( 'DOT/Matrix3' ); - var PaintChoice = require( 'PROPORTION_PLAYGROUND/common/model/paint/PaintChoice' ); - var Path = require( 'SCENERY/nodes/Path' ); - var Property = require( 'AXON/Property' ); - var proportionPlayground = require( 'PROPORTION_PLAYGROUND/proportionPlayground' ); - var ProportionPlaygroundColorProfile = require( 'PROPORTION_PLAYGROUND/common/view/ProportionPlaygroundColorProfile' ); - var ProportionPlaygroundConstants = require( 'PROPORTION_PLAYGROUND/common/ProportionPlaygroundConstants' ); - var SceneRatioNode = require( 'PROPORTION_PLAYGROUND/common/view/SceneRatioNode' ); - var Shape = require( 'KITE/Shape' ); - var Util = require( 'DOT/Util' ); - var Vector2 = require( 'DOT/Vector2' ); + const Color = require( 'SCENERY/util/Color' ); + const DerivedProperty = require( 'AXON/DerivedProperty' ); + const inherit = require( 'PHET_CORE/inherit' ); + const Matrix3 = require( 'DOT/Matrix3' ); + const PaintChoice = require( 'PROPORTION_PLAYGROUND/common/model/paint/PaintChoice' ); + const Path = require( 'SCENERY/nodes/Path' ); + const Property = require( 'AXON/Property' ); + const proportionPlayground = require( 'PROPORTION_PLAYGROUND/proportionPlayground' ); + const ProportionPlaygroundColorProfile = require( 'PROPORTION_PLAYGROUND/common/view/ProportionPlaygroundColorProfile' ); + const ProportionPlaygroundConstants = require( 'PROPORTION_PLAYGROUND/common/ProportionPlaygroundConstants' ); + const SceneRatioNode = require( 'PROPORTION_PLAYGROUND/common/view/SceneRatioNode' ); + const Shape = require( 'KITE/Shape' ); + const Util = require( 'DOT/Util' ); + const Vector2 = require( 'DOT/Vector2' ); // {Shape} SVG declaration for the splotch shape. Generated from AI file => cut shape => save svg => cut newlines. var splotchShape = new Shape( 'M175.548,87.46c-2.652,3.387-4.599,8.469-0.975,12.482c3.643,4.034,8.46,1.764,11.977-0.388c6.346-3.881,1.241-0.534,7.13-5.117c7.318-5.694,13.795-4.323,17.793,4.046c2.696,5.641,1.031,8.84-5.098,10.066c-6.174,1.236-12.324,2.588-18.477,3.935c-0.798,0.175-1.777,0.417-2.26,0.981c-1.729,2.027-3.28,4.207-4.898,6.33c2.099,1.585,4.006,4.091,6.334,4.576c6.167,1.285,12.523,1.639,18.786,2.495c1.69,0.231,3.316,0.935,4.972,1.421c0.018,0.477,0.036,0.953,0.055,1.43c-1.242,0.352-2.479,0.725-3.727,1.053c-3.848,1.006-7.85,1.619-11.514,3.084c-4.927,1.969-5.336,4.534-1.449,8.096c9.553,8.754,20.298,14.904,33.725,15.479c3.374,0.144,7.044,1.089,9.9,2.798c1.76,1.053,3.432,4.554,2.963,6.399c-0.497,1.952-3.533,4.455-5.549,4.537c-2.844,0.115-6.529-0.992-8.533-2.938c-9.734-9.449-22.449-11.273-34.711-14.006c-3.004-0.67-6.744,1.183-9.9,2.475c-0.93,0.381-1.852,3.283-1.329,4.232c1.58,2.871,3.353,6.677,5.991,7.706c5.505,2.147,9.01,5.718,10.932,10.843c0.675,1.799-0.443,4.27-0.743,6.434c-2.123-0.378-4.853-0.062-6.239-1.279c-2.684-2.356-4.887-5.404-6.782-8.479c-2.231-3.619-7.937-7.49-11.847-6.582c-5.605,1.302-8.945,3.139-7.575,9.9c0.354,1.75,0.649,3.512,1.175,6.381c-3.296-1.469-5.717-2.611-8.188-3.635c-5.258-2.176-7.522-0.95-7.273,4.535c0.434,9.541,1.814,18.908,7.496,27.066c1.612,2.316,3.164,4.744,4.277,7.321c1.496,3.46,1.539,6.931-2.195,9.223c-3.411,2.094-8.797,1.282-10.66-2.12c-1.455-2.655-2.158-5.877-2.545-8.929c-0.604-4.769,0.077-9.815-1.2-14.345c-0.864-3.066-3.776-6.97-6.483-7.645c-2.082-0.518-6.139,2.859-7.804,5.471c-4.624,7.252-7.462,15.103-5.544,24.145c1.307,6.163-1.352,11.809-5.5,13.854c-4.072,2.008-7.643,0.488-8.096-4.001c-0.308-3.047,0.1-6.363,1.014-9.302c5.025-16.164,4.215-19.184-8.766-29.479c-8.654-6.865-24.182,0.414-33.848,5.763c-0.835,0.461-1.717,0.839-3.248,1.582c0-2.451-0.023-4.336,0.004-6.221c0.084-5.889,3.645-18.248-1.932-20.153c-10.764-3.676-32.707,8.215-43.582,10.267c-1.518,0.286-2.9,2.368-3.939,3.896c-2.844,4.176-7.365,6.137-11.648,4.33c-4.013-1.691-6.356-4.798-5.973-9.4c0.537-6.442,6.281-9.333,12.01-5.535c3.11,2.061,5.361,1.895,8.045-0.062c6.568-4.791,24.639-20.029,30.617-25.468c9.883-8.991,8.709-16.622-2.848-23.353c-2.664-1.551-5.586-2.66-9.576-4.529c2.318-1.109,3.485-1.908,4.771-2.235c3.28-0.832,6.855-2.278,6.137-5.911c-0.542-2.737-3.165-6.37-5.646-7.168c-7.207-2.32-14.805-3.434-22.258-4.98c-3.084-0.639-6.297-0.85-9.259-1.834c-5.11-1.698-6.97-5.312-5.415-9.525c1.588-4.305,5.395-6.268,10.192-4.203c5.632,2.423,10.903,5.688,16.313,8.621c2.339,1.268,4.578,2.728,6.955,3.918c8.732,4.373,11.553,3.791,17.592-3.453c5.058-6.068,5.144-11.299,0.123-18.111c-2.117-2.872-4.467-5.572-6.116-9.473c2.448,0.549,5.005,0.814,7.329,1.692c13.615,5.146,6.604-17.941,4.469-26.97c-0.414-1.751-1.07-4.021-2.15-5.748c-0.941-1.504-3.145-2.355-3.745-3.9c-0.89-2.289-1.644-5.191-0.951-7.349c0.513-1.599,3.644-3.62,5.21-3.325c2.442,0.458,5.031,2.332,6.634,4.344c1.169,1.467,0.438,4.23,1.197,6.244c1.607,4.263,7.323,10.848,8.907,12.201c5.684,4.858,18.543,11.651,23.102,11.607c3.336-0.033,7.303-4.781,6.898-9.233c-0.535-5.883-2.037-11.71-3.5-17.465c-0.938-3.69-2.674-7.169-3.814-10.817c-0.534-1.713-0.792-3.619-0.677-5.406c0.349-5.422,4.169-9.926,8.329-9.66c5.32,0.34,6.951,4.461,7.093,8.758c0.186,5.613-0.306,11.281-0.899,16.884c-0.822,7.767,0.078,14.958,5.357,21.13c2.654,3.102,6.229,5.846,9.891,4.038c2.776-1.371,5.768-5.224,6.043-8.213c0.927-10.071,0.71-20.249,0.875-30.387c0.072-4.454,0.012-8.911,0.012-13.993c0,0,1.56-5.787,9.365-8.598c9.375-3.375,9.625,8.47,9.625,8.47s-0.082,0.642-1.079,4.55c-1.801,7.057-5.226,13.684-7.333,20.683c-2.335,7.757-4.174,15.687-5.741,23.636c-0.446,2.262,0.81,4.858,1.285,7.301c0.784,0.396,1.504,1.409,2.354,1.188c4.289-1.117,13.07-9.568,13.74-9.106c0,1.343-5.031,10.494-4.715,13.927c0.681,7.389,20.323-3.229,30.99-5.562L175.548,87.46z' ); diff --git a/js/explore/ExploreScreen.js b/js/explore/ExploreScreen.js index 4b7df9b..9eb2046 100644 --- a/js/explore/ExploreScreen.js +++ b/js/explore/ExploreScreen.js @@ -5,29 +5,29 @@ * * @author Sam Reid (PhET Interactive Simulations) */ -define( function( require ) { +define( require => { 'use strict'; // modules - var AlignBox = require( 'SCENERY/nodes/AlignBox' ); - var BilliardsTable = require( 'PROPORTION_PLAYGROUND/common/model/billiards/BilliardsTable' ); - var BilliardsTableNode = require( 'PROPORTION_PLAYGROUND/common/view/billiards/BilliardsTableNode' ); - var HBox = require( 'SCENERY/nodes/HBox' ); - var inherit = require( 'PHET_CORE/inherit' ); - var NecklaceGraphicNode = require( 'PROPORTION_PLAYGROUND/common/view/necklace/NecklaceGraphicNode' ); - var Node = require( 'SCENERY/nodes/Node' ); - var PhetFont = require( 'SCENERY_PHET/PhetFont' ); - var ProportionModel = require( 'PROPORTION_PLAYGROUND/common/model/ProportionModel' ); - var proportionPlayground = require( 'PROPORTION_PLAYGROUND/proportionPlayground' ); - var ProportionPlaygroundColorProfile = require( 'PROPORTION_PLAYGROUND/common/view/ProportionPlaygroundColorProfile' ); - var ProportionScreenView = require( 'PROPORTION_PLAYGROUND/common/view/ProportionScreenView' ); - var Rectangle = require( 'SCENERY/nodes/Rectangle' ); - var Screen = require( 'JOIST/Screen' ); - var Text = require( 'SCENERY/nodes/Text' ); - var VBox = require( 'SCENERY/nodes/VBox' ); + const AlignBox = require( 'SCENERY/nodes/AlignBox' ); + const BilliardsTable = require( 'PROPORTION_PLAYGROUND/common/model/billiards/BilliardsTable' ); + const BilliardsTableNode = require( 'PROPORTION_PLAYGROUND/common/view/billiards/BilliardsTableNode' ); + const HBox = require( 'SCENERY/nodes/HBox' ); + const inherit = require( 'PHET_CORE/inherit' ); + const NecklaceGraphicNode = require( 'PROPORTION_PLAYGROUND/common/view/necklace/NecklaceGraphicNode' ); + const Node = require( 'SCENERY/nodes/Node' ); + const PhetFont = require( 'SCENERY_PHET/PhetFont' ); + const ProportionModel = require( 'PROPORTION_PLAYGROUND/common/model/ProportionModel' ); + const proportionPlayground = require( 'PROPORTION_PLAYGROUND/proportionPlayground' ); + const ProportionPlaygroundColorProfile = require( 'PROPORTION_PLAYGROUND/common/view/ProportionPlaygroundColorProfile' ); + const ProportionScreenView = require( 'PROPORTION_PLAYGROUND/common/view/ProportionScreenView' ); + const Rectangle = require( 'SCENERY/nodes/Rectangle' ); + const Screen = require( 'JOIST/Screen' ); + const Text = require( 'SCENERY/nodes/Text' ); + const VBox = require( 'SCENERY/nodes/VBox' ); // strings - var screenExploreString = require( 'string!PROPORTION_PLAYGROUND/screen.explore' ); + const screenExploreString = require( 'string!PROPORTION_PLAYGROUND/screen.explore' ); // constants var HOME_SCREEN_ICON_BOUNDS = Screen.MINIMUM_HOME_SCREEN_ICON_SIZE.toBounds(); diff --git a/js/predict/PredictScreen.js b/js/predict/PredictScreen.js index b8ba14e..42f8186 100644 --- a/js/predict/PredictScreen.js +++ b/js/predict/PredictScreen.js @@ -5,29 +5,29 @@ * * @author Sam Reid (PhET Interactive Simulations) */ -define( function( require ) { +define( require => { 'use strict'; // modules - var AlignBox = require( 'SCENERY/nodes/AlignBox' ); - var inherit = require( 'PHET_CORE/inherit' ); - var Node = require( 'SCENERY/nodes/Node' ); - var PaintChoice = require( 'PROPORTION_PLAYGROUND/common/model/paint/PaintChoice' ); - var PhetFont = require( 'SCENERY_PHET/PhetFont' ); - var Property = require( 'AXON/Property' ); - var ProportionModel = require( 'PROPORTION_PLAYGROUND/common/model/ProportionModel' ); - var proportionPlayground = require( 'PROPORTION_PLAYGROUND/proportionPlayground' ); - var ProportionPlaygroundColorProfile = require( 'PROPORTION_PLAYGROUND/common/view/ProportionPlaygroundColorProfile' ); - var ProportionScreenView = require( 'PROPORTION_PLAYGROUND/common/view/ProportionScreenView' ); - var Rectangle = require( 'SCENERY/nodes/Rectangle' ); - var Screen = require( 'JOIST/Screen' ); - var Splotch = require( 'PROPORTION_PLAYGROUND/common/model/paint/Splotch' ); - var SplotchNode = require( 'PROPORTION_PLAYGROUND/common/view/paint/SplotchNode' ); - var Text = require( 'SCENERY/nodes/Text' ); - var Vector2 = require( 'DOT/Vector2' ); + const AlignBox = require( 'SCENERY/nodes/AlignBox' ); + const inherit = require( 'PHET_CORE/inherit' ); + const Node = require( 'SCENERY/nodes/Node' ); + const PaintChoice = require( 'PROPORTION_PLAYGROUND/common/model/paint/PaintChoice' ); + const PhetFont = require( 'SCENERY_PHET/PhetFont' ); + const Property = require( 'AXON/Property' ); + const ProportionModel = require( 'PROPORTION_PLAYGROUND/common/model/ProportionModel' ); + const proportionPlayground = require( 'PROPORTION_PLAYGROUND/proportionPlayground' ); + const ProportionPlaygroundColorProfile = require( 'PROPORTION_PLAYGROUND/common/view/ProportionPlaygroundColorProfile' ); + const ProportionScreenView = require( 'PROPORTION_PLAYGROUND/common/view/ProportionScreenView' ); + const Rectangle = require( 'SCENERY/nodes/Rectangle' ); + const Screen = require( 'JOIST/Screen' ); + const Splotch = require( 'PROPORTION_PLAYGROUND/common/model/paint/Splotch' ); + const SplotchNode = require( 'PROPORTION_PLAYGROUND/common/view/paint/SplotchNode' ); + const Text = require( 'SCENERY/nodes/Text' ); + const Vector2 = require( 'DOT/Vector2' ); // strings - var screenPredictString = require( 'string!PROPORTION_PLAYGROUND/screen.predict' ); + const screenPredictString = require( 'string!PROPORTION_PLAYGROUND/screen.predict' ); // Our splotch's "visual center" is not in the center of its bounds, so we need to shift the text slightly. var SCREEN_ICON_TEXT_OFFSET = new Vector2( 14, 14 ); diff --git a/js/proportion-playground-main.js b/js/proportion-playground-main.js index a9a1310..2098b8b 100644 --- a/js/proportion-playground-main.js +++ b/js/proportion-playground-main.js @@ -5,17 +5,17 @@ * * @author Sam Reid (PhET Interactive Simulations) */ -define( function( require ) { +define( require => { 'use strict'; // modules - var ExploreScreen = require( 'PROPORTION_PLAYGROUND/explore/ExploreScreen' ); - var PredictScreen = require( 'PROPORTION_PLAYGROUND/predict/PredictScreen' ); - var Sim = require( 'JOIST/Sim' ); - var SimLauncher = require( 'JOIST/SimLauncher' ); + const ExploreScreen = require( 'PROPORTION_PLAYGROUND/explore/ExploreScreen' ); + const PredictScreen = require( 'PROPORTION_PLAYGROUND/predict/PredictScreen' ); + const Sim = require( 'JOIST/Sim' ); + const SimLauncher = require( 'JOIST/SimLauncher' ); // strings - var proportionPlaygroundTitleString = require( 'string!PROPORTION_PLAYGROUND/proportion-playground.title' ); + const proportionPlaygroundTitleString = require( 'string!PROPORTION_PLAYGROUND/proportion-playground.title' ); var simOptions = { credits: { diff --git a/js/proportionPlayground.js b/js/proportionPlayground.js index 80a57be..c3f1225 100644 --- a/js/proportionPlayground.js +++ b/js/proportionPlayground.js @@ -5,11 +5,11 @@ * * @author Sam Reid (PhET Interactive Simulations) */ -define( function( require ) { +define( require => { 'use strict'; // modules - var Namespace = require( 'PHET_CORE/Namespace' ); + const Namespace = require( 'PHET_CORE/Namespace' ); return new Namespace( 'proportionPlayground' ); } );