mirror of
https://github.com/Mibew/simple-icons.git
synced 2025-05-02 09:06:43 +03:00
Update all dependencies (#6351)
* Update all dependencies * Update SVGO configuration SVGO v2.4.0 deprecated the old approach of extending default plugins (using `extendDefaultPlugins`) and introduced a new approach using the 'preset-default' plugin. Co-authored-by: Renovate Bot <bot@renovateapp.com> Co-authored-by: Eric Cornelissen <ericornelissen@gmail.com>
This commit is contained in:
parent
12ca93cf27
commit
81344e6bd3
14
package-lock.json
generated
14
package-lock.json
generated
@ -4024,13 +4024,13 @@
|
|||||||
}
|
}
|
||||||
},
|
},
|
||||||
"svgo": {
|
"svgo": {
|
||||||
"version": "2.3.1",
|
"version": "2.4.0",
|
||||||
"resolved": "https://registry.npmjs.org/svgo/-/svgo-2.3.1.tgz",
|
"resolved": "https://registry.npmjs.org/svgo/-/svgo-2.4.0.tgz",
|
||||||
"integrity": "sha512-riDDIQgXpEnn0BEl9Gvhh1LNLIyiusSpt64IR8upJu7MwxnzetmF/Y57pXQD2NMX2lVyMRzXt5f2M5rO4wG7Dw==",
|
"integrity": "sha512-W25S1UUm9Lm9VnE0TvCzL7aso/NCzDEaXLaElCUO/KaVitw0+IBicSVfM1L1c0YHK5TOFh73yQ2naCpVHEQ/OQ==",
|
||||||
"dev": true,
|
"dev": true,
|
||||||
"requires": {
|
"requires": {
|
||||||
"@trysound/sax": "0.1.1",
|
"@trysound/sax": "0.1.1",
|
||||||
"chalk": "^4.1.0",
|
"colorette": "^1.2.2",
|
||||||
"commander": "^7.1.0",
|
"commander": "^7.1.0",
|
||||||
"css-select": "^4.1.3",
|
"css-select": "^4.1.3",
|
||||||
"css-tree": "^1.1.2",
|
"css-tree": "^1.1.2",
|
||||||
@ -4175,9 +4175,9 @@
|
|||||||
}
|
}
|
||||||
},
|
},
|
||||||
"uglify-js": {
|
"uglify-js": {
|
||||||
"version": "3.14.0",
|
"version": "3.14.1",
|
||||||
"resolved": "https://registry.npmjs.org/uglify-js/-/uglify-js-3.14.0.tgz",
|
"resolved": "https://registry.npmjs.org/uglify-js/-/uglify-js-3.14.1.tgz",
|
||||||
"integrity": "sha512-R/tiGB1ZXp2BC+TkRGLwj8xUZgdfT2f4UZEgX6aVjJ5uttPrr4fYmwTWDGqVnBCLbOXRMY6nr/BTbwCtVfps0g==",
|
"integrity": "sha512-JhS3hmcVaXlp/xSo3PKY5R0JqKs5M3IV+exdLHW99qKvKivPO4Z8qbej6mte17SOPqAOVMjt/XGgWacnFSzM3g==",
|
||||||
"dev": true
|
"dev": true
|
||||||
},
|
},
|
||||||
"universalify": {
|
"universalify": {
|
||||||
|
@ -26,9 +26,9 @@
|
|||||||
"svg-path-bbox": "1.0.1",
|
"svg-path-bbox": "1.0.1",
|
||||||
"svg-path-segments": "1.0.0",
|
"svg-path-segments": "1.0.0",
|
||||||
"svglint": "1.0.8",
|
"svglint": "1.0.8",
|
||||||
"svgo": "2.3.1",
|
"svgo": "2.4.0",
|
||||||
"svgpath": "2.3.1",
|
"svgpath": "2.3.1",
|
||||||
"uglify-js": "3.14.0"
|
"uglify-js": "3.14.1"
|
||||||
},
|
},
|
||||||
"scripts": {
|
"scripts": {
|
||||||
"build": "node scripts/build/package.js",
|
"build": "node scripts/build/package.js",
|
||||||
|
217
svgo.config.js
217
svgo.config.js
@ -1,126 +1,105 @@
|
|||||||
const { extendDefaultPlugins } = require('svgo');
|
|
||||||
|
|
||||||
module.exports = {
|
module.exports = {
|
||||||
multipass: true,
|
multipass: true,
|
||||||
plugins: extendDefaultPlugins([
|
plugins: [
|
||||||
{
|
{
|
||||||
name: 'convertPathData',
|
name: 'preset-default',
|
||||||
params: {
|
params: {
|
||||||
// 3 decimals of precision in floating point numbers
|
overrides: {
|
||||||
floatPrecision: 3,
|
// customize options
|
||||||
// Some editors (e.g. Adobe Illustrator and Sketch) cannot parse flags
|
convertPathData: {
|
||||||
// without space wrapping
|
// 3 decimals of precision in floating point numbers
|
||||||
noSpaceAfterFlags: false,
|
floatPrecision: 3,
|
||||||
|
// Some editors (e.g. Adobe Illustrator and Sketch) cannot parse flags
|
||||||
|
// without space wrapping
|
||||||
|
noSpaceAfterFlags: false,
|
||||||
|
},
|
||||||
|
|
||||||
|
// Sort the attributes on the <svg> tag
|
||||||
|
sortAttrs: {
|
||||||
|
order: ['role', 'viewBox'],
|
||||||
|
xmlnsOrder: 'end',
|
||||||
|
},
|
||||||
|
|
||||||
|
// Convert basic shapes (such as <circle>) to <path>
|
||||||
|
convertShapeToPath: {
|
||||||
|
// including <arc>
|
||||||
|
convertArcs: true,
|
||||||
|
},
|
||||||
|
|
||||||
|
// Compound all <path>s into one
|
||||||
|
mergePaths: {
|
||||||
|
force: true,
|
||||||
|
noSpaceAfterFlags: false,
|
||||||
|
},
|
||||||
|
|
||||||
|
// Keep the <title> tag
|
||||||
|
removeTitle: false,
|
||||||
|
|
||||||
|
// Keep the role="img" attribute and automatically add it
|
||||||
|
// to the <svg> tag if it's not there already
|
||||||
|
addAttributesToSVGElement: {
|
||||||
|
attributes: [
|
||||||
|
{role: 'img'},
|
||||||
|
],
|
||||||
|
},
|
||||||
|
|
||||||
|
// Keep the 'role' attribute, if it's already defined
|
||||||
|
removeUnknownsAndDefaults: {
|
||||||
|
keepRoleAttr: true,
|
||||||
|
},
|
||||||
|
|
||||||
|
// Remove all attributes except 'role', 'viewBox', and 'xmlns' from
|
||||||
|
// <svg> tags
|
||||||
|
removeAttrs: {
|
||||||
|
attrs: [
|
||||||
|
'baseProfile',
|
||||||
|
'version',
|
||||||
|
'fill-rule',
|
||||||
|
],
|
||||||
|
},
|
||||||
|
|
||||||
|
// Remove paths with fill="none"
|
||||||
|
removeUselessStrokeAndFill: {
|
||||||
|
removeNone: true,
|
||||||
|
},
|
||||||
|
|
||||||
|
// Explicitly enable everything else
|
||||||
|
removeDoctype: true,
|
||||||
|
removeXMLProcInst: true,
|
||||||
|
removeComments: true,
|
||||||
|
removeMetadata: true,
|
||||||
|
removeEditorsNSData: true,
|
||||||
|
cleanupAttrs: true,
|
||||||
|
inlineStyles: true,
|
||||||
|
minifyStyles: true,
|
||||||
|
convertStyleToAttrs: true,
|
||||||
|
cleanupIDs: true,
|
||||||
|
prefixIds: true,
|
||||||
|
removeRasterImages: true,
|
||||||
|
removeUselessDefs: true,
|
||||||
|
cleanupNumericValues: true,
|
||||||
|
cleanupListOfValues: true,
|
||||||
|
convertColors: true,
|
||||||
|
removeNonInheritableGroupAttrs: true,
|
||||||
|
removeViewBox: true,
|
||||||
|
cleanupEnableBackground: true,
|
||||||
|
removeHiddenElems: true,
|
||||||
|
removeEmptyText: true,
|
||||||
|
moveElemsAttrsToGroup: true,
|
||||||
|
moveGroupAttrsToElems: true,
|
||||||
|
collapseGroups: true,
|
||||||
|
convertTransform: true,
|
||||||
|
removeEmptyAttrs: true,
|
||||||
|
removeEmptyContainers: true,
|
||||||
|
removeUnusedNS: true,
|
||||||
|
removeDesc: true,
|
||||||
|
removeDimensions: true,
|
||||||
|
removeStyleElement: true,
|
||||||
|
removeScriptElement: true,
|
||||||
|
removeOffCanvasPaths: true,
|
||||||
|
reusePaths: true,
|
||||||
|
},
|
||||||
},
|
},
|
||||||
},
|
},
|
||||||
|
],
|
||||||
// Sort the attributes on the <svg> tag
|
|
||||||
{
|
|
||||||
name: 'sortAttrs',
|
|
||||||
params: {
|
|
||||||
order: ['role', 'viewBox'],
|
|
||||||
xmlnsOrder: 'end',
|
|
||||||
},
|
|
||||||
},
|
|
||||||
|
|
||||||
// Convert basic shapes (such as <circle>) to <path>
|
|
||||||
{
|
|
||||||
name: 'convertShapeToPath',
|
|
||||||
params: {
|
|
||||||
// including <arc>
|
|
||||||
convertArcs: true,
|
|
||||||
},
|
|
||||||
},
|
|
||||||
|
|
||||||
// Compound all <path>s into one
|
|
||||||
{
|
|
||||||
name: 'mergePaths',
|
|
||||||
params: {
|
|
||||||
force: true,
|
|
||||||
noSpaceAfterFlags: false,
|
|
||||||
},
|
|
||||||
},
|
|
||||||
|
|
||||||
// Keep the <title> tag
|
|
||||||
{
|
|
||||||
name: 'removeTitle',
|
|
||||||
active: false,
|
|
||||||
},
|
|
||||||
|
|
||||||
// Keep the role="img" attribute and automatically add it
|
|
||||||
// to the <svg> tag if it's not there already
|
|
||||||
{
|
|
||||||
name: 'addAttributesToSVGElement',
|
|
||||||
params: {
|
|
||||||
attributes: [
|
|
||||||
{role: 'img'},
|
|
||||||
],
|
|
||||||
},
|
|
||||||
},
|
|
||||||
|
|
||||||
// Keep the 'role' attribute, if it's already defined
|
|
||||||
{
|
|
||||||
name: 'removeUnknownsAndDefaults',
|
|
||||||
params: {
|
|
||||||
keepRoleAttr: true,
|
|
||||||
},
|
|
||||||
},
|
|
||||||
|
|
||||||
// Remove all attributes except 'role', 'viewBox', and 'xmlns' from
|
|
||||||
// <svg> tags
|
|
||||||
{
|
|
||||||
name: 'removeAttrs',
|
|
||||||
params: {
|
|
||||||
attrs: [
|
|
||||||
'baseProfile',
|
|
||||||
'version',
|
|
||||||
'fill-rule',
|
|
||||||
],
|
|
||||||
},
|
|
||||||
},
|
|
||||||
|
|
||||||
// Remove paths with fill="none"
|
|
||||||
{
|
|
||||||
name: 'removeUselessStrokeAndFill',
|
|
||||||
params: {
|
|
||||||
removeNone: true,
|
|
||||||
},
|
|
||||||
},
|
|
||||||
|
|
||||||
// Explicitly enable everything else
|
|
||||||
'removeDoctype',
|
|
||||||
'removeXMLProcInst',
|
|
||||||
'removeComments',
|
|
||||||
'removeMetadata',
|
|
||||||
'removeEditorsNSData',
|
|
||||||
'cleanupAttrs',
|
|
||||||
'inlineStyles',
|
|
||||||
'minifyStyles',
|
|
||||||
'convertStyleToAttrs',
|
|
||||||
'cleanupIDs',
|
|
||||||
'prefixIds',
|
|
||||||
'removeRasterImages',
|
|
||||||
'removeUselessDefs',
|
|
||||||
'cleanupNumericValues',
|
|
||||||
'cleanupListOfValues',
|
|
||||||
'convertColors',
|
|
||||||
'removeNonInheritableGroupAttrs',
|
|
||||||
'removeViewBox',
|
|
||||||
'cleanupEnableBackground',
|
|
||||||
'removeHiddenElems',
|
|
||||||
'removeEmptyText',
|
|
||||||
'moveElemsAttrsToGroup',
|
|
||||||
'moveGroupAttrsToElems',
|
|
||||||
'collapseGroups',
|
|
||||||
'convertTransform',
|
|
||||||
'removeEmptyAttrs',
|
|
||||||
'removeEmptyContainers',
|
|
||||||
'removeUnusedNS',
|
|
||||||
'removeDesc',
|
|
||||||
'removeDimensions',
|
|
||||||
'removeStyleElement',
|
|
||||||
'removeScriptElement',
|
|
||||||
'removeOffCanvasPaths',
|
|
||||||
'reusePaths',
|
|
||||||
]),
|
|
||||||
};
|
};
|
||||||
|
Loading…
Reference in New Issue
Block a user