Comments (9)
I had the same issue. I added background-color: white;
CSS rule to the image parent node and it helped.
from dom-to-image.
Hi! Thanks for reporting. I'll take a look at that. In the meantime, could you please post the problematic image itself?
from dom-to-image.
Hey tsayen, thanks for the quick answer ! I solve this issue quickly changing the format of the image (was .jpg so i create a new version with transparency [png]).
However, the original jpg image didn't have border and I don't know why appears a border
from dom-to-image.
The problem might also be because of the image scaling. Do you maybe set the image dimensions explicitly? I seem to recall some border-like artefacts showing on JPG as an effect of scaling.
from dom-to-image.
Yes, is a div which have a background image with explicit dimensions (height:100;width:100%;)
Thanks for the support
from dom-to-image.
Do you observe those borders in the original html or is it just the rendered image?
from dom-to-image.
I was trying to reproduce the issue with a test JPG image, but I can't (see here http://jsfiddle.net/tsayen/sark5r13/2/)
If the issue is still bothering you, maybe you send me an example image (just attach it to the comment) that is rendered wrong.
Or we can close this for now.
What do you say?
from dom-to-image.
closing this for now
from dom-to-image.
I had the same issue. I added
background-color: white;
CSS rule to the image parent node and it helped.
I had problems with borders appearing out of nowhere in different nodes (div, and textarea) and this solved it. Thanks
from dom-to-image.
Related Issues (20)
- Get canvas ref from another component
- Failed to execute 'toDataURL' on 'HTMLCanvasElement': Tainted canvases may not be exported. HOT 2
- Most of the issues have been fixed in forked library `modern-screenshot` HOT 4
- toPng() throw error. HOT 8
- Super long HTML growth chart - Node images with height exceeding 16000 are blank HOT 2
- DomToPNG not working if dom contains %BB
- dom to image giving blank images HOT 3
- How to keep ratio without adding blank space around the image HOT 1
- Rendering svg
- The internal picture is blank
- Cookies not passed to image request
- It not support xlink:href for svg? HOT 1
- When there is a large DOM content, empty file download happening. Are there any limitations? HOT 3
- the image some time cutting and some time show correct HOT 1
- sometimes image in HTML is big,domtoimage will show blank image in IOS not Android
- DOMException: Failed to execute 'toDataURL' on 'HTMLCanvasElement': Tainted canvases may not be exported
- DOMException: Failed to execute 'toDataURL' on 'HTMLCanvasElement': Tainted canvases may not be exported HOT 1
- Full Scrollable (CLOSED)
- shadow-root not rendered. HOT 1
- Exporting to PNG does not check checkboxes
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from dom-to-image.