@umbraco-cms/backoffice
    Preparing search index...

    Class UmbValidationCleanUpByPathManager<ItemType>

    Removes the validation messages of items that disappear from an observed array of items.

    Each item is identified by the validation data path returned for it by dataPathResolver. When an item that was previously present stops being present, the messages at its data path — and at any descendant path — are removed from the given Validation Context. Meaning anything nested inside a removed item's data (e.g. a Block nested inside a removed Block) goes away with it.

    Notice the first emission of the observed array only establishes the baseline, as it can not be known what was removed before this manager began observing.

    new UmbValidationCleanUpByPathManager<PropertyEditorSettingsProperty>(
    this,
    this.validationContext,
    this.properties,
    (property) => `$.values[${UmbDataPathPropertyValueQuery(property)}]`,
    );

    Type Parameters

    • ItemType = unknown

    Hierarchy (View Summary)

    Index
    • The addEventListener() method of the EventTarget interface sets up a function that will be called whenever the specified event is delivered to the target.

      MDN Reference

      Parameters

      • type: string
      • callback: EventListenerOrEventListenerObject | null
      • Optionaloptions: boolean | AddEventListenerOptions

      Returns void

    • The dispatchEvent() method of the EventTarget sends an Event to the object, (synchronously) invoking the affected event listeners in the appropriate order.

      MDN Reference

      Parameters

      • event: Event

      Returns boolean

    • The removeEventListener() method of the EventTarget interface removes an event listener previously registered with EventTarget.addEventListener() from the target.

      MDN Reference

      Parameters

      • type: string
      • callback: EventListenerOrEventListenerObject | null
      • Optionaloptions: boolean | EventListenerOptions

      Returns void