Skip to content

Commit 55c8eeb

Browse files
committed
Allow whitespace in css url references when inlining
1 parent 57ba8af commit 55c8eeb

1 file changed

Lines changed: 1 addition & 1 deletion

File tree

src/dom-to-image-more.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1036,7 +1036,7 @@
10361036
}
10371037

10381038
function newInliner() {
1039-
const URL_REGEX = /url\((["']?)((?:\\?.)*?)\1\)/gm;
1039+
const URL_REGEX = /url\(\s*(["']?)((?:\\.|[^\\)])+)\1\s*\)/gm;
10401040

10411041
return {
10421042
inlineAll: inlineAll,

0 commit comments

Comments
 (0)