CommunityConfiguration is built on top of JSON schemas, reusing the basic JSON datatypes, such as number (or integer). In certain cases, it only makes sense to use positive (non-negative) numbers/integers. In JSONSchema, this can be set using the minimum / maximum validation constraints. However, those constraints are not yet respected by CommunityConfiguration. Let's add the support for them, as it would be useful for certain fields
GrowthExperiments, such as Maximum number of links to show per task.
Acceptance Criteria
- Representation of JSONSchema in CommunityConfiguration allows users to set minimum/maximum value for numbers/integers
Original description
As of now, no numeric fields do not complain when a negative number is added. For example, at https://es.wikipedia.beta.wmflabs.org/wiki/Especial:CommunityConfiguration/GrowthSuggestedEdits, it is completely possible to configure a negative number under Maximum number of links to show per task:
Using a negative number in this place does not make any sense at all, but it's currently allowed.