Comparing version 0.0.5 to 0.0.6
@@ -14,3 +14,3 @@ 'use strict'; | ||
var n = e.schema.length; | ||
out += 'should NOT have more than ' + (n) + ' item'; | ||
out += 'should not have more than ' + (n) + ' item'; | ||
if (n != 1) { | ||
@@ -21,3 +21,3 @@ out += 's'; | ||
case 'additionalProperties': | ||
out = 'should NOT have additional properties'; | ||
out = 'should not have additional properties'; | ||
break; | ||
@@ -44,9 +44,6 @@ case 'anyOf': | ||
break; | ||
case 'maximum': | ||
out = 'should be ' + (e.params.condition); | ||
break; | ||
case 'maxItems': | ||
out = ''; | ||
var n = e.schema; | ||
out += 'should NOT have more than ' + (n) + ' item'; | ||
out += 'should not have more than ' + (n) + ' item'; | ||
if (n != 1) { | ||
@@ -59,3 +56,3 @@ out += 's'; | ||
var n = e.schema; | ||
out += 'should NOT be longer than ' + (n) + ' character'; | ||
out += 'should not be longer than ' + (n) + ' character'; | ||
if (n != 1) { | ||
@@ -68,3 +65,3 @@ out += 's'; | ||
var n = e.schema; | ||
out += 'should NOT have more than ' + (n) + ' propert'; | ||
out += 'should not have more than ' + (n) + ' propert'; | ||
if (n == 1) { | ||
@@ -76,3 +73,3 @@ out += 'y'; | ||
break; | ||
case 'minimum': | ||
case 'maximum': | ||
out = 'should be ' + (e.params.condition); | ||
@@ -83,3 +80,3 @@ break; | ||
var n = e.schema; | ||
out += 'should NOT have less than ' + (n) + ' item'; | ||
out += 'should not have less than ' + (n) + ' item'; | ||
if (n != 1) { | ||
@@ -100,3 +97,3 @@ out += 's'; | ||
var n = e.schema; | ||
out += 'should NOT have less than ' + (n) + ' propert'; | ||
out += 'should not have less than ' + (n) + ' propert'; | ||
if (n == 1) { | ||
@@ -108,2 +105,5 @@ out += 'y'; | ||
break; | ||
case 'minimum': | ||
out = 'should be ' + (e.params.condition); | ||
break; | ||
case 'multipleOf': | ||
@@ -113,3 +113,3 @@ out = 'should be multiple of ' + (e.schema); | ||
case 'not': | ||
out = 'should NOT be valid according to schema in "not"'; | ||
out = 'should not be valid according to schema in "not"'; | ||
break; | ||
@@ -129,3 +129,3 @@ case 'oneOf': | ||
case 'uniqueItems': | ||
out = 'should NOT have duplicate items (items ## ' + (e.params.j) + ' and ' + (e.params.i) + ' are identical)'; | ||
out = 'should not have duplicate items (items ## ' + (e.params.j) + ' and ' + (e.params.i) + ' are identical)'; | ||
break; | ||
@@ -132,0 +132,0 @@ } |
@@ -30,3 +30,3 @@ 'use strict'; | ||
out += ' a következő tulajdonsága'; | ||
if (n == 1) {} else { | ||
if (n != 1) { | ||
out += 'i'; | ||
@@ -42,5 +42,2 @@ } | ||
break; | ||
case 'maximum': | ||
out = 'kell legyen ' + (e.params.condition); | ||
break; | ||
case 'maxItems': | ||
@@ -61,3 +58,3 @@ out = ''; | ||
break; | ||
case 'minimum': | ||
case 'maximum': | ||
out = 'kell legyen ' + (e.params.condition); | ||
@@ -80,2 +77,5 @@ break; | ||
break; | ||
case 'minimum': | ||
out = 'kell legyen ' + (e.params.condition); | ||
break; | ||
case 'multipleOf': | ||
@@ -82,0 +82,0 @@ out = 'a többszöröse kell legyen a következő számnak: ' + (e.schema); |
'use strict'; | ||
module.exports = { | ||
de: require('./de'), | ||
en: require('./en'), | ||
@@ -5,0 +6,0 @@ hu: require('./hu'), |
@@ -44,5 +44,2 @@ 'use strict'; | ||
break; | ||
case 'maximum': | ||
out = 'powinien być ' + (e.params.condition); | ||
break; | ||
case 'maxItems': | ||
@@ -76,3 +73,3 @@ out = ''; | ||
break; | ||
case 'minimum': | ||
case 'maximum': | ||
out = 'powinien być ' + (e.params.condition); | ||
@@ -108,2 +105,5 @@ break; | ||
break; | ||
case 'minimum': | ||
out = 'powinien być ' + (e.params.condition); | ||
break; | ||
case 'multipleOf': | ||
@@ -110,0 +110,0 @@ out = 'powinien być wielokrotnością ' + (e.schema); |
@@ -14,3 +14,3 @@ 'use strict'; | ||
var n = e.schema.length; | ||
out += 'должен иметь НЕ более, чем ' + (n) + ' элемент'; | ||
out += 'должен иметь не более, чем ' + (n) + ' элемент'; | ||
if (n >= 2 && n <= 4) { | ||
@@ -45,9 +45,6 @@ out += 'а'; | ||
break; | ||
case 'maximum': | ||
out = 'должен быть ' + (e.params.condition); | ||
break; | ||
case 'maxItems': | ||
out = ''; | ||
var n = e.schema; | ||
out += 'должен иметь НЕ более, чем ' + (n) + ' элемент'; | ||
out += 'должен иметь не более, чем ' + (n) + ' элемент'; | ||
if (n >= 2 && n <= 4) { | ||
@@ -62,3 +59,3 @@ out += 'а'; | ||
var n = e.schema; | ||
out += 'должен быть НЕ длиннее, чем ' + (n) + ' символ'; | ||
out += 'должен быть не длиннее, чем ' + (n) + ' символ'; | ||
if (n >= 2 && n <= 4) { | ||
@@ -73,3 +70,3 @@ out += 'а'; | ||
var n = e.schema; | ||
out += 'должен иметь НЕ более, чем ' + (n) + ' пол'; | ||
out += 'должен иметь не более, чем ' + (n) + ' пол'; | ||
if (n == 1) { | ||
@@ -83,3 +80,3 @@ out += 'е'; | ||
break; | ||
case 'minimum': | ||
case 'maximum': | ||
out = 'должен быть ' + (e.params.condition); | ||
@@ -90,3 +87,3 @@ break; | ||
var n = e.schema; | ||
out += 'должен иметь НЕ менее, чем ' + (n) + ' элемент'; | ||
out += 'должен иметь не менее, чем ' + (n) + ' элемент'; | ||
if (n >= 2 && n <= 4) { | ||
@@ -101,3 +98,3 @@ out += 'а'; | ||
var n = e.schema; | ||
out += 'должен быть НЕ короче, чем ' + (n) + ' символ'; | ||
out += 'должен быть не короче, чем ' + (n) + ' символ'; | ||
if (n >= 2 && n <= 4) { | ||
@@ -112,3 +109,3 @@ out += 'а'; | ||
var n = e.schema; | ||
out += 'должен иметь НЕ менее, чем ' + (n) + ' пол'; | ||
out += 'должен иметь не менее, чем ' + (n) + ' пол'; | ||
if (n == 1) { | ||
@@ -122,2 +119,5 @@ out += 'е'; | ||
break; | ||
case 'minimum': | ||
out = 'должен быть ' + (e.params.condition); | ||
break; | ||
case 'multipleOf': | ||
@@ -127,3 +127,3 @@ out = 'должен быть кратным ' + (e.schema); | ||
case 'not': | ||
out = 'должен НЕ соответствовать схеме в "not"'; | ||
out = 'должен не соответствовать схеме в "not"'; | ||
break; | ||
@@ -130,0 +130,0 @@ case 'oneOf': |
{ | ||
"name": "ajv-i18n", | ||
"version": "0.0.5", | ||
"version": "0.0.6", | ||
"description": "Internationalised error messages for ajv JSON-Schema validator", | ||
@@ -5,0 +5,0 @@ "main": "localize/index.js", |
# ajv-i18n | ||
Internationalised error messages for [Ajv](https://github.com/epoberezkin/ajv) - currently the fastest JSON-Schema validator | ||
[![Build Status](https://travis-ci.org/epoberezkin/ajv-i18n.svg?branch=master)](https://travis-ci.org/epoberezkin/ajv-i18n) | ||
[![npm version](https://badge.fury.io/js/ajv-i18n.svg)](http://badge.fury.io/js/ajv-i18n) | ||
@@ -9,3 +10,3 @@ | ||
At the moment these locales are supported: `en`, `hu`, `pl` and `ru`. | ||
At the moment these locales are supported: `de`, `en`, `hu`, `pl` and `ru`. | ||
@@ -12,0 +13,0 @@ Please contribute those that you need to use. |
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
23689
11
618
80