Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Why isn’t the image resource specified in border-image-source being downloaded during the process of converting the DOM element to an image? #456

Open
ljwswust opened this issue Mar 13, 2024 · 4 comments
Labels

Comments

@ljwswust
Copy link

**html **

<div class="decorate-item" style="border-image-source: url("/static/img-templet/border-236-7ab7e7d6ce1bc4b5.gif"); border-image-slice: 35 fill; border-width: 35px; border-style: solid; background-clip: padding-box; filter: blur(0px);"></div>

expectation

image

practical

政务 (9)

Which aspects should I consider to troubleshoot the problem?。

@ljwswust ljwswust added the bug label Mar 13, 2024
@biiibooo
Copy link
Contributor

biiibooo bot commented Mar 13, 2024

👋 @ljwswust

Thanks for opening your first issue here! If you're reporting a 🐞 bug, please make sure you include steps to reproduce it.
To help make it easier for us to investigate your issue, please follow the contributing guidelines.

We get a lot of issues on this repo, so please be patient and we will get back to you as soon as we can.

@ljwswust
Copy link
Author

html-to-image: 1.11.11
macOS: 13.6.4
chrome: 122.0.6261.112 (x86_64)

@blacktunes
Copy link

You can convert the images to base64

@Westbrooke117
Copy link

You can fix this by passing in the image source url as a base64 encoded image instead of a path.

e.g. instead of writing:
border-image-source: url('/path/to/image.png')
write:
border-image-source: url('data:image/png;base64,<your-image-encoded-in-base64-here>)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

3 participants