declare const RIDDLE_PROOF_BASIC_GAMEPLAY_VERSION = "riddle-proof.basic-gameplay.v1";
declare const RIDDLE_PROOF_BASIC_GAMEPLAY_ASSESSMENT_VERSION = "riddle-proof.basic-gameplay.assessment.v1";
declare const RIDDLE_PROOF_BASIC_GAMEPLAY_CATCH_VERSION = "riddle-proof.basic-gameplay.catch.v1";
type BasicGameplayFailureCode = "route_http_error" | "fatal_page_error" | "route_blank_or_thin" | "no_game_surface" | "mobile_horizontal_overflow" | "responsive_bounds_clipped" | "primary_control_missing" | "primary_control_inert" | "progression_assertion_failed" | "responsive_setup_failed";
type BasicGameplayWarningCode = "canvas_inert" | "some_actions_failed" | "missing_reset_path" | "critical_console_error";
interface BasicGameplayCanvasState {
    index?: number;
    width?: number;
    height?: number;
    css_width?: number;
    css_height?: number;
    visible?: boolean;
    readable?: boolean;
    hash?: string | null;
}
interface BasicGameplaySnapshot {
    screenshot_hash?: string | null;
    visual_sample_hash?: string | null;
    viewport_screenshot_hash?: string | null;
    artifact_screenshot_hash?: string | null;
    artifact_screenshot?: BasicGameplayProofArtifact | null;
    dom_signature_hash?: string | null;
    body_text_hash?: string | null;
    body_text_length?: number;
    visible_large_node_count?: number;
    enabled_clickable_count?: number;
    reset_control_count?: number;
    visible_canvas_count?: number;
    canvases?: BasicGameplayCanvasState[];
    first_canvas_hash?: string | null;
    first_canvas_visual_sample_hash?: string | null;
    [key: string]: unknown;
}
interface BasicGameplayActionResult {
    ok?: boolean;
    action?: string;
    [key: string]: unknown;
}
declare const BASIC_GAMEPLAY_ACTION_TYPES: readonly ["wait", "key", "key-down", "key-up", "hold-key", "repeat", "click", "click-by-text", "set-input-value", "canvas-click", "canvas-pointer-down", "canvas-pointer-move", "canvas-pointer-up", "wait-for-text", "window-call", "evaluate"];
declare const BASIC_GAMEPLAY_PROGRESS_CHECK_TYPES: readonly ["selector_count_increases", "selector_count_at_least", "selector_count_equals", "selector_count_equal", "selector_count_eq", "selector_absent", "selector_text_matches", "number_increases", "number_decreases", "number_at_least", "number_gte", "number_unchanged", "number_stays_equal", "number_equals", "canvas_hash_changes", "screenshot_hash_changes", "visual_hash_changes", "state_changes"];
type BasicGameplayActionType = typeof BASIC_GAMEPLAY_ACTION_TYPES[number] | (string & {});
type BasicGameplayProgressCheckType = typeof BASIC_GAMEPLAY_PROGRESS_CHECK_TYPES[number] | (string & {});
interface BasicGameplayMetric {
    phase?: string;
    label?: string;
    selector?: string | null;
    state_path?: string | null;
    state_call?: string | null;
    property_path?: string | null;
    present?: boolean;
    text?: string | null;
    pattern_matched?: boolean | null;
    number?: number | null;
    count?: number | null;
    value_type?: string | null;
    error?: string | null;
    screenshot_hash?: string | null;
    visual_sample_hash?: string | null;
    viewport_screenshot_hash?: string | null;
    artifact_screenshot_hash?: string | null;
    artifact_screenshot?: BasicGameplayProofArtifact | null;
    dom_signature_hash?: string | null;
    body_text_hash?: string | null;
    first_canvas_hash?: string | null;
    first_canvas_visual_sample_hash?: string | null;
    visible_canvas_count?: number | null;
    [key: string]: unknown;
}
interface BasicGameplayArtifactResolution {
    source: "riddle_screenshot_artifacts" | (string & {});
    before_hash?: string | null;
    after_hash?: string | null;
    [key: string]: unknown;
}
interface BasicGameplayProgressionCheck {
    label?: string;
    type?: BasicGameplayProgressCheckType;
    selector?: string | null;
    state_path?: string | null;
    state_call?: string | null;
    property_path?: string | null;
    from_phase?: string;
    to_phase?: string;
    expected?: unknown;
    value?: unknown;
    min?: unknown;
    max?: unknown;
    pattern?: string;
    flags?: string;
    ok?: boolean;
    reason?: string | null;
    before?: BasicGameplayMetric | null;
    after?: BasicGameplayMetric | null;
    artifact_resolution?: BasicGameplayArtifactResolution;
    [key: string]: unknown;
}
interface BasicGameplaySuiteFailure {
    code: "progression_assertion_failed" | "responsive_setup_failed" | "responsive_bounds_clipped";
    label?: string;
    reason?: string | null;
    selector?: string | null;
    state_path?: string | null;
    state_call?: string | null;
    property_path?: string | null;
    overflow_px?: number | null;
    max_allowed_px?: number | null;
    offenders?: BasicGameplayBoundsOffender[];
    viewport?: {
        label?: string | null;
        width?: number | null;
        height?: number | null;
        phase?: string | null;
    };
    action_result?: BasicGameplayActionResult;
}
interface BasicGameplayBoundsOffender {
    selector?: string | null;
    tag?: string | null;
    overflow?: number;
    overflow_px?: number;
    left_overflow_px?: number;
    right_overflow_px?: number;
    bounds_overflow_px?: number;
    clipped?: Record<string, unknown>;
    rect?: Record<string, unknown>;
    bounds?: Record<string, unknown>;
    viewport_width?: number;
    viewportWidth?: number;
    [key: string]: unknown;
}
interface BasicGameplayResponsiveViewportEvidence {
    label?: string;
    width?: number;
    height?: number;
    phase?: string;
    overflow_px?: number;
    bounds_overflow_px?: number;
    overflow_offenders?: BasicGameplayBoundsOffender[];
    setup_action_results?: BasicGameplayActionResult[];
    setupActionResults?: BasicGameplayActionResult[];
    [key: string]: unknown;
}
interface BasicGameplayMobileEvidence {
    overflow_px?: number;
    bounds_overflow_px?: number;
    overflow_offenders?: BasicGameplayBoundsOffender[];
    [key: string]: unknown;
}
interface RiddleProofBasicGameplayRouteEvidence {
    name?: string;
    path?: string;
    assessment_mode?: string | null;
    assessmentMode?: string | null;
    proof_mode?: string | null;
    proofMode?: string | null;
    audit?: boolean;
    http_status?: number | null;
    response_status?: number | null;
    status?: number | null;
    console_error_count?: number;
    page_error_count?: number;
    initial?: BasicGameplaySnapshot;
    timed?: BasicGameplaySnapshot;
    after_action?: BasicGameplaySnapshot;
    afterAction?: BasicGameplaySnapshot;
    after_continue?: BasicGameplaySnapshot;
    afterContinue?: BasicGameplaySnapshot;
    after_cleanup?: BasicGameplaySnapshot;
    afterCleanup?: BasicGameplaySnapshot;
    mobile?: BasicGameplayMobileEvidence;
    action_results?: BasicGameplayActionResult[];
    actionResults?: BasicGameplayActionResult[];
    continued_action_results?: BasicGameplayActionResult[];
    continuedActionResults?: BasicGameplayActionResult[];
    continued_cleanup_action_results?: BasicGameplayActionResult[];
    continuedCleanupActionResults?: BasicGameplayActionResult[];
    restart_action_results?: BasicGameplayActionResult[];
    restartActionResults?: BasicGameplayActionResult[];
    responsive_viewports?: BasicGameplayResponsiveViewportEvidence[];
    responsiveViewports?: BasicGameplayResponsiveViewportEvidence[];
    progression_checks?: BasicGameplayProgressionCheck[];
    progressionChecks?: BasicGameplayProgressionCheck[];
    requires_reset?: boolean;
    [key: string]: unknown;
}
interface RiddleProofBasicGameplayEvidence {
    version?: typeof RIDDLE_PROOF_BASIC_GAMEPLAY_VERSION | string;
    site?: string | null;
    base_url?: string;
    results?: RiddleProofBasicGameplayRouteEvidence[];
    [key: string]: unknown;
}
interface AssessBasicGameplayOptions {
    maxMobileOverflowPx?: number;
    minBodyTextLength?: number;
    minVisibleLargeNodes?: number;
    minSurfaceLargeNodes?: number;
    warnOnMissingResetPath?: boolean;
    warnOnConsoleError?: boolean;
    failOnConsoleError?: boolean;
}
interface BasicGameplayChangeSummary {
    body_text_changed: boolean;
    screenshot_changed: boolean;
    canvas_changed: boolean;
    changed: boolean;
}
interface RiddleProofBasicGameplayRouteAssessment {
    name?: string;
    path?: string;
    assessment_mode?: string | null;
    ok: boolean;
    failures: BasicGameplayFailureCode[];
    warnings: BasicGameplayWarningCode[];
    suite_failures?: BasicGameplaySuiteFailure[];
    signals: {
        route_loaded: boolean;
        surface_visible: boolean;
        action_attempted: boolean;
        timed_progression_observed: boolean;
        first_interaction_observed: boolean;
        state_change_observed: boolean;
        mobile_overflow_absent: boolean;
        reset_path_present: boolean;
        fatal_errors_absent: boolean;
    };
    diffs: {
        timed: BasicGameplayChangeSummary;
        after_action: BasicGameplayChangeSummary;
        after_continue?: BasicGameplayChangeSummary;
        after_cleanup?: BasicGameplayChangeSummary;
    };
}
interface RiddleProofBasicGameplayAssessment {
    version: typeof RIDDLE_PROOF_BASIC_GAMEPLAY_ASSESSMENT_VERSION;
    evidence_present: boolean;
    passed: boolean;
    checked_routes: number;
    passing_routes: number;
    failing_routes: Array<{
        name?: string;
        path?: string;
        assessment_mode?: string | null;
        failures: BasicGameplayFailureCode[];
        warnings: BasicGameplayWarningCode[];
        suite_failures?: BasicGameplaySuiteFailure[];
    }>;
    failure_counts: Record<string, number>;
    warning_counts: Record<string, number>;
    route_results: RiddleProofBasicGameplayRouteAssessment[];
}
interface BasicGameplayProofArtifact {
    name: string;
    role?: string;
    kind?: string;
    url?: string;
    path?: string;
    sha256?: string;
    [key: string]: unknown;
}
interface BasicGameplayRouteReference {
    name?: string;
    path?: string;
    [key: string]: unknown;
}
interface AttachBasicGameplayArtifactOptions {
    routes?: BasicGameplayRouteReference[];
    artifacts?: BasicGameplayProofArtifact[];
}
interface BasicGameplayCatchRecord {
    site?: string | null;
    route?: string;
    path?: string;
    code: string;
    label?: string;
    type?: string;
    selector?: string | null;
    state_path?: string | null;
    state_call?: string | null;
    property_path?: string | null;
    reason?: string | null;
    phase?: string;
    from_phase?: string;
    to_phase?: string;
    before?: BasicGameplayMetric | null;
    after?: BasicGameplayMetric | null;
    action_result?: BasicGameplayActionResult;
    console_errors?: unknown[];
    page_errors?: unknown[];
    summary: string;
    [key: string]: unknown;
}
interface BasicGameplayFixReference {
    repo?: string;
    commit?: string;
    pr_url?: string;
    summary?: string;
    [key: string]: unknown;
}
interface CreateBasicGameplayCatchSummaryInput {
    title?: string;
    site?: string;
    route?: string;
    detected_at?: string;
    before: unknown;
    after?: unknown;
    fix?: BasicGameplayFixReference;
    artifacts?: BasicGameplayProofArtifact[];
}
interface BasicGameplayAssessmentSummary {
    evidence_present: boolean;
    passed: boolean;
    checked_routes: number;
    passing_routes: number;
    failing_routes: RiddleProofBasicGameplayAssessment["failing_routes"];
    failure_counts: Record<string, number>;
    warning_counts: Record<string, number>;
    notable_codes: string[];
}
interface RiddleProofBasicGameplayCatchSummary {
    version: typeof RIDDLE_PROOF_BASIC_GAMEPLAY_CATCH_VERSION;
    title: string;
    site?: string;
    route?: string;
    detected_at: string;
    before: BasicGameplayAssessmentSummary;
    after?: BasicGameplayAssessmentSummary;
    fixed: boolean;
    fix?: BasicGameplayFixReference;
    artifacts: BasicGameplayProofArtifact[];
    summary_lines: string[];
    marketing_summary: string;
}
declare function assessBasicGameplayEvidence(evidence: unknown, options?: AssessBasicGameplayOptions): RiddleProofBasicGameplayAssessment;
declare function assessBasicGameplayRoute(route: RiddleProofBasicGameplayRouteEvidence, options?: AssessBasicGameplayOptions): RiddleProofBasicGameplayRouteAssessment;
declare function sanitizeBasicGameplayJsonString(value: unknown): string;
declare function compactBasicGameplayText(value: unknown, max?: number): string;
declare function assessBasicGameplayProgressionCheck(check: BasicGameplayProgressionCheck): BasicGameplayProgressionCheck;
declare function assessBasicGameplayProgressionChecks(route: RiddleProofBasicGameplayRouteEvidence): BasicGameplayProgressionCheck[];
declare function augmentBasicGameplayAssessmentWithProgressionChecks(assessment: RiddleProofBasicGameplayAssessment, evidence: unknown, options?: AssessBasicGameplayOptions): RiddleProofBasicGameplayAssessment;
declare function resolveBasicGameplayProgressionCheckWithArtifactScreenshots(check: BasicGameplayProgressionCheck): BasicGameplayProgressionCheck;
declare function attachBasicGameplayArtifactScreenshotHashes(evidence: RiddleProofBasicGameplayEvidence, routesOrOptions?: BasicGameplayRouteReference[] | AttachBasicGameplayArtifactOptions, maybeArtifacts?: BasicGameplayProofArtifact[]): RiddleProofBasicGameplayEvidence;
declare function createBasicGameplayCatchRecords(assessment: RiddleProofBasicGameplayAssessment, evidence: unknown, options?: AssessBasicGameplayOptions): BasicGameplayCatchRecord[];
declare function createBasicGameplayCatchSummary(input: CreateBasicGameplayCatchSummaryInput, options?: AssessBasicGameplayOptions): RiddleProofBasicGameplayCatchSummary;
declare function extractBasicGameplayEvidence(...sources: unknown[]): RiddleProofBasicGameplayEvidence | null;

export { type AssessBasicGameplayOptions, type AttachBasicGameplayArtifactOptions, BASIC_GAMEPLAY_ACTION_TYPES, BASIC_GAMEPLAY_PROGRESS_CHECK_TYPES, type BasicGameplayActionResult, type BasicGameplayActionType, type BasicGameplayArtifactResolution, type BasicGameplayAssessmentSummary, type BasicGameplayBoundsOffender, type BasicGameplayCanvasState, type BasicGameplayCatchRecord, type BasicGameplayChangeSummary, type BasicGameplayFailureCode, type BasicGameplayFixReference, type BasicGameplayMetric, type BasicGameplayMobileEvidence, type BasicGameplayProgressCheckType, type BasicGameplayProgressionCheck, type BasicGameplayProofArtifact, type BasicGameplayResponsiveViewportEvidence, type BasicGameplayRouteReference, type BasicGameplaySnapshot, type BasicGameplaySuiteFailure, type BasicGameplayWarningCode, type CreateBasicGameplayCatchSummaryInput, RIDDLE_PROOF_BASIC_GAMEPLAY_ASSESSMENT_VERSION, RIDDLE_PROOF_BASIC_GAMEPLAY_CATCH_VERSION, RIDDLE_PROOF_BASIC_GAMEPLAY_VERSION, type RiddleProofBasicGameplayAssessment, type RiddleProofBasicGameplayCatchSummary, type RiddleProofBasicGameplayEvidence, type RiddleProofBasicGameplayRouteAssessment, type RiddleProofBasicGameplayRouteEvidence, assessBasicGameplayEvidence, assessBasicGameplayProgressionCheck, assessBasicGameplayProgressionChecks, assessBasicGameplayRoute, attachBasicGameplayArtifactScreenshotHashes, augmentBasicGameplayAssessmentWithProgressionChecks, compactBasicGameplayText, createBasicGameplayCatchRecords, createBasicGameplayCatchSummary, extractBasicGameplayEvidence, resolveBasicGameplayProgressionCheckWithArtifactScreenshots, sanitizeBasicGameplayJsonString };
