diff --git a/js/atomic-interactions/model/DualAtomModel.js b/js/atomic-interactions/model/DualAtomModel.js index 41211428..3a80fb2f 100644 --- a/js/atomic-interactions/model/DualAtomModel.js +++ b/js/atomic-interactions/model/DualAtomModel.js @@ -29,7 +29,7 @@ const SLOW_MOTION_TIME_MULTIPLIER = 0.5; const MAX_TIME_STEP = 0.005; // in seconds // valid values in reduced usage scenario -const VALID_ATOM_PAIRS_FOR_REDUCED = [AtomPair.NEON_NEON, AtomPair.ARGON_ARGON, AtomPair.ADJUSTABLE]; +const VALID_ATOM_PAIRS_FOR_REDUCED = [ AtomPair.NEON_NEON, AtomPair.ARGON_ARGON, AtomPair.ADJUSTABLE ]; // threshold used for limiting force to zero to prevent jitter, empirically determined const MIN_FORCE_JITTER_THRESHOLD = 1e-30; @@ -76,7 +76,7 @@ class DualAtomModel { // @public (read-write) - speed at which the model is running this.timeSpeedProperty = new EnumerationProperty( TimeSpeed, TimeSpeed.NORMAL, { - validValues: [TimeSpeed.NORMAL, TimeSpeed.SLOW], + validValues: [ TimeSpeed.NORMAL, TimeSpeed.SLOW ], tandem: tandem.createTandem( 'timeSpeedProperty' ) } ); @@ -145,7 +145,7 @@ class DualAtomModel { // update the LJ potential parameters when the adjustable attraction atom is in use Property.multilink( - [this.atomPairProperty, this.adjustableAtomInteractionStrengthProperty, this.adjustableAtomDiameterProperty], + [ this.atomPairProperty, this.adjustableAtomInteractionStrengthProperty, this.adjustableAtomDiameterProperty ], ( atomPair, interactionStrength, atomDiameter ) => { if ( atomPair === AtomPair.ADJUSTABLE ) { this.setEpsilon( interactionStrength ); diff --git a/js/atomic-interactions/model/ForceDisplayMode.js b/js/atomic-interactions/model/ForceDisplayMode.js index 8d69f2ac..5121a082 100644 --- a/js/atomic-interactions/model/ForceDisplayMode.js +++ b/js/atomic-interactions/model/ForceDisplayMode.js @@ -7,6 +7,6 @@ import Enumeration from '../../../../phet-core/js/Enumeration.js'; import statesOfMatter from '../../statesOfMatter.js'; -const ForceDisplayMode = Enumeration.byKeys( ['COMPONENTS', 'TOTAL', 'HIDDEN'] ); +const ForceDisplayMode = Enumeration.byKeys( [ 'COMPONENTS', 'TOTAL', 'HIDDEN' ] ); statesOfMatter.register( 'ForceDisplayMode', ForceDisplayMode ); export default ForceDisplayMode; \ No newline at end of file diff --git a/js/atomic-interactions/view/ForcesAccordionBox.js b/js/atomic-interactions/view/ForcesAccordionBox.js index 1cd1c7a3..12d8f303 100644 --- a/js/atomic-interactions/view/ForcesAccordionBox.js +++ b/js/atomic-interactions/view/ForcesAccordionBox.js @@ -133,8 +133,8 @@ class ForcesAccordionBox extends AccordionBox { }; // compute the maximum item width - const widestItem = _.maxBy( [hideForcesText, totalForceText, attractiveText, vanderwaalsText, repulsiveText, - electronOverlapText], item => { + const widestItem = _.maxBy( [ hideForcesText, totalForceText, attractiveText, vanderwaalsText, repulsiveText, + electronOverlapText ], item => { return item.label.width + ( ( item.icon ) ? item.icon.width + ICON_PADDING : 0 ); } ); const maxWidth = widestItem.label.width + ( ( widestItem.icon ) ? widestItem.icon.width + ICON_PADDING : 0 ); @@ -143,10 +143,10 @@ class ForcesAccordionBox extends AccordionBox { const createConsistentlySpacedLabel = labelSpec => { if ( labelSpec.icon ) { const strutWidth = maxWidth - labelSpec.label.width - labelSpec.icon.width; - return new HBox( { children: [labelSpec.label, new HStrut( strutWidth ), labelSpec.icon] } ); + return new HBox( { children: [ labelSpec.label, new HStrut( strutWidth ), labelSpec.icon ] } ); } else { - return new HBox( { children: [labelSpec.label] } ); + return new HBox( { children: [ labelSpec.label ] } ); } }; @@ -156,7 +156,7 @@ class ForcesAccordionBox extends AccordionBox { createConsistentlySpacedLabel( attractiveText ), createConsistentlySpacedLabel( vanderwaalsText ), createConsistentlySpacedLabel( repulsiveText ), - createConsistentlySpacedLabel( electronOverlapText )], + createConsistentlySpacedLabel( electronOverlapText ) ], align: 'left' } ); @@ -178,17 +178,17 @@ class ForcesAccordionBox extends AccordionBox { const bracketToTextSpacing = 2; const componentForce = new HBox( { spacing: bracketToTextSpacing, - children: [bracket, componentForceText] + children: [ bracket, componentForceText ] } ); const totalForceStrutWidth = maxWidth - totalForceText.label.width - totalForceText.icon.width + bracket.width + bracketToTextSpacing; const totalForceItem = new HBox( { - children: [totalForceText.label, + children: [ totalForceText.label, new HStrut( totalForceStrutWidth ), - totalForceText.icon] + totalForceText.icon ] } ); - const totalForce = new HBox( { spacing: 2, children: [totalForceItem] } ); - const hideForce = new HBox( { spacing: 2, children: [createConsistentlySpacedLabel( hideForcesText )] } ); + const totalForce = new HBox( { spacing: 2, children: [ totalForceItem ] } ); + const hideForce = new HBox( { spacing: 2, children: [ createConsistentlySpacedLabel( hideForcesText ) ] } ); const radioButtonGroup = new AquaRadioButtonGroup( forcesProperty, diff --git a/js/atomic-interactions/view/PositionMarker.js b/js/atomic-interactions/view/PositionMarker.js index e75d9788..3c806485 100644 --- a/js/atomic-interactions/view/PositionMarker.js +++ b/js/atomic-interactions/view/PositionMarker.js @@ -53,7 +53,7 @@ class PositionMarker extends Node { super( { children: [ haloNode, sphereNode ], tandem: options.tandem, - pickablePropertyPhetioInstrumented:true + pickablePropertyPhetioInstrumented: true } ); // @private diff --git a/js/atomic-interactions/view/ZoomableGridNode.js b/js/atomic-interactions/view/ZoomableGridNode.js index 17f68dcd..7c71facb 100644 --- a/js/atomic-interactions/view/ZoomableGridNode.js +++ b/js/atomic-interactions/view/ZoomableGridNode.js @@ -66,8 +66,8 @@ class ZoomableGridNode extends Node { atomsView.drawPotentialCurve(); }, baseColor: '#FFD333', - magnifyingGlassOptions:{ - glassRadius:8 + magnifyingGlassOptions: { + glassRadius: 8 }, xMargin: 3, yMargin: 3, @@ -88,8 +88,8 @@ class ZoomableGridNode extends Node { atomsView.drawPotentialCurve(); }, baseColor: '#FFD333', - magnifyingGlassOptions:{ - glassRadius:8 + magnifyingGlassOptions: { + glassRadius: 8 }, xMargin: 3, yMargin: 3, diff --git a/js/common/PhaseStateEnum.js b/js/common/PhaseStateEnum.js index 71418c8d..b989cfa4 100644 --- a/js/common/PhaseStateEnum.js +++ b/js/common/PhaseStateEnum.js @@ -7,6 +7,6 @@ import Enumeration from '../../../phet-core/js/Enumeration.js'; import statesOfMatter from '../statesOfMatter.js'; -const PhaseStateEnum = Enumeration.byKeys( ['SOLID', 'LIQUID', 'GAS', 'UNKNOWN'] ); +const PhaseStateEnum = Enumeration.byKeys( [ 'SOLID', 'LIQUID', 'GAS', 'UNKNOWN' ] ); statesOfMatter.register( 'PhaseStateEnum', PhaseStateEnum ); export default PhaseStateEnum; \ No newline at end of file diff --git a/js/common/SubstanceType.js b/js/common/SubstanceType.js index 37504e33..148733e8 100644 --- a/js/common/SubstanceType.js +++ b/js/common/SubstanceType.js @@ -7,6 +7,6 @@ import Enumeration from '../../../phet-core/js/Enumeration.js'; import statesOfMatter from '../statesOfMatter.js'; -const SubstanceType = Enumeration.byKeys( ['NEON', 'ARGON', 'DIATOMIC_OXYGEN', 'WATER', 'ADJUSTABLE_ATOM'] ); +const SubstanceType = Enumeration.byKeys( [ 'NEON', 'ARGON', 'DIATOMIC_OXYGEN', 'WATER', 'ADJUSTABLE_ATOM' ] ); statesOfMatter.register( 'SubstanceType', SubstanceType ); export default SubstanceType; \ No newline at end of file diff --git a/js/common/model/AtomType.js b/js/common/model/AtomType.js index 4565ecaf..7f67e991 100644 --- a/js/common/model/AtomType.js +++ b/js/common/model/AtomType.js @@ -9,7 +9,7 @@ import Enumeration from '../../../../phet-core/js/Enumeration.js'; import statesOfMatter from '../../statesOfMatter.js'; -const AtomType = Enumeration.byKeys( ['NEON', 'ARGON', 'OXYGEN', 'HYDROGEN', 'ADJUSTABLE'] ); +const AtomType = Enumeration.byKeys( [ 'NEON', 'ARGON', 'OXYGEN', 'HYDROGEN', 'ADJUSTABLE' ] ); statesOfMatter.register( 'AtomType', AtomType ); export default AtomType; \ No newline at end of file diff --git a/js/common/view/AtomAndMoleculeIconFactory.js b/js/common/view/AtomAndMoleculeIconFactory.js index 072730a0..65867ec0 100644 --- a/js/common/view/AtomAndMoleculeIconFactory.js +++ b/js/common/view/AtomAndMoleculeIconFactory.js @@ -33,7 +33,7 @@ const AtomAndMoleculeIconFactory = { case SubstanceType.DIATOMIC_OXYGEN: var oxygen1 = new Circle( 5, { fill: SOMConstants.OXYGEN_COLOR } ); var oxygen2 = new Circle( 5, { fill: SOMConstants.OXYGEN_COLOR, left: oxygen1.right - 4 } ); - icon = new Node( { children: [oxygen1, oxygen2] } ); + icon = new Node( { children: [ oxygen1, oxygen2 ] } ); break; case SubstanceType.WATER: @@ -46,7 +46,7 @@ const AtomAndMoleculeIconFactory = { fill: SOMConstants.HYDROGEN_COLOR, stroke: SOMConstants.HYDROGEN_COLOR, bottom: waterOxygen.top + 5, left: waterOxygen.right - 5 } ); - icon = new Node( { children: [waterHydrogen2, waterOxygen, waterHydrogen1] } ); + icon = new Node( { children: [ waterHydrogen2, waterOxygen, waterHydrogen1 ] } ); break; default: diff --git a/js/common/view/CompositeThermometerNode.js b/js/common/view/CompositeThermometerNode.js index 18fb1508..cedc5eb4 100644 --- a/js/common/view/CompositeThermometerNode.js +++ b/js/common/view/CompositeThermometerNode.js @@ -40,7 +40,7 @@ const CELSIUS_TEMPERATURE_RANGE = new Range( const TEMPERATURE_READOUT_FONT = new PhetFont( 11 ); // local enum -const TemperatureUnits = Enumeration.byKeys( ['KELVIN', 'CELSIUS'] ); +const TemperatureUnits = Enumeration.byKeys( [ 'KELVIN', 'CELSIUS' ] ); // clamping the red mercury display at 1000 const MAX_TEMPERATURE_TO_CLAMP_RED_MERCURY = 1000; @@ -88,7 +88,7 @@ class CompositeThermometerNode extends Node { // Property that contains the temperature in degrees Celsius const temperatureInCelsiusProperty = new DerivedProperty( - [multipleParticleModel.temperatureInKelvinProperty], + [ multipleParticleModel.temperatureInKelvinProperty ], temperatureInKelvin => temperatureInKelvin === null ? null : kelvinToCelsius( temperatureInKelvin ) ); @@ -130,7 +130,7 @@ class CompositeThermometerNode extends Node { this.addChild( new VBox( { spacing: 10, - children: [temperatureComboBoxDisplay, thermometerNode], + children: [ temperatureComboBoxDisplay, thermometerNode ], resize: false } ) ); this.addChild( comboBoxListParent ); diff --git a/js/common/view/DialGaugeNode.js b/js/common/view/DialGaugeNode.js index 149907fe..6636a295 100644 --- a/js/common/view/DialGaugeNode.js +++ b/js/common/view/DialGaugeNode.js @@ -112,7 +112,7 @@ class DialGaugeNode extends Node { connectorCollar.centerY = gaugeNode.centerY; connectorCollar.left = gaugeNode.right - 10; const dialComponentsNode = new Node( { - children: [connector, connectorCollar, gaugeNode, readoutNode] + children: [ connector, connectorCollar, gaugeNode, readoutNode ] } ); diff --git a/js/common/view/GlobalOptionsNode.js b/js/common/view/GlobalOptionsNode.js index a4bbf642..6f378a87 100644 --- a/js/common/view/GlobalOptionsNode.js +++ b/js/common/view/GlobalOptionsNode.js @@ -27,7 +27,7 @@ class GlobalOptionsNode extends VBox { // VBox is used to make it easy to add additional options super( { - children: [projectorModeCheckbox], + children: [ projectorModeCheckbox ], spacing: OptionsDialog.DEFAULT_SPACING, align: 'left' } ); diff --git a/js/common/view/PointingHandNode.js b/js/common/view/PointingHandNode.js index 84bfe19b..a7aaeda0 100644 --- a/js/common/view/PointingHandNode.js +++ b/js/common/view/PointingHandNode.js @@ -66,7 +66,7 @@ class PointingHandNode extends Node { pointingHandImageNode.scale( WIDTH / pointingHandImageNode.width ); const hintNode = new Node( { - children: [upArrowNode, downArrowNode], + children: [ upArrowNode, downArrowNode ], visible: false, top: pointingHandImageNode.bottom - 50, // adjusted a bit for better look left: pointingHandImageNode.right - 20 // adjusted a bit for better look diff --git a/js/common/view/SOMColorProfile.js b/js/common/view/SOMColorProfile.js index fc85fa6f..17a5743c 100644 --- a/js/common/view/SOMColorProfile.js +++ b/js/common/view/SOMColorProfile.js @@ -16,7 +16,7 @@ import statesOfMatter from '../../statesOfMatter.js'; // constants const GRAY = new Color( 230, 230, 230 ); -const SOMColorProfile = new ColorProfile( ['default', 'projector'], { +const SOMColorProfile = new ColorProfile( [ 'default', 'projector' ], { background: { default: 'black', projector: 'white' diff --git a/js/common/view/SubstanceSelectorNode.js b/js/common/view/SubstanceSelectorNode.js index 08940a0b..13bcaefa 100644 --- a/js/common/view/SubstanceSelectorNode.js +++ b/js/common/view/SubstanceSelectorNode.js @@ -26,7 +26,7 @@ class SubstanceSelectorNode extends HBox { stroke: Color.TRANSPARENT // it can be helpful during debugging to changes this to a visible color } ); super( { - children: [label, spacer, icon] + children: [ label, spacer, icon ] } ); // resize the spacer if the label size changes diff --git a/js/phase-changes/PhaseChangesModel.js b/js/phase-changes/PhaseChangesModel.js index 00e4d043..1c55d6bc 100644 --- a/js/phase-changes/PhaseChangesModel.js +++ b/js/phase-changes/PhaseChangesModel.js @@ -76,7 +76,7 @@ class PhaseChangesModel extends MultipleParticleModel { } ); // @public (read-only) - a derived property that indicates whether the lid is higher than the injection point - this.lidAboveInjectionPointProperty = new DerivedProperty( [this.containerHeightProperty], containerHeight => { + this.lidAboveInjectionPointProperty = new DerivedProperty( [ this.containerHeightProperty ], containerHeight => { // This may appear a little suspect, but the model is designed such that the container height is always reset // to its max when the particle diameter and injection change, so this can be trusted. diff --git a/js/phase-changes/view/InteractionPotentialAccordionBox.js b/js/phase-changes/view/InteractionPotentialAccordionBox.js index e1ed092e..c53899bb 100644 --- a/js/phase-changes/view/InteractionPotentialAccordionBox.js +++ b/js/phase-changes/view/InteractionPotentialAccordionBox.js @@ -51,7 +51,7 @@ class InteractionPotentialAccordionBox extends AccordionBox { accordionContent.addChild( graph.interactionPotentialCanvasNode ); accordionContent.addChild( graph.ljPotentialGraph ); - const accordionContentHBox = new HBox( { children: [accordionContent] } ); + const accordionContentHBox = new HBox( { children: [ accordionContent ] } ); const titleNode = new Text( interactionPotentialString, { fill: SOMColorProfile.controlPanelTextProperty, font: new PhetFont( { size: 13 } ) diff --git a/js/states/StatesIcon.js b/js/states/StatesIcon.js index 627e15af..527a6dc1 100644 --- a/js/states/StatesIcon.js +++ b/js/states/StatesIcon.js @@ -34,7 +34,7 @@ class StatesIcon extends ScreenIcon { // icons packed into a nice little box const iconsBox = new HBox( { - children: [new Image( solidIconImage ), new Image( liquidIconImage ), new Image( gasIconImage )], + children: [ new Image( solidIconImage ), new Image( liquidIconImage ), new Image( gasIconImage ) ], spacing: 20, // empirically determined maxWidth: options.size.width, centerX: options.size.width / 2, @@ -43,7 +43,7 @@ class StatesIcon extends ScreenIcon { const iconRootNode = new Rectangle( 0, 0, options.size.width, options.size.height, 0, 0, { fill: Color.BLACK, - children: [iconsBox] + children: [ iconsBox ] } ); super( iconRootNode, options ); diff --git a/js/states/view/StatesMoleculesControlPanel.js b/js/states/view/StatesMoleculesControlPanel.js index 759fed61..138b6afc 100644 --- a/js/states/view/StatesMoleculesControlPanel.js +++ b/js/states/view/StatesMoleculesControlPanel.js @@ -115,7 +115,7 @@ class StatesMoleculesControlPanel extends Node { } else { return new HBox( { - children: [selectionNodeSpec.label] + children: [ selectionNodeSpec.label ] } ); } }; @@ -160,7 +160,7 @@ class StatesMoleculesControlPanel extends Node { // create the background for the title - initial size is arbitrary, it will be sized and positioned below const titleBackground = new Rectangle( 0, 0, 1, 1, { fill: options.fill } ); - this.addChild( new Node( { children: [titleBackground, title] } ) ); + this.addChild( new Node( { children: [ titleBackground, title ] } ) ); // closure for updating the title background size and overall position const updateTitle = () => { diff --git a/js/states/view/StatesPhaseControlNode.js b/js/states/view/StatesPhaseControlNode.js index 2cd7d210..8e32bbfd 100644 --- a/js/states/view/StatesPhaseControlNode.js +++ b/js/states/view/StatesPhaseControlNode.js @@ -146,7 +146,7 @@ class StatesPhaseControlNode extends Node { // put the buttons together in a single VBox const buttons = new VBox( { - children: [solidStateButton, liquidStateButton, gasStateButton], + children: [ solidStateButton, liquidStateButton, gasStateButton ], spacing: 10, align: 'center' } ); diff --git a/js/states/view/StatesScreenView.js b/js/states/view/StatesScreenView.js index a9c8e220..2af65889 100644 --- a/js/states/view/StatesScreenView.js +++ b/js/states/view/StatesScreenView.js @@ -80,7 +80,7 @@ class StatesScreenView extends ScreenView { // control when the heater/cooler node is enabled for input Property.multilink( - [multipleParticleModel.isPlayingProperty, multipleParticleModel.isExplodedProperty], + [ multipleParticleModel.isPlayingProperty, multipleParticleModel.isExplodedProperty ], ( isPlaying, isExploded ) => { if ( !isPlaying || isExploded ) { heaterCoolerNode.interruptSubtreeInput(); // cancel interaction