resourceloader: Avoid unnecessary xmlns attributes in ResourceLoaderImage
authorBartosz Dziewoński <matma.rex@gmail.com>
Tue, 15 Jan 2019 19:43:35 +0000 (20:43 +0100)
committerVolkerE <volker.e@wikimedia.org>
Wed, 16 Jan 2019 02:22:45 +0000 (02:22 +0000)
commit1805fd3be51787b956573616154175fa4c66df08
treefa41dae84e65947f058dc22ea63b87cadb81ad3b
parentbda1de61c2635489689add8e69f148c1271230c3
resourceloader: Avoid unnecessary xmlns attributes in ResourceLoaderImage

We were creating the `<g>` element without specifying a namespace,
which caused the library to add `xmlns` attributes with the document's
default SVG namespace to elements that we appended underneath it.
(At least, that's what I think was happening.)

Specify the SVG namespace when creating it to avoid the mess and
reduce resulting file size.

Change-Id: Ida27494aeae9dece16f878c16cf9aa582e6deac3
includes/resourceloader/ResourceLoaderImage.php
tests/phpunit/data/resourceloader/def_variantize.svg