Background
There are certain values which are not accepted and currently it simply seems like the input is broken. The same values are not allowed, but we will display error messages so that the user understands what is happening.
Requirements
- Display errors when:
- the user enters a parameter name already existing in the template (either documented or not)
- the user enters a parameter name already existing in the template (either documented or not) that is unselected
- the user enters the alias of a parameter already existing in the template (can only be a documented param)
- the user enters the name/alias of a deprecated parameter
- the user enters a forbidden character {, =, |, and }.
- Error displayed using OOUI component "FieldLayout with error message"
- Button to add the parameter is disabled
Mocks
Error message text
Param exists: "Cannot add two parameters of the same name."
Alias: "“$input” is an alias of the parameter “$conflicting parameter name” and cannot be added because it would be a duplicate."
Deprecated: "“$input” cannot be added because the parameter has been marked as deprecated."
Forbidden character: ""$inputsymbol" is a forbidden character. Please remove it to add the parameter."