import { View, Text, Button, Switch } from "react-native-ui-lib"; import React, { useEffect, useState } from "react"; import PointsSlider from "@/components/shared/PointsSlider"; import { repeatOptions, useToDosContext } from "@/contexts/ToDosContext"; import { Feather, AntDesign, Ionicons } from "@expo/vector-icons"; import { Dialog, TextField, DateTimePicker, Picker, ButtonSize, } from "react-native-ui-lib"; import { PanningDirectionsEnum } from "react-native-ui-lib/src/incubator/panView"; import { StyleSheet } from "react-native"; import DropModalIcon from "@/assets/svgs/DropModalIcon"; import { CalendarEvent, useCalendarContext } from "@/contexts/CalendarContext"; import ClockIcon from "@/assets/svgs/ClockIcon"; import LockIcon from "@/assets/svgs/LockIcon"; import MenuIcon from "@/assets/svgs/MenuIcon"; import { eventCellCss } from "react-native-big-calendar"; interface IEditEventDialog { event: CalendarEvent; isVisible: boolean; setIsVisible: (value: boolean) => void; } const EditEventDialog = (editEventProps: IEditEventDialog) => { const { updateEvent } = useCalendarContext(); const [event, setEvent] = useState(editEventProps.event); useEffect(() => { setEvent(editEventProps.event); }, [editEventProps.isVisible]); return ( editEventProps.setIsVisible(false)} containerStyle={{ borderRadius: 10, backgroundColor: "white", width: "100%", alignSelf: "stretch", padding: 0, paddingTop: 4, margin: 0, }} visible={editEventProps.isVisible} > ); }; export default EditEventDialog; const styles = StyleSheet.create({ divider: { height: 1, backgroundColor: "#e4e4e4", marginVertical: 15 }, gradient: { height: "25%", position: "absolute", bottom: 0, width: "100%", }, buttonContainer: { position: "absolute", bottom: 25, width: "100%", }, button: { backgroundColor: "rgb(253, 23, 117)", paddingVertical: 20, }, topBtn: { backgroundColor: "white", color: "#05a8b6", }, rotateSwitch: { marginLeft: 35, marginBottom: 10, marginTop: 25, }, });