/**
 * Optimistic Mutation Error Classes
 * Defines error types for optimistic UI updates with rollback support
 */
/**
 * Mutation error - occurs when the server rejects the mutation
 * Retryable: Depends on error type (network yes, validation no)
 */
/**
 * Queue error - occurs when action queue operations fail
 * Retryable: Yes (queue operations can be retried)
 */
class QueueError extends Error {
    constructor(message, actionId, details) {
        super(message);
        this.actionId = actionId;
        this.details = details;
        this.type = "queue";
        this.retryable = true;
        this.name = "QueueError";
        // Queue errors don't have original/rollback data
        this.originalData = undefined;
        this.rollbackData = undefined;
    }
}

export { QueueError };
