Skip to content

Commit

Permalink
v2.9.0
Browse files Browse the repository at this point in the history
  • Loading branch information
marcandre committed Apr 10, 2019
1 parent 4be771e commit 7fc5786
Show file tree
Hide file tree
Showing 17 changed files with 84 additions and 27 deletions.
4 changes: 4 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,10 @@

Parsley follows [semver](https://semver.org/). This lists new features only. For bug fixes and small changes, check the commit list.

## 2.9

- Added `euvatin` (European Union Value Added Tax Identification Number) validator.

## 2.8

- Added `refresh` method. Parsley automatically refreshes before validating, but `refresh` is there if one needs to insure that some fields are rebound/unbound, or triggers are updated, etc...
Expand Down
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ JavaScript form validation, without actually writing a single line of JavaScript

## Version

2.8.2
2.9.0

## Doc

Expand Down
10 changes: 5 additions & 5 deletions dist/i18n/en.extra.js
Original file line number Diff line number Diff line change
Expand Up @@ -6,9 +6,9 @@ Parsley.addMessages('en', {
minwords: "This value is too short. It should have %s words or more.",
maxwords: "This value is too long. It should have %s words or fewer.",
words: "This value length is invalid. It should be between %s and %s words long.",
gt: "This value should be greater.",
gte: "This value should be greater or equal.",
lt: "This value should be less.",
lte: "This value should be less or equal.",
notequalto: "This value should be different."
gt: "This value should be greater than %s.",
gte: "This value should be greater or equal to %s.",
lt: "This value should be less than %s.",
lte: "This value should be less or equal to %s.",
notequalto: "This value should be different from %s."
});
3 changes: 2 additions & 1 deletion dist/i18n/en.js
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,8 @@ Parsley.addMessages('en', {
mincheck: "You must select at least %s choices.",
maxcheck: "You must select %s choices or fewer.",
check: "You must select between %s and %s choices.",
equalto: "This value should be the same."
equalto: "This value should be the same.",
euvatin: "It's not a valid VAT Identification Number.",
});

Parsley.setLocale('en');
10 changes: 9 additions & 1 deletion dist/i18n/it.extra.js
Original file line number Diff line number Diff line change
Expand Up @@ -2,5 +2,13 @@
// Load this after Parsley

Parsley.addMessages('it', {
dateiso: "Inserire una data valida (AAAA-MM-GG)."
dateiso: "Inserire una data valida (AAAA-MM-GG).",
minwords: "Questo valore deve avere almeno %s parole.",
maxwords: "Questo valore deve avere meno di %s parole.",
words: "Questo valore deve avere tra %s e %s parole.",
gt: "Questo valore deve essere maggiore di %s.",
gte: "Questo valore deve essere maggiore o uguale a %s.",
lt: "Questo valore deve essere minore di %s.",
lte: "Questo valore deve essere minore o uguale a %s.",
notequalto: "Questo valore deve essere differente da %s.",
});
3 changes: 2 additions & 1 deletion dist/i18n/it.js
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,8 @@ Parsley.addMessages('it', {
mincheck: "Devi scegliere almeno %s opzioni.",
maxcheck: "Devi scegliere al più %s opzioni.",
check: "Devi scegliere tra %s e %s opzioni.",
equalto: "Questo valore deve essere identico."
equalto: "Questo valore deve essere identico.",
euvatin: "Non è un codice IVA valido",
});

Parsley.setLocale('it');
20 changes: 16 additions & 4 deletions dist/parsley.js

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion dist/parsley.js.map

Large diffs are not rendered by default.

2 changes: 1 addition & 1 deletion dist/parsley.min.js

Large diffs are not rendered by default.

2 changes: 1 addition & 1 deletion dist/parsley.min.js.map

Large diffs are not rendered by default.

2 changes: 1 addition & 1 deletion doc/annotated-source/factory.html
Original file line number Diff line number Diff line change
Expand Up @@ -189,7 +189,7 @@ <h1>factory.js</h1>
Factory.prototype = {
<span class="hljs-attr">init</span>: <span class="hljs-function"><span class="hljs-keyword">function</span> (<span class="hljs-params">options</span>) </span>{
<span class="hljs-keyword">this</span>.__class__ = <span class="hljs-string">'Parsley'</span>;
<span class="hljs-keyword">this</span>.__version__ = <span class="hljs-string">'@@version'</span>;
<span class="hljs-keyword">this</span>.__version__ = <span class="hljs-string">'VERSION'</span>;
<span class="hljs-keyword">this</span>.__id__ = Utils.generateID();</pre></div></div>

</li>
Expand Down
2 changes: 1 addition & 1 deletion doc/annotated-source/main.html
Original file line number Diff line number Diff line change
Expand Up @@ -149,7 +149,7 @@ <h1>main.js</h1>
<span class="hljs-attr">actualizeOptions</span>: <span class="hljs-literal">null</span>,
<span class="hljs-attr">_resetOptions</span>: <span class="hljs-literal">null</span>,
<span class="hljs-attr">Factory</span>: Factory,
<span class="hljs-attr">version</span>: <span class="hljs-string">'@@version'</span>
<span class="hljs-attr">version</span>: <span class="hljs-string">'VERSION'</span>
});</pre></div></div>

</li>
Expand Down
13 changes: 12 additions & 1 deletion doc/annotated-source/validator_registry.html
Original file line number Diff line number Diff line change
Expand Up @@ -796,7 +796,18 @@ <h1>validator_registry.js</h1>
<span class="hljs-keyword">return</span> value === refOrValue;
},
<span class="hljs-attr">priority</span>: <span class="hljs-number">256</span>
}
},
<span class="hljs-attr">euvatin</span>: {
<span class="hljs-attr">validateString</span>: <span class="hljs-function"><span class="hljs-keyword">function</span> (<span class="hljs-params">value, refOrValue</span>) </span>{
<span class="hljs-keyword">if</span> (!value) {
<span class="hljs-keyword">return</span> <span class="hljs-literal">true</span>; <span class="hljs-comment">// Builtin validators all accept empty strings, except `required` of course</span>
}

<span class="hljs-keyword">var</span> re = <span class="hljs-regexp">/^[A-Z][A-Z][A-Za-z0-9 -]{2,}$/</span>;
<span class="hljs-keyword">return</span> re.test(value);
},
<span class="hljs-attr">priority</span>: <span class="hljs-number">30</span>,
},
}
};

