import type { UmbValidationController } from './validation.controller.js'; import { UmbControllerBase } from '../../../../libs/class-api/index.js'; import type { UmbControllerAlias, UmbControllerHost } from '../../../../libs/controller-api/index.js'; import type { Observable } from '../../../../libs/observable-api/index.js'; /** * A method resolving the unique identifier of a message's first-bracket query parameters, e.g. for * `{alias: 'title', culture: 'en-US'}` this might return `'title'`. Return undefined to ignore a message * (it won't be considered for removal, regardless of what disappears from the known uniques). */ export type UmbValidationCleanUpGetUniqueMethod = (queryParams: Record) => string | undefined; /** * Removes the validation messages of items based on observation of uniques. * @example * ```ts * new UmbValidationCleanUpByUniqueManager( * this, * this.validationContext, * '$.values', * this.structure.contentTypePropertyAliases, * (queryParams) => queryParams.alias, * ); * ``` */ export declare class UmbValidationCleanUpByUniqueManager extends UmbControllerBase { #private; /** * Creates an instance of UmbValidationCleanUpByUniqueManager. * @param {UmbControllerHost} host - The host of this controller. * @param {UmbValidationController} validationController - The Validation Context to remove messages from. * @param {string} scopePath - The JSON-Path prefix to scan for messages, e.g. `$.values`. Must not contain a bracket itself, as the first bracket found under it is assumed to be the item's own. * @param {Observable | undefined>} uniques - An Observable of the currently known unique identifiers. * @param {UmbValidationCleanUpGetUniqueMethod} getUniqueMethod - Resolves the unique identifier of a message's first-bracket query parameters. * @param {UmbControllerAlias} [controllerAlias] - An optional controller alias, enables replacing this manager with a new one. */ constructor(host: UmbControllerHost, validationController: UmbValidationController, scopePath: string, uniques: Observable | undefined>, getUniqueMethod: UmbValidationCleanUpGetUniqueMethod, controllerAlias?: UmbControllerAlias); destroy(): void; }