We use cookies to give you the best experience on our website. If you continue to browse, then you agree to our privacy policy and cookie policy. Image for the cookie policy date
Unfortunately, activation email could not send to your email. Please try again.
Syncfusion Feedback

DiagramComponent "corrupts" the SVG/NativeModel

Thread ID:





148546 Oct 24,2019 10:35 AM UTC Oct 28,2019 09:51 AM UTC Angular - EJ 2 3
Tags: Diagram
Asked On October 24, 2019 10:35 AM UTC

Hello SyncFusion Team,

I'm using the @syncfusion/ej2-angular-diagrams control in my Angular app.

I'm loading a NativeModel node from an SVG file.

However the node looks different from the source SVG (I've tried it in multiple browsers: chrome, firefox, edge etc). 

Is this a known issue? Any workarounds? 

PS: I have set up a stackblitz repro: https://stackblitz.com/edit/diagram-rendering

Actual SVGDiagramComponent renders it as (notice the left arrow)

Shyam G [Syncfusion]
Replied On October 25, 2019 07:24 AM UTC

Hi Mithun, 
The last points in a polygon have been provided in a new line in your sample (see Example of Actual Code). The new line points have created unsuitable SVG. We have now solved it by removing the new line spaces (see Example Modified code). Refer to the example code and sample below. 
Code example: 
<polygon fill="#FFFFFF" points="10.685,33.515 20.018,33.515 16.766,30.263 25.447,21.582 22.618,18.753 13.937,27.434  
10.685,24.182 " /> 
<polygon fill="#FFFFFF" points="10.685,33.515 20.018,33.515 16.766,30.263 25.447,21.582 22.618,18.753 13.937,27.434 10.685,24.182 " /> 
Shyam G 

Replied On October 27, 2019 01:25 AM UTC

Thank you. 

Is there a recommended linter/validator for SVG files? Preferably something that be run on the command line (i.e. part of the build process).


Shyam G [Syncfusion]
Replied On October 28, 2019 09:51 AM UTC

Hi Mithun, 
You do not need the SVG linter / validator to validate your SVG. The SVG tag can be removed in your SVG alone. If you are facing any problems in SVG, you can share them with us so we can solve them. Also, please refer to the reference below if you need to validate the SVG. 
Shyam G 


This post will be permanently deleted. Are you sure you want to continue?

Sorry, An error occured while processing your request. Please try again later.

Please sign in to access our forum

This page will automatically be redirected to the sign-in page in 10 seconds.

Warning Icon You are using an outdated version of Internet Explorer that may not display all features of this and other websites. Upgrade to Internet Explorer 8 or newer for a better experience.Close Icon

Live Chat Icon For mobile
Live Chat Icon