From e15d843754b529c3d274a32b8d3ed1dd327fb07e Mon Sep 17 00:00:00 2001 From: kirill Shilov Date: Thu, 18 Apr 2019 20:45:26 +0300 Subject: [PATCH] added fix for removeSVGAttributes --- demo/src/demo/demo.component.ts | 2 +- src/svg-util.ts | 1 + 2 files changed, 2 insertions(+), 1 deletion(-) diff --git a/demo/src/demo/demo.component.ts b/demo/src/demo/demo.component.ts index 2ef1099..c70bb79 100644 --- a/demo/src/demo/demo.component.ts +++ b/demo/src/demo/demo.component.ts @@ -5,7 +5,7 @@ import { Component, OnInit } from '@angular/core'; template: `
Content
-
+
diff --git a/src/svg-util.ts b/src/svg-util.ts index d17a2e8..f29da85 100644 --- a/src/svg-util.ts +++ b/src/svg-util.ts @@ -51,6 +51,7 @@ export function removeAttributes(element: Element, attrs: Array): void { for (let i = 0; i < svgAttrs.length; i++) { if (attrs.indexOf(svgAttrs[i].name.toLowerCase()) > -1) { element.removeAttribute(svgAttrs[i].name); + i--; } }