diff --git a/gravity-and-orbits-strings_en.json b/gravity-and-orbits-strings_en.json index 75cdd423..84de717c 100644 --- a/gravity-and-orbits-strings_en.json +++ b/gravity-and-orbits-strings_en.json @@ -11,9 +11,6 @@ "ourSun": { "value": "Our Sun" }, - "earthDay": { - "value": "Earth Day" - }, "planet": { "value": "Planet" }, @@ -95,9 +92,6 @@ "ourMoon": { "value": "Our Moon" }, - "earthMinute": { - "value": "Earth Minute" - }, "returnObjects": { "value": "Return Objects" }, diff --git a/js/GravityAndOrbitsStrings.ts b/js/GravityAndOrbitsStrings.ts index ce82ea85..04e67574 100644 --- a/js/GravityAndOrbitsStrings.ts +++ b/js/GravityAndOrbitsStrings.ts @@ -19,8 +19,6 @@ type StringsType = { 'earthMassesStringProperty': LinkableProperty; 'ourSun': string; 'ourSunStringProperty': LinkableProperty; - 'earthDay': string; - 'earthDayStringProperty': LinkableProperty; 'planet': string; 'planetStringProperty': LinkableProperty; 'planetMass': string; @@ -77,8 +75,6 @@ type StringsType = { 'pathStringProperty': LinkableProperty; 'ourMoon': string; 'ourMoonStringProperty': LinkableProperty; - 'earthMinute': string; - 'earthMinuteStringProperty': LinkableProperty; 'returnObjects': string; 'returnObjectsStringProperty': LinkableProperty; 'star': string; diff --git a/js/common/SceneFactory.ts b/js/common/SceneFactory.ts index db4e6151..27843a2f 100644 --- a/js/common/SceneFactory.ts +++ b/js/common/SceneFactory.ts @@ -374,14 +374,12 @@ const getSwitchableRenderer = ( image1: string | HTMLImageElement, image2: strin const scaledDays = ( timeProperty: TProperty, tandem: Tandem ) => { return new DerivedProperty( [ timeProperty, - GravityAndOrbitsStrings.earthDayStringProperty, GravityAndOrbitsStrings.earthDaysStringProperty, GravityAndOrbitsStrings.pattern[ '0value' ][ '1unitsStringProperty' ] - ], ( time, earthDayString, earthDaysString, patternString ) => { + ], ( time, earthDaysString, patternString ) => { const value = ( time / GravityAndOrbitsClock.SECONDS_PER_DAY ); const fixedValue = Utils.toFixed( value, 0 ); - const units = ( fixedValue === '1' ) ? earthDayString : earthDaysString; - return StringUtils.format( patternString, fixedValue, units ); + return StringUtils.format( patternString, fixedValue, earthDaysString ); }, { tandem: tandem, phetioValueType: StringIO @@ -395,14 +393,12 @@ const scaledDays = ( timeProperty: TProperty, tandem: Tandem ) => { const formatMinutes = ( timeProperty: TProperty, tandem: Tandem ) => { return new DerivedProperty( [ timeProperty, - GravityAndOrbitsStrings.earthMinuteStringProperty, GravityAndOrbitsStrings.earthMinutesStringProperty, GravityAndOrbitsStrings.pattern[ '0value' ][ '1unitsStringProperty' ] - ], ( time, earthMinuteString, earthMinutesString, patternString ) => { + ], ( time, earthMinutesString, patternString ) => { const value = ( time / SECONDS_PER_MINUTE ); const fixedValue = Utils.toFixed( value, 0 ); - const units = ( fixedValue === '1' ) ? earthMinuteString : earthMinutesString; - return StringUtils.format( patternString, fixedValue, units ); + return StringUtils.format( patternString, fixedValue, earthMinutesString ); }, { tandem: tandem, phetioValueType: StringIO