Merged
Conversation
web-mapviewer
|
||||||||||||||||||||||||||||
| Project |
web-mapviewer
|
| Branch Review |
develop
|
| Run status |
|
| Run duration | 01m 23s |
| Commit |
|
| Committer | Pascal Barth |
| View all properties for this run ↗︎ | |
| Test results | |
|---|---|
|
|
0
|
|
|
0
|
|
|
1
|
|
|
0
|
|
|
48
|
| View all changes introduced in this branch ↗︎ | |
We will move the generation of margin in the viewer, instead of dealing with that on the backend. This is because it's way easier to keep the "true-to-scale" when shrinking the map viewport (and let it recalculate everything) instead of resizing the flatten map and thus changing the scale of the image. Using CSS padding instead of margin, so that we respect the A4 size we previously calculated (if we use margin, it will extend the "page" size and break the A4 layout)
ae7672c to
82d0bb3
Compare
rebert
reviewed
Apr 28, 2025
|
|
||
| export const PRINT_DEFAULT_DPI = 96 | ||
|
|
||
| export const PRINT_MARGIN_IN_MILLIMETERS = 4 |
Contributor
There was a problem hiding this comment.
PRINT_PADDING_IN_MILIMETERS ?
Contributor
Author
There was a problem hiding this comment.
it's technically a print margin (that's how you call it on the print dialog). But I'm using padding under the hood so that I don't break the layout
rebert
approved these changes
Apr 28, 2025
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
We will move the generation of margin in the viewer, instead of dealing with that on the backend. This is because it's way easier to keep the "true-to-scale" when shrinking the map viewport (and let it recalculate everything) instead of resizing the flatten map and thus changing the scale of the image.
Test link