diff --git a/packages/react-native-reanimated/src/ViewDescriptorsSet.ts b/packages/react-native-reanimated/src/ViewDescriptorsSet.ts index 898d7f4007a6..9c046ae9195d 100644 --- a/packages/react-native-reanimated/src/ViewDescriptorsSet.ts +++ b/packages/react-native-reanimated/src/ViewDescriptorsSet.ts @@ -3,12 +3,6 @@ import type { SharedValue } from './commonTypes'; import { makeMutable } from './core'; import type { Descriptor } from './hook/commonTypes'; -export interface ViewDescriptorsSet { - shareableViewDescriptors: SharedValue; - add: (item: Descriptor) => void; - remove: (viewTag: number) => void; -} - export function makeViewDescriptorsSet(): ViewDescriptorsSet { const shareableViewDescriptors = makeMutable([]); const data: ViewDescriptorsSet = { diff --git a/packages/react-native-reanimated/src/commonTypes.ts b/packages/react-native-reanimated/src/commonTypes.ts index 96dbd63e9892..ccea10b4a92a 100644 --- a/packages/react-native-reanimated/src/commonTypes.ts +++ b/packages/react-native-reanimated/src/commonTypes.ts @@ -1,15 +1,10 @@ 'use strict'; -import type { - ImageStyle, - TextStyle, - TransformsStyle, - ViewStyle, -} from 'react-native'; +import type { TextStyle, TransformsStyle, ViewStyle } from 'react-native'; import type { ShareableRef, WorkletFunction } from 'react-native-worklets'; -import type { CSSAnimationProperties, CSSTransitionProperties } from './css'; import type { EasingFunctionFactory } from './Easing'; +import type { ReanimatedHTMLElement } from './ReanimatedModule/js-reanimated'; type LayoutAnimationOptions = | 'originX' @@ -416,27 +411,31 @@ type MaybeSharedValue = ? SharedValueDisableContravariance : never); -type MaybeSharedValueRecursive = Value extends readonly (infer Item)[] - ? - | SharedValueDisableContravariance - | (MaybeSharedValueRecursive | Item)[] - : Value extends object +export type MaybeSharedValueRecursive = + Value extends readonly (infer Item)[] ? - | SharedValueDisableContravariance - | { - [Key in keyof Value]: - | MaybeSharedValueRecursive - | Value[Key]; - } - : MaybeSharedValue; - -type DefaultStyle = ViewStyle & ImageStyle & TextStyle; - -// Ideally we want AnimatedStyle to not be generic, but there are -// so many dependencies on it being generic that it's not feasible at the moment. -export type AnimatedStyle