Expand Down
28 changes: 24 additions & 4 deletions doc/assets/spec-build.js

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

4 changes: 2 additions & 2 deletions doc/download.html
Original file line number Diff line number Diff line change
Expand Up @@ -63,13 +63,13 @@ <h3 class="text-muted"><a href="../">Parsley</a></h3>

<!-- Jumbotron -->
<div class="jumbotron">
<h1>Download <em>Parsley</em> <small class="parsley-version">v2.8.2</small></h1>
<h1>Download <em>Parsley</em> <small class="parsley-version">v2.9.0</small></h1>
<hr>
<div class="col-md-12"><h2>Whole project..</h2></div>

<div class="col-md-12"><code>$ bower install --save parsleyjs</code></div>
<div class="col-md-12"><code>$ npm install --save parsleyjs</code></div>
<div class="col-md-12"><a href="https://github.com/guillaumepotier/Parsley.js/releases/tag/2.8.2" class="download" data-version="zipball" target="_blank">parsley.zip</a> <small>250ko</small></div>
<div class="col-md-12"><a href="https://github.com/guillaumepotier/Parsley.js/releases/tag/2.9.0" class="download" data-version="zipball" target="_blank">parsley.zip</a> <small>250ko</small></div>

<div class="col-md-12"><h2>..or pick & go!</h2></div>

Expand Down
2 changes: 1 addition & 1 deletion index.html
Original file line number Diff line number Diff line change
Expand Up @@ -123,7 +123,7 @@ <h3 class="text-muted"><a href="#">Parsley</a></h3>
<h1><em>Parsley</em>, the <strong>ultimate</strong> JavaScript <strong>form validation</strong> library</h1>
<p class="lead">Validating forms frontend have never been so <em>powerful</em> and <em>easy</em>.</p>
<p><a class="btn btn-lg btn-go" href="doc/index.html" role="button">Get started today</a></p>
<p class="version"><i class="icon glyphicon glyphicon-tag"></i>&nbsp;<span class="parsley-version">v2.8.2</span></p>
<p class="version"><i class="icon glyphicon glyphicon-tag"></i>&nbsp;<span class="parsley-version">v2.9.0</span></p>
</div>

<!-- Example row of columns -->
Expand Down
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "parsleyjs",
"version": "2.8.2",
"version": "2.9.0",
"homepage": "http://parsleyjs.org",
"license": "MIT",
"description": "Validate your forms, frontend, without writing a single line of javascript!",
Expand Down

0 comments on commit 7fc5786

Please sign in to comment.