import { EventModel } from '../types/scheduler-types'; import { CrudAction } from '../types/enums'; /** * Gets the following parent event from following occurrences * * @param {EventModel} occurrence - The event with followingId * @param {EventModel[]} eventsProcessed - All processed events * @returns {EventModel | undefined} - The following parent event * @private */ export declare function getFollowingParent(occurrence: EventModel, eventsProcessed: EventModel[]): EventModel | undefined; /** * Merges recurrence rule end dates from following event with parent event structure * If following event has UNTIL or COUNT, replaces parent's end constraint with following's * If following event has no end constraint (infinite), removes end date from parent rule * * @param {EventModel} parentEvent - The parent event with original recurrence rule * @param {EventModel[]} eventsProcessed - Array of processed events to find following event * @returns {string | undefined} - Merged recurrence rule or undefined if no following event found * @private */ export declare function getMergedRecurrenceRule(parentEvent: EventModel, eventsProcessed?: EventModel[]): string | undefined; /** * Handles editing the current and following occurrences of a recurring event * Creates new parent event for following series with split rule * Updates original parent to end before following date * * @param {EventModel} originalEvent - The occurrence being edited * @param {EventModel} parentEvent - New event data (startTime, endTime, subject, etc.) * @param {EventModel[]} eventsData - Original events datasource for ID generation * @returns {Object} - { updatedParent, newFollowingParent, changedOccurrence } * @private */ export declare function editFollowingEvents(originalEvent: EventModel, parentEvent: EventModel, eventsData: EventModel[]): { updatedParent: EventModel; originalEvent: EventModel; changedOccurrence: EventModel | undefined; }; /** * Gets the following parent event from following occurrences * * @param {Date} occurrenceTime - The start time of the occurrence being edited * @param {Date} parentTime - The start time of the parent event * @returns {boolean} - Whether the occurrence is a following event * @private */ export declare function isValidFollowingTime(occurrenceTime: Date, parentTime: Date): boolean; /** * Gets following parent events and their occurrences linked to a parent event * * @param {EventModel} parentEvent - The parent event to find following events for * @param {EventModel[]} eventsProcessed - All processed events * @returns {Object} - { followingParentEvents, followingOccurrences } * @private */ export declare function getFollowingParentEventsAndOccurrences(parentEvent: EventModel, eventsProcessed: EventModel[]): { followingParentEvents: EventModel[]; followingOccurrences: EventModel[]; }; /** * Handles deleting the current and following occurrences of a recurring event * Updates original parent rule to end before the deletion date * * @param {EventModel} originalEvent - The occurrence being deleted * @param {EventModel[]} eventsProcessed - All processed events * @param {EventModel} originalParent - (Optional) The original parent event, if already determined to avoid redundant lookup * @returns {Object} - { updatedParent, deletedIds } * @private */ export declare function deleteFollowingEvents(originalEvent: EventModel, eventsProcessed: EventModel[], originalParent: EventModel): { updatedParent: EventModel; deletedEvents: EventModel[]; }; /** * Validates recurrence pattern to ensure start/end times are within the interval bounds. * For example, if interval is 1 (DAILY), start and end should be within the same day. * * @param {EventModel} eventData - Event to validate * @returns {string | null} Message key if invalid, null if valid * @private */ export declare function validateRecurrencePattern(eventData: EventModel): string | null; /** * Filters events by recurrence ID and returns matching events along with parent event. * Used when we need to identify the parent event while filtering by recurrence ID. * * @param {EventModel[]} events The events array to filter * @param {string | number} recurrenceID The recurrence ID to match against * @param {boolean} forFollowingEvent Filter parent related events * @returns {Object} Filtered events and parent event * @private */ export declare function filterEventsByRecurrenceIdWithParent(events: EventModel[], recurrenceID: string | number, forFollowingEvent?: boolean): { events: EventModel[]; parentEvent?: EventModel; }; /** * Converts a recurrence alert selection option to the appropriate edit action. * Maps user selection from recurrence dialog to the corresponding edit CrudAction. * Handles special case for EditFollowingEvents where selectOption needs conversion. * Common function used across multiple components for edit operations. * * @param {string} selectOption - The selected option from recurrence alert * @param {string} currentAction - The current action context ('EditFollowingEvents', 'EditSeries', etc.) * @returns {CrudAction} - The corresponding edit action * @private */ export declare function getRecurrenceEditAction(selectOption: string, currentAction: string): CrudAction; /** * Maps the current editor action context to the appropriate delete action. * Used during delete confirmation when user is in EditFollowingEvents or EditSeries context. * Common function used in editor delete handlers to determine which delete operation to perform. * * @param {string} action - The current editor action ('EditFollowingEvents', 'EditSeries', 'EditOccurrence', etc.) * @param {boolean} hasRecurrenceID - Whether the event has a recurrenceID (indicates occurrence) * @returns {CrudAction} - The corresponding delete action * @private */ export declare function getActionBasedDeleteAction(action: string, hasRecurrenceID: boolean): CrudAction; /** * Determines the appropriate save action when series events have changed. * Maps the editor action context and event IDs to determine if we're editing current + following or just the series. * Used after user confirms series change in the recurrence alert dialog. * * @param {string} action - The current editor action ('EditFollowingEvents', 'EditSeries') * @param {any} eventDataId - The modified event's ID * @param {any} eventDataRecurrenceID - The modified event's recurrence ID * @returns {CrudAction} - The appropriate save action * @private */ export declare function getActionBasedSaveAction(action: string, eventDataId: string | number, eventDataRecurrenceID: string | number): CrudAction;