import {useState, Component } from 'react';
import { Alert, Button, StyleSheet, Text, Pressable, View, TouchableOpacity } from "react-native";
import CalendarPicker from 'react-native-calendar-picker';
import Modal from "react-native-modal";
function App()
{
const [isModalVisible, setIsModalVisible] = useState(true);
return (
<View style={{ flex: 1, alignItems:"center", justifyContent:"center" }}>
<View>
<Modal isVisible={isModalVisible}>
<View style={{ flex: 1, justifyContent:"center", alignItems:"center" }}>
<CalendarPicker />
</View>
<TouchableOpacity onPress={()=> setIsModalVisible(!isModalVisible)}>
<Text>
Click Me
</Text>
</TouchableOpacity>
</Modal>
</View>
<TouchableOpacity onPress={()=> setIsModalVisible(!isModalVisible)}>
<Text>
Click Me
</Text>
</TouchableOpacity>
</View>
);
}
export default App;