Interface: AnnotationPresetsUpdateEvent

PSPDFKit.AnnotationPresetsUpdateEvent

This event will be emitted whenever the current preset is about to be updated with new property values set by the user in the annotation toolbar.

Example

Register a AnnotationPresetsUpdateEvent handler and prevent the current preset from being updated.

instance.addEventListener("annotationPresets.update", (event) => {
  event.preventDefault();
});

Members




Members

currentPreset: string

Current active preset ID.

Type:
  • string

currentPresetProperties: PSPDFKit.AnnotationPreset

Properties and values of the current active preset.

Type:

newPresetProperties: PSPDFKit.AnnotationPreset

Properties and values to be merged with the ones in the current active preset.

Type:

preventDefault: function

Call this method to opt-out from updating the current preset.

Type:
  • function