import { type Dayjs } from 'dayjs'
import { type ListFrontEndInterface } from '../CommonType'

export interface EventStateType {
    EventList: EventlistFormDataInterface[]
    EventListCount: number
}
export interface EventlistFormDataInterface {
    eventId: number
    eventTitle: string
    description: string
    startFrom: string
    endTo: string
    isEmailSent: number

    generalEventFollowerList: Array<{
        eventFollowerId: number
        eventId: number
        userId: number
        userName: string
        imageUrl: string
        emailAddress: string
    }>
    userIds: number[] | null
    createdBy: string
    eventType: number
    recurringFrequency: number
    recurringFrequencyType: number
    recurringFrequencyPeriodId: number
    recurringEnds: number
    recurringOccurrence: number
    recurringEndsOn: string | null
    isRepeatOnSun: number
    isRepeatOnMon: number
    isRepeatOnTue: number
    isRepeatOnWed: number
    isRepeatOnThu: number
    isRepeatOnFri: number
    isRepeatOnSat: number
}
export interface EventListDataTypeInterface extends EventlistFormDataInterface {
    key: React.Key
}
export interface EvenetPayloadInteface {
    data: EventlistFormDataInterface[]
    noOfRecords: number
}
export interface Event {
    eventId: string
    startFrom: string
    userid: number
    endTo: string
    description: string
    participants: string
}

export interface PropsApp {
    selectedDate: Dayjs
    selectedEvent: any
    selectedEvents: any
    onDeleteEvent: (eventId: number) => void
    setModaleventVisible: React.Dispatch<React.SetStateAction<boolean>>
}
export interface EventData {
    eventId: number
    eventType: number
    eventTitle: string
    description: string
    startFrom: moment.Moment
    endTo: moment.Moment
    isEmailSent: number
    userIds: number[]
    // Add more properties if necessary
}
export interface userlistEvent {
    userList: ListFrontEndInterface[]
}
export interface ManageDiaryFormProps {
    date: Dayjs
    userList: SelectOption[]
    initialFormData: any
    oncloseEventModal: () => void
}
interface SelectOption {
    label: string
    value: number | null // `null` added for the 'Please select' option
}
