Skip to content

Commit

Permalink
avoid backtracking (#100)
Browse files Browse the repository at this point in the history
  • Loading branch information
mbostock authored Mar 28, 2022
1 parent 7d61bbe commit 994d8fd
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions src/color.js
Original file line number Diff line number Diff line change
Expand Up @@ -6,8 +6,8 @@ export var darker = 0.7;
export var brighter = 1 / darker;

var reI = "\\s*([+-]?\\d+)\\s*",
reN = "\\s*([+-]?\\d*\\.?\\d+(?:[eE][+-]?\\d+)?)\\s*",
reP = "\\s*([+-]?\\d*\\.?\\d+(?:[eE][+-]?\\d+)?)%\\s*",
reN = "\\s*([+-]?(?:\\d*\\.)?\\d+(?:[eE][+-]?\\d+)?)\\s*",
reP = "\\s*([+-]?(?:\\d*\\.)?\\d+(?:[eE][+-]?\\d+)?)%\\s*",
reHex = /^#([0-9a-f]{3,8})$/,
reRgbInteger = new RegExp("^rgb\\(" + [reI, reI, reI] + "\\)$"),
reRgbPercent = new RegExp("^rgb\\(" + [reP, reP, reP] + "\\)$"),
Expand Down

0 comments on commit 994d8fd

Please sign in to comment.