From 589cf4a85d5b0adf1ed6d887e6604fd7e36e4461 Mon Sep 17 00:00:00 2001 From: Jonathan Olson Date: Mon, 4 Mar 2024 18:13:14 -0700 Subject: [PATCH] Fixing imports to use direct imports, instead of phet-lib imports.ts files. See https://github.com/phetsims/phet-lib/issues/6 --- js/display/PaintObserver.js | 2 +- js/display/SVGGradientStop.ts | 2 +- js/display/drawables/RectangleWebGLDrawable.js | 2 +- js/nodes/Paintable.ts | 2 +- js/util/CanvasContextWrapper.js | 2 +- js/util/ColorDef.ts | 2 +- js/util/Gradient.ts | 2 +- js/util/PaintDef.js | 2 +- js/util/sceneryDeserialize.ts | 2 +- js/util/scenerySerialize.ts | 3 ++- 10 files changed, 11 insertions(+), 10 deletions(-) diff --git a/js/display/PaintObserver.js b/js/display/PaintObserver.js index a11d67079..bd59507ca 100644 --- a/js/display/PaintObserver.js +++ b/js/display/PaintObserver.js @@ -6,7 +6,7 @@ * @author Jonathan Olson */ -import { isTReadOnlyProperty } from '../../../axon/js/imports.js'; +import { isTReadOnlyProperty } from '../../../axon/js/TReadOnlyProperty.js'; import { Color, Gradient, scenery } from '../imports.js'; class PaintObserver { diff --git a/js/display/SVGGradientStop.ts b/js/display/SVGGradientStop.ts index d2a9bbd4a..3c04cd8e1 100644 --- a/js/display/SVGGradientStop.ts +++ b/js/display/SVGGradientStop.ts @@ -9,7 +9,7 @@ import Pool, { TPoolable } from '../../../phet-core/js/Pool.js'; import WithoutNull from '../../../phet-core/js/types/WithoutNull.js'; import { ActiveSVGGradient, Color, scenery, svgns, TColor } from '../imports.js'; -import { isTReadOnlyProperty } from '../../../axon/js/imports.js'; +import { isTReadOnlyProperty } from '../../../axon/js/TReadOnlyProperty.js'; const scratchColor = new Color( 'transparent' ); diff --git a/js/display/drawables/RectangleWebGLDrawable.js b/js/display/drawables/RectangleWebGLDrawable.js index 967408019..c36943f09 100644 --- a/js/display/drawables/RectangleWebGLDrawable.js +++ b/js/display/drawables/RectangleWebGLDrawable.js @@ -6,7 +6,7 @@ * @author Jonathan Olson */ -import { isTReadOnlyProperty } from '../../../../axon/js/imports.js'; +import { isTReadOnlyProperty } from '../../../../axon/js/TReadOnlyProperty.js'; import Vector2 from '../../../../dot/js/Vector2.js'; import Poolable from '../../../../phet-core/js/Poolable.js'; import { Color, RectangleStatefulDrawable, Renderer, scenery, WebGLSelfDrawable } from '../../imports.js'; diff --git a/js/nodes/Paintable.ts b/js/nodes/Paintable.ts index 93852ef18..4ddd780e2 100644 --- a/js/nodes/Paintable.ts +++ b/js/nodes/Paintable.ts @@ -16,7 +16,7 @@ import { CanvasContextWrapper, Color, Gradient, LinearGradient, Node, Paint, Pai import Constructor from '../../../phet-core/js/types/Constructor.js'; import IntentionalAny from '../../../phet-core/js/types/IntentionalAny.js'; import Vector2 from '../../../dot/js/Vector2.js'; -import { isTReadOnlyProperty } from '../../../axon/js/imports.js'; +import { isTReadOnlyProperty } from '../../../axon/js/TReadOnlyProperty.js'; const isSafari5 = platform.safari5; diff --git a/js/util/CanvasContextWrapper.js b/js/util/CanvasContextWrapper.js index 0a144f2d7..b24e648bc 100644 --- a/js/util/CanvasContextWrapper.js +++ b/js/util/CanvasContextWrapper.js @@ -10,7 +10,7 @@ * @author Jonathan Olson */ -import { isTReadOnlyProperty } from '../../../axon/js/imports.js'; +import { isTReadOnlyProperty } from '../../../axon/js/TReadOnlyProperty.js'; import { scenery } from '../imports.js'; class CanvasContextWrapper { diff --git a/js/util/ColorDef.ts b/js/util/ColorDef.ts index a80f2c35c..770e66a81 100644 --- a/js/util/ColorDef.ts +++ b/js/util/ColorDef.ts @@ -14,7 +14,7 @@ import OrIO from '../../../tandem/js/types/OrIO.js'; import ReferenceIO from '../../../tandem/js/types/ReferenceIO.js'; import StringIO from '../../../tandem/js/types/StringIO.js'; import { Color, scenery, TColor } from '../imports.js'; -import { isTReadOnlyProperty } from '../../../axon/js/imports.js'; +import { isTReadOnlyProperty } from '../../../axon/js/TReadOnlyProperty.js'; const ColorDef = { /** diff --git a/js/util/Gradient.ts b/js/util/Gradient.ts index 791e3009d..86d2fe0f3 100644 --- a/js/util/Gradient.ts +++ b/js/util/Gradient.ts @@ -8,7 +8,7 @@ import cleanArray from '../../../phet-core/js/cleanArray.js'; import { Color, Paint, scenery, TColor } from '../imports.js'; -import { isTReadOnlyProperty } from '../../../axon/js/imports.js'; +import { isTReadOnlyProperty } from '../../../axon/js/TReadOnlyProperty.js'; export type GradientStop = { ratio: number; diff --git a/js/util/PaintDef.js b/js/util/PaintDef.js index 9b6a80eb6..6380a5d2e 100644 --- a/js/util/PaintDef.js +++ b/js/util/PaintDef.js @@ -6,7 +6,7 @@ * @author Jonathan Olson */ -import { isTReadOnlyProperty } from '../../../axon/js/imports.js'; +import { isTReadOnlyProperty } from '../../../axon/js/TReadOnlyProperty.js'; import { Color, Gradient, Paint, scenery } from '../imports.js'; const PaintDef = { diff --git a/js/util/sceneryDeserialize.ts b/js/util/sceneryDeserialize.ts index 924c026da..8c905f67c 100644 --- a/js/util/sceneryDeserialize.ts +++ b/js/util/sceneryDeserialize.ts @@ -14,7 +14,7 @@ import Vector2 from '../../../dot/js/Vector2.js'; import { Shape } from '../../../kite/js/imports.js'; import IntentionalAny from '../../../phet-core/js/types/IntentionalAny.js'; import { Circle, Color, DOM, Gradient, Image, Line, LinearGradient, Mipmap, Node, Paint, Path, Pattern, RadialGradient, Rectangle, scenery, Text } from '../imports.js'; -import { TinyProperty } from '../../../axon/js/imports.js'; +import TinyProperty from '../../../axon/js/TinyProperty.js'; const sceneryDeserialize = ( value: { type: string; [ key: string ]: IntentionalAny } ): IntentionalAny => { const nodeTypes = [ diff --git a/js/util/scenerySerialize.ts b/js/util/scenerySerialize.ts index 2345a3b05..a2aa67306 100644 --- a/js/util/scenerySerialize.ts +++ b/js/util/scenerySerialize.ts @@ -14,7 +14,8 @@ import { Shape } from '../../../kite/js/imports.js'; import inheritance from '../../../phet-core/js/inheritance.js'; import { CanvasContextWrapper, CanvasNode, Circle, Color, Display, DOM, Gradient, Image, Line, LinearGradient, Node, Paint, PAINTABLE_DEFAULT_OPTIONS, Path, Pattern, RadialGradient, Rectangle, scenery, Text, WebGLNode } from '../imports.js'; import IntentionalAny from '../../../phet-core/js/types/IntentionalAny.js'; -import { ReadOnlyProperty, TinyProperty } from '../../../axon/js/imports.js'; +import ReadOnlyProperty from '../../../axon/js/ReadOnlyProperty.js'; +import TinyProperty from '../../../axon/js/TinyProperty.js'; const scenerySerialize = ( value: unknown ): IntentionalAny => { if ( value instanceof Vector2 ) {