Rich Automation Inputs
We have a way to create validations for each parameter and this will
provide security for your template at the form level. Each parameter
could receive any validations following these specifications:
plain textThe types are consist in: text, email, url, number, tel, time, date, select. āāāāāāāāāāāāāāāāāāā¬āāāāāāāāāāāāāāāāāā¬āāāāāāāāāāāāāāāāāāāāāā¬āāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāā ā Attribute ā Types ā Default value ā Desciption ā āāāāāāāāāāāāāāāāāāā¼āāāāāāāāāāāāāāāāāā¼āāāāāāāāāāāāāāāāāāāāāā¼āāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāā¤ ā description ā All ā ā String. Text that appears inside ā ā ā ā ā of the helper tooltip. ā āāāāāāāāāāāāāāāāāāā¼āāāāāāāāāāāāāāāāāā¼āāāāāāāāāāāāāāāāāāāāāā¼āāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāā¤ ā placeholder ā All ā "Define a value for ā String. Text that appears in the ā | | | {{parameter_name}}" ā form control when it has no value ā ā ā ā ā set. ā āāāāāāāāāāāāāāāāāāā¼āāāāāāāāāāāāāāāāāā¼āāāāāāāāāāāāāāāāāāāāāā¼āāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāā¤ ā required ā All ā true ā Boolean. A value is required or ā ā ā ā ā must be check for the form to be ā ā ā ā ā submittable. ā āāāāāāāāāāāāāāāāāāā¼āāāāāāāāāāāāāāāāāā¼āāāāāāāāāāāāāāāāāāāāāā¼āāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāā¤ ā pattern ā text, url, tel, ā ā JavaScript regular expression. ā ā ā email ā ā Pattern the value must match to be ā ā ā ā ā valid. ā āāāāāāāāāāāāāāāāāāā¼āāāāāāāāāāāāāāāāāā¼āāāāāāāāāāāāāāāāāāāāāā¼āāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāā¤ ā maxlength ā text, url, tel, ā ā Maximum length (number of ā ā ā email ā ā characters) of value. ā āāāāāāāāāāāāāāāāāāā¼āāāāāāāāāāāāāāāāāā¼āāāāāāāāāāāāāāāāāāāāāā¼āāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāā¤ ā minlength ā text, url, tel, ā ā Minimum length (number of ā ā ā email ā ā characters) of value. ā āāāāāāāāāāāāāāāāāāā¼āāāāāāāāāāāāāāāāāā¼āāāāāāāāāāāāāāāāāāāāāā¼āāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāā¤ ā max ā number, time, ā ā Number. Maximum value. ā ā ā date ā ā ā āāāāāāāāāāāāāāāāāāā¼āāāāāāāāāāāāāāāāāā¼āāāāāāāāāāāāāāāāāāāāāā¼āāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāā¤ ā min ā number, time, ā ā Number. Minimum value. ā ā ā date ā ā ā āāāāāāāāāāāāāāāāāāā¼āāāāāāāāāāāāāāāāāā¼āāāāāāāāāāāāāāāāāāāāāā¼āāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāā¤ ā step ā number, time, ā ā Incremental values that are valid. ā ā ā date ā ā ā āāāāāāāāāāāāāāāāāāā¼āāāāāāāāāāāāāāāāāā¼āāāāāāāāāāāāāāāāāāāāāā¼āāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāā¤ ā options ā select ā ā Array of strings. Options that ā ā ā ā ā appears in the select HTML element. ā āāāāāāāāāāāāāāāāāāā“āāāāāāāāāāāāāāāāāā“āāāāāāāāāāāāāāāāāāāāāā“āāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāāā
:::tip pro-tip We are using parts of the same types and atributes
from the HTML element input, you can find more
informations here. :::
Creating the file for validation
These validations are stored in a JSON file with the same name of
their template file and with the .config extension instead.
For other-template.sql
Use other-template.config.json
You can use as example this file:
json{ "name": { "type": "text", "description": "this is a text without pattern" }, "shorter_name": { "type": "text", "description": "this is a text with patterns", "maxlength": 10, "minlength": 2 }, "email": { "type": "email", "description": "this is a email with pattern" }, "github_link": { "type": "url", "description": "this is a url without pattern" }, "age": { "type": "number", "description": "this is a number without pattern" }, "school_grade": { "type": "number", "description": "this is a number float with range", "min": 0, "max": 10, "step": 0.1 }, "less_than_ten": { "type": "number", "description": "this is a number with range", "min": 0, "max": 9 }, "telephone": { "type": "tel", "description": "this is a tel with pattern", "placeholder": "999-999-9990", "pattern": "[0-9]{3}-[0-9]{3}-[0-9]{4}" }, "lunch_time": { "type": "time", "description": "this is a time without pattern" }, "birthday": { "type": "date", "description": "this is a date without range" }, "best_day_last_year": { "type": "date", "description": "this is a date with patterns", "min": "2021-01-01", "max": "2021-12-31" }, "which_your_favourite_band": { "type": "select", "description": "this is a select options", "options": ["backstreet boys", "the cure", "maroon 5", "the cranberries"] }}