@embedpdf/engines 1.0.24 → 1.0.25
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/{engine-BKTSw4UQ.js → engine-Cbe0OXlS.js} +4 -6
- package/dist/engine-Cbe0OXlS.js.map +1 -0
- package/dist/{engine-Bc97hISy.cjs → engine-Dzk7rWzi.cjs} +2 -2
- package/dist/engine-Dzk7rWzi.cjs.map +1 -0
- package/dist/{runner-BPw2Wq1D.cjs → index-CSW2HASy.cjs} +2 -2
- package/dist/index-CSW2HASy.cjs.map +1 -0
- package/dist/{runner-DTKoO4M3.js → index-CXkPSqgS.js} +4 -2
- package/dist/index-CXkPSqgS.js.map +1 -0
- package/dist/index.cjs +1 -1
- package/dist/index.cjs.map +1 -1
- package/dist/index.js +5 -4
- package/dist/lib/pdfium/index.cjs +1 -1
- package/dist/lib/pdfium/index.d.ts +1 -0
- package/dist/lib/pdfium/index.js +3 -2
- package/dist/lib/pdfium/web/direct-engine.cjs +1 -1
- package/dist/lib/pdfium/web/direct-engine.js +1 -1
- package/dist/lib/pdfium/web/worker-engine.cjs +1 -1
- package/dist/lib/pdfium/web/worker-engine.js +1 -1
- package/dist/preact/index.cjs +1 -1
- package/dist/preact/index.js +1 -1
- package/dist/react/index.cjs +1 -1
- package/dist/react/index.js +1 -1
- package/dist/vue/index.cjs +1 -1
- package/dist/vue/index.js +1 -1
- package/package.json +3 -3
- package/dist/engine-BKTSw4UQ.js.map +0 -1
- package/dist/engine-Bc97hISy.cjs.map +0 -1
- package/dist/runner-BPw2Wq1D.cjs.map +0 -1
- package/dist/runner-DTKoO4M3.js.map +0 -1
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { NoopLogger, PdfTaskHelper, PdfErrorCode, pdfDateToDate, ignore, isUuidV4, uuidV4, PdfAnnotationSubtype,
|
|
1
|
+
import { NoopLogger, PdfTaskHelper, PdfErrorCode, pdfDateToDate, ignore, isUuidV4, uuidV4, PdfAnnotationSubtype, PdfPageFlattenFlag, stripPdfUnwantedMarkers, PdfAnnotationIcon, PdfAnnotationBorderStyle, PdfAnnotationColorType, PdfAnnotationLineEnding, pdfColorToWebColor, webColorToPdfColor, pdfAlphaToWebOpacity, webOpacityToPdfAlpha, dateToPdfDate, quadToRect, rectToQuad, PdfStandardFont, PdfPageObjectType, flagsToNames, namesToFlags, PDF_FORM_FIELD_TYPE, Rotation, AppearanceMode, Task, toIntRect, transformRect, buildUserToDeviceMatrix, PdfActionType, PdfZoomMode, MatchFlag } from "@embedpdf/models";
|
|
2
2
|
function readString(wasmModule, readChars, parseChars, defaultLength = 100) {
|
|
3
3
|
let buffer = wasmModule.wasmExports.malloc(defaultLength);
|
|
4
4
|
for (let i = 0; i < defaultLength; i++) {
|
|
@@ -1375,7 +1375,7 @@ class PdfiumEngine {
|
|
|
1375
1375
|
* @public
|
|
1376
1376
|
*/
|
|
1377
1377
|
renderThumbnail(doc, page, options) {
|
|
1378
|
-
const { scaleFactor = 1,
|
|
1378
|
+
const { scaleFactor = 1, ...rest } = options ?? {};
|
|
1379
1379
|
this.logger.debug(LOG_SOURCE, LOG_CATEGORY, "renderThumbnail", doc, page, options);
|
|
1380
1380
|
this.logger.perf(
|
|
1381
1381
|
LOG_SOURCE,
|
|
@@ -1400,9 +1400,7 @@ class PdfiumEngine {
|
|
|
1400
1400
|
}
|
|
1401
1401
|
const result = this.renderPage(doc, page, {
|
|
1402
1402
|
scaleFactor: Math.max(scaleFactor, 0.5),
|
|
1403
|
-
|
|
1404
|
-
dpr,
|
|
1405
|
-
withAnnotations: true
|
|
1403
|
+
...rest
|
|
1406
1404
|
});
|
|
1407
1405
|
this.logger.perf(LOG_SOURCE, LOG_CATEGORY, `RenderThumbnail`, "End", `${doc.id}-${page.index}`);
|
|
1408
1406
|
return result;
|
|
@@ -6390,4 +6388,4 @@ export {
|
|
|
6390
6388
|
readArrayBuffer as c,
|
|
6391
6389
|
readString as r
|
|
6392
6390
|
};
|
|
6393
|
-
//# sourceMappingURL=engine-
|
|
6391
|
+
//# sourceMappingURL=engine-Cbe0OXlS.js.map
|