Skip to content

Commit

Permalink
move TODOs, #552
Browse files Browse the repository at this point in the history
  • Loading branch information
zepumph committed May 19, 2023
1 parent b639294 commit 14c2bb8
Show file tree
Hide file tree
Showing 6 changed files with 25 additions and 25 deletions.
6 changes: 3 additions & 3 deletions js/common/view/describers/BothHandsDescriber.ts
Original file line number Diff line number Diff line change
Expand Up @@ -64,7 +64,7 @@ class BothHandsDescriber {
}
}

// TODO: PatternStringProperty when time, https://github.com/phetsims/ratio-and-proportion/issues/499
// TODO: PatternStringProperty when time, https://github.com/phetsims/ratio-and-proportion/issues/552
return StringUtils.fillIn( ratioDistancePositionContextResponsePatternStringProperty, {
distance: this.handPositionsDescriber.getBothHandsDistance( true, options ),
position: this.getBothHandsPosition()
Expand All @@ -75,7 +75,7 @@ class BothHandsDescriber {
* Similar to getBothHandsContextResponse, but without extra logic for edges and distance-progress.
*/
public getBothHandsDynamicDescription(): string {
// TODO: PatternStringProperty when time, https://github.com/phetsims/ratio-and-proportion/issues/499
// TODO: PatternStringProperty when time, https://github.com/phetsims/ratio-and-proportion/issues/552
return StringUtils.fillIn( ratioDistancePositionContextResponsePatternStringProperty, {
distance: this.handPositionsDescriber.getBothHandsDistance( true, {
distanceResponseType: DistanceResponseType.DISTANCE_REGION
Expand All @@ -95,7 +95,7 @@ class BothHandsDescriber {
const leftPosition = this.handPositionsDescriber.getHandPositionDescription( currentTuple.antecedent, tickMarkView );
const rightPosition = this.handPositionsDescriber.getHandPositionDescription( currentTuple.consequent, tickMarkView );

// TODO: PatternStringProperty when time, https://github.com/phetsims/ratio-and-proportion/issues/499
// TODO: PatternStringProperty when time, https://github.com/phetsims/ratio-and-proportion/issues/552
if ( leftPosition === rightPosition ) {
return StringUtils.fillIn( RatioAndProportionStrings.a11y.bothHands.equalObjectResponseAlertStringProperty, {
inPosition: leftPosition
Expand Down
18 changes: 9 additions & 9 deletions js/common/view/describers/HandPositionsDescriber.ts
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,7 @@ import DistanceResponseType from './DistanceResponseType.js';
import optionize from '../../../../../phet-core/js/optionize.js';
import RatioInputModality from './RatioInputModality.js';

// TODO: Dynamic string support when time, https://github.com/phetsims/ratio-and-proportion/issues/499
// TODO: Dynamic string support when time, https://github.com/phetsims/ratio-and-proportion/issues/552
const DISTANCE_REGIONS_CAPITALIZED = [
RatioAndProportionStrings.a11y.handPosition.distance.capitalized.farthestFromStringProperty.value,
RatioAndProportionStrings.a11y.handPosition.distance.capitalized.extremelyFarFromStringProperty.value,
Expand Down Expand Up @@ -168,14 +168,14 @@ class HandPositionsDescriber {

// semi quantitative description uses ordinal numbers instead of full numbers.
if ( semiQuantitative && typeof tickMarkData.ordinalPosition === 'string' ) {
// TODO: PatternStringProperty when time, https://github.com/phetsims/ratio-and-proportion/issues/499
// TODO: PatternStringProperty when time, https://github.com/phetsims/ratio-and-proportion/issues/552
return StringUtils.fillIn( RatioAndProportionStrings.a11y.tickMark.semiQuantitativeHandPositionPatternStringProperty, {
relativePosition: tickMarkData.relativePosition,
ordinal: tickMarkData.ordinalPosition
} );
}

// TODO: PatternStringProperty when time, https://github.com/phetsims/ratio-and-proportion/issues/499
// TODO: PatternStringProperty when time, https://github.com/phetsims/ratio-and-proportion/issues/552
return StringUtils.fillIn( RatioAndProportionStrings.a11y.tickMark.quantitativeHandPositionPatternStringProperty, {
relativePosition: tickMarkData.relativePosition,
tickMarkPosition: tickMarkData.tickMarkPosition
Expand Down Expand Up @@ -284,13 +284,13 @@ class HandPositionsDescriber {
RatioAndProportionStrings.a11y.leftHandLowerStringProperty :
RatioAndProportionStrings.a11y.rightHandLowerStringProperty;

// TODO: PatternStringProperty when time, https://github.com/phetsims/ratio-and-proportion/issues/499
// TODO: PatternStringProperty when time, https://github.com/phetsims/ratio-and-proportion/issues/552
const distanceResponse = StringUtils.fillIn( RatioAndProportionStrings.a11y.handPosition.distanceOrDistanceProgressClauseStringProperty, {
otherHand: otherHandStringProperty,
distanceOrDistanceProgress: distanceClause
} );

// TODO: PatternStringProperty when time, https://github.com/phetsims/ratio-and-proportion/issues/499
// TODO: PatternStringProperty when time, https://github.com/phetsims/ratio-and-proportion/issues/552
return StringUtils.fillIn( RatioAndProportionStrings.a11y.ratio.distancePositionContextResponseStringProperty, {
distance: distanceResponse,
position: this.getHandPositionDescription( this.ratioTupleProperty.value.getForTerm( ratioTerm ),
Expand Down Expand Up @@ -362,7 +362,7 @@ class HandPositionsDescriber {
fartherString: RatioAndProportionStrings.a11y.handPosition.fartherApartStringProperty.value
} );
if ( distanceProgressPhrase ) {
// TODO: PatternStringProperty when time, https://github.com/phetsims/ratio-and-proportion/issues/499
// TODO: PatternStringProperty when time, https://github.com/phetsims/ratio-and-proportion/issues/552
return StringUtils.fillIn( RatioAndProportionStrings.a11y.bothHands.handsDistanceProgressPatternStringProperty, {
distanceProgress: distanceProgressPhrase
} );
Expand All @@ -376,7 +376,7 @@ class HandPositionsDescriber {
const pattern = capitalized ? RatioAndProportionStrings.a11y.bothHands.handsDistancePatternCapitalizedStringProperty.value :
RatioAndProportionStrings.a11y.bothHands.handsDistancePatternStringProperty.value;

// TODO: PatternStringProperty when time, https://github.com/phetsims/ratio-and-proportion/issues/499
// TODO: PatternStringProperty when time, https://github.com/phetsims/ratio-and-proportion/issues/552
return StringUtils.fillIn( pattern, { distance: distanceRegion } );
}

Expand All @@ -392,7 +392,7 @@ class HandPositionsDescriber {
fartherString: RatioAndProportionStrings.a11y.handPosition.fartherApartStringProperty.value
} );
if ( distanceProgressPhrase ) {
// TODO: PatternStringProperty when time, https://github.com/phetsims/ratio-and-proportion/issues/499
// TODO: PatternStringProperty when time, https://github.com/phetsims/ratio-and-proportion/issues/552
const distanceProgressDescription = StringUtils.fillIn( RatioAndProportionStrings.a11y.bothHands.handsDistanceProgressPatternStringProperty, {
distanceProgress: distanceProgressPhrase
} );
Expand Down Expand Up @@ -531,7 +531,7 @@ class HandPositionsDescriber {
RatioAndProportionStrings.a11y.ratio.bothHandsGoBeyondEdgeContextResponseStringProperty :
RatioAndProportionStrings.a11y.ratio.singleHandGoBeyondEdgeContextResponseStringProperty;

// TODO: PatternStringProperty when time, https://github.com/phetsims/ratio-and-proportion/issues/499
// TODO: PatternStringProperty when time, https://github.com/phetsims/ratio-and-proportion/issues/552
return StringUtils.fillIn( patternStringProperty, {
position: extremityPosition,
hand: handAtEdge,
Expand Down
8 changes: 4 additions & 4 deletions js/common/view/describers/RatioDescriber.ts
Original file line number Diff line number Diff line change
Expand Up @@ -101,21 +101,21 @@ class RatioDescriber {
}

public getProximityToChallengeRatio(): string {
// TODO: PatternStringProperty when time, https://github.com/phetsims/ratio-and-proportion/issues/499
// TODO: PatternStringProperty when time, https://github.com/phetsims/ratio-and-proportion/issues/552
return StringUtils.fillIn( RatioAndProportionStrings.a11y.ratio.proximityToRatioObjectResponseStringProperty, {
proximityToRatio: this.getRatioFitness( false )
} );
}

public getProximityToNewChallengeRatioSentence(): string {
// TODO: PatternStringProperty when time, https://github.com/phetsims/ratio-and-proportion/issues/499
// TODO: PatternStringProperty when time, https://github.com/phetsims/ratio-and-proportion/issues/552
return StringUtils.fillIn( RatioAndProportionStrings.a11y.ratio.proximityToNewRatioPatternStringProperty, {
proximity: this.getRatioFitness( false )
} );
}

public getCurrentChallengeSentence( antecedent: number, consequent: number ): string {
// TODO: PatternStringProperty when time, https://github.com/phetsims/ratio-and-proportion/issues/499
// TODO: PatternStringProperty when time, https://github.com/phetsims/ratio-and-proportion/issues/552
return StringUtils.fillIn( RatioAndProportionStrings.a11y.ratio.currentChallengeStringProperty, {

// for consistency with all values, see https://github.com/phetsims/ratio-and-proportion/issues/283
Expand All @@ -125,7 +125,7 @@ class RatioDescriber {
}

public getTargetRatioChangeAlert( antecedent: number, consequent: number ): string {
// TODO: PatternStringProperty when time, https://github.com/phetsims/ratio-and-proportion/issues/499
// TODO: PatternStringProperty when time, https://github.com/phetsims/ratio-and-proportion/issues/552
return StringUtils.fillIn( RatioAndProportionStrings.a11y.ratio.targetRatioChangedContextResponseStringProperty, {
proximityToRatio: this.getProximityToNewChallengeRatioSentence(),
currentChallenge: this.getCurrentChallengeSentence( antecedent, consequent )
Expand Down
8 changes: 4 additions & 4 deletions js/create/view/CreateScreenSummaryNode.ts
Original file line number Diff line number Diff line change
Expand Up @@ -107,7 +107,7 @@ class CreateScreenSummaryNode extends Node {
}

private getStateOfSim( currentChallenge: TReadOnlyProperty<string> = RatioAndProportionStrings.a11y.create.challengeStringProperty ): string {
// TODO: PatternStringProperty when time, https://github.com/phetsims/ratio-and-proportion/issues/499
// TODO: PatternStringProperty when time, https://github.com/phetsims/ratio-and-proportion/issues/552
return StringUtils.fillIn( RatioAndProportionStrings.a11y.screenSummaryQualitativeStateOfSimStringProperty, {
color: BackgroundColorHandler.getCurrentColorRegion( this.ratioFitnessProperty.value, this.inProportionProperty.value ),
ratioFitness: this.ratioDescriber.getRatioFitness( false ),
Expand All @@ -117,14 +117,14 @@ class CreateScreenSummaryNode extends Node {
}

private getLeftHandState(): string {
// TODO: PatternStringProperty when time, https://github.com/phetsims/ratio-and-proportion/issues/499
// TODO: PatternStringProperty when time, https://github.com/phetsims/ratio-and-proportion/issues/552
return StringUtils.fillIn( RatioAndProportionStrings.a11y.leftHandBulletStringProperty, {
position: this.handPositionsDescriber.getHandPositionDescription( this.ratioTupleProperty.value.antecedent, this.tickMarkViewProperty.value )
} );
}

private getRightHandState(): string {
// TODO: PatternStringProperty when time, https://github.com/phetsims/ratio-and-proportion/issues/499
// TODO: PatternStringProperty when time, https://github.com/phetsims/ratio-and-proportion/issues/552
return StringUtils.fillIn( RatioAndProportionStrings.a11y.rightHandBulletStringProperty, {
position: this.handPositionsDescriber.getHandPositionDescription( this.ratioTupleProperty.value.consequent, this.tickMarkViewProperty.value )
} );
Expand All @@ -140,7 +140,7 @@ class CreateScreenSummaryNode extends Node {
const patternStringProperty = this.myChallengeAccordionBox.expandedProperty.value ?
RatioAndProportionStrings.a11y.detailsButtonWithCurrentChallengePatternStringProperty :
RatioAndProportionStrings.a11y.detailsButtonPatternStringProperty;
// TODO: PatternStringProperty when time, https://github.com/phetsims/ratio-and-proportion/issues/499
// TODO: PatternStringProperty when time, https://github.com/phetsims/ratio-and-proportion/issues/552
return StringUtils.fillIn( patternStringProperty, {
stateOfSim: this.getStateOfSim(),
leftHand: this.getLeftHandState(),
Expand Down
2 changes: 1 addition & 1 deletion js/create/view/TickMarkRangeComboBoxNode.ts
Original file line number Diff line number Diff line change
Expand Up @@ -112,7 +112,7 @@ class TickMarkRangeComboBoxNode extends HBox {
}

private getContextResponse(): string {
// TODO: PatternStringProperty when time, https://github.com/phetsims/ratio-and-proportion/issues/499
// TODO: PatternStringProperty when time, https://github.com/phetsims/ratio-and-proportion/issues/552
return StringUtils.fillIn( RatioAndProportionStrings.a11y.create.tickMarkRangeContextResponseStringProperty, {
range: this.tickMarkRangeMap[ this.tickMarkRangeProperty.value ]
} );
Expand Down
8 changes: 4 additions & 4 deletions js/discover/view/DiscoverScreenSummaryNode.ts
Original file line number Diff line number Diff line change
Expand Up @@ -96,7 +96,7 @@ class DiscoverScreenSummaryNode extends Node {
}

private getStateOfSim(): string {
// TODO: PatternStringProperty when time, https://github.com/phetsims/ratio-and-proportion/issues/499
// TODO: PatternStringProperty when time, https://github.com/phetsims/ratio-and-proportion/issues/552
return StringUtils.fillIn( RatioAndProportionStrings.a11y.screenSummaryQualitativeStateOfSimStringProperty, {
color: BackgroundColorHandler.getCurrentColorRegion( this.ratioFitnessProperty.value, this.inProportionProperty.value ),
ratioFitness: this.ratioDescriber.getRatioFitness( false ),
Expand All @@ -106,21 +106,21 @@ class DiscoverScreenSummaryNode extends Node {
}

private getLeftHandState(): string {
// TODO: PatternStringProperty when time, https://github.com/phetsims/ratio-and-proportion/issues/499
// TODO: PatternStringProperty when time, https://github.com/phetsims/ratio-and-proportion/issues/552
return StringUtils.fillIn( RatioAndProportionStrings.a11y.leftHandBulletStringProperty, {
position: this.handPositionsDescriber.getHandPositionDescription( this.ratioTupleProperty.value.antecedent, this.tickMarkViewProperty.value )
} );
}

private getRightHandState(): string {
// TODO: PatternStringProperty when time, https://github.com/phetsims/ratio-and-proportion/issues/499
// TODO: PatternStringProperty when time, https://github.com/phetsims/ratio-and-proportion/issues/552
return StringUtils.fillIn( RatioAndProportionStrings.a11y.rightHandBulletStringProperty, {
position: this.handPositionsDescriber.getHandPositionDescription( this.ratioTupleProperty.value.consequent, this.tickMarkViewProperty.value )
} );
}

public getDetailsButtonState(): string {
// TODO: PatternStringProperty when time, https://github.com/phetsims/ratio-and-proportion/issues/499
// TODO: PatternStringProperty when time, https://github.com/phetsims/ratio-and-proportion/issues/552
return StringUtils.fillIn( RatioAndProportionStrings.a11y.detailsButtonPatternStringProperty, {
stateOfSim: this.getStateOfSim(),
leftHand: this.getLeftHandState(),
Expand Down

0 comments on commit 14c2bb8

Please sign in to comment.