diff options
author | wout <wout@impinc.co.uk> | 2013-06-23 14:59:46 +0100 |
---|---|---|
committer | wout <wout@impinc.co.uk> | 2013-06-23 14:59:46 +0100 |
commit | a72b8a7afb609b9a76c494d9123d78e5c40962bf (patch) | |
tree | fdaacf9d56a3cc9e935ab1a5dcb4ad0458f929e4 /src/regex.js | |
parent | 5e52bd4f9f309b20bc848d5d45e5e620b17c1ad7 (diff) | |
download | svg.js-a72b8a7afb609b9a76c494d9123d78e5c40962bf.tar.gz svg.js-a72b8a7afb609b9a76c494d9123d78e5c40962bf.zip |
Added SVG.Number, reworked gradient system
Diffstat (limited to 'src/regex.js')
-rw-r--r-- | src/regex.js | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/src/regex.js b/src/regex.js index 4cd74ae..4286d8a 100644 --- a/src/regex.js +++ b/src/regex.js @@ -13,7 +13,7 @@ SVG.regex = { /* parse rgb value */ , rgb: /rgb\((\d+),(\d+),(\d+)\)/ - + /* test hex value */ , isHex: /^#[a-f0-9]{3,6}$/i @@ -31,5 +31,8 @@ SVG.regex = { /* test for numeric string */ , isNumber: /^-?[\d\.]+$/ + + /* test for percent value */ +, isPercent: /^-?[\d\.]+%$/ }
\ No newline at end of file |