From 8a62816eb96dc8056fe998d33f2d5dfaba435dc8 Mon Sep 17 00:00:00 2001 From: Marla Schulz Date: Fri, 12 May 2023 08:57:36 -0700 Subject: [PATCH] Add intervalToolIcon color to CAVColors, see: https://github.com/phetsims/center-and-variability/issues/194 --- js/common/CAVColors.ts | 1 + js/mean-and-median/view/MeanAndMedianAccordionBox.ts | 2 +- js/variability/view/IntervalToolIconNode.ts | 6 +++--- js/variability/view/VariabilityAccordionBox.ts | 2 +- 4 files changed, 6 insertions(+), 5 deletions(-) diff --git a/js/common/CAVColors.ts b/js/common/CAVColors.ts index ec3d4307..418c562d 100644 --- a/js/common/CAVColors.ts +++ b/js/common/CAVColors.ts @@ -58,6 +58,7 @@ const CAVColors = { grayDataPointFill: new ProfileColorProperty( centerAndVariability, 'grayDataPointFill', { default: '#8f8f8f' } ), + intervalToolIconRectangleFillColorProperty: new ProfileColorProperty( centerAndVariability, 'intervalToolIconRectangleFill', { default: '#fef8ab' } ), intervalToolIconShadedSphereMainColorProperty: new ProfileColorProperty( centerAndVariability, 'intervalToolIconShadedSphereMainColor', { default: '#e0d987' } ), intervalToolIconShadedSphereHighlightColorProperty: new ProfileColorProperty( centerAndVariability, 'intervalToolIconShadedSphereHighlightColor', { default: '#e0d987' } ), intervalToolIconShadedSphereShadowColorProperty: new ProfileColorProperty( centerAndVariability, 'intervalToolIconShadedSphereShadowColor', { default: '#545034' } ), diff --git a/js/mean-and-median/view/MeanAndMedianAccordionBox.ts b/js/mean-and-median/view/MeanAndMedianAccordionBox.ts index 4661bbbd..13c99646 100644 --- a/js/mean-and-median/view/MeanAndMedianAccordionBox.ts +++ b/js/mean-and-median/view/MeanAndMedianAccordionBox.ts @@ -1,7 +1,7 @@ // Copyright 2023, University of Colorado Boulder import CAVAccordionBox from '../../common/view/CAVAccordionBox.js'; -import { AlignGroup, Color, Node, Path, Text } from '../../../../scenery/js/imports.js'; +import { AlignGroup, Node, Path, Text } from '../../../../scenery/js/imports.js'; import CenterAndVariabilityStrings from '../../CenterAndVariabilityStrings.js'; import PhetFont from '../../../../scenery-phet/js/PhetFont.js'; import Bounds2 from '../../../../dot/js/Bounds2.js'; diff --git a/js/variability/view/IntervalToolIconNode.ts b/js/variability/view/IntervalToolIconNode.ts index e8fcbcf4..5b400e27 100644 --- a/js/variability/view/IntervalToolIconNode.ts +++ b/js/variability/view/IntervalToolIconNode.ts @@ -16,14 +16,14 @@ export default class IntervalToolIconNode extends Node { public constructor( providedOptions?: NodeOptions ) { // Sampled from the design in https://github.com/phetsims/center-and-variability/issues/182 - const rectangleFill = '#fef8ab'; + const rectangleFillProperty = CAVColors.intervalToolIconRectangleFillColorProperty; const mainRectangle = new Rectangle( 0, 0, 20, 15, { - fill: rectangleFill + fill: rectangleFillProperty } ); const createHandle = ( options: NodeTransformOptions ) => new Rectangle( 0, 0, 2, mainRectangle.height + 8, { - fill: rectangleFill, + fill: rectangleFillProperty, ...options } ); diff --git a/js/variability/view/VariabilityAccordionBox.ts b/js/variability/view/VariabilityAccordionBox.ts index b340cf3e..0e9eff04 100644 --- a/js/variability/view/VariabilityAccordionBox.ts +++ b/js/variability/view/VariabilityAccordionBox.ts @@ -1,6 +1,6 @@ // Copyright 2023, University of Colorado Boulder -import { AlignGroup, Color, Path, Text, VBox, Node } from '../../../../scenery/js/imports.js'; +import { AlignGroup, Node, Path, Text, VBox } from '../../../../scenery/js/imports.js'; import CenterAndVariabilityStrings from '../../CenterAndVariabilityStrings.js'; import Bounds2 from '../../../../dot/js/Bounds2.js'; import Tandem from '../../../../tandem/js/Tandem.js';