import { type LucideIcon } from 'lucide-react';
import type { Node } from '@xyflow/react';
import type { PrStatus, CiStatus, DeploymentState } from '../../../../../../packages/core/src/domain/generated/output.js';
import type { AgentTypeValue } from './agent-type-icons.js';
export type FeatureNodeState = 'creating' | 'running' | 'action-required' | 'done' | 'blocked' | 'pending' | 'error' | 'deleting' | 'archived';
export type FeatureLifecyclePhase = 'pending' | 'requirements' | 'research' | 'implementation' | 'review' | 'awaitingUpstream' | 'deploy' | 'maintain';
/** Human-readable display labels for lifecycle phases. */
export declare const lifecycleDisplayLabels: Record<FeatureLifecyclePhase, string>;
/** Inline-start border color for each lifecycle phase. */
export declare const lifecycleBorderColors: Record<FeatureLifecyclePhase, string>;
/** Accent bar background color for each lifecycle phase. */
export declare const lifecycleAccentColors: Record<FeatureLifecyclePhase, string>;
/** Phase badge: short letter, color classes, and user-friendly tooltip. */
export declare const lifecyclePhaseBadge: Record<FeatureLifecyclePhase, {
    letter: string;
    bg: string;
    text: string;
    dot: string;
    tooltip: string;
    description: string;
}>;
/** State-based inline-start border overrides (takes precedence over lifecycle). */
export declare const stateBorderColors: Partial<Record<FeatureNodeState, string>>;
/** State-based accent bar overrides (takes precedence over lifecycle). */
export declare const stateAccentColors: Partial<Record<FeatureNodeState, string>>;
/** Present-participle verbs for the running badge, keyed by lifecycle phase. */
export declare const lifecycleRunningVerbs: Record<FeatureLifecyclePhase, string>;
export interface FeatureNodeData {
    [key: string]: unknown;
    name: string;
    description?: string;
    featureId: string;
    lifecycle: FeatureLifecyclePhase;
    state: FeatureNodeState;
    progress: number;
    /** Absolute path to the repository on disk */
    repositoryPath: string;
    /** Git branch name for this feature */
    branch: string;
    /** Absolute path to the git worktree for this feature (sessions use this path) */
    worktreePath?: string;
    /** Absolute path to the specs folder on disk */
    specPath?: string;
    /** Epoch ms when the current agent run started (for elapsed-time in sidebar) */
    startedAt?: number;
    /** Human-readable runtime for done state (e.g. "2h 15m") */
    runtime?: string;
    /** Feature name this node is blocked by */
    blockedBy?: string;
    /** Short error message for error state */
    errorMessage?: string;
    /** Whether the feature was created in fast mode (skip SDLC phases). */
    fastMode?: boolean;
    /** Agent executor type (e.g. "claude-code", "cursor"). */
    agentType?: AgentTypeValue;
    /** LLM model identifier used for this feature's agent run. */
    modelId?: string;
    /** Feature summary / user query */
    summary?: string;
    /** Epoch ms or ISO string when the feature was created */
    createdAt?: string | number;
    /** Repository display name (e.g. "my-repo") */
    repositoryName?: string;
    /** Domain UUID of the parent Application when this feature was launched
     *  scoped to an Application (SDD mode). Carried through the server→client
     *  boundary so derive-graph can render an app→feature parent edge instead
     *  of the default repo→feature edge. */
    applicationId?: string;
    /** Remote URL for the repository (HTTPS, suitable for browser linking) */
    remoteUrl?: string;
    /** Base branch the feature was branched from (e.g. "main") */
    baseBranch?: string;
    /** AI-generated one-line description of the feature (from spec artifact) */
    oneLiner?: string;
    /** Original user query that initiated this feature */
    userQuery?: string;
    /** PR metadata for features with an associated pull request */
    pr?: {
        url: string;
        number: number;
        status: PrStatus;
        ciStatus?: CiStatus;
        commitHash?: string;
        mergeable?: boolean;
    };
    /** Approval gates configuration for phase transitions */
    approvalGates?: {
        allowPrd: boolean;
        allowPlan: boolean;
        allowMerge: boolean;
    };
    /** Whether to push branch to remote after implementation */
    push?: boolean;
    /** Whether to open a PR after implementation */
    openPr?: boolean;
    /** Whether CI watch/fix loop is enabled after push */
    ciWatchEnabled?: boolean;
    /** Whether evidence collection is enabled for this feature */
    enableEvidence?: boolean;
    /** Whether evidence is committed to the PR body */
    commitEvidence?: boolean;
    /** Whether to fork the repo and create a PR to upstream */
    forkAndPr?: boolean;
    /** Whether to commit specs into the repository */
    commitSpecs?: boolean;
    /** Whether to hide CI status badges from UI */
    hideCiStatus?: boolean;
    /** Whether the feature has an associated agent run (for log tab visibility) */
    hasAgentRun?: boolean;
    /** Whether the feature has plan data available */
    hasPlan?: boolean;
    /** Deployment status for features with an active deployment */
    deployment?: {
        status: DeploymentState;
        url?: string;
    };
    onAction?: () => void;
    onSettings?: () => void;
    hasChildren?: boolean;
    /** Whether skill injection was enabled for this feature */
    injectSkills?: boolean;
    /** Skills that were injected into this feature's worktree */
    injectedSkills?: string[];
    onDelete?: (featureId: string, cleanup?: boolean, cascadeDelete?: boolean, closePr?: boolean) => void;
    onRetry?: (featureId: string) => void;
    onStart?: (featureId: string) => void;
    onStop?: (featureId: string) => void;
    onArchive?: (featureId: string) => void;
    onUnarchive?: (featureId: string) => void;
    showHandles?: boolean;
}
export type FeatureNodeType = Node<FeatureNodeData, 'featureNode'>;
export interface FeatureNodeStateConfig {
    icon: LucideIcon;
    borderClass: string;
    labelClass: string;
    progressClass: string;
    badgeClass: string;
    badgeBgClass: string;
    label: string;
    showProgressBar: boolean;
}
export declare const featureNodeStateConfig: Record<FeatureNodeState, FeatureNodeStateConfig>;
//# sourceMappingURL=feature-node-state-config.d.ts.map