Import SVG file with styles defined in Ignition

Hi everyone,

I need to import some project customized SVG, and bind SVG elements to the Ignition project styles.
I already defined the project styles on the gateway.
I would like to avoid going to each element, add a “style” and define the “class”.

So my plan was to define the “Ignition” style on the SVG before the import.
I tried hard but I did not find a way to do so.
Did anyone try to achieve this already?

Thanks for your help!

Finally I found it.
On the SVG => style=“classes:ignitionStylePath”

Unfortunately, there isn’t really a graceful way to do this that I am aware of.

Adding the styles in the SVG and choosing the embed option might” work (I’ve never tried), but you would need to insure that the structure matches what Ignition is expecting. I’m not sure what that structure looks like in an SVG.

Looks like it does work.

Anytime I have needed to animate SVG elements I have just drawn them manually in ignition (not exactly trivial as there are no first party tools [yet] to make it easier). However, I generally use very basic SVGs with very few elements, so that makes it a more viable option for me.