diff --git a/js/molarity/MolarityA11yStrings.js b/js/molarity/MolarityA11yStrings.js deleted file mode 100644 index 68d2a361..00000000 --- a/js/molarity/MolarityA11yStrings.js +++ /dev/null @@ -1,552 +0,0 @@ -// Copyright 2019, University of Colorado Boulder - -/** - * Single location of all accessibility strings. These strings are not meant to be translatable yet. Rosetta needs - * some work to provide translators with context for these strings, and we want to receive some community feedback - * before these strings are submitted for translation. - * - * @author Michael Kauzmann (PhET Interactive Simulations) - * @author Taylor Want (PhET Interactive Simulations) - */ -define( require => { - 'use strict'; - - // modules - const molarity = require( 'MOLARITY/molarity' ); - - const MolarityA11yStrings = { - of: { - value: 'of' - }, - more: { - capitalized: { - value: 'More' - }, - lowercase: { - value: 'more' - } - }, - less: { - capitalized: { - value: 'Less' - }, - lowercase: { - value: 'less' - } - }, - solute: { - value: 'solute' - }, - soluteAmount: { - value: 'Solute Amount' - }, - solutionVolume: { - value: 'Solution Volume' - }, - beakerSolutionControls: { - value: 'Beaker Solution Controls' - }, - - ////////////////////////// HELP TEXT STRINGS /////////////////////////////// - solutionValuesHelpText: { - value: 'Explore with values shown.' - }, - sliderHelpText: { - value: 'Solute amount and solution volume allow changes to chosen solution.' - }, - soluteComboBoxHelpText: { - value: 'Choose a different solute for beaker.' - }, - - ///////////////////////// KEYBOARD HELP CONTENT SECTION STRINGS /////////////////////////////// - popUpListDescription: { - value: 'Pop up list of solutes with Enter or Space keys' - }, - moveThroughDescription: { - value: 'Move through solutes with Up and Down arrow keys' - }, - changeChooseDescription: { - value: 'Choose solute with Enter key' - }, - closeListDescription: { - value: 'Close list without changing with Esc key' - }, - - ///////////////////////// SCREEN SUMMARY STRINGS /////////////////////////////// - screenSummaryPlayAreaPattern: { - value: 'In the Play Area, you find a beaker containing a solution, and a concentration readout. You can change solute amount, solution volume, and choose from nine different solutes to play with the solution in beaker.' - }, - screenSummaryControlAreaPattern: { - value: 'In the Control Area there is a checkbox to show exact values for amount of solute (in moles), volume of solution (in liters), and concentration (in molar), and a button to reset the sim.' - }, - currentStateOfSimPattern: { - value: 'Currently, beaker {{volume}} of a {{color}} ‬solution containing {{soluteAmount}} {{of}} ‪{{solute}}‬ solute. {{concentrationClause}}.' - }, - currentStateOfSimNoSolutePattern: { - value: 'Currently, beaker {{volume}} of pure water, and contains no {{solute}} solute.' - }, - simInteractionHint: { - value: 'Play with solution in beaker and observe changes to concentration.' - }, - screenSummaryQuantitativeConcentrationPattern: { - value: 'Solution is {{isSaturated}}, and concentration is {{concentration}}' - }, - screenSummaryQualitativeConcentrationPattern: { - value: 'Solution is {{isSaturated}} and {{concentration}}' - }, - pureWater: { - value: 'pure water' - }, - waterFormulaDescription: { - value: 'chemical formula of pure water is H2O' - }, - - // Beaker description strings - beakerHeader: { - value: 'Beaker' - }, - beakerDescriptionPattern: { - value: 'Beaker {{volume}} of a {{solute}} solution. The {{color}} solution:' - }, - beakerDescriptionPureWaterPattern: { - value: 'Beaker {{volume}} of pure water. The {{color}} solution:' - }, - hasZeroConcentration: { - value: 'has zero concentration' - }, - beakerSoluteAmountPattern: { - value: 'contains {{soluteAmount}} {{solute}}' - }, - beakerSaturationPattern: { - value: 'is saturated with {{solids}} solids' - }, - beakerChemicalFormulaPattern: { - value: 'chemical formula of {{solute}} is {{chemicalFormula}}' - }, - beakerConcentrationRangePattern: { - value: 'concentration readout range for this solution 0 to {{maxConcentration}} molar' - }, - - // saturation states - saturated: { - value: 'saturated' - }, - notSaturated: { - value: 'not saturated' - }, - - ///////////////////////// VALUE TEXT STRINGS /////////////////////////////// - // Quantitative value text strings for both volume and solute amount sliders - solutionVolumeAndUnitPattern: { - value: '{{volume}} liters' - }, - hasVolumePattern: { - value: 'has {{volume}} liters' - }, - soluteAmountAndUnitPattern: { - value: '{{soluteAmount}} moles' - }, - quantitativeSaturatedValueTextPattern: { - value: '{{solidsChange}}. {{stillSaturatedClause}}' - }, - quantitativeConcentrationStatePattern: { - value: 'concentration {{concentration}}' - }, - concentrationAndUnit: { - value: '{{concentration}} molar' - }, - - // Qualitative value text strings for both volume and solute amount sliders - qualitativeSaturatedValueTextPattern: { - value: '{{propertyAmountChange}}, {{solidsChange}}. {{stillSaturatedClause}}' - }, - qualitativeVolumeStatePattern: { - value: 'beaker {{volume}}' - }, - qualitativeSoluteAmountStatePattern: { - value: '{{soluteAmount}} {{solute}}' - }, - qualitativeConcentrationStateClausePattern: { - value: ', {{concentration}}' - }, - - ///////////////////////// ALERT STRINGS /////////////////////////////// - // No solute alert - noSoluteAlert: { - value: 'Zero concentration. Solution pure water.' - }, - - // Slider alert patters - quantitativeSliderAlertPattern: { - value: '{{concentrationChange}} at {{concentration}}. {{colorChange}}.' - }, - qualitativeSliderAlertPattern: { - value: '{{quantityChange}}. {{colorChange}}{{stateInfo}}.' - }, - - // Quantity change patterns - volumeChangePattern: { - value: '{{moreLess}} solution' - }, - soluteAmountChangedPattern: { - value: '{{moreLess}} solute' - }, - concentrationChangePattern: { - value: '{{moreLess}} concentrated' - }, - colorChangePattern: { - value: 'Solution {{lighterDarker}}' - }, - lighter: { - value: 'lighter' - }, - darker: { - value: 'darker' - }, - - // Solute changed alert string - soluteChangedUnsaturatedAlertPattern: { - value: '{{color}} solution, {{concentrationClause}}.' - }, - soluteChangedSaturatedAlertPattern: { - value: '{{color}} solution, saturated with {{solids}} solids{{concentrationClause}}.' - }, - soluteChangedQuantitativeConcentrationPattern: { - value: ' at {{concentration}}' - }, - noSoluteAlertQuantitative: { - value: 'Clear solution, pure water at zero moles.' - }, - noSoluteAlertQualitative: { - value: 'Clear solution, pure water with no solute.' - }, - - // New saturation state alerts - atMaxConcentrationPattern: { - value: 'at {{concentration}}' - }, - atMaxConcentrationAlertPattern: { - value: 'At {{concentration}}. Solution darkest.' - }, - saturationReachedAlertPattern: { - value: 'Saturated with {{solids}} solids at {{concentration}}.' - }, - saturationLostQualitativeAlertPattern: { - value: 'No longer saturated. Solution lighter, {{concentration}}.' - }, - saturationLostQuantitativeAlertPattern: { - value: 'No longer saturated at {{concentration}}. Solution lighter.' - }, - - // Saturated solution alert strings - stillSaturatedAlertPattern: { - value: 'Saturated {{withSolids}} {{maxConcentration}}.' - }, - withSolidsAlertPattern: { - value: 'with {{solidAmount}} solids' - }, - solidsChangePattern: { - value: '{{moreLess}} solids' - }, - - // Alert strings for solution values checkbox - solutionValuesCheckedAlert: { - value: 'Moles, litres and concentration values shown.' - }, - solutionValuesUncheckedAlert: { - value: 'Values hidden.' - }, - - ////////////////////////// QUALITATIVE VALUE DESCRIPTION REGIONS ///////////////////////// - // Volume active regions - volumeRegions: { - active: { - isFull: { - value: 'is full' - }, - isNearlyFull: { - value: 'is nearly full' - }, - isOverHalfFull: { - value: 'is over half full' - }, - isHalfFull: { - value: 'is half full' - }, - isUnderHalfFull: { - value: 'is under half full' - }, - isAtLowestAmount: { - value: 'is at lowest amount' - }, - isNearlyEmpty: { - value: 'is nearly empty' - } - }, - passive: { - full: { - value: 'full' - }, - nearlyFull: { - value: 'nearly full' - }, - overHalfFull: { - value: 'over half full' - }, - halfFull: { - value: 'half full' - }, - underHalfFull: { - value: 'under half full' - }, - nearlyEmpty: { - value: 'nearly empty' - }, - atLowestAmount: { - value: 'at lowest amount' - } - } - }, - - // Solute Amount Regions - uppercase - soluteAmountRegions: { - capitalized: { - maxAmountOf: { - value: 'Max amount of' - }, - aLotOf: { - value: 'A lot of' - }, - aBunchOf: { - value: 'A bunch of' - }, - some: { - value: 'Some' - }, - aLowAmountOf: { - value: 'A low amount of' - }, - aLittle: { - value: 'A little' - }, - no: { - value: 'No' - } - }, - lowercase: { - maxAmountOf: { - value: 'max amount of' - }, - aLotOf: { - value: 'a lot of' - }, - aBunchOf: { - value: 'a bunch of' - }, - some: { - value: 'some' - }, - aLowAmountOf: { - value: 'a low amount of' - }, - aLittle: { - value: 'a little' - }, - no: { - value: 'no' - } - } - }, - - // Precipitate Amount regions - precipitateAmountRegions: { - lowercase: { - aCoupleOf: { - value: 'a couple of' - }, - aFew: { - value: 'a few' - }, - some: { - value: 'some' - }, - aBunchOf: { - value: 'a bunch of' - }, - aLotOf: { - value: 'a lot of' - } - }, - capitalized: { - aCoupleOf: { - value: 'A couple of' - }, - aFew: { - value: 'A few' - }, - some: { - value: 'Some' - }, - aBunchOf: { - value: 'A bunch of' - }, - aLotOf: { - value: 'A lot of' - } - } - }, - - // Concentration regions - concentrationRegions: { - active: { - hasZeroConcentration: { - value: 'has zero concentration' - }, - hasLowConcentration: { - value: 'has low concentration' - }, - isSlightlyConcentrated: { - value: 'is slightly concentrated' - }, - isNotVeryConcentrated: { - value: 'is not very concentrated' - }, - isVeryConcentrated: { - value: 'is very concentrated' - }, - isHighlyConcentrated: { - value: 'is highly concentrated' - }, - hasMaxConcentration: { - value: 'has max concentration' - } - }, - passive: { - zeroConcentration: { - value: 'zero concentration' - }, - lowConcentration: { - value: 'low concentration' - }, - slightlyConcentrated: { - value: 'slightly concentrated' - }, - notVeryConcentrated: { - value: 'not very concentrated' - }, - veryConcentrated: { - value: 'very concentrated' - }, - highlyConcentrated: { - value: 'highly concentrated' - }, - maxConcentration: { - value: 'max concentration' - } - } - }, - - // capitalized color strings - soluteColors: { - capitalized: { - red: { - value: 'Red' - }, - pink: { - value: 'Pink' - }, - orange: { - value: 'Orange' - }, - gold: { - value: 'Gold' - }, - yellow: { - value: 'Yellow' - }, - green: { - value: 'Green' - }, - blue: { - value: 'Blue' - }, - purple: { - value: 'Purple' - }, - clear: { - value: 'Clear' - } - }, - lowercase: { - red: { - value: 'red' - }, - pink: { - value: 'pink' - }, - orange: { - value: 'orange' - }, - gold: { - value: 'gold' - }, - yellow: { - value: 'yellow' - }, - green: { - value: 'green' - }, - blue: { - value: 'blue' - }, - purple: { - value: 'purple' - }, - clear: { - value: 'clear' - } - } - }, - - // Lowercase solute names - cobaltIINitrateLowercase: { - value: 'cobalt(II) nitrate' - }, - cobaltChlorideLowercase: { - value: 'cobalt(II) chloride' - }, - copperSulfateLowercase: { - value: 'copper(II) sulfate' - }, - drinkMixLowercase: { - value: 'drink mix' - }, - goldIIIChlorideLowercase: { - value: 'gold(III) chloride' - }, - nickelIIChlorideLowercase: { - value: 'nickel(II) chloride' - }, - potassiumChromateLowercase: { - value: 'potassium chromate' - }, - potassiumDichromateLowercase: { - value: 'potassium dichromate' - }, - potassiumPermanganateLowercase: { - value: 'potassium permanganate' - } - }; - - // TODO: This seems it should be factored out, see https://github.com/phetsims/tasks/issues/917 - if ( phet.chipper.queryParameters.stringTest === 'xss' ) { - for ( const key in MolarityA11yStrings ) { - MolarityA11yStrings[ key ].value += ''; - } - } - - // verify that object is immutable, without the runtime penalty in production code - if ( assert ) { Object.freeze( MolarityA11yStrings ); } - - return molarity.register( 'MolarityA11yStrings', MolarityA11yStrings ); -} ); diff --git a/js/molarity/model/MolarityModel.js b/js/molarity/model/MolarityModel.js index cb8b449f..8a2d232c 100644 --- a/js/molarity/model/MolarityModel.js +++ b/js/molarity/model/MolarityModel.js @@ -13,7 +13,6 @@ define( require => { const Color = require( 'SCENERY/util/Color' ); const inherit = require( 'PHET_CORE/inherit' ); const molarity = require( 'MOLARITY/molarity' ); - const MolarityA11yStrings = require( 'MOLARITY/molarity/MolarityA11yStrings' ); const MolarityConstants = require( 'MOLARITY/molarity/MolarityConstants' ); const MolaritySymbols = require( 'MOLARITY/molarity/MolaritySymbols' ); const Solute = require( 'MOLARITY/molarity/model/Solute' ); @@ -34,35 +33,35 @@ define( require => { // a11y strings // color strings - const soluteColorsLowercaseRedString = MolarityA11yStrings.soluteColors.lowercase.red.value; - const soluteColorsLowercasePinkString = MolarityA11yStrings.soluteColors.lowercase.pink.value; - const soluteColorsLowercaseOrangeString = MolarityA11yStrings.soluteColors.lowercase.orange.value; - const soluteColorsLowercaseGoldString = MolarityA11yStrings.soluteColors.lowercase.gold.value; - const soluteColorsLowercaseYellowString = MolarityA11yStrings.soluteColors.lowercase.yellow.value; - const soluteColorsLowercaseGreenString = MolarityA11yStrings.soluteColors.lowercase.green.value; - const soluteColorsLowercaseBlueString = MolarityA11yStrings.soluteColors.lowercase.blue.value; - const soluteColorsLowercasePurpleString = MolarityA11yStrings.soluteColors.lowercase.purple.value; + const soluteColorsLowercaseRedString = require( 'string!MOLARITY/a11y.soluteColors.lowercase.red' ); + const soluteColorsLowercasePinkString = require( 'string!MOLARITY/a11y.soluteColors.lowercase.pink' ); + const soluteColorsLowercaseOrangeString = require( 'string!MOLARITY/a11y.soluteColors.lowercase.orange' ); + const soluteColorsLowercaseGoldString = require( 'string!MOLARITY/a11y.soluteColors.lowercase.gold' ); + const soluteColorsLowercaseYellowString = require( 'string!MOLARITY/a11y.soluteColors.lowercase.yellow' ); + const soluteColorsLowercaseGreenString = require( 'string!MOLARITY/a11y.soluteColors.lowercase.green' ); + const soluteColorsLowercaseBlueString = require( 'string!MOLARITY/a11y.soluteColors.lowercase.blue' ); + const soluteColorsLowercasePurpleString = require( 'string!MOLARITY/a11y.soluteColors.lowercase.purple' ); // capitalized color strings - const soluteColorsCapitalizedRedString = MolarityA11yStrings.soluteColors.capitalized.red.value; - const soluteColorsCapitalizedPinkString = MolarityA11yStrings.soluteColors.capitalized.pink.value; - const soluteColorsCapitalizedOrangeString = MolarityA11yStrings.soluteColors.capitalized.orange.value; - const soluteColorsCapitalizedGoldString = MolarityA11yStrings.soluteColors.capitalized.gold.value; - const soluteColorsCapitalizedYellowString = MolarityA11yStrings.soluteColors.capitalized.yellow.value; - const soluteColorsCapitalizedGreenString = MolarityA11yStrings.soluteColors.capitalized.green.value; - const soluteColorsCapitalizedPurpleString = MolarityA11yStrings.soluteColors.capitalized.purple.value; - const soluteColorsCapitalizedBlueString = MolarityA11yStrings.soluteColors.capitalized.blue.value; + const soluteColorsCapitalizedRedString = require( 'string!MOLARITY/a11y.soluteColors.capitalized.red' ); + const soluteColorsCapitalizedPinkString = require( 'string!MOLARITY/a11y.soluteColors.capitalized.pink' ); + const soluteColorsCapitalizedOrangeString = require( 'string!MOLARITY/a11y.soluteColors.capitalized.orange' ); + const soluteColorsCapitalizedGoldString = require( 'string!MOLARITY/a11y.soluteColors.capitalized.gold' ); + const soluteColorsCapitalizedYellowString = require( 'string!MOLARITY/a11y.soluteColors.capitalized.yellow' ); + const soluteColorsCapitalizedGreenString = require( 'string!MOLARITY/a11y.soluteColors.capitalized.green' ); + const soluteColorsCapitalizedPurpleString = require( 'string!MOLARITY/a11y.soluteColors.capitalized.purple' ); + const soluteColorsCapitalizedBlueString = require( 'string!MOLARITY/a11y.soluteColors.capitalized.blue' ); // Lowercase solute name strings - const cobaltChlorideLowercaseString = MolarityA11yStrings.cobaltChlorideLowercase.value; - const cobaltIINitrateLowercaseString = MolarityA11yStrings.cobaltIINitrateLowercase.value; - const copperSulfateLowercaseString = MolarityA11yStrings.copperSulfateLowercase.value; - const drinkMixLowercaseString = MolarityA11yStrings.drinkMixLowercase.value; - const goldIIIChlorideLowercaseString = MolarityA11yStrings.goldIIIChlorideLowercase.value; - const nickelIIChlorideLowercaseString = MolarityA11yStrings.nickelIIChlorideLowercase.value; - const potassiumChromateLowercaseString = MolarityA11yStrings.potassiumChromateLowercase.value; - const potassiumDichromateLowercaseString = MolarityA11yStrings.potassiumDichromateLowercase.value; - const potassiumPermanganateLowercaseString = MolarityA11yStrings.potassiumPermanganateLowercase.value; + const cobaltChlorideLowercaseString = require( 'string!MOLARITY/a11y.cobaltChlorideLowercase' ); + const cobaltIINitrateLowercaseString = require( 'string!MOLARITY/a11y.cobaltIINitrateLowercase' ); + const copperSulfateLowercaseString = require( 'string!MOLARITY/a11y.copperSulfateLowercase' ); + const drinkMixLowercaseString = require( 'string!MOLARITY/a11y.drinkMixLowercase' ); + const goldIIIChlorideLowercaseString = require( 'string!MOLARITY/a11y.goldIIIChlorideLowercase' ); + const nickelIIChlorideLowercaseString = require( 'string!MOLARITY/a11y.nickelIIChlorideLowercase' ); + const potassiumChromateLowercaseString = require( 'string!MOLARITY/a11y.potassiumChromateLowercase' ); + const potassiumDichromateLowercaseString = require( 'string!MOLARITY/a11y.potassiumDichromateLowercase' ); + const potassiumPermanganateLowercaseString = require( 'string!MOLARITY/a11y.potassiumPermanganateLowercase' ); // constants const blueStringPair = new StringCasingPair( soluteColorsLowercaseBlueString, soluteColorsCapitalizedBlueString ); diff --git a/js/molarity/view/ConcentrationDisplay.js b/js/molarity/view/ConcentrationDisplay.js index 51dbd85d..e11a801d 100644 --- a/js/molarity/view/ConcentrationDisplay.js +++ b/js/molarity/view/ConcentrationDisplay.js @@ -101,7 +101,7 @@ define( require => { } ); const pointerNode = new PointerNode( solution, concentrationRange, barSize, valuesVisibleProperty, - tandem.createTandem( 'pointerNode') ); + tandem.createTandem( 'pointerNode' ) ); // rendering order this.addChild( titleNode ); @@ -168,12 +168,12 @@ define( require => { const y = 0; const arrowShape = new Shape() .moveTo( x, y ) - .lineTo( x + ARROW_HEAD_HEIGHT, y - (ARROW_HEAD_WIDTH / 2) ) - .lineTo( x + ARROW_HEAD_HEIGHT, y - (ARROW_TAIL_WIDTH / 2) ) - .lineTo( x + ARROW_LENGTH, y - (ARROW_TAIL_WIDTH / 2) ) - .lineTo( x + ARROW_LENGTH, y + (ARROW_TAIL_WIDTH / 2) ) - .lineTo( x + ARROW_HEAD_HEIGHT, y + (ARROW_TAIL_WIDTH / 2) ) - .lineTo( x + ARROW_HEAD_HEIGHT, y + (ARROW_HEAD_WIDTH / 2) ) + .lineTo( x + ARROW_HEAD_HEIGHT, y - ( ARROW_HEAD_WIDTH / 2 ) ) + .lineTo( x + ARROW_HEAD_HEIGHT, y - ( ARROW_TAIL_WIDTH / 2 ) ) + .lineTo( x + ARROW_LENGTH, y - ( ARROW_TAIL_WIDTH / 2 ) ) + .lineTo( x + ARROW_LENGTH, y + ( ARROW_TAIL_WIDTH / 2 ) ) + .lineTo( x + ARROW_HEAD_HEIGHT, y + ( ARROW_TAIL_WIDTH / 2 ) ) + .lineTo( x + ARROW_HEAD_HEIGHT, y + ( ARROW_HEAD_WIDTH / 2 ) ) .close(); // @private diff --git a/js/molarity/view/describers/ConcentrationDescriber.js b/js/molarity/view/describers/ConcentrationDescriber.js index b91ca375..edb97a4f 100644 --- a/js/molarity/view/describers/ConcentrationDescriber.js +++ b/js/molarity/view/describers/ConcentrationDescriber.js @@ -13,43 +13,42 @@ define( require => { // modules const MolarityConstants = require( 'MOLARITY/molarity/MolarityConstants' ); const molarity = require( 'MOLARITY/molarity' ); - const MolarityA11yStrings = require( 'MOLARITY/molarity/MolarityA11yStrings' ); const Util = require( 'DOT/Util' ); const StringUtils = require( 'PHETCOMMON/util/StringUtils' ); // a11y strings - const colorChangePatternString = MolarityA11yStrings.colorChangePattern.value; - const concentrationAndUnitString = MolarityA11yStrings.concentrationAndUnit.value; - const concentrationChangePatternString = MolarityA11yStrings.concentrationChangePattern.value; - const beakerConcentrationRangePatternString = MolarityA11yStrings.beakerConcentrationRangePattern.value; - const qualitativeConcentrationStateClausePatternString = MolarityA11yStrings.qualitativeConcentrationStateClausePattern.value; - const quantitativeConcentrationStatePatternString = MolarityA11yStrings.quantitativeConcentrationStatePattern.value; + const colorChangePatternString = require( 'string!MOLARITY/a11y.colorChangePattern' ); + const concentrationAndUnitString = require( 'string!MOLARITY/a11y.concentrationAndUnit' ); + const concentrationChangePatternString = require( 'string!MOLARITY/a11y.concentrationChangePattern' ); + const beakerConcentrationRangePatternString = require( 'string!MOLARITY/a11y.beakerConcentrationRangePattern' ); + const qualitativeConcentrationStateClausePatternString = require( 'string!MOLARITY/a11y.qualitativeConcentrationStateClausePattern' ); + const quantitativeConcentrationStatePatternString = require( 'string!MOLARITY/a11y.quantitativeConcentrationStatePattern' ); // Concentration region strings - const concentrationRegionsPassiveZeroConcentrationString = MolarityA11yStrings.concentrationRegions.passive.zeroConcentration.value; - const concentrationRegionsPassiveLowConcentrationString = MolarityA11yStrings.concentrationRegions.passive.lowConcentration.value; - const concentrationRegionsPassiveSlightlyConcentratedString = MolarityA11yStrings.concentrationRegions.passive.slightlyConcentrated.value; - const concentrationRegionsPassiveNotVeryConcentratedString = MolarityA11yStrings.concentrationRegions.passive.notVeryConcentrated.value; - const concentrationRegionsPassiveVeryConcentratedString = MolarityA11yStrings.concentrationRegions.passive.veryConcentrated.value; - const concentrationRegionsPassiveHighlyConcentratedString = MolarityA11yStrings.concentrationRegions.passive.highlyConcentrated.value; - const concentrationRegionsPassiveMaxConcentrationString = MolarityA11yStrings.concentrationRegions.passive.maxConcentration.value; + const concentrationRegionsPassiveZeroConcentrationString = require( 'string!MOLARITY/a11y.concentrationRegions.passive.zeroConcentration' ); + const concentrationRegionsPassiveLowConcentrationString = require( 'string!MOLARITY/a11y.concentrationRegions.passive.lowConcentration' ); + const concentrationRegionsPassiveSlightlyConcentratedString = require( 'string!MOLARITY/a11y.concentrationRegions.passive.slightlyConcentrated' ); + const concentrationRegionsPassiveNotVeryConcentratedString = require( 'string!MOLARITY/a11y.concentrationRegions.passive.notVeryConcentrated' ); + const concentrationRegionsPassiveVeryConcentratedString = require( 'string!MOLARITY/a11y.concentrationRegions.passive.veryConcentrated' ); + const concentrationRegionsPassiveHighlyConcentratedString = require( 'string!MOLARITY/a11y.concentrationRegions.passive.highlyConcentrated' ); + const concentrationRegionsPassiveMaxConcentrationString = require( 'string!MOLARITY/a11y.concentrationRegions.passive.maxConcentration' ); // Concentration active region strings - const concentrationRegionsActiveHasZeroConcentrationString = MolarityA11yStrings.concentrationRegions.active.hasZeroConcentration.value; - const concentrationRegionsActiveHasLowConcentrationString = MolarityA11yStrings.concentrationRegions.active.hasLowConcentration.value; - const concentrationRegionsActiveIsSlightlyConcentratedString = MolarityA11yStrings.concentrationRegions.active.isSlightlyConcentrated.value; - const concentrationRegionsActiveIsNotVeryConcentratedString = MolarityA11yStrings.concentrationRegions.active.isNotVeryConcentrated.value; - const concentrationRegionsActiveIsVeryConcentratedString = MolarityA11yStrings.concentrationRegions.active.isVeryConcentrated.value; - const concentrationRegionsActiveIsHighlyConcentratedString = MolarityA11yStrings.concentrationRegions.active.isHighlyConcentrated.value; - const concentrationRegionsActiveHasMaxConcentrationString = MolarityA11yStrings.concentrationRegions.active.hasMaxConcentration.value; + const concentrationRegionsActiveHasZeroConcentrationString = require( 'string!MOLARITY/a11y.concentrationRegions.active.hasZeroConcentration' ); + const concentrationRegionsActiveHasLowConcentrationString = require( 'string!MOLARITY/a11y.concentrationRegions.active.hasLowConcentration' ); + const concentrationRegionsActiveIsSlightlyConcentratedString = require( 'string!MOLARITY/a11y.concentrationRegions.active.isSlightlyConcentrated' ); + const concentrationRegionsActiveIsNotVeryConcentratedString = require( 'string!MOLARITY/a11y.concentrationRegions.active.isNotVeryConcentrated' ); + const concentrationRegionsActiveIsVeryConcentratedString = require( 'string!MOLARITY/a11y.concentrationRegions.active.isVeryConcentrated' ); + const concentrationRegionsActiveIsHighlyConcentratedString = require( 'string!MOLARITY/a11y.concentrationRegions.active.isHighlyConcentrated' ); + const concentrationRegionsActiveHasMaxConcentrationString = require( 'string!MOLARITY/a11y.concentrationRegions.active.hasMaxConcentration' ); // Change strings - const lessCapitalizedString = MolarityA11yStrings.less.capitalized.value; - const lessLowercaseString = MolarityA11yStrings.less.lowercase.value; - const moreCapitalizedString = MolarityA11yStrings.more.capitalized.value; - const moreLowercaseString = MolarityA11yStrings.more.lowercase.value; - const lighterString = MolarityA11yStrings.lighter.value; - const darkerString = MolarityA11yStrings.darker.value; + const lessCapitalizedString = require( 'string!MOLARITY/a11y.less.capitalized' ); + const lessLowercaseString = require( 'string!MOLARITY/a11y.less.lowercase' ); + const moreCapitalizedString = require( 'string!MOLARITY/a11y.more.capitalized' ); + const moreLowercaseString = require( 'string!MOLARITY/a11y.more.lowercase' ); + const lighterString = require( 'string!MOLARITY/a11y.lighter' ); + const darkerString = require( 'string!MOLARITY/a11y.darker' ); // constants const ACTIVE_CONCENTRATION_STRINGS = [ diff --git a/js/molarity/view/describers/PrecipitateAmountDescriber.js b/js/molarity/view/describers/PrecipitateAmountDescriber.js index 70de3b9e..62644b79 100644 --- a/js/molarity/view/describers/PrecipitateAmountDescriber.js +++ b/js/molarity/view/describers/PrecipitateAmountDescriber.js @@ -16,39 +16,38 @@ define( require => { // modules const MolarityConstants = require( 'MOLARITY/molarity/MolarityConstants' ); const molarity = require( 'MOLARITY/molarity' ); - const MolarityA11yStrings = require( 'MOLARITY/molarity/MolarityA11yStrings' ); const Solution = require( 'MOLARITY/molarity/model/Solution' ); const StringUtils = require( 'PHETCOMMON/util/StringUtils' ); // a11y strings - const atMaxConcentrationPatternString = MolarityA11yStrings.atMaxConcentrationPattern.value; - const beakerSaturationPatternString = MolarityA11yStrings.beakerSaturationPattern.value; - const saturationLostQualitativeAlertPatternString = MolarityA11yStrings.saturationLostQualitativeAlertPattern.value; - const saturationLostQuantitativeAlertPatternString = MolarityA11yStrings.saturationLostQuantitativeAlertPattern.value; - const saturationReachedAlertPatternString = MolarityA11yStrings.saturationReachedAlertPattern.value; - const stillSaturatedAlertPatternString = MolarityA11yStrings.stillSaturatedAlertPattern.value; - const withSolidsAlertPatternString = MolarityA11yStrings.withSolidsAlertPattern.value; - const solidsChangePatternString = MolarityA11yStrings.solidsChangePattern.value; + const atMaxConcentrationPatternString = require( 'string!MOLARITY/a11y.atMaxConcentrationPattern' ); + const beakerSaturationPatternString = require( 'string!MOLARITY/a11y.beakerSaturationPattern' ); + const saturationLostQualitativeAlertPatternString = require( 'string!MOLARITY/a11y.saturationLostQualitativeAlertPattern' ); + const saturationLostQuantitativeAlertPatternString = require( 'string!MOLARITY/a11y.saturationLostQuantitativeAlertPattern' ); + const saturationReachedAlertPatternString = require( 'string!MOLARITY/a11y.saturationReachedAlertPattern' ); + const stillSaturatedAlertPatternString = require( 'string!MOLARITY/a11y.stillSaturatedAlertPattern' ); + const withSolidsAlertPatternString = require( 'string!MOLARITY/a11y.withSolidsAlertPattern' ); + const solidsChangePatternString = require( 'string!MOLARITY/a11y.solidsChangePattern' ); // Precipitate Amount capitalized region strings - const precipitateAmountRegionsCapitalizedALotOfString = MolarityA11yStrings.precipitateAmountRegions.capitalized.aLotOf.value; - const precipitateAmountRegionsCapitalizedABunchOfString = MolarityA11yStrings.precipitateAmountRegions.capitalized.aBunchOf.value; - const precipitateAmountRegionsCapitalizedSomeString = MolarityA11yStrings.precipitateAmountRegions.capitalized.some.value; - const precipitateAmountRegionsCapitalizedACoupleOfString = MolarityA11yStrings.precipitateAmountRegions.capitalized.aCoupleOf.value; - const precipitateAmountRegionsCapitalizedAFewString = MolarityA11yStrings.precipitateAmountRegions.capitalized.aFew.value; + const precipitateAmountRegionsCapitalizedALotOfString = require( 'string!MOLARITY/a11y.precipitateAmountRegions.capitalized.aLotOf' ); + const precipitateAmountRegionsCapitalizedABunchOfString = require( 'string!MOLARITY/a11y.precipitateAmountRegions.capitalized.aBunchOf' ); + const precipitateAmountRegionsCapitalizedSomeString = require( 'string!MOLARITY/a11y.precipitateAmountRegions.capitalized.some' ); + const precipitateAmountRegionsCapitalizedACoupleOfString = require( 'string!MOLARITY/a11y.precipitateAmountRegions.capitalized.aCoupleOf' ); + const precipitateAmountRegionsCapitalizedAFewString = require( 'string!MOLARITY/a11y.precipitateAmountRegions.capitalized.aFew' ); // Precipitate Amount lowercase region strings - const precipitateAmountRegionsLowercaseALotOfString = MolarityA11yStrings.precipitateAmountRegions.lowercase.aLotOf.value; - const precipitateAmountRegionsLowercaseABunchOfString = MolarityA11yStrings.precipitateAmountRegions.lowercase.aBunchOf.value; - const precipitateAmountRegionsLowercaseSomeString = MolarityA11yStrings.precipitateAmountRegions.lowercase.some.value; - const precipitateAmountRegionsLowercaseACoupleOfString = MolarityA11yStrings.precipitateAmountRegions.lowercase.aCoupleOf.value; - const precipitateAmountRegionsLowercaseAFewString = MolarityA11yStrings.precipitateAmountRegions.lowercase.aFew.value; + const precipitateAmountRegionsLowercaseALotOfString = require( 'string!MOLARITY/a11y.precipitateAmountRegions.lowercase.aLotOf' ); + const precipitateAmountRegionsLowercaseABunchOfString = require( 'string!MOLARITY/a11y.precipitateAmountRegions.lowercase.aBunchOf' ); + const precipitateAmountRegionsLowercaseSomeString = require( 'string!MOLARITY/a11y.precipitateAmountRegions.lowercase.some' ); + const precipitateAmountRegionsLowercaseACoupleOfString = require( 'string!MOLARITY/a11y.precipitateAmountRegions.lowercase.aCoupleOf' ); + const precipitateAmountRegionsLowercaseAFewString = require( 'string!MOLARITY/a11y.precipitateAmountRegions.lowercase.aFew' ); // Change strings - const lessCapitalizedString = MolarityA11yStrings.less.capitalized.value; - const moreCapitalizedString = MolarityA11yStrings.more.capitalized.value; - const lessLowercaseString = MolarityA11yStrings.less.lowercase.value; - const moreLowercaseString = MolarityA11yStrings.more.lowercase.value; + const lessCapitalizedString = require( 'string!MOLARITY/a11y.less.capitalized' ); + const moreCapitalizedString = require( 'string!MOLARITY/a11y.more.capitalized' ); + const lessLowercaseString = require( 'string!MOLARITY/a11y.less.lowercase' ); + const moreLowercaseString = require( 'string!MOLARITY/a11y.more.lowercase' ); // constants const PRECIPITATE_AMOUNT_STRINGS_CAPITALIZED = [