Small fixes in CustomGenerator; artworkmap is now a json-preset

This commit is contained in:
Pieter Vander Vennet 2020-08-25 02:12:26 +02:00
parent c8b2dab669
commit 1cdf2ee9bc
9 changed files with 224 additions and 150 deletions

View file

@ -13,6 +13,7 @@ export class ValidatedTextField {
"$": (str) => true,
"string": (str) => true,
"date": (str) => true, // TODO validate and add a date picker
"wikidata": (str) => true, // TODO validate wikidata IDS
"int": (str) => {str = ""+str; return str !== undefined && str.indexOf(".") < 0 && !isNaN(Number(str))},
"nat": (str) => {str = ""+str; return str !== undefined && str.indexOf(".") < 0 && !isNaN(Number(str)) && Number(str) > 0},
"float": (str) => !isNaN(Number(str)),