/** * AutoWrapup class implements a timer for automatic wrap-up functionality. * It handles timing the wrap-up period and executing a callback when the timer completes. */ export default class AutoWrapup { private timer; private startTime; private readonly interval; allowCancelAutoWrapup: boolean; /** * Creates a new AutoWrapup timer * @param interval - Time in milliseconds before auto wrap-up executes * @param allowCancelAutoWrapup - Whether to allow canceling the auto wrap-up */ constructor(interval: number, allowCancelAutoWrapup?: boolean); /** * Starts the auto wrap-up timer * @param onComplete - Callback function to execute when timer completes */ start(onComplete: () => void): void; /** * Clears the auto wrap-up timer if it's running */ clear(): void; /** * Gets the remaining time in milliseconds * @returns Time left in milliseconds */ getTimeLeft(): number; /** * Checks if the timer is currently running * @returns True if the timer is running, false otherwise */ isRunning(): boolean; /** * Gets the remaining time in seconds (rounded) * @returns Time left in seconds */ getTimeLeftSeconds(): number; }