import type { VaultInfo } from "./vault.js"; export interface VaultLayout { /** Content root relative to .napkin/ dir (e.g. ".." for sibling layout) */ root: string; /** .obsidian/ dir relative to .napkin/ dir (e.g. "../.obsidian" for sibling layout) */ obsidian: string; } export interface NapkinConfig { vault?: VaultLayout; overview: { depth: number; /** Max keywords per folder row; 0 = quality-governed, no cap. */ keywords: number; /** Roll up numerous, lexically homogeneous sibling folders into one row. */ collapse: boolean; }; search: { limit: number; snippetLines: number; }; daily: { folder: string; format: string; }; templates: { folder: string; }; graph: { renderer: "auto" | "glimpse" | "browser"; }; } /** The sibling layout: content in the project dir, .napkin/ beside it. */ export declare const SIBLING_VAULT_LAYOUT: VaultLayout; export declare const DEFAULT_CONFIG: NapkinConfig; /** * A private, immutable copy of a caller-supplied config. * * Copied so later edits to the caller's object cannot change an instance * already built from it; frozen so the instance cannot hand out a * configuration the caller can mutate underneath it. */ export declare function freezeConfig(config: NapkinConfig): NapkinConfig; /** * The configuration in force for a vault: the one supplied in code at * construction, or the vault's config.json. * * Every internal read goes through here, and `loadConfig` is private to * this module, so reaching a vault's settings without honouring injection * is a compile error rather than a bug to be found later. */ export declare function effectiveConfig(vault: VaultInfo): NapkinConfig; /** * Save napkin config to config.json in the .napkin/ directory and sync to .obsidian/. * If obsidianDir is not provided, resolves it from config.vault or defaults to .napkin/.obsidian/. */ export declare function saveConfig(napkinDir: string, config: NapkinConfig, obsidianDir?: string): void; /** * Update specific config fields, save, and sync. */ export declare function updateConfig(napkinDir: string, partial: Record): NapkinConfig;