Skip to content

Commit ba71bd1

Browse files
committed
Revert "fix(pdf-server): own markup annotations in our layer, not the canvas"
This reverts commit 2f989a7.
1 parent 2f989a7 commit ba71bd1

1 file changed

Lines changed: 1 addition & 10 deletions

File tree

examples/pdf-server/src/mcp-app.ts

Lines changed: 1 addition & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -3158,20 +3158,11 @@ async function renderPage() {
31583158
// Set --scale-factor so CSS font-size/transform rules work correctly.
31593159
textLayerEl.style.setProperty("--scale-factor", `${scale}`);
31603160

3161-
// Render canvas - track the task so we can cancel it.
3162-
//
3163-
// annotationMode: DISABLE — markup annotations are owned by OUR
3164-
// annotation layer (renderAnnotationsForPage). Letting page.render
3165-
// paint them too gave a doubled-up display where the canvas pixel
3166-
// looked like the annotation but wasn't clickable, and our DOM
3167-
// version (which IS clickable) sat on top with our own styling.
3168-
// Form widgets are unaffected — those live in #form-layer via
3169-
// AnnotationLayer.render(), not the canvas.
3161+
// Render canvas - track the task so we can cancel it
31703162
// eslint-disable-next-line @typescript-eslint/no-explicit-any
31713163
const renderTask = (page.render as any)({
31723164
canvasContext: ctx,
31733165
viewport,
3174-
annotationMode: AnnotationMode.DISABLE,
31753166
});
31763167
currentRenderTask = renderTask;
31773168

0 commit comments

Comments
 (0)