diff options
| author | Igor Minar | 2010-11-17 14:46:49 -0800 |
|---|---|---|
| committer | Igor Minar | 2010-11-18 02:35:28 -0800 |
| commit | a6978b201bbc1756b661dd968b3fb1b0d97f5033 (patch) | |
| tree | f717b9de459dbe2d2402b1da3600c8af6a0f31c2 /docs/collect.js | |
| parent | 28e72cbe6bfb874fa6a7f15769e5c83d66fb617f (diff) | |
| download | angular.js-a6978b201bbc1756b661dd968b3fb1b0d97f5033.tar.bz2 | |
make @param type and description non-optional
Diffstat (limited to 'docs/collect.js')
| -rw-r--r-- | docs/collect.js | 14 |
1 files changed, 7 insertions, 7 deletions
diff --git a/docs/collect.js b/docs/collect.js index 70a1ffbf..aa16490b 100644 --- a/docs/collect.js +++ b/docs/collect.js @@ -246,15 +246,15 @@ var TAG = { param: function(doc, name, value){ doc.param = doc.param || []; doc.paramRest = doc.paramRest || []; - var match = value.match(/^({([^\s=]+)(=)?}\s*)?(([^\s=]+)|\[(\S+)=([^\]]+)\])\s+(.*)/); - // 1 2 23 3 1 45 5 6 6 7 7 4 8 8 + var match = value.match(/^{([^}=]+)(=)?}\s+(([^\s=]+)|\[(\S+)=([^\]]+)\])\s+(.*)/); + // 1 12 2 34 4 5 5 6 6 3 7 7 if (match) { var param = { - type: match[2], - name: match[6] || match[5], - optional: !!match[3], - 'default':match[7], - description:markdownNoP(value.replace(match[0], match[8])) + type: match[1], + name: match[5] || match[4], + optional: !!match[2], + 'default':match[6], + description:markdownNoP(value.replace(match[0], match[7])) }; doc.param.push(param); if (!doc.paramFirst) { |
