import type { ViewProps, StyleProp, ViewStyle, ImageProps } from 'react-native'; import type { IconName } from '../Icon'; interface BaseMapPinProps extends ViewProps { /** * Additional style. */ style?: StyleProp; /** * Testing id of the component. */ testID?: string; /** * State of the map pin. */ state?: 'idle' | 'selected' | 'applied'; } interface ImageMapPinProps extends BaseMapPinProps { /** * Icon to display in the map pin. */ icon?: never; /** * Image to display in the map pin. */ image: ImageProps; } interface IconMapPinProps extends BaseMapPinProps { /** * Icon to display in the map pin. */ icon: IconName; /** * Image to display in the map pin. */ image?: never; } export type MapPinProps = ImageMapPinProps | IconMapPinProps; export {};