Skip to content

Releases: lottev1991/html2canvas

v1.6.5-custom

22 Jan 05:34
Compare
Choose a tag to compare

This is really only a readme update in order to keep up with npm. I copied this from the previous release because It's essentially the same.


  • New canvas render option: imageSmoothingEnabled (defaults to true, which is standard HTML5 canvas behavior). Setting it to false will stop the blurring upon scaling and/or zooming the canvas. This could be desirable for things such as pixel art.
    • The same effect can be achieved by setting the image-rendering CSS option of the to-be-rendered DOM element to either pixelated or crisp-edges. The other options will return true.
    • You don't have to set both options at the same time. It will still work fine if you do, but it's not necessary.
    • This also fixes niklasvh#2850.
  • Adds a function where visible child elements of hidden parent elements will be rendered upon the canvas (before, they would be hidden, which I personally consider undesirable). I did not code this feature; all credit goes to @toohtik (see niklasvh#2866). I merely decided to implement it in my own custom fork.
  • Reverts 4e6c022, since while it may fix iframe element rendering, it also completely messes up the cropping function of html2canvas by moving child elements all over the place. I'm not currently prioritizing iframes in any of my projects, so I'm reverting it for now. That being said, I'm willing to re-implement it if a better fix is ever found.

v1.6.4-custom

12 Jan 21:07
Compare
Choose a tag to compare
  • New canvas render option: imageSmoothingEnabled (defaults to true, which is standard HTML5 canvas behavior). Setting it to false will stop the blurring upon scaling and/or zooming the canvas. This could be desirable for things such as pixel art.
    • The same effect can be achieved by setting the image-rendering CSS option of the to-be-rendered DOM element to either pixelated or crisp-edges. The other options will return true.
    • You don't have to set both options at the same time. It will still work fine if you do, but it's not necessary.
    • This also fixes niklasvh#2850.
  • Adds a function where visible child elements of hidden parent elements will be rendered upon the canvas (before, they would be hidden, which I personally consider undesirable). I did not code this feature; all credit goes to @toohtik (see niklasvh#2866). I merely decided to implement it in my own custom fork.
  • Reverts 4e6c022, since while it may fix iframe element rendering, it also completely messes up the cropping function of html2canvas by moving child elements all over the place. I'm not currently prioritizing iframes in any of my projects, so I'm reverting it for now. That being said, I'm willing to re-implement it if a better fix is ever found.