-
Notifications
You must be signed in to change notification settings - Fork 5
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Create DecayEquationView.ts and return the decayLikelihoodPercent alo…
…ng with the decayType information in AtomIdentifier.js. See #46.
- Loading branch information
Showing
5 changed files
with
46 additions
and
7 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,30 @@ | ||
// Copyright 2023, University of Colorado Boulder | ||
|
||
import buildANucleus from '../../buildANucleus.js'; | ||
import DecayEquationModel from '../model/DecayEquationModel.js'; | ||
import BuildANucleusStrings from '../../BuildANucleusStrings.js'; | ||
import StringUtils from '../../../../phetcommon/js/util/StringUtils.js'; | ||
import AtomIdentifier from '../../../../shred/js/AtomIdentifier.js'; | ||
import { Text } from '../../../../scenery/js/imports.js'; | ||
|
||
/** | ||
* Node that represents the view of a decay equation. | ||
* | ||
* @author Luisa Vargas | ||
* @author Marla Schulz (PhET Interactive Simulations) | ||
*/ | ||
|
||
class DecayEquationView { | ||
|
||
public constructor( decayEquationModel: DecayEquationModel ) { | ||
|
||
const mostLikelyDecayString = new Text( StringUtils.fillIn( BuildANucleusStrings.mostLikelyDecayPattern, { | ||
decayLikelihoodPercent: AtomIdentifier.getAvailableDecaysAndPercents() | ||
} ) ); | ||
console.log( mostLikelyDecayString ); | ||
|
||
} | ||
} | ||
|
||
buildANucleus.register( 'DecayEquationView', DecayEquationView ); | ||
export default DecayEquationView; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters