-
Notifications
You must be signed in to change notification settings - Fork 12
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
optimize and sort imports, phetsims/chipper#1462
- Loading branch information
Showing
24 changed files
with
57 additions
and
57 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
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -23,10 +23,10 @@ | |
* @author Jonathan Olson <[email protected]> | ||
*/ | ||
|
||
import { AllowedKeysString, EnglishKeyString, eventCodeToEnglishString, FocusManager, globalHotkeyRegistry, globalKeyStateTracker, Hotkey, KeyboardUtils, metaEnglishKeys, Node, scenery } from '../imports.js'; | ||
import DerivedProperty, { UnknownDerivedProperty } from '../../../axon/js/DerivedProperty.js'; | ||
import TProperty from '../../../axon/js/TProperty.js'; | ||
import TinyProperty from '../../../axon/js/TinyProperty.js'; | ||
import TProperty from '../../../axon/js/TProperty.js'; | ||
import { AllowedKeysString, EnglishKeyString, eventCodeToEnglishString, FocusManager, globalHotkeyRegistry, globalKeyStateTracker, Hotkey, KeyboardUtils, metaEnglishKeys, Node, scenery } from '../imports.js'; | ||
|
||
const arrayComparator = <Key>( a: Key[], b: Key[] ): boolean => { | ||
return a.length === b.length && a.every( ( element, index ) => element === b[ index ] ); | ||
|
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 |
---|---|---|
|
@@ -9,10 +9,10 @@ | |
* @author Jonathan Olson <[email protected]> | ||
*/ | ||
|
||
import Enumeration from '../../../phet-core/js/Enumeration.js'; | ||
import EnumerationValue from '../../../phet-core/js/EnumerationValue.js'; | ||
import Orientation from '../../../phet-core/js/Orientation.js'; | ||
import { scenery } from '../imports.js'; | ||
import EnumerationValue from '../../../phet-core/js/EnumerationValue.js'; | ||
import Enumeration from '../../../phet-core/js/Enumeration.js'; | ||
|
||
export const HorizontalLayoutAlignValues = [ 'left', 'right', 'center', 'origin' ] as const; | ||
export type HorizontalLayoutAlign = typeof HorizontalLayoutAlignValues[number]; | ||
|
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 |
---|---|---|
|
@@ -9,10 +9,10 @@ | |
* @author Jonathan Olson <[email protected]> | ||
*/ | ||
|
||
import Enumeration from '../../../phet-core/js/Enumeration.js'; | ||
import EnumerationValue from '../../../phet-core/js/EnumerationValue.js'; | ||
import Orientation from '../../../phet-core/js/Orientation.js'; | ||
import { scenery } from '../imports.js'; | ||
import EnumerationValue from '../../../phet-core/js/EnumerationValue.js'; | ||
import Enumeration from '../../../phet-core/js/Enumeration.js'; | ||
|
||
export const HorizontalLayoutJustificationValues = [ 'left', 'right', 'center', 'spaceBetween', 'spaceAround', 'spaceEvenly' ] as const; | ||
export type HorizontalLayoutJustification = typeof HorizontalLayoutJustificationValues[number]; | ||
|
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 |
---|---|---|
|
@@ -7,14 +7,14 @@ | |
* @author Jonathan Olson <[email protected]> | ||
*/ | ||
|
||
import memoize from '../../../phet-core/js/memoize.js'; | ||
import { DelayedMutate, HEIGHT_SIZABLE_OPTION_KEYS, HeightSizable, HeightSizableOptions, Node, REQUIRES_BOUNDS_OPTION_KEYS, scenery, WIDTH_SIZABLE_OPTION_KEYS, WidthSizable, WidthSizableOptions } from '../imports.js'; | ||
import Constructor from '../../../phet-core/js/types/Constructor.js'; | ||
import Dimension2 from '../../../dot/js/Dimension2.js'; | ||
import assertMutuallyExclusiveOptions from '../../../phet-core/js/assertMutuallyExclusiveOptions.js'; | ||
import memoize from '../../../phet-core/js/memoize.js'; | ||
import Constructor from '../../../phet-core/js/types/Constructor.js'; | ||
import IntentionalAny from '../../../phet-core/js/types/IntentionalAny.js'; | ||
import { TWidthSizable } from './WidthSizable.js'; | ||
import { DelayedMutate, HEIGHT_SIZABLE_OPTION_KEYS, HeightSizable, HeightSizableOptions, Node, REQUIRES_BOUNDS_OPTION_KEYS, scenery, WIDTH_SIZABLE_OPTION_KEYS, WidthSizable, WidthSizableOptions } from '../imports.js'; | ||
import { THeightSizable } from './HeightSizable.js'; | ||
import { TWidthSizable } from './WidthSizable.js'; | ||
|
||
export const SIZABLE_SELF_OPTION_KEYS = [ | ||
'preferredSize', | ||
|
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 |
---|---|---|
|
@@ -19,16 +19,16 @@ | |
* @author Jonathan Olson <[email protected]> | ||
*/ | ||
|
||
import TProperty from '../../../../axon/js/TProperty.js'; | ||
import Disposable, { DisposableOptions } from '../../../../axon/js/Disposable.js'; | ||
import NumberProperty from '../../../../axon/js/NumberProperty.js'; | ||
import TProperty from '../../../../axon/js/TProperty.js'; | ||
import Bounds2 from '../../../../dot/js/Bounds2.js'; | ||
import arrayRemove from '../../../../phet-core/js/arrayRemove.js'; | ||
import { combineOptions, optionize3 } from '../../../../phet-core/js/optionize.js'; | ||
import { AlignBox, Node, scenery } from '../../imports.js'; | ||
import { AlignBoxOptions } from '../nodes/AlignBox.js'; | ||
import Disposable, { DisposableOptions } from '../../../../axon/js/Disposable.js'; | ||
import Orientation from '../../../../phet-core/js/Orientation.js'; | ||
import StrictOmit from '../../../../phet-core/js/types/StrictOmit.js'; | ||
import { AlignBox, Node, scenery } from '../../imports.js'; | ||
import { AlignBoxOptions } from '../nodes/AlignBox.js'; | ||
|
||
let globalId = 1; | ||
|
||
|
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 |
---|---|---|
|
@@ -6,9 +6,9 @@ | |
* @author Jonathan Olson <[email protected]> | ||
*/ | ||
|
||
import { ExternalFlowConfigurableOptions, FLOW_CONFIGURABLE_OPTION_KEYS, FlowConfigurable, FlowConstraint, LayoutAlign, LayoutProxy, MarginLayoutCell, Node, scenery } from '../../imports.js'; | ||
import StrictOmit from '../../../../phet-core/js/types/StrictOmit.js'; | ||
import optionize from '../../../../phet-core/js/optionize.js'; | ||
import StrictOmit from '../../../../phet-core/js/types/StrictOmit.js'; | ||
import { ExternalFlowConfigurableOptions, FLOW_CONFIGURABLE_OPTION_KEYS, FlowConfigurable, FlowConstraint, LayoutAlign, LayoutProxy, MarginLayoutCell, Node, scenery } from '../../imports.js'; | ||
|
||
const FLOW_CELL_KEYS = [ | ||
...FLOW_CONFIGURABLE_OPTION_KEYS, | ||
|
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 |
---|---|---|
|
@@ -20,15 +20,15 @@ | |
* @author Jonathan Olson <[email protected]> | ||
*/ | ||
|
||
import TEmitter from '../../../../axon/js/TEmitter.js'; | ||
import TinyEmitter from '../../../../axon/js/TinyEmitter.js'; | ||
import Orientation from '../../../../phet-core/js/Orientation.js'; | ||
import memoize from '../../../../phet-core/js/memoize.js'; | ||
import mutate from '../../../../phet-core/js/mutate.js'; | ||
import { HorizontalLayoutAlign, LayoutAlign, LayoutOrientation, MARGIN_LAYOUT_CONFIGURABLE_OPTION_KEYS, MarginLayoutConfigurable, MarginLayoutConfigurableOptions, RestrictedHorizontalLayoutAlign, RestrictedVerticalLayoutAlign, scenery, VerticalLayoutAlign } from '../../imports.js'; | ||
import Orientation from '../../../../phet-core/js/Orientation.js'; | ||
import Constructor from '../../../../phet-core/js/types/Constructor.js'; | ||
import WithoutNull from '../../../../phet-core/js/types/WithoutNull.js'; | ||
import IntentionalAny from '../../../../phet-core/js/types/IntentionalAny.js'; | ||
import TEmitter from '../../../../axon/js/TEmitter.js'; | ||
import WithoutNull from '../../../../phet-core/js/types/WithoutNull.js'; | ||
import { HorizontalLayoutAlign, LayoutAlign, LayoutOrientation, MARGIN_LAYOUT_CONFIGURABLE_OPTION_KEYS, MarginLayoutConfigurable, MarginLayoutConfigurableOptions, RestrictedHorizontalLayoutAlign, RestrictedVerticalLayoutAlign, scenery, VerticalLayoutAlign } from '../../imports.js'; | ||
import { TMarginLayoutConfigurable } from './MarginLayoutConfigurable.js'; | ||
|
||
const FLOW_CONFIGURABLE_OPTION_KEYS = [ | ||
|
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 |
---|---|---|
|
@@ -7,12 +7,12 @@ | |
* @author Jonathan Olson <[email protected]> | ||
*/ | ||
|
||
import TProperty from '../../../../axon/js/TProperty.js'; | ||
import Bounds2 from '../../../../dot/js/Bounds2.js'; | ||
import Orientation from '../../../../phet-core/js/Orientation.js'; | ||
import arrayRemove from '../../../../phet-core/js/arrayRemove.js'; | ||
import mutate from '../../../../phet-core/js/mutate.js'; | ||
import Orientation from '../../../../phet-core/js/Orientation.js'; | ||
import { ExternalFlowConfigurableOptions, FLOW_CONFIGURABLE_OPTION_KEYS, FlowCell, FlowConfigurable, FlowLine, HorizontalLayoutJustification, LayoutAlign, LayoutJustification, Node, NodeLayoutAvailableConstraintOptions, NodeLayoutConstraint, scenery, VerticalLayoutJustification } from '../../imports.js'; | ||
import TProperty from '../../../../axon/js/TProperty.js'; | ||
|
||
const FLOW_CONSTRAINT_OPTION_KEYS = [ | ||
...FLOW_CONFIGURABLE_OPTION_KEYS, | ||
|
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 |
---|---|---|
|
@@ -6,10 +6,10 @@ | |
* @author Jonathan Olson <[email protected]> | ||
*/ | ||
|
||
import optionize from '../../../../phet-core/js/optionize.js'; | ||
import Orientation from '../../../../phet-core/js/Orientation.js'; | ||
import OrientationPair from '../../../../phet-core/js/OrientationPair.js'; | ||
import { ExternalGridConfigurableOptions, GRID_CONFIGURABLE_OPTION_KEYS, GridConfigurable, GridConstraint, LayoutAlign, LayoutProxy, MarginLayoutCell, Node, scenery } from '../../imports.js'; | ||
import optionize from '../../../../phet-core/js/optionize.js'; | ||
|
||
const GRID_CELL_KEYS = [ | ||
...GRID_CONFIGURABLE_OPTION_KEYS, | ||
|
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 |
---|---|---|
|
@@ -17,13 +17,13 @@ | |
* @author Jonathan Olson <[email protected]> | ||
*/ | ||
|
||
import Constructor from '../../../../phet-core/js/types/Constructor.js'; | ||
import assertMutuallyExclusiveOptions from '../../../../phet-core/js/assertMutuallyExclusiveOptions.js'; | ||
import memoize from '../../../../phet-core/js/memoize.js'; | ||
import mutate from '../../../../phet-core/js/mutate.js'; | ||
import { HorizontalLayoutAlign, HorizontalLayoutAlignValues, LayoutAlign, MARGIN_LAYOUT_CONFIGURABLE_OPTION_KEYS, MarginLayoutConfigurable, MarginLayoutConfigurableOptions, scenery, VerticalLayoutAlign, VerticalLayoutAlignValues } from '../../imports.js'; | ||
import assertMutuallyExclusiveOptions from '../../../../phet-core/js/assertMutuallyExclusiveOptions.js'; | ||
import WithoutNull from '../../../../phet-core/js/types/WithoutNull.js'; | ||
import Constructor from '../../../../phet-core/js/types/Constructor.js'; | ||
import IntentionalAny from '../../../../phet-core/js/types/IntentionalAny.js'; | ||
import WithoutNull from '../../../../phet-core/js/types/WithoutNull.js'; | ||
import { HorizontalLayoutAlign, HorizontalLayoutAlignValues, LayoutAlign, MARGIN_LAYOUT_CONFIGURABLE_OPTION_KEYS, MarginLayoutConfigurable, MarginLayoutConfigurableOptions, scenery, VerticalLayoutAlign, VerticalLayoutAlignValues } from '../../imports.js'; | ||
|
||
const GRID_CONFIGURABLE_OPTION_KEYS = [ | ||
'xAlign', | ||
|
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 |
---|---|---|
|
@@ -10,12 +10,12 @@ | |
* @author Jonathan Olson <[email protected]> | ||
*/ | ||
|
||
import TProperty from '../../../../axon/js/TProperty.js'; | ||
import Bounds2 from '../../../../dot/js/Bounds2.js'; | ||
import mutate from '../../../../phet-core/js/mutate.js'; | ||
import Orientation from '../../../../phet-core/js/Orientation.js'; | ||
import OrientationPair from '../../../../phet-core/js/OrientationPair.js'; | ||
import mutate from '../../../../phet-core/js/mutate.js'; | ||
import { ExternalGridConfigurableOptions, GRID_CONFIGURABLE_OPTION_KEYS, GridCell, GridConfigurable, GridLine, LayoutAlign, Node, NodeLayoutAvailableConstraintOptions, NodeLayoutConstraint, scenery } from '../../imports.js'; | ||
import TProperty from '../../../../axon/js/TProperty.js'; | ||
|
||
const GRID_CONSTRAINT_OPTION_KEYS = [ | ||
...GRID_CONFIGURABLE_OPTION_KEYS, | ||
|
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 |
---|---|---|
|
@@ -15,14 +15,14 @@ | |
* @author Jonathan Olson <[email protected]> | ||
*/ | ||
|
||
import TEmitter from '../../../../axon/js/TEmitter.js'; | ||
import TinyEmitter from '../../../../axon/js/TinyEmitter.js'; | ||
import assertMutuallyExclusiveOptions from '../../../../phet-core/js/assertMutuallyExclusiveOptions.js'; | ||
import memoize from '../../../../phet-core/js/memoize.js'; | ||
import { scenery } from '../../imports.js'; | ||
import Constructor from '../../../../phet-core/js/types/Constructor.js'; | ||
import assertMutuallyExclusiveOptions from '../../../../phet-core/js/assertMutuallyExclusiveOptions.js'; | ||
import WithoutNull from '../../../../phet-core/js/types/WithoutNull.js'; | ||
import IntentionalAny from '../../../../phet-core/js/types/IntentionalAny.js'; | ||
import TEmitter from '../../../../axon/js/TEmitter.js'; | ||
import WithoutNull from '../../../../phet-core/js/types/WithoutNull.js'; | ||
import { scenery } from '../../imports.js'; | ||
|
||
const MARGIN_LAYOUT_CONFIGURABLE_OPTION_KEYS = [ | ||
'margin', | ||
|
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
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