import { SettingsFileScope, SettingsValueView, SettingsWriteRequest } from "../../types/settings.mjs"; import { SettingsFieldContribution } from "@agimon-ai/po-core/web"; //#region src/web/lib/settingsDraft.d.ts export declare function settingsKeyOf(field: SettingsFieldContribution): string; /** Why a field cannot be edited at the selected scope, or nothing. */ export declare function settingsLockedReason(view: SettingsValueView | undefined, scope: SettingsFileScope): string | undefined; export interface PlannedWritesInput { fields: readonly SettingsFieldContribution[]; /** Pending edits by dotted key; null clears the key. */ drafts: Readonly>; scope: SettingsFileScope; repoRoot: string; /** The target file's hash when the page last read it. */ startingHash: string; } /** * The typed edits a save combines into one request with the file's read hash. * Keeping contribution order makes the result predictable for callers. */ export declare function plannedSettingsWrites(input: PlannedWritesInput): SettingsWriteRequest[]; /** Whether a save can be attempted at all: something changed, and it can land somewhere. */ export declare function canSaveSettings(input: { dirty: number; scope: SettingsFileScope; repoRoot: string; }): boolean; //#endregion //# sourceMappingURL=settingsDraft.d.mts.map