fix(annotations): correct signature frame mapping by filtering by pageIndex
- Updated `mapSignature` to filter signature annotations by `pageIndex` when finding nearest elements. - Ensures correct association of frames and signature data for each page. - Prevents errors caused by cross-page annotation references.
This commit is contained in:
@@ -14,7 +14,7 @@ function detailedCurrentDate() {
|
||||
}).format();
|
||||
}
|
||||
|
||||
function findNearest(origin, getX, getY, ...dests) {
|
||||
function findNearest(origin, getX, getY, dests) {
|
||||
const distanceToOrigin = (point) => Math.sqrt((getX(origin) - getX(point))**2 + (getY(origin) - getY(point))**2);
|
||||
return dests.reduce(
|
||||
(nearest, dest) => {
|
||||
|
||||
Reference in New Issue
Block a user