import React, { ComponentProps, ComponentPropsWithRef } from 'react' import { styled } from '../css/styled' import { Pressable as NativePressable, Platform } from 'react-native' declare module 'react-native' { interface PressableStateCallbackType { hovered?: boolean focused?: boolean } } const StyledPressable = styled(NativePressable)( ({ showCursor }: { showCursor: boolean }) => ({ ...Platform.select({ web: { cursor: showCursor ? 'pointer' : 'default', }, }), }) ) export const Pressable = React.forwardRef(function Pressable( props: Omit, 'showCursor'>, ref?: ComponentPropsWithRef['ref'] ) { return ( ) })