/** * Viewer plugin registry — runtime registration + slot-aware lookup. * * Plugin packs call `register(plugin)` during module load (typically * from a top-level `register.ts` the consumer imports for side * effects). The viewer reads `getPluginsForSlot(slot)` at render * time to find what to mount. * * The registry is process-wide. Apps mounting two viewer instances on * the same page currently share the same plugin set; per-instance * scoping is a future addition. * * @public */ import type { ViewerPlugin, ViewerSlot } from "./types"; /** * Register a plugin. Throws on duplicate id, or on a second * `replaces` claim against the same target. * * @public */ export declare function register(plugin: ViewerPlugin): void; /** * Unregister a plugin by id. No-op if absent. Also clears any * `replaces` claim this plugin held, freeing the target for a * subsequent override. * * @public */ export declare function unregister(id: string): void; /** * Return every registered plugin for a slot, sorted by `order` asc * (where supported by the plugin shape; defaults to insertion order). * * Plugins that have been overridden via another plugin's `replaces` * field are filtered out — the overrider takes their place when it * shares the same slot. Cross-slot overrides also remove the * original from this slot (the override declares an intent to take * over the named feature; rendering the replaced one alongside * would defeat the override semantics). * * @public */ export declare function getPluginsForSlot(slot: S): Array>; /** * Snapshot of every registered plugin (mainly for tests / debugging). * Includes plugins that have been overridden — `getPluginsForSlot` * filters those out, but they remain in the registry. * * @public */ export declare function listAll(): ReadonlyArray; /** * Reset the registry. **Test-only.** Production code never calls this. * * @public */ export declare function _resetRegistryForTesting(): void; //# sourceMappingURL=registry.d.ts.map