Annotations

LinkAnnotation

Detailed reference for LinkAnnotation.

Concrete annotation type used for creation, update, and export workflows.

Type details

  • Kind: class
  • Declared members: 3

Declaration

class LinkAnnotation {
  readonly borderColor?: Color | null;
  readonly borderStyle?: 'solid' | 'dashed' | 'beveled' | 'inset' | 'underline' | null;
  readonly borderWidth?: number | null;
}

Members

  • borderColor
  • borderStyle
  • borderWidth

Runtime behavior

Native/imported PDF link annotations can include an action payload on the annotation model:

  • type: 'uri' with uri: string: opens safe external links (http, https, mailto, tel).
  • type: 'goTo' with pageIndex: number: navigates to a page in the current document.
  • Unsupported action types are treated as unknown and are ignored by default.

Default link handling is cancellable from the annotations.press event via preventDefault().