import React from 'react';
import { type TagProps } from './tag';
/**
 * Canonical ticket status values.
 * This is the single source of truth for ticket statuses across all frontends.
 */
export type TicketStatus = 'ACTIVE' | 'AI_ASSISTANCE' | 'TECH_REQUIRED' | 'ON_HOLD' | 'RESOLVED' | 'ARCHIVED';
type TagVariant = NonNullable<TagProps['variant']>;
interface TicketStatusConfig {
    label: string;
    variant: TagVariant;
    icon?: React.ReactNode;
}
/**
 * Resolves any status string to a canonical TicketStatus.
 * Returns null for unknown values.
 */
export declare function resolveTicketStatus(status: string): TicketStatus | null;
/**
 * Returns the display config (label, variant, icon) for a given ticket status.
 * Accepts any known status format (backend, chat, dialog).
 */
export declare function getTicketStatusConfig(status: string): TicketStatusConfig;
/**
 * Returns just the label and variant for use with the Tag component.
 * Drop-in replacement for the getTicketStatusTag utility in openframe-frontend.
 */
export declare function getTicketStatusTag(status: string): {
    label: string;
    variant: TagVariant;
    icon?: React.ReactNode;
};
/** Backend status-definition kinds. */
export type TicketStatusKind = 'AI_ASSISTANCE' | 'TECH_REQUIRED' | 'RESOLVED' | 'ARCHIVED' | 'CUSTOM';
/** Canonical TicketStatus for a backend kind, or undefined for CUSTOM/unknown. */
export declare function kindToCanonicalStatus(kind: string | null | undefined): TicketStatus | undefined;
/**
 * Whether a status of this kind renders with its canonical (system) styling
 * rather than the backend-provided color: AI_ASSISTANCE/RESOLVED/ARCHIVED do;
 * TECH_REQUIRED and custom statuses use their color.
 */
export declare function usesCanonicalStatusStyle(kind: string | null | undefined): boolean;
export interface TicketStatusInput {
    /** Legacy enum status (may be empty/null under the lifecycle feature). */
    status?: string | null;
    /** Backend status kind (AI_ASSISTANCE, TECH_REQUIRED, RESOLVED, ARCHIVED, CUSTOM). */
    statusKind?: string | null;
    /** Custom status display name. */
    statusName?: string | null;
    /** Custom status hex color. */
    statusColor?: string | null;
}
/**
 * Maps a ticket's status fields to TicketStatusTag props, the unified design
 * shared across OpenFrame surfaces: AI_ASSISTANCE/RESOLVED/ARCHIVED render with
 * their canonical variant/icon; TECH_REQUIRED and custom statuses render from the
 * backend color, labelled by the custom status name.
 */
export declare function resolveStatusTagProps(input: TicketStatusInput): {
    status: string;
    label?: string;
    color?: string;
};
/** A selectable status option for the inline status-change dropdown. */
export interface TicketStatusTagOption {
    id: string;
    name: string;
    color: string;
}
export interface TicketStatusTagProps {
    /** Ticket status in any known format (ACTIVE, active, ACTION_REQUIRED, etc.) */
    status: string;
    /** Override the default label */
    label?: string;
    /**
     * Hex color override. Replaces the variant's fill; text
     * color is computed for contrast. The status's preset icon is preserved.
     */
    color?: string;
    /** Override the status's default Tag variant (e.g. force 'outline' or 'primary'). */
    variant?: TagVariant;
    /** Additional className for the Tag */
    className?: string;
    /** Show the status-specific icon (e.g. checkmark for resolved) */
    showIcon?: boolean;
    /**
     * Make the tag an inline status changer. When provided (with `onSelect`), the
     * tag renders with a chevron and opens a dropdown of these options on click.
     */
    options?: TicketStatusTagOption[];
    /** Called with the chosen option id. Required for the inline dropdown. */
    onSelect?: (id: string) => void;
    /** Disables the dropdown while a change is in flight. */
    isPending?: boolean;
}
/**
 * Unified ticket status tag component.
 * Renders a styled Tag with the correct color variant and optional icon
 * for any ticket status value from any layer (backend, dialog, chat).
 */
export declare function TicketStatusTag({ status, label, color, variant, className, showIcon, options, onSelect, isPending, }: TicketStatusTagProps): React.JSX.Element;
export {};
//# sourceMappingURL=ticket-status-tag.d.ts.map