Skip to content

Commit

Permalink
make image imports match file names, phetsims/chipper#1060
Browse files Browse the repository at this point in the history
  • Loading branch information
pixelzoom committed Aug 12, 2021
1 parent 772b351 commit fbb7ee9
Show file tree
Hide file tree
Showing 7 changed files with 55 additions and 55 deletions.
20 changes: 10 additions & 10 deletions js/basics/model/AnimalsScene.js
Original file line number Diff line number Diff line change
Expand Up @@ -7,12 +7,12 @@
*/

import Image from '../../../../scenery/js/nodes/Image.js';
import catImage from '../../../images/cat_png.js';
import catShadowImage from '../../../images/catShadow_png.js';
import dogImage from '../../../images/dog_png.js';
import dogShadowImage from '../../../images/dogShadow_png.js';
import turtleImage from '../../../images/turtle_png.js';
import turtleShadowImage from '../../../images/turtleShadow_png.js';
import cat_png from '../../../images/cat_png.js';
import catShadow_png from '../../../images/catShadow_png.js';
import dog_png from '../../../images/dog_png.js';
import dogShadow_png from '../../../images/dogShadow_png.js';
import turtle_png from '../../../images/turtle_png.js';
import turtleShadow_png from '../../../images/turtleShadow_png.js';
import EqualityExplorerConstants from '../../common/EqualityExplorerConstants.js';
import equalityExplorer from '../../equalityExplorer.js';
import BasicsScene from './BasicsScene.js';
Expand All @@ -25,17 +25,17 @@ class AnimalsScene extends BasicsScene {
const variables = [

// name, image, shadow
new ObjectVariable( 'dog', dogImage, dogShadowImage, { value: 11 } ),
new ObjectVariable( 'cat', catImage, catShadowImage, { value: 4 } ),
new ObjectVariable( 'turtle', turtleImage, turtleShadowImage, { value: 6 } )
new ObjectVariable( 'dog', dog_png, dogShadow_png, { value: 11 } ),
new ObjectVariable( 'cat', cat_png, catShadow_png, { value: 4 } ),
new ObjectVariable( 'turtle', turtle_png, turtleShadow_png, { value: 6 } )
];

super( variables, {

debugName: 'animals',

// icon used to represent this scene in the scene control (radio buttons)
icon: new Image( turtleImage, {
icon: new Image( turtle_png, {
maxHeight: EqualityExplorerConstants.SMALL_TERM_DIAMETER
} ),

Expand Down
20 changes: 10 additions & 10 deletions js/basics/model/CoinsScene.js
Original file line number Diff line number Diff line change
Expand Up @@ -7,12 +7,12 @@
*/

import Image from '../../../../scenery/js/nodes/Image.js';
import coin1Image from '../../../images/coin1_png.js';
import coin1ShadowImage from '../../../images/coin1Shadow_png.js';
import coin2Image from '../../../images/coin2_png.js';
import coin2ShadowImage from '../../../images/coin2Shadow_png.js';
import coin3Image from '../../../images/coin3_png.js';
import coin3ShadowImage from '../../../images/coin3Shadow_png.js';
import coin1_png from '../../../images/coin1_png.js';
import coin1Shadow_png from '../../../images/coin1Shadow_png.js';
import coin2_png from '../../../images/coin2_png.js';
import coin2Shadow_png from '../../../images/coin2Shadow_png.js';
import coin3_png from '../../../images/coin3_png.js';
import coin3Shadow_png from '../../../images/coin3Shadow_png.js';
import EqualityExplorerConstants from '../../common/EqualityExplorerConstants.js';
import equalityExplorer from '../../equalityExplorer.js';
import BasicsScene from './BasicsScene.js';
Expand All @@ -25,17 +25,17 @@ class CoinsScene extends BasicsScene {
const variables = [

// name, image, shadow
new ObjectVariable( 'coin1', coin1Image, coin1ShadowImage, { value: 3 } ),
new ObjectVariable( 'coin2', coin2Image, coin2ShadowImage, { value: 2 } ),
new ObjectVariable( 'coin3', coin3Image, coin3ShadowImage, { value: 5 } )
new ObjectVariable( 'coin1', coin1_png, coin1Shadow_png, { value: 3 } ),
new ObjectVariable( 'coin2', coin2_png, coin2Shadow_png, { value: 2 } ),
new ObjectVariable( 'coin3', coin3_png, coin3Shadow_png, { value: 5 } )
];

super( variables, {

debugName: 'coins',

// icon used to represent this scene in the scene control (radio buttons)
icon: new Image( coin3Image, {
icon: new Image( coin3_png, {
maxHeight: EqualityExplorerConstants.SMALL_TERM_DIAMETER
} )
} );
Expand Down
20 changes: 10 additions & 10 deletions js/basics/model/FruitsScene.js
Original file line number Diff line number Diff line change
Expand Up @@ -7,12 +7,12 @@
*/

import Image from '../../../../scenery/js/nodes/Image.js';
import appleImage from '../../../images/apple_png.js';
import appleShadowImage from '../../../images/appleShadow_png.js';
import lemonImage from '../../../images/lemon_png.js';
import lemonShadowImage from '../../../images/lemonShadow_png.js';
import orangeImage from '../../../images/orange_png.js';
import orangeShadowImage from '../../../images/orangeShadow_png.js';
import apple_png from '../../../images/apple_png.js';
import appleShadow_png from '../../../images/appleShadow_png.js';
import lemon_png from '../../../images/lemon_png.js';
import lemonShadow_png from '../../../images/lemonShadow_png.js';
import orange_png from '../../../images/orange_png.js';
import orangeShadow_png from '../../../images/orangeShadow_png.js';
import EqualityExplorerConstants from '../../common/EqualityExplorerConstants.js';
import equalityExplorer from '../../equalityExplorer.js';
import BasicsScene from './BasicsScene.js';
Expand All @@ -25,17 +25,17 @@ class FruitsScene extends BasicsScene {
const variables = [

// name, image, shadow
new ObjectVariable( 'apple', appleImage, appleShadowImage, { value: 4 } ),
new ObjectVariable( 'lemon', lemonImage, lemonShadowImage, { value: 5 } ),
new ObjectVariable( 'orange', orangeImage, orangeShadowImage, { value: 2 } )
new ObjectVariable( 'apple', apple_png, appleShadow_png, { value: 4 } ),
new ObjectVariable( 'lemon', lemon_png, lemonShadow_png, { value: 5 } ),
new ObjectVariable( 'orange', orange_png, orangeShadow_png, { value: 2 } )
];

super( variables, {

debugName: 'fruits',

// icon used to represent this scene in the scene control (radio buttons)
icon: new Image( appleImage, {
icon: new Image( apple_png, {
maxHeight: EqualityExplorerConstants.SMALL_TERM_DIAMETER
} )
} );
Expand Down
12 changes: 6 additions & 6 deletions js/basics/model/ShapesScene.js
Original file line number Diff line number Diff line change
Expand Up @@ -7,10 +7,10 @@
*/

import Fraction from '../../../../phetcommon/js/model/Fraction.js';
import sphereImage from '../../../images/sphere_png.js';
import sphereShadowImage from '../../../images/sphereShadow_png.js';
import squareImage from '../../../images/square_png.js';
import squareShadowImage from '../../../images/squareShadow_png.js';
import sphere_png from '../../../images/sphere_png.js';
import sphereShadow_png from '../../../images/sphereShadow_png.js';
import square_png from '../../../images/square_png.js';
import squareShadow_png from '../../../images/squareShadow_png.js';
import ConstantTermNode from '../../common/view/ConstantTermNode.js';
import equalityExplorer from '../../equalityExplorer.js';
import BasicsScene from './BasicsScene.js';
Expand All @@ -23,8 +23,8 @@ class ShapesScene extends BasicsScene {
const variables = [

// name, image, shadow
new ObjectVariable( 'sphere', sphereImage, sphereShadowImage, { value: 2 } ),
new ObjectVariable( 'square', squareImage, squareShadowImage, { value: 3 } )
new ObjectVariable( 'sphere', sphere_png, sphereShadow_png, { value: 2 } ),
new ObjectVariable( 'square', square_png, squareShadow_png, { value: 3 } )
];

super( variables, {
Expand Down
14 changes: 7 additions & 7 deletions js/common/EqualityExplorerScreenIcons.js
Original file line number Diff line number Diff line change
Expand Up @@ -16,9 +16,9 @@ import Image from '../../../scenery/js/nodes/Image.js';
import Node from '../../../scenery/js/nodes/Node.js';
import Text from '../../../scenery/js/nodes/Text.js';
import VBox from '../../../scenery/js/nodes/VBox.js';
import phetGirlJugglingStarsImage from '../../../vegas/images/phet-girl-juggling-stars_png.js';
import appleBigImage from '../../images/appleBig_png.js';
import orangeBigImage from '../../images/orangeBig_png.js';
import phetGirlJugglingStars_png from '../../../vegas/images/phet-girl-juggling-stars_png.js';
import appleBig_png from '../../images/appleBig_png.js';
import orangeBig_png from '../../images/orangeBig_png.js';
import equalityExplorer from '../equalityExplorer.js';
import equalityExplorerStrings from '../equalityExplorerStrings.js';
import EqualityExplorerColors from './EqualityExplorerColors.js';
Expand All @@ -35,8 +35,8 @@ const EqualityExplorerScreenIcons = {
createBasicsScreenIcon: function() {

// apples on left side of the equation
const appleNode1 = new Image( appleBigImage );
const appleNode2 = new Image( appleBigImage, {
const appleNode1 = new Image( appleBig_png );
const appleNode2 = new Image( appleBig_png, {
left: appleNode1.left - 10,
top: appleNode1.bottom + 5
} );
Expand All @@ -51,7 +51,7 @@ const EqualityExplorerScreenIcons = {
} );

// an orange on right side of the equation
const orangeNode = new Image( orangeBigImage );
const orangeNode = new Image( orangeBig_png );

const iconNode = new HBox( {
spacing: 15,
Expand Down Expand Up @@ -167,7 +167,7 @@ const EqualityExplorerScreenIcons = {
* @returns {ScreenIcon}
*/
createSolveItHomeScreenIcon: function() {
const iconNode = new Image( phetGirlJugglingStarsImage );
const iconNode = new Image( phetGirlJugglingStars_png );
return new ScreenIcon( iconNode, {
fill: EqualityExplorerColors.SOLVE_IT_SCREEN_BACKGROUND
} );
Expand Down
8 changes: 4 additions & 4 deletions js/common/view/LockControl.js
Original file line number Diff line number Diff line change
Expand Up @@ -13,8 +13,8 @@ import FireListener from '../../../../scenery/js/listeners/FireListener.js';
import Image from '../../../../scenery/js/nodes/Image.js';
import Node from '../../../../scenery/js/nodes/Node.js';
import BooleanToggleNode from '../../../../sun/js/BooleanToggleNode.js';
import lockClosedImage from '../../../images/lockClosed_png.js';
import lockOpenedImage from '../../../images/lockOpened_png.js';
import lockClosed_png from '../../../images/lockClosed_png.js';
import lockOpened_png from '../../../images/lockOpened_png.js';
import equalityExplorer from '../../equalityExplorer.js';

class LockControl extends Node {
Expand All @@ -33,8 +33,8 @@ class LockControl extends Node {
}, options );

// icons
const lockClosedNode = new Image( lockClosedImage );
const lockOpenedNode = new Image( lockOpenedImage );
const lockClosedNode = new Image( lockClosed_png );
const lockOpenedNode = new Image( lockOpened_png );
assert && assert( lockClosedNode.width === lockOpenedNode.width && lockClosedNode.height === lockOpenedNode.height,
'lock images must have identical dimensions' );

Expand Down
16 changes: 8 additions & 8 deletions js/solveit/view/EqualityExplorerRewardNode.js
Original file line number Diff line number Diff line change
Expand Up @@ -13,10 +13,10 @@ import FaceNode from '../../../../scenery-phet/js/FaceNode.js';
import StarNode from '../../../../scenery-phet/js/StarNode.js';
import Image from '../../../../scenery/js/nodes/Image.js';
import RewardNode from '../../../../vegas/js/RewardNode.js';
import appleImage from '../../../images/apple_png.js';
import catImage from '../../../images/cat_png.js';
import dogImage from '../../../images/dog_png.js';
import orangeImage from '../../../images/orange_png.js';
import apple_png from '../../../images/apple_png.js';
import cat_png from '../../../images/cat_png.js';
import dog_png from '../../../images/dog_png.js';
import orange_png from '../../../images/orange_png.js';
import EqualityExplorerConstants from '../../common/EqualityExplorerConstants.js';
import ConstantTerm from '../../common/model/ConstantTerm.js';
import UniversalOperation from '../../common/model/UniversalOperation.js';
Expand All @@ -36,10 +36,10 @@ const INTEGER_VALUES = ChallengeGenerator.rangeToArray( -9, 9 );
INTEGER_VALUES.splice( INTEGER_VALUES.indexOf( 0 ), 1 );

// Node instances that are reused throughout the rewards
const APPLE_NODE = new Image( appleImage, IMAGE_OPTIONS );
const CAT_NODE = new Image( catImage, IMAGE_OPTIONS );
const DOG_NODE = new Image( dogImage, IMAGE_OPTIONS );
const ORANGE_NODE = new Image( orangeImage, IMAGE_OPTIONS );
const APPLE_NODE = new Image( apple_png, IMAGE_OPTIONS );
const CAT_NODE = new Image( cat_png, IMAGE_OPTIONS );
const DOG_NODE = new Image( dog_png, IMAGE_OPTIONS );
const ORANGE_NODE = new Image( orange_png, IMAGE_OPTIONS );
const STAR_NODE = new StarNode( {
innerRadius: DIAMETER / 4,
outerRadius: DIAMETER / 2
Expand Down

0 comments on commit fbb7ee9

Please sign in to comment.