Support images, .NET 8.0 and added options#92
Merged
webgio merged 12 commits intowebgio:masterfrom Oct 28, 2024
Merged
Conversation
added 6 commits
July 22, 2024 16:00
…e a new package version
Author
|
Also bumped the version to 1.4.0 and added manual test in Web App to verify that images are created (png and jpeg). A similar automated test as with Pdf (to check if a text inside the PDF is present) is not possible as it is an image. @webgio What do you think of the proposed changes? |
Author
|
Added two unit tests based on existing Rotativa code that at least check for the image format. |
Author
|
Added some useful option flags, moved Zoom to This is the last commit for this PR before the review. @webgio Could you review the code? |
This was referenced Aug 14, 2024
webgio
approved these changes
Oct 28, 2024
Owner
webgio
left a comment
There was a problem hiding this comment.
Works, thanks for the contribution!
| [InlineData("https://localhost:7059", "Asp.net 6")] | ||
| public void Contact_PDF(string url, string site) | ||
| //[InlineData("https://localhost:7059", "Asp.net 6")] | ||
| [InlineData("https://localhost:56246", "Asp.net 8")] |
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.
Created a fork as I needed to create images with wkhtmltoimage in .NET 8.
return new ViewAsPdf("MyPartialView", isPartialView = true);ViewAsImagebased on original Rotativa code;ViewAsPdf: use default ViewName, Model, ViewData and TempData properties instead of overriding them;MasterNameas it wasn't used;zoomparameter (as Add Zoom property #53 #54 has conflicts);