From b0d4e58cc0279210cee3d02a8ba44856b6d0af12 Mon Sep 17 00:00:00 2001 From: Sam Reid Date: Wed, 24 May 2023 08:01:00 -0600 Subject: [PATCH] Specify type alias for empty self options, see https://github.com/phetsims/center-and-variability/issues/214 --- js/common/view/CAVObjectNode.ts | 4 +++- js/common/view/DragIndicatorArrowNode.ts | 3 ++- 2 files changed, 5 insertions(+), 2 deletions(-) diff --git a/js/common/view/CAVObjectNode.ts b/js/common/view/CAVObjectNode.ts index cdbcf0e4..0f56c9bc 100644 --- a/js/common/view/CAVObjectNode.ts +++ b/js/common/view/CAVObjectNode.ts @@ -20,6 +20,8 @@ import PickRequired from '../../../../phet-core/js/types/PickRequired.js'; import Multilink from '../../../../axon/js/Multilink.js'; import optionize, { EmptySelfOptions } from '../../../../phet-core/js/optionize.js'; +type SelfOptions = EmptySelfOptions; + export type CAVObjectNodeOptions = // Take all options from NodeOptions, but do not allow passing through inputEnabledProperty since it requires special handling in multilink @@ -36,7 +38,7 @@ export default class CAVObjectNode extends Node { modelRadius: number, providedOptions?: CAVObjectNodeOptions ) { - const options = optionize()( { + const options = optionize()( { cursor: 'pointer' }, providedOptions ); super( options ); diff --git a/js/common/view/DragIndicatorArrowNode.ts b/js/common/view/DragIndicatorArrowNode.ts index 4b0b51db..7c847c3d 100644 --- a/js/common/view/DragIndicatorArrowNode.ts +++ b/js/common/view/DragIndicatorArrowNode.ts @@ -15,13 +15,14 @@ import PickRequired from '../../../../phet-core/js/types/PickRequired.js'; import optionize, { EmptySelfOptions } from '../../../../phet-core/js/optionize.js'; import { NodeOptions } from '../../../../scenery/js/imports.js'; +type SelfOptions = EmptySelfOptions; type DragIndicatorArrowNodeOptions = PickRequired & Pick & NodeOptions; export default class DragIndicatorArrowNode extends ArrowNode { public constructor( options: DragIndicatorArrowNodeOptions ) { - super( 0, 0, 35, 0, optionize()( { + super( 0, 0, 35, 0, optionize()( { headHeight: 8, headWidth: 12, tailWidth: 5,