SVG import - duplicate layer names erased
In Illustrator CC 2019 (v23.0.2), some of the layer names are stripped during SVG import. This is not an issue in CC 2018 (v22.0.0).
Steps to reproduce:
1. Create an SVG file with two layers with the same ID attribute
2. Open in Illustrator CC 2019
3. One of layer names will be blank
The attached file shows the layer names in CC 2019 when opening the SVG below
<svg>
<rect id="LayerName1" x="0" y="0" width="237.6" height="3.2" fill="rgb(0, 0, 0)" fill-opacity=" 0"></rect>
<rect id="LayerName1" x="0" y="0" width="237.6" height="3.2" fill="rgb(0, 0, 0)" fill-opacity=" 0"></rect>
<rect id="LayerName2" x="0" y="0" width="237.6" height="3.2" fill="rgb(0, 0, 0)" fill-opacity=" 0"></rect>
</svg>
-
Rob Louw commented
I am having a similar issue. SVG names are stripped from the SVG file on import using AI 2019 v23.0.4.
Opening the same SVG file with AI CC 2018 preserves the layer names and numbers.
-
Brennan Young commented
It's ugly behavior on the part of AI, especially without warning, but isn't reuse of IDs in the same namespace disallowed in XML/SVG?
The right thing for you to do is to ensure compliant markup, and the right thing for AI would be to warn about screwy input. -
Elliot Bentley commented
In Illustrator CC 2019 (v23.0.2), some of the layer names are stripped during SVG import. This is not an issue in CC 2018 (v22.0.0).
Steps to reproduce:
1. Create an SVG file with two layers with the same ID attribute
2. Open in Illustrator CC 2019
3. One of layer names will be blankThe attached file is an SVG that can be used to reproduce the bug.