namespace ClaudeDo.Data.Repositories;

public enum DiscardPlanningResult
{
    /// <summary>Planning state cleared, children handled.</summary>
    Discarded,
    /// <summary>Parent not found or not in <c>PlanningPhase.Active</c>.</summary>
    NotInPlanning,
    /// <summary>At least one child is <c>Queued</c> and the caller did not opt in to auto-dequeue.</summary>
    BlockedByQueuedChildren,
    /// <summary>At least one child is <c>Running</c>; user must cancel it before discarding.</summary>
    BlockedByRunningChildren,
}

public readonly record struct DiscardPlanningOutcome(
    DiscardPlanningResult Result,
    int QueuedChildrenCount,
    int RunningChildrenCount);
