mirror of
https://github.com/svg/svgo.git
synced 2025-07-31 07:44:22 +03:00
Use https when possible and fix an inactive domain (#1374)
This commit is contained in:
@ -277,9 +277,9 @@ const config = await loadConfig(configFile, cwd)
|
|||||||
|
|
||||||
## Backers
|
## Backers
|
||||||
|
|
||||||
| [<img src="https://sheetjs.com/sketch128.png" width="80">](https://sheetjs.com/) | [<img src="https://raw.githubusercontent.com/fontello/fontello/master/fontello-image.svg" width="80">](http://fontello.com/) |
|
| [<img src="https://sheetjs.com/sketch128.png" width="80">](https://sheetjs.com/) | [<img src="https://raw.githubusercontent.com/fontello/fontello/master/fontello-image.svg" width="80">](https://fontello.com/) |
|
||||||
|:-:|:-:|
|
|:-:|:-:|
|
||||||
| [SheetJS LLC](https://sheetjs.com/) | [Fontello](http://fontello.com/) |
|
| [SheetJS LLC](https://sheetjs.com/) | [Fontello](https://fontello.com/) |
|
||||||
|
|
||||||
## Donations
|
## Donations
|
||||||
|
|
||||||
|
@ -21,17 +21,17 @@
|
|||||||
{
|
{
|
||||||
"name": "Sergey Belov",
|
"name": "Sergey Belov",
|
||||||
"email": "peimei@ya.ru",
|
"email": "peimei@ya.ru",
|
||||||
"url": "http://github.com/arikon"
|
"url": "https://github.com/arikon"
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
"name": "Lev Solntsev",
|
"name": "Lev Solntsev",
|
||||||
"email": "lev.sun@ya.ru",
|
"email": "lev.sun@ya.ru",
|
||||||
"url": "http://github.com/GreLI"
|
"url": "https://github.com/GreLI"
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
"name": "Bogdan Chadkin",
|
"name": "Bogdan Chadkin",
|
||||||
"email": "trysound@yandex.ru",
|
"email": "trysound@yandex.ru",
|
||||||
"url": "http://github.com/TrySound"
|
"url": "https://github.com/TrySound"
|
||||||
}
|
}
|
||||||
],
|
],
|
||||||
"repository": {
|
"repository": {
|
||||||
|
@ -1,6 +1,6 @@
|
|||||||
'use strict';
|
'use strict';
|
||||||
|
|
||||||
// http://www.w3.org/TR/SVG11/intro.html#Definitions
|
// https://www.w3.org/TR/SVG11/intro.html#Definitions
|
||||||
exports.elemsGroups = {
|
exports.elemsGroups = {
|
||||||
animation: ['animate', 'animateColor', 'animateMotion', 'animateTransform', 'set'],
|
animation: ['animate', 'animateColor', 'animateMotion', 'animateTransform', 'set'],
|
||||||
descriptive: ['desc', 'metadata', 'title'],
|
descriptive: ['desc', 'metadata', 'title'],
|
||||||
@ -19,7 +19,7 @@ exports.textElems = exports.elemsGroups.textContent.concat('title');
|
|||||||
|
|
||||||
exports.pathElems = ['path', 'glyph', 'missing-glyph'];
|
exports.pathElems = ['path', 'glyph', 'missing-glyph'];
|
||||||
|
|
||||||
// http://www.w3.org/TR/SVG11/intro.html#Definitions
|
// https://www.w3.org/TR/SVG11/intro.html#Definitions
|
||||||
exports.attrsGroups = {
|
exports.attrsGroups = {
|
||||||
animationAddition: ['additive', 'accumulate'],
|
animationAddition: ['additive', 'accumulate'],
|
||||||
animationAttributeTarget: ['attributeType', 'attributeName'],
|
animationAttributeTarget: ['attributeType', 'attributeName'],
|
||||||
@ -158,7 +158,7 @@ exports.attrsGroupsDefaults = {
|
|||||||
transferFunction: {slope: '1', intercept: '0', amplitude: '1', exponent: '1', offset: '0'}
|
transferFunction: {slope: '1', intercept: '0', amplitude: '1', exponent: '1', offset: '0'}
|
||||||
};
|
};
|
||||||
|
|
||||||
// http://www.w3.org/TR/SVG11/eltindex.html
|
// https://www.w3.org/TR/SVG11/eltindex.html
|
||||||
exports.elems = {
|
exports.elems = {
|
||||||
a: {
|
a: {
|
||||||
attrsGroups: [
|
attrsGroups: [
|
||||||
@ -2269,7 +2269,7 @@ exports.elems = {
|
|||||||
}
|
}
|
||||||
};
|
};
|
||||||
|
|
||||||
// http://wiki.inkscape.org/wiki/index.php/Inkscape-specific_XML_attributes
|
// https://wiki.inkscape.org/wiki/index.php/Inkscape-specific_XML_attributes
|
||||||
exports.editorNamespaces = [
|
exports.editorNamespaces = [
|
||||||
'http://sodipodi.sourceforge.net/DTD/sodipodi-0.dtd',
|
'http://sodipodi.sourceforge.net/DTD/sodipodi-0.dtd',
|
||||||
'http://inkscape.sourceforge.net/DTD/sodipodi-0.dtd',
|
'http://inkscape.sourceforge.net/DTD/sodipodi-0.dtd',
|
||||||
@ -2295,7 +2295,7 @@ exports.editorNamespaces = [
|
|||||||
'http://www.vector.evaxdesign.sk'
|
'http://www.vector.evaxdesign.sk'
|
||||||
];
|
];
|
||||||
|
|
||||||
// http://www.w3.org/TR/SVG11/linking.html#processingIRI
|
// https://www.w3.org/TR/SVG11/linking.html#processingIRI
|
||||||
exports.referencesProps = [
|
exports.referencesProps = [
|
||||||
'clip-path',
|
'clip-path',
|
||||||
'color-profile',
|
'color-profile',
|
||||||
@ -2309,7 +2309,7 @@ exports.referencesProps = [
|
|||||||
'style'
|
'style'
|
||||||
];
|
];
|
||||||
|
|
||||||
// http://www.w3.org/TR/SVG11/propidx.html
|
// https://www.w3.org/TR/SVG11/propidx.html
|
||||||
exports.inheritableAttrs = [
|
exports.inheritableAttrs = [
|
||||||
'clip-rule',
|
'clip-rule',
|
||||||
'color',
|
'color',
|
||||||
@ -2370,7 +2370,7 @@ exports.presentationNonInheritableGroupAttrs = [
|
|||||||
'visibility'
|
'visibility'
|
||||||
];
|
];
|
||||||
|
|
||||||
// http://www.w3.org/TR/SVG11/single-page.html#types-ColorKeywords
|
// https://www.w3.org/TR/SVG11/single-page.html#types-ColorKeywords
|
||||||
exports.colorsNames = {
|
exports.colorsNames = {
|
||||||
'aliceblue': '#f0f8ff',
|
'aliceblue': '#f0f8ff',
|
||||||
'antiquewhite': '#faebd7',
|
'antiquewhite': '#faebd7',
|
||||||
@ -2557,7 +2557,7 @@ exports.colorsShortNames = {
|
|||||||
'#f5deb3': 'wheat'
|
'#f5deb3': 'wheat'
|
||||||
};
|
};
|
||||||
|
|
||||||
// http://www.w3.org/TR/SVG11/single-page.html#types-DataTypeColor
|
// https://www.w3.org/TR/SVG11/single-page.html#types-DataTypeColor
|
||||||
exports.colorsProps = [
|
exports.colorsProps = [
|
||||||
'color', 'fill', 'stroke', 'stop-color', 'flood-color', 'lighting-color'
|
'color', 'fill', 'stroke', 'stop-color', 'flood-color', 'lighting-color'
|
||||||
];
|
];
|
||||||
|
@ -75,7 +75,7 @@ exports.path2js = function(path) {
|
|||||||
|
|
||||||
data = data.map(Number);
|
data = data.map(Number);
|
||||||
// Subsequent moveto pairs of coordinates are threated as implicit lineto commands
|
// Subsequent moveto pairs of coordinates are threated as implicit lineto commands
|
||||||
// http://www.w3.org/TR/SVG11/paths.html#PathDataMovetoCommands
|
// https://www.w3.org/TR/SVG11/paths.html#PathDataMovetoCommands
|
||||||
if (instruction == 'M' || instruction == 'm') {
|
if (instruction == 'M' || instruction == 'm') {
|
||||||
pathData.push({
|
pathData.push({
|
||||||
instruction: pathData.length == 0 ? 'M' : instruction,
|
instruction: pathData.length == 0 ? 'M' : instruction,
|
||||||
@ -354,7 +354,7 @@ function transformPoint(matrix, x, y) {
|
|||||||
/**
|
/**
|
||||||
* Compute Cubic Bézie bounding box.
|
* Compute Cubic Bézie bounding box.
|
||||||
*
|
*
|
||||||
* @see http://processingjs.nihongoresources.com/bezierinfo/
|
* @see https://pomax.github.io/bezierinfo/
|
||||||
*
|
*
|
||||||
* @param {Float} xa
|
* @param {Float} xa
|
||||||
* @param {Float} ya
|
* @param {Float} ya
|
||||||
@ -461,7 +461,7 @@ function computeCubicFirstDerivativeRoots(a, b, c, d) {
|
|||||||
/**
|
/**
|
||||||
* Compute Quadratic Bézier bounding box.
|
* Compute Quadratic Bézier bounding box.
|
||||||
*
|
*
|
||||||
* @see http://processingjs.nihongoresources.com/bezierinfo/
|
* @see https://pomax.github.io/bezierinfo/
|
||||||
*
|
*
|
||||||
* @param {Float} xa
|
* @param {Float} xa
|
||||||
* @param {Float} ya
|
* @param {Float} ya
|
||||||
@ -623,7 +623,7 @@ function set(dest, source) {
|
|||||||
/**
|
/**
|
||||||
* Checks if two paths have an intersection by checking convex hulls
|
* Checks if two paths have an intersection by checking convex hulls
|
||||||
* collision using Gilbert-Johnson-Keerthi distance algorithm
|
* collision using Gilbert-Johnson-Keerthi distance algorithm
|
||||||
* http://entropyinteractive.com/2011/04/gjk-algorithm/
|
* https://web.archive.org/web/20180822200027/http://entropyinteractive.com/2011/04/gjk-algorithm/
|
||||||
*
|
*
|
||||||
* @param {Array} path1 JS path representation
|
* @param {Array} path1 JS path representation
|
||||||
* @param {Array} path2 JS path representation
|
* @param {Array} path2 JS path representation
|
||||||
@ -852,7 +852,7 @@ function gatherPoints(points, item, index, path) {
|
|||||||
|
|
||||||
/**
|
/**
|
||||||
* Forms a convex hull from set of points of every subpath using monotone chain convex hull algorithm.
|
* Forms a convex hull from set of points of every subpath using monotone chain convex hull algorithm.
|
||||||
* http://en.wikibooks.org/wiki/Algorithm_Implementation/Geometry/Convex_hull/Monotone_chain
|
* https://en.wikibooks.org/wiki/Algorithm_Implementation/Geometry/Convex_hull/Monotone_chain
|
||||||
*
|
*
|
||||||
* @param points An array of [X, Y] coordinates
|
* @param points An array of [X, Y] coordinates
|
||||||
*/
|
*/
|
||||||
@ -914,7 +914,7 @@ function cross(o, a, b) {
|
|||||||
|
|
||||||
function a2c(x1, y1, rx, ry, angle, large_arc_flag, sweep_flag, x2, y2, recursive) {
|
function a2c(x1, y1, rx, ry, angle, large_arc_flag, sweep_flag, x2, y2, recursive) {
|
||||||
// for more information of where this Math came from visit:
|
// for more information of where this Math came from visit:
|
||||||
// http://www.w3.org/TR/SVG11/implnote.html#ArcImplementationNotes
|
// https://www.w3.org/TR/SVG11/implnote.html#ArcImplementationNotes
|
||||||
var _120 = Math.PI * 120 / 180,
|
var _120 = Math.PI * 120 / 180,
|
||||||
rad = Math.PI / 180 * (+angle || 0),
|
rad = Math.PI / 180 * (+angle || 0),
|
||||||
res = [],
|
res = [],
|
||||||
|
@ -115,7 +115,7 @@ var mth = exports.mth = {
|
|||||||
|
|
||||||
/**
|
/**
|
||||||
* Decompose matrix into simple transforms. See
|
* Decompose matrix into simple transforms. See
|
||||||
* http://frederic-wang.fr/decomposition-of-2d-transform-matrices.html
|
* https://frederic-wang.fr/decomposition-of-2d-transform-matrices.html
|
||||||
*
|
*
|
||||||
* @param {Object} data matrix transform object
|
* @param {Object} data matrix transform object
|
||||||
* @return {Object|Array} transforms array or original transform object
|
* @return {Object|Array} transforms array or original transform object
|
||||||
|
@ -9,7 +9,7 @@ exports.description = 'remove or cleanup enable-background attribute when possib
|
|||||||
/**
|
/**
|
||||||
* Remove or cleanup enable-background attr which coincides with a width/height box.
|
* Remove or cleanup enable-background attr which coincides with a width/height box.
|
||||||
*
|
*
|
||||||
* @see http://www.w3.org/TR/SVG11/filters.html#EnableBackgroundProperty
|
* @see https://www.w3.org/TR/SVG11/filters.html#EnableBackgroundProperty
|
||||||
*
|
*
|
||||||
* @example
|
* @example
|
||||||
* <svg width="100" height="50" enable-background="new 0 0 100 50">
|
* <svg width="100" height="50" enable-background="new 0 0 100 50">
|
||||||
|
@ -24,8 +24,8 @@ var collections = require('./_collections'),
|
|||||||
/**
|
/**
|
||||||
* Convert different colors formats in element attributes to hex.
|
* Convert different colors formats in element attributes to hex.
|
||||||
*
|
*
|
||||||
* @see http://www.w3.org/TR/SVG11/types.html#DataTypeColor
|
* @see https://www.w3.org/TR/SVG11/types.html#DataTypeColor
|
||||||
* @see http://www.w3.org/TR/SVG11/single-page.html#types-ColorKeywords
|
* @see https://www.w3.org/TR/SVG11/single-page.html#types-ColorKeywords
|
||||||
*
|
*
|
||||||
* @example
|
* @example
|
||||||
* Convert color name keyword to long hex:
|
* Convert color name keyword to long hex:
|
||||||
|
@ -9,7 +9,7 @@ exports.description = 'converts non-eccentric <ellipse>s to <circle>s';
|
|||||||
/**
|
/**
|
||||||
* Converts non-eccentric <ellipse>s to <circle>s.
|
* Converts non-eccentric <ellipse>s to <circle>s.
|
||||||
*
|
*
|
||||||
* @see http://www.w3.org/TR/SVG11/shapes.html
|
* @see https://www.w3.org/TR/SVG11/shapes.html
|
||||||
*
|
*
|
||||||
* @param {Object} item current iteration item
|
* @param {Object} item current iteration item
|
||||||
* @return {Boolean} if false, item will be filtered out
|
* @return {Boolean} if false, item will be filtered out
|
||||||
|
@ -48,7 +48,7 @@ var pathElems = require('./_collections.js').pathElems,
|
|||||||
* trim useless delimiters and leading zeros,
|
* trim useless delimiters and leading zeros,
|
||||||
* decrease accuracy of floating-point numbers.
|
* decrease accuracy of floating-point numbers.
|
||||||
*
|
*
|
||||||
* @see http://www.w3.org/TR/SVG11/paths.html#PathData
|
* @see https://www.w3.org/TR/SVG11/paths.html#PathData
|
||||||
*
|
*
|
||||||
* @param {Object} item current iteration item
|
* @param {Object} item current iteration item
|
||||||
* @param {Object} params plugin params
|
* @param {Object} params plugin params
|
||||||
|
@ -18,7 +18,7 @@ var none = { value: 0 },
|
|||||||
* It also allows further optimizations like
|
* It also allows further optimizations like
|
||||||
* combining paths with similar attributes.
|
* combining paths with similar attributes.
|
||||||
*
|
*
|
||||||
* @see http://www.w3.org/TR/SVG11/shapes.html
|
* @see https://www.w3.org/TR/SVG11/shapes.html
|
||||||
*
|
*
|
||||||
* @param {Object} item current iteration item
|
* @param {Object} item current iteration item
|
||||||
* @param {Object} params plugin params
|
* @param {Object} params plugin params
|
||||||
|
@ -35,7 +35,7 @@ var cleanupOutData = require('../lib/svgo/tools').cleanupOutData,
|
|||||||
* convert transforms to the matrices and multiply them all into one,
|
* convert transforms to the matrices and multiply them all into one,
|
||||||
* remove useless transforms.
|
* remove useless transforms.
|
||||||
*
|
*
|
||||||
* @see http://www.w3.org/TR/SVG11/coords.html#TransformMatrixDefined
|
* @see https://www.w3.org/TR/SVG11/coords.html#TransformMatrixDefined
|
||||||
*
|
*
|
||||||
* @param {Object} item current iteration item
|
* @param {Object} item current iteration item
|
||||||
* @param {Object} params plugin params
|
* @param {Object} params plugin params
|
||||||
|
@ -11,7 +11,7 @@ var container = require('./_collections').elemsGroups.container;
|
|||||||
/**
|
/**
|
||||||
* Remove empty containers.
|
* Remove empty containers.
|
||||||
*
|
*
|
||||||
* @see http://www.w3.org/TR/SVG11/intro.html#TermContainerElement
|
* @see https://www.w3.org/TR/SVG11/intro.html#TermContainerElement
|
||||||
*
|
*
|
||||||
* @example
|
* @example
|
||||||
* <defs/>
|
* <defs/>
|
||||||
|
@ -15,7 +15,7 @@ exports.params = {
|
|||||||
/**
|
/**
|
||||||
* Remove empty Text elements.
|
* Remove empty Text elements.
|
||||||
*
|
*
|
||||||
* @see http://www.w3.org/TR/SVG11/text.html
|
* @see https://www.w3.org/TR/SVG11/text.html
|
||||||
*
|
*
|
||||||
* @example
|
* @example
|
||||||
* Remove empty text element:
|
* Remove empty text element:
|
||||||
|
@ -59,7 +59,7 @@ exports.fn = function (item, params) {
|
|||||||
|
|
||||||
// display="none"
|
// display="none"
|
||||||
//
|
//
|
||||||
// http://www.w3.org/TR/SVG11/painting.html#DisplayProperty
|
// https://www.w3.org/TR/SVG11/painting.html#DisplayProperty
|
||||||
// "A value of display: none indicates that the given element
|
// "A value of display: none indicates that the given element
|
||||||
// and its children shall not be rendered directly"
|
// and its children shall not be rendered directly"
|
||||||
if (
|
if (
|
||||||
@ -69,7 +69,7 @@ exports.fn = function (item, params) {
|
|||||||
|
|
||||||
// opacity="0"
|
// opacity="0"
|
||||||
//
|
//
|
||||||
// http://www.w3.org/TR/SVG11/masking.html#ObjectAndGroupOpacityProperties
|
// https://www.w3.org/TR/SVG11/masking.html#ObjectAndGroupOpacityProperties
|
||||||
if (
|
if (
|
||||||
params.opacity0 &&
|
params.opacity0 &&
|
||||||
item.hasAttr('opacity', '0') &&
|
item.hasAttr('opacity', '0') &&
|
||||||
@ -79,7 +79,7 @@ exports.fn = function (item, params) {
|
|||||||
|
|
||||||
// Circles with zero radius
|
// Circles with zero radius
|
||||||
//
|
//
|
||||||
// http://www.w3.org/TR/SVG11/shapes.html#CircleElementRAttribute
|
// https://www.w3.org/TR/SVG11/shapes.html#CircleElementRAttribute
|
||||||
// "A value of zero disables rendering of the element"
|
// "A value of zero disables rendering of the element"
|
||||||
//
|
//
|
||||||
// <circle r="0">
|
// <circle r="0">
|
||||||
@ -92,7 +92,7 @@ exports.fn = function (item, params) {
|
|||||||
|
|
||||||
// Ellipse with zero x-axis radius
|
// Ellipse with zero x-axis radius
|
||||||
//
|
//
|
||||||
// http://www.w3.org/TR/SVG11/shapes.html#EllipseElementRXAttribute
|
// https://www.w3.org/TR/SVG11/shapes.html#EllipseElementRXAttribute
|
||||||
// "A value of zero disables rendering of the element"
|
// "A value of zero disables rendering of the element"
|
||||||
//
|
//
|
||||||
// <ellipse rx="0">
|
// <ellipse rx="0">
|
||||||
@ -105,7 +105,7 @@ exports.fn = function (item, params) {
|
|||||||
|
|
||||||
// Ellipse with zero y-axis radius
|
// Ellipse with zero y-axis radius
|
||||||
//
|
//
|
||||||
// http://www.w3.org/TR/SVG11/shapes.html#EllipseElementRYAttribute
|
// https://www.w3.org/TR/SVG11/shapes.html#EllipseElementRYAttribute
|
||||||
// "A value of zero disables rendering of the element"
|
// "A value of zero disables rendering of the element"
|
||||||
//
|
//
|
||||||
// <ellipse ry="0">
|
// <ellipse ry="0">
|
||||||
@ -118,7 +118,7 @@ exports.fn = function (item, params) {
|
|||||||
|
|
||||||
// Rectangle with zero width
|
// Rectangle with zero width
|
||||||
//
|
//
|
||||||
// http://www.w3.org/TR/SVG11/shapes.html#RectElementWidthAttribute
|
// https://www.w3.org/TR/SVG11/shapes.html#RectElementWidthAttribute
|
||||||
// "A value of zero disables rendering of the element"
|
// "A value of zero disables rendering of the element"
|
||||||
//
|
//
|
||||||
// <rect width="0">
|
// <rect width="0">
|
||||||
@ -131,7 +131,7 @@ exports.fn = function (item, params) {
|
|||||||
|
|
||||||
// Rectangle with zero height
|
// Rectangle with zero height
|
||||||
//
|
//
|
||||||
// http://www.w3.org/TR/SVG11/shapes.html#RectElementHeightAttribute
|
// https://www.w3.org/TR/SVG11/shapes.html#RectElementHeightAttribute
|
||||||
// "A value of zero disables rendering of the element"
|
// "A value of zero disables rendering of the element"
|
||||||
//
|
//
|
||||||
// <rect height="0">
|
// <rect height="0">
|
||||||
@ -145,7 +145,7 @@ exports.fn = function (item, params) {
|
|||||||
|
|
||||||
// Pattern with zero width
|
// Pattern with zero width
|
||||||
//
|
//
|
||||||
// http://www.w3.org/TR/SVG11/pservers.html#PatternElementWidthAttribute
|
// https://www.w3.org/TR/SVG11/pservers.html#PatternElementWidthAttribute
|
||||||
// "A value of zero disables rendering of the element (i.e., no paint is applied)"
|
// "A value of zero disables rendering of the element (i.e., no paint is applied)"
|
||||||
//
|
//
|
||||||
// <pattern width="0">
|
// <pattern width="0">
|
||||||
@ -157,7 +157,7 @@ exports.fn = function (item, params) {
|
|||||||
|
|
||||||
// Pattern with zero height
|
// Pattern with zero height
|
||||||
//
|
//
|
||||||
// http://www.w3.org/TR/SVG11/pservers.html#PatternElementHeightAttribute
|
// https://www.w3.org/TR/SVG11/pservers.html#PatternElementHeightAttribute
|
||||||
// "A value of zero disables rendering of the element (i.e., no paint is applied)"
|
// "A value of zero disables rendering of the element (i.e., no paint is applied)"
|
||||||
//
|
//
|
||||||
// <pattern height="0">
|
// <pattern height="0">
|
||||||
@ -169,7 +169,7 @@ exports.fn = function (item, params) {
|
|||||||
|
|
||||||
// Image with zero width
|
// Image with zero width
|
||||||
//
|
//
|
||||||
// http://www.w3.org/TR/SVG11/struct.html#ImageElementWidthAttribute
|
// https://www.w3.org/TR/SVG11/struct.html#ImageElementWidthAttribute
|
||||||
// "A value of zero disables rendering of the element"
|
// "A value of zero disables rendering of the element"
|
||||||
//
|
//
|
||||||
// <image width="0">
|
// <image width="0">
|
||||||
@ -181,7 +181,7 @@ exports.fn = function (item, params) {
|
|||||||
|
|
||||||
// Image with zero height
|
// Image with zero height
|
||||||
//
|
//
|
||||||
// http://www.w3.org/TR/SVG11/struct.html#ImageElementHeightAttribute
|
// https://www.w3.org/TR/SVG11/struct.html#ImageElementHeightAttribute
|
||||||
// "A value of zero disables rendering of the element"
|
// "A value of zero disables rendering of the element"
|
||||||
//
|
//
|
||||||
// <image height="0">
|
// <image height="0">
|
||||||
@ -193,7 +193,7 @@ exports.fn = function (item, params) {
|
|||||||
|
|
||||||
// Path with empty data
|
// Path with empty data
|
||||||
//
|
//
|
||||||
// http://www.w3.org/TR/SVG11/paths.html#DAttribute
|
// https://www.w3.org/TR/SVG11/paths.html#DAttribute
|
||||||
//
|
//
|
||||||
// <path d=""/>
|
// <path d=""/>
|
||||||
if (
|
if (
|
||||||
@ -204,7 +204,7 @@ exports.fn = function (item, params) {
|
|||||||
|
|
||||||
// Polyline with empty points
|
// Polyline with empty points
|
||||||
//
|
//
|
||||||
// http://www.w3.org/TR/SVG11/shapes.html#PolylineElementPointsAttribute
|
// https://www.w3.org/TR/SVG11/shapes.html#PolylineElementPointsAttribute
|
||||||
//
|
//
|
||||||
// <polyline points="">
|
// <polyline points="">
|
||||||
if (
|
if (
|
||||||
@ -215,7 +215,7 @@ exports.fn = function (item, params) {
|
|||||||
|
|
||||||
// Polygon with empty points
|
// Polygon with empty points
|
||||||
//
|
//
|
||||||
// http://www.w3.org/TR/SVG11/shapes.html#PolygonElementPointsAttribute
|
// https://www.w3.org/TR/SVG11/shapes.html#PolygonElementPointsAttribute
|
||||||
//
|
//
|
||||||
// <polygon points="">
|
// <polygon points="">
|
||||||
if (
|
if (
|
||||||
|
@ -9,7 +9,7 @@ exports.description = 'removes <metadata>';
|
|||||||
/**
|
/**
|
||||||
* Remove <metadata>.
|
* Remove <metadata>.
|
||||||
*
|
*
|
||||||
* http://www.w3.org/TR/SVG11/metadata.html
|
* https://www.w3.org/TR/SVG11/metadata.html
|
||||||
*
|
*
|
||||||
* @param {Object} item current iteration item
|
* @param {Object} item current iteration item
|
||||||
* @return {Boolean} if false, item will be filtered out
|
* @return {Boolean} if false, item will be filtered out
|
||||||
|
@ -9,7 +9,7 @@ exports.description = 'removes <style> element (disabled by default)';
|
|||||||
/**
|
/**
|
||||||
* Remove <style>.
|
* Remove <style>.
|
||||||
*
|
*
|
||||||
* http://www.w3.org/TR/SVG11/styling.html#StyleElement
|
* https://www.w3.org/TR/SVG11/styling.html#StyleElement
|
||||||
*
|
*
|
||||||
* @param {Object} item current iteration item
|
* @param {Object} item current iteration item
|
||||||
* @return {Boolean} if false, item will be filtered out
|
* @return {Boolean} if false, item will be filtered out
|
||||||
|
@ -11,7 +11,7 @@ var viewBoxElems = ['svg', 'pattern', 'symbol'];
|
|||||||
/**
|
/**
|
||||||
* Remove viewBox attr which coincides with a width/height box.
|
* Remove viewBox attr which coincides with a width/height box.
|
||||||
*
|
*
|
||||||
* @see http://www.w3.org/TR/SVG11/coords.html#ViewBoxAttribute
|
* @see https://www.w3.org/TR/SVG11/coords.html#ViewBoxAttribute
|
||||||
*
|
*
|
||||||
* @example
|
* @example
|
||||||
* <svg width="100" height="50" viewBox="0 0 100 50">
|
* <svg width="100" height="50" viewBox="0 0 100 50">
|
||||||
|
Reference in New Issue
Block a user