From 912e82b530804bad345a228d368307a73a51e88a Mon Sep 17 00:00:00 2001 From: Joe Heffernan Date: Wed, 11 Sep 2024 11:04:00 -0700 Subject: [PATCH] declare ColorChange interface locally --- src/components/ColorPicker/index.tsx | 2 +- src/constants/interfaces.ts | 7 +++++++ src/state/selection/actions.ts | 3 +-- src/state/selection/types.ts | 3 +-- 4 files changed, 10 insertions(+), 5 deletions(-) diff --git a/src/components/ColorPicker/index.tsx b/src/components/ColorPicker/index.tsx index 1958333d..dab139ff 100644 --- a/src/components/ColorPicker/index.tsx +++ b/src/components/ColorPicker/index.tsx @@ -4,9 +4,9 @@ import { Popover, Tooltip } from "antd"; import { HexColorInput, HexColorPicker } from "react-colorful"; import classNames from "classnames"; import { useDebounce } from "use-debounce"; -import { ColorChange } from "@aics/simularium-viewer"; import { AGENT_COLORS } from "../../containers/ViewerPanel/constants"; +import { ColorChange } from "../../constants/interfaces"; import { SetColorChangeAction, SetRecentColorsAction, diff --git a/src/constants/interfaces.ts b/src/constants/interfaces.ts index e2dae3ca..3ace35a9 100644 --- a/src/constants/interfaces.ts +++ b/src/constants/interfaces.ts @@ -1,3 +1,5 @@ +import { SelectionEntry } from "@aics/simularium-viewer"; + export interface TrajectoryDisplayData { modelName: string; id: string; @@ -84,3 +86,8 @@ export interface MetadataDisplay { label: JSX.Element; value: () => JSX.Element | string; } + +export interface ColorChange { + agent: SelectionEntry; + color: string; +} diff --git a/src/state/selection/actions.ts b/src/state/selection/actions.ts index b553d400..8e5bbbc6 100644 --- a/src/state/selection/actions.ts +++ b/src/state/selection/actions.ts @@ -1,5 +1,4 @@ -import { ColorChange } from "@aics/simularium-viewer"; -import { AgentMetadata } from "../../constants/interfaces"; +import { AgentMetadata, ColorChange } from "../../constants/interfaces"; import { SELECT_METADATA, CHANGE_TIME_HEAD, diff --git a/src/state/selection/types.ts b/src/state/selection/types.ts index 5233709d..eaeb827d 100644 --- a/src/state/selection/types.ts +++ b/src/state/selection/types.ts @@ -1,5 +1,4 @@ -import { ColorChange } from "@aics/simularium-viewer"; -import { AgentMetadata } from "../../constants/interfaces"; +import { AgentMetadata, ColorChange } from "../../constants/interfaces"; import { TrajectoryStateBranch } from "../trajectory/types"; export interface SelectionStateBranch {