Skip to content

modern-pdf-lib


modern-pdf-lib / VisibleSignatureOptions

Interface: VisibleSignatureOptions

Defined in: src/signature/signatureHandler.ts:26

Options for a visible signature appearance on the page.

Properties

backgroundColor?

optional backgroundColor: [number, number, number]

Defined in: src/signature/signatureHandler.ts:42

Background color as [r, g, b] values (0–1). Default: transparent.


borderColor?

optional borderColor: [number, number, number]

Defined in: src/signature/signatureHandler.ts:46

Border color as [r, g, b] values (0–1). Default: [0, 0, 0] (black).


borderWidth?

optional borderWidth: number

Defined in: src/signature/signatureHandler.ts:48

Border width in points. Default: 1. Set to 0 for no border.


fontSize?

optional fontSize: number

Defined in: src/signature/signatureHandler.ts:38

Font size for the text. Default: 10.


pageIndex?

optional pageIndex: number

Defined in: src/signature/signatureHandler.ts:28

Zero-based page index where the signature should appear. Default: 0.


rect

rect: [number, number, number, number]

Defined in: src/signature/signatureHandler.ts:30

Rectangle [x, y, width, height] in PDF points from the bottom-left corner.


text?

optional text: string[]

Defined in: src/signature/signatureHandler.ts:36

Text lines to display in the signature box. Each string becomes a separate line. If omitted, auto-generates from the signer name, reason, location, and date.

Released under the MIT License.