Skip to content

Commit dd70f34

Browse files
KreegAndrey Nelyubin
andauthored
fix: begin's attribute incorrectly modification (#1658)
Co-authored-by: Andrey Nelyubin <[email protected]>
1 parent 422fa14 commit dd70f34

File tree

2 files changed

+45
-2
lines changed

2 files changed

+45
-2
lines changed

plugins/cleanupIds.js

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -10,9 +10,9 @@ const { referencesProps } = require('./_collections.js');
1010
exports.name = 'cleanupIds';
1111
exports.description = 'removes unused IDs and minifies used';
1212

13-
const regReferencesUrl = /\burl\(("|')?#(.+?)\1\)/;
13+
const regReferencesUrl = /\burl\((["'])?#(.+?)\1\)/;
1414
const regReferencesHref = /^#(.+?)$/;
15-
const regReferencesBegin = /(\w+)\./;
15+
const regReferencesBegin = /(\D+)\./;
1616
const generateIdChars = [
1717
'a',
1818
'b',

test/plugins/cleanupIds.21.svg

Lines changed: 43 additions & 0 deletions
Loading

0 commit comments

Comments
 (0)