pdfcpu type
All checks were successful
continuous-integration/drone/push Build is passing

This commit is contained in:
Sebastian Frank 2022-02-08 16:06:09 +01:00
parent 78b33639c5
commit 9e4132af0f
Signed by: apairon
GPG Key ID: A0E05A8199CE3F57

23
index.d.ts vendored
View File

@ -481,22 +481,39 @@ interface PdfPackage {
* process existing pdf data
*
* @param command pdfcpu command
* @param pdfData []byte of pdf data
* @param pdfData []byte of pdf data, multiple []byte as array of pdf's to merge or object with description to create
* @param options options
*
* @returns []byte of new pdf data
*/
cpu(
command: "watermark" | "stamp" | "merge",
command: "watermark" | "stamp" | "merge" | "rotate" | "create",
pdfData: any | any[],
options?: {
pages?: (string | number)[]
description?: {
[key: string]: number | string
fontname?: string
points?: number
rtl?: boolean
position?: "full" | "tl" | "tc" | "tr" | "l" | "c" | "r" | "bl" | "bc" | "br"
offset?: string
scalefactor?: number
aligntext?: "left" | "center" | "right" | "justified"
strokecolor?: string
fillcolor?: string
backgroundcolor?: string
rotation?: number
diagonal?: 1|2
opacity?: number
rendermode?: 0|1|2
margins?: number | string
border?: number | string
url?: string
}
mode?: "text" | "image" | "pdf"
bytes?: any // []byte of watermark image
file?: string // file for pdf watermark
rotation?: number
}
): any
}