import React, { cloneElement, useMemo } from 'react'; import { Animated, PanResponder, Platform } from 'react-native'; import { Box } from '../Box'; import useTheme from '../../context/theme/useTheme'; import createSxStyle from '../../lib/sx'; import { BottomSheetProps } from './types'; import { Modal } from '../Modal'; import { Button } from '../Button'; import { CloseIcon } from '../../icons'; import { isValidChild } from '../../utils/render'; import { Text } from '../Text'; import { getOpacity } from '../../utils'; export const BottomSheet: React.FC = ({ children, visible, onClose, fullScreen, sx, headerSx, styles, containerStyle, containerSx, contentStyle, contentSx, headerPan, title, height, width, headerStyle = {}, animationType = 'slide', showHeaderPan = Platform.select({ web: false, default: true, }), closeButton = (