/**
 * Living Docs Updater for Pull Sync (Increment 0089)
 *
 * Applies pulled changes from external tools to living documentation.
 * Updates YAML frontmatter with sync metadata and changed field values.
 *
 * Features:
 * - Apply status/priority/assignee changes to living docs
 * - Add sync metadata (lastPulledAt, externalModifiedAt, externalModifiedBy)
 * - Preserve format of non-synced fields (title, description, ACs)
 *
 * @module sync/living-docs-updater
 */
import { Logger } from '../utils/logger.js';
import { ExternalChange } from './external-change-puller.js';
import { ConflictResolution } from '../../plugins/specweave/lib/integrations/ado/conflict-resolver.js';
/**
 * Options for applying a single change
 */
export interface ApplyChangeOptions {
    /**
     * Path to the living doc file (spec.md, user-story.md, etc.)
     */
    filePath: string;
    /**
     * External change to apply
     */
    change: ExternalChange;
    /**
     * Local file modification timestamp (for conflict resolution)
     */
    localModified?: string;
}
/**
 * Result of applying a change
 */
export interface ApplyChangeResult {
    applied: boolean;
    filePath: string;
    conflictResolution?: ConflictResolution;
    error?: string;
}
/**
 * Living Docs Updater Options
 */
export interface LivingDocsUpdaterOptions {
    /**
     * Project root directory
     */
    projectRoot: string;
    /**
     * Logger instance
     */
    logger?: Logger;
}
/**
 * LivingDocsUpdater - Applies external changes to living documentation
 */
export declare class LivingDocsUpdater {
    private readonly projectRoot;
    private readonly logger;
    private readonly conflictResolver;
    constructor(options: LivingDocsUpdaterOptions);
    /**
     * Apply multiple changes to living docs
     *
     * @param changes - Array of external changes to apply
     * @param fileMapping - Map of externalId -> filePath for linked docs
     * @returns Array of results for each change
     */
    applyChanges(changes: ExternalChange[], fileMapping: Map<string, string>): Promise<ApplyChangeResult[]>;
    /**
     * Apply a single change to a living doc file
     */
    applyChange(options: ApplyChangeOptions): Promise<ApplyChangeResult>;
    /**
     * Update frontmatter with sync metadata
     */
    private updateSyncMetadata;
    /**
     * Map external status to SpecWeave status
     */
    private mapExternalStatus;
    /**
     * Update a single frontmatter field
     *
     * @param filePath - Path to the living doc file
     * @param field - Field name to update
     * @param value - New value for the field
     */
    updateFrontmatter(filePath: string, field: string, value: unknown): Promise<boolean>;
}
//# sourceMappingURL=living-docs-updater.d.ts.map