From 9c16083597280b8a6e0b75e8354d1c7556a3d1a1 Mon Sep 17 00:00:00 2001 From: Aria Minaei Date: Wed, 8 Mar 2023 12:22:35 +0100 Subject: [PATCH] Remove the accidental dependency between studio and core --- theatre/core/src/sheets/TheatreSheet.ts | 3 +-- theatre/studio/src/panels/DetailPanel/ObjectDetails.tsx | 3 +-- 2 files changed, 2 insertions(+), 4 deletions(-) diff --git a/theatre/core/src/sheets/TheatreSheet.ts b/theatre/core/src/sheets/TheatreSheet.ts index 66cb614..09ac383 100644 --- a/theatre/core/src/sheets/TheatreSheet.ts +++ b/theatre/core/src/sheets/TheatreSheet.ts @@ -19,12 +19,11 @@ import type { import type SheetObject from '@theatre/core/sheetObjects/SheetObject' import type {ObjectAddressKey} from '@theatre/shared/utils/ids' import {notify} from '@theatre/shared/notify' -import type {IStudio} from '@theatre/studio' export type SheetObjectPropTypeConfig = PropTypeConfig_Compound -export type SheetObjectAction = (object: ISheetObject, studio: IStudio) => void +export type SheetObjectAction = (object: ISheetObject) => void export type SheetObjectActionsConfig = Record diff --git a/theatre/studio/src/panels/DetailPanel/ObjectDetails.tsx b/theatre/studio/src/panels/DetailPanel/ObjectDetails.tsx index 00f49b8..58c146d 100644 --- a/theatre/studio/src/panels/DetailPanel/ObjectDetails.tsx +++ b/theatre/studio/src/panels/DetailPanel/ObjectDetails.tsx @@ -5,7 +5,6 @@ import type {$FixMe} from '@theatre/shared/utils/types' import DeterminePropEditorForDetail from './DeterminePropEditorForDetail' import {useVal} from '@theatre/react' import uniqueKeyForAnyObject from '@theatre/shared/utils/uniqueKeyForAnyObject' -import getStudio from '@theatre/studio/getStudio' import styled from 'styled-components' const ActionButtonContainer = styled.div` @@ -63,7 +62,7 @@ const ObjectDetails: React.FC<{ { - action(obj.publicApi, getStudio().publicApi) + action(obj.publicApi) }} > {actionName}