From 110f330c26a2134372789c44f0fc034128f8028d Mon Sep 17 00:00:00 2001 From: Dai Jie Date: Thu, 11 Dec 2025 18:26:03 +0800 Subject: [PATCH] fix: Remove quotes from SVG url() attributes --- src/core/QRSVG.ts | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/core/QRSVG.ts b/src/core/QRSVG.ts index b02ee7c4..fd2aeec3 100644 --- a/src/core/QRSVG.ts +++ b/src/core/QRSVG.ts @@ -541,7 +541,7 @@ export default class QRSVG { rect.setAttribute("y", String(y)); rect.setAttribute("height", String(height)); rect.setAttribute("width", String(width)); - rect.setAttribute("clip-path", `url('#clip-path-${name}')`); + rect.setAttribute("clip-path", `url(#clip-path-${name})`); if (options) { let gradient: SVGElement; @@ -603,7 +603,7 @@ export default class QRSVG { gradient.appendChild(stop); }); - rect.setAttribute("fill", `url('#${name}')`); + rect.setAttribute("fill", `url(#${name})`); this._defs.appendChild(gradient); } else if (color) { rect.setAttribute("fill", color);