-
Notifications
You must be signed in to change notification settings - Fork 1
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Check for reference by <use> before deleting defaults in removeUnknow…
…nsAndDefaults.
- Loading branch information
1 parent
e90cdad
commit d8c3ea8
Showing
3 changed files
with
115 additions
and
3 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,36 @@ | ||
Preserve defaults on elements in <defs> that may be <use>d. | ||
|
||
See: https://github.com/svg/svgo/issues/1486 | ||
|
||
=== | ||
|
||
<svg xmlns="http://www.w3.org/2000/svg" viewBox="350 -953 560 490"> | ||
<defs> | ||
<g id="bubble_2" fill="#ff0000"> | ||
<text x="791" y="-761" dy="0.7ex" text-anchor="start" stroke="none">China</text> | ||
</g> | ||
</defs> | ||
<g text-anchor="middle"> | ||
<g text-anchor="start"> | ||
<use href="#bubble_2"/> | ||
</g> | ||
<use href="#bubble_2"/> | ||
</g> | ||
</svg> | ||
|
||
@@@ | ||
|
||
<svg xmlns="http://www.w3.org/2000/svg" viewBox="350 -953 560 490"> | ||
<defs> | ||
<g id="bubble_2" fill="#ff0000"> | ||
<text x="791" y="-761" dy="0.7ex" text-anchor="start" stroke="none">China</text> | ||
</g> | ||
</defs> | ||
<g text-anchor="middle"> | ||
<g text-anchor="start"> | ||
<use href="#bubble_2"/> | ||
</g> | ||
<use href="#bubble_2"/> | ||
</g> | ||
</svg> | ||
|