2023-11-10 23:41:31 +03:00
|
|
|
|
2023-11-14 03:26:42 +03:00
|
|
|
import SharedOperations, { OperationsType } from "@stirling-pdf/shared-operations/src";
|
|
|
|
import { ImposeParamsType } from '@stirling-pdf/shared-operations/src/functions/impose'
|
|
|
|
import { PdfFile } from "@stirling-pdf/shared-operations/src/wrappers/PdfFile";
|
2023-11-10 23:41:31 +03:00
|
|
|
|
|
|
|
// Import injected libraries here!
|
2023-11-12 20:58:40 +03:00
|
|
|
//import * as pdfcpuWrapper from "@stirling-pdf/shared-operations/wasm/pdfcpu/pdfcpu-wrapper-node.js";
|
2023-11-10 23:41:31 +03:00
|
|
|
|
2023-11-14 03:26:42 +03:00
|
|
|
async function impose(params: ImposeParamsType): Promise<PdfFile> {
|
|
|
|
const paramsToUse = { ...params, pdfcpuWrapper: null }; // TODO change null to pdfcpuWrapper
|
|
|
|
return SharedOperations.impose(paramsToUse);
|
2023-11-13 03:50:02 +03:00
|
|
|
}
|
2023-11-10 23:41:31 +03:00
|
|
|
|
2023-11-14 03:26:42 +03:00
|
|
|
const toExport: OperationsType = {
|
2023-11-10 23:41:31 +03:00
|
|
|
...SharedOperations,
|
2023-11-13 03:50:02 +03:00
|
|
|
impose,
|
2023-11-10 23:41:31 +03:00
|
|
|
}
|
2023-11-13 03:50:02 +03:00
|
|
|
export default toExport;
|