1
0
mirror of https://github.com/simple-icons/simple-icons.git synced 2024-12-16 01:10:30 +02:00

Properly remove SVG attributes with SVGO (#10618)

This commit is contained in:
Álvaro Mondéjar 2024-03-13 01:11:26 +01:00 committed by GitHub
parent 0c847d8589
commit 19be66383c
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194

View File

@ -71,7 +71,7 @@ export default {
// Sort the attributes on the <svg> tag
name: 'sortAttrs',
params: {
order: ['role', 'viewBox'],
order: ['role', 'viewBox', 'xmlns'],
xmlnsOrder: 'end',
},
},
@ -80,7 +80,11 @@ export default {
{
name: 'removeAttrs',
params: {
attrs: ['svg:(?!(role|viewBox|xmlns))', 'path:(?!d)', 'title:*'],
attrs: [
'svg:.*(?<!((role)|(viewBox)|(xmlns)))',
'path:(?!d)',
'title:*',
],
},
},
'removeElementsByAttr',