Improve PDF rendering quality and HiDPI support
Enhanced thumbnail rendering in `envelope-viewer.css` by adding `image-rendering` properties for better visual quality. Updated `pdf-viewer.js` to support high-quality rendering with HiDPI support: - Replaced fixed scale with dynamic scaling using `devicePixelRatio` (capped at 2x) and a base scale of 0.75. - Adjusted canvas resolution to match scaled viewport dimensions. - Removed inline canvas styles to delegate display size to CSS. - Retained high-quality rendering settings for the canvas context. These changes improve visual fidelity while maintaining performance.
This commit is contained in:
@@ -182,6 +182,8 @@ body.resizing {
|
||||
height: 100%;
|
||||
object-fit: contain;
|
||||
object-position: center;
|
||||
image-rendering: -webkit-optimize-contrast;
|
||||
image-rendering: crisp-edges;
|
||||
}
|
||||
|
||||
.pdf-thumbnail__label {
|
||||
|
||||
Reference in New Issue
Block a user