Page MenuHomePhabricator

[BUG] SVG Translate drops text nodes when there are tspan elements.
Closed, DuplicatePublic


What is the problem?
Steps to reproduce problem
  1. 2. 3.

Expected behavior:
Should allow translation of all the words in the diagram.

Observed behavior:
Words in text nodes are not offered for translation.
Instead of displaying "semicircular" and "canals", the tool only displays "canals".

The SVG source is

  <switch transform="translate(560 85)" text-anchor="middle">
    <text systemLanguage="de">Bogengänge</text>
    <text systemLanguage="en">Semicircular<tspan x="0" y="20">canals</tspan></text>
    <text systemLanguage="eo">Kanaloj<tspan x="0" y="20">semicirculares</tspan></text>
    <text systemLanguage="fa">کانال‌های<tspan x="0" y="20">نیم‌دایره</tspan></text>
    <text systemLanguage="fi"><tspan x="0" y="20">Kaarikäytävät</tspan></text>
    <text systemLanguage="fr">Canaux<tspan x="0" y="20">semi-circulaires</tspan></text>
    <text systemLanguage="he">תעלות<tspan x="0" y="20">בצורת חצי עיגול</tspan></text>
    <text systemLanguage="ne">अर्धरात्रिक<tspan x="0" y="20">नहर</tspan></text>
    <text systemLanguage="ru">полукружные<tspan x="0" y="20">каналы</tspan></text>
    <text systemLanguage="ta"><tspan x="0" y="-20">அரை</tspan><tspan x="0" y="0">வட்ட</tspan><tspan x="0" y="20">வட்டங்கள்</tspan></text>
    <text>Semicircular<tspan x="0" y="20">canals</tspan></text>

Note that "Simicircular" is in a text node, but "canals" is in a `tspan` element. Former is missing, but latter appears.

Operating system: Win10
Browser: Chrome
Wiki(s): toolforge
Editor, if applicable:

Screenshots (if applicable):