Skip to content

Commit

Permalink
Remove the removeViewBox plugin from the default plugins list
Browse files Browse the repository at this point in the history
Fixes svg#1128
  • Loading branch information
JohnAlbin authored and SethFalco committed Dec 9, 2023
1 parent 3dc2f6f commit 24ed2c6
Show file tree
Hide file tree
Showing 3 changed files with 1 addition and 4 deletions.
1 change: 0 additions & 1 deletion docs/03-plugins/remove-viewbox.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,6 @@
title: Remove ViewBox
svgo:
pluginId: removeViewBox
defaultPlugin: true
---

Removes the [`viewBox`](https://developer.mozilla.org/docs/Web/SVG/Attribute/viewBox) attribute where it matches the documents width and height.
Expand Down
2 changes: 0 additions & 2 deletions plugins/preset-default.js
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,6 @@ const convertColors = require('./convertColors.js');
const removeUnknownsAndDefaults = require('./removeUnknownsAndDefaults.js');
const removeNonInheritableGroupAttrs = require('./removeNonInheritableGroupAttrs.js');
const removeUselessStrokeAndFill = require('./removeUselessStrokeAndFill.js');
const removeViewBox = require('./removeViewBox.js');
const cleanupEnableBackground = require('./cleanupEnableBackground.js');
const removeHiddenElems = require('./removeHiddenElems.js');
const removeEmptyText = require('./removeEmptyText.js');
Expand Down Expand Up @@ -57,7 +56,6 @@ const presetDefault = createPreset({
removeUnknownsAndDefaults,
removeNonInheritableGroupAttrs,
removeUselessStrokeAndFill,
removeViewBox,
cleanupEnableBackground,
removeHiddenElems,
removeEmptyText,
Expand Down
2 changes: 1 addition & 1 deletion plugins/removeDimensions.js
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@

exports.name = 'removeDimensions';
exports.description =
'removes width and height in presence of viewBox (opposite to removeViewBox, disable it first)';
'removes width and height in presence of viewBox (opposite to removeViewBox)';

/**
* Remove width/height attributes and add the viewBox attribute if it's missing
Expand Down

0 comments on commit 24ed2c6

Please sign in to comment.