chore: bump ext-apps to 1.5.0 (#588)

* chore: bump ext-apps to 1.5.0

* style: auto-fix prettier formatting

---------

Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
This commit is contained in:
Olivier Chafik 2026-04-02 10:09:49 +01:00 • committed by GitHub
commit 621a70a724
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
3 changed files with 58 additions and 56 deletions

View file

@ -1,6 +1,6 @@
{
"name": "@modelcontextprotocol/server-pdf",
"version": "1.4.0",
"version": "1.5.0",
"type": "module",
"description": "MCP server for loading and extracting text from PDF files with chunked pagination and interactive viewer",
"repository": {

View file

@ -864,7 +864,10 @@ describe("buildAnnotatedPdfBytes", () => {
// Now remove the first one by ref.
const stripped = await buildAnnotatedPdfBytes(seeded, [], new Map(), [
{ objectNumber: ref0.objectNumber, generationNumber: ref0.generationNumber },
{
objectNumber: ref0.objectNumber,
generationNumber: ref0.generationNumber,
},
]);
const strippedDoc = await PDFDocument.load(stripped);
const remaining = strippedDoc.getPage(0).node.Annots();

View file

@ -1123,8 +1123,7 @@ export function importPdfjsAnnotation(
// a placement-only record that the renderer fills with the rasterized
// appearance from pdf.js's annotationCanvasMap. This keeps Ink, Polygon,
// image-signature stamps, etc. visible AND selectable in our layer.
const importAsBitmap =
!ourType || (ourType === "stamp" && ann.hasAppearance);
const importAsBitmap = !ourType || (ourType === "stamp" && ann.hasAppearance);
if (importAsBitmap) {
if (!ann.rect) return null;
const r = pdfjsRectToRect(ann.rect);