SVG defintions always take the first one

* Move filter definition out
This commit is contained in:
Roeland Jago Douma 2016-08-18 15:54:19 +02:00 committed by Morris Jobke
parent f68d5d1071
commit c07090ef6e
No known key found for this signature in database
GPG Key ID: 9CE5ED29E7FCD38A
2 changed files with 3 additions and 1 deletions

View File

@ -238,7 +238,6 @@ OC.Settings.Apps = OC.Settings.Apps || {
if (appfromstore) {
img += '<image x="0" y="0" width="72" height="72" preserveAspectRatio="xMinYMin meet" xlink:href="' + url + '" class="app-icon" /></svg>';
} else {
img += '<defs><filter id="invertIcon"><feColorMatrix in="SourceGraphic" type="matrix" values="-1 0 0 0 1 0 -1 0 0 1 0 0 -1 0 1 0 0 0 1 0"></feColorMatrix></filter></defs>';
img += '<image x="0" y="0" width="72" height="72" preserveAspectRatio="xMinYMin meet" filter="url(#invertIcon)" xlink:href="' + url + '" class="app-icon"></image></svg>';
}
return img;

View File

@ -180,6 +180,9 @@ script(
</div>
</div>
<div id="app-content">
<svg height="0">
<defs><filter id="invertIcon"><feColorMatrix in="SourceGraphic" type="matrix" values="-1 0 0 0 1 0 -1 0 0 1 0 0 -1 0 1 0 0 0 1 0"></feColorMatrix></filter></defs>
</svg>
<div id="apps-list" class="icon-loading"></div>
<div id="apps-list-empty" class="hidden emptycontent emptycontent-search">
<div class="icon-search"></div>