Open dkazakov8 opened 1 month ago
Thanks, I'll take a look. Does the 7.0.0 work fine for you otherwise?
Thanks, I'll take a look. Does the 7.0.0 work fine for you otherwise?
Please update it if there's time . Thank you
Thanks, I'll take a look. Does the 7.0.0 work fine for you otherwise?
Yes, thanks. Everything else is working fine. The only difference from version 6.1.0 in my use cases was an incorrect z-index for the annotations layer (annotations are not clickable), which I fixed with:
.PdfHighlighter__highlight-layer {
z-index: 3 !important;
}
Also encountering this issue on 7.0.0, any update?
Same here, having the same issue
Simple bandaid solution is to replace:
debouncedScaleValue: () => void = debounce(this.handleScaleValue, 500);
in PdfHighlighter.tsx with
debouncedScaleValue = this.handleScaleValue;
Keep in mind that removing debouncing may result in severe performance losses for resizing functionality.
Hello,
I just upgraded to version 7.0.0, and when I resize the window, this error appears in the console: "Uncaught Error: Debounced method called with different contexts." This occurs inside the "debounce" library, and the root cause is this line. The
debouncedScaleValue
method has no bound context, so when it's used in ResizeObserver or addEventListener, it has different contexts.It seems like this error doesn't negatively affect functionality; it just spams the console with errors.
this.debouncedScaleValue = this.debouncedScaleValue.bind(this)
helps, maybe someone could include it in a PR.