Join GitHub today
GitHub is home to over 31 million developers working together to host and review code, manage projects, and build software together.Sign up
Add a validation framework #179
Add a validation framework for input of parameters of the blocks on double clicking them. Any input in the popup will be validated. On validation failure, it will highlight that block and ask the user to update it.
Design a simple input box with multiple fields and a submit + cancel buttons. For each input field, add validation types. If any validation passes, treat as success and go to next field. If validation passes for all fields, submit box should close. If validation fails, do not close the submit box and highlight the input field and show error message just below (or above) it.
You may also validate all input fields and show error message for all invalid fields (optional).
On changing the value, the error message must be cleared.
Here are some sample validation types:
It should be easy to add more types later. This can also be implemented using a third-party free/libre and open source framework (this should be clearly mentioned in the submission).
e.g. A field can have these validation types: "empty,integer,vectorinteger,variable".