Skip to content

Commit

Permalink
Move MipmapElement to chipper, see #1523
Browse files Browse the repository at this point in the history
  • Loading branch information
samreid committed Dec 17, 2024
1 parent 7619a26 commit dd302e2
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 4 deletions.
6 changes: 3 additions & 3 deletions js/MipmapElement.ts → js/browser/MipmapElement.ts
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
// Copyright 2022-2024, University of Colorado Boulder

import asyncLoader from './asyncLoader.js';
import phetCore from './phetCore.js';
import asyncLoader from '../../../phet-core/js/asyncLoader.js';
import chipper from './chipper.js';

/**
* Size and raster data for levels in a mipmap. See also type Mipmap in Imageable.ts. Defined in phet-core instead of
Expand Down Expand Up @@ -38,4 +38,4 @@ export default class MipmapElement {
}
}

phetCore.register( 'MipmapElement', MipmapElement );
chipper.register( 'MipmapElement', MipmapElement );
2 changes: 1 addition & 1 deletion js/grunt/modulify.ts
Original file line number Diff line number Diff line change
Expand Up @@ -157,7 +157,7 @@ const modulifyMipmap = async ( abspath: string, repo: string, subdir: string, fi
const entries = mipmapLevels.map( ( { width, height, url } ) => ` new MipmapElement( ${width}, ${height}, '${url}' )` );

const mipmapContents = `${HEADER}
import MipmapElement from '${expandDots( abspath )}phet-core/js/MipmapElement.js';
import MipmapElement from '${expandDots( abspath )}chipper/js/browser/MipmapElement.js';
// The levels in the mipmap. Specify explicit types rather than inferring to assist the type checker, for this boilerplate case.
const mipmaps = [
Expand Down

0 comments on commit dd302e2

Please sign in to comment.