Input Types

In Alpaco you can have many different input types, separated or grouped together to form sets of settings.

These are the current allowed Input Types:

  • ​Text String

    - A single line of text with no formatting options.

  • Textarea

    - Multi-line text input with simple formatting options.

  • ​Select

    - Select/Dropdown of predefined values.

  • ​Boolean

    - On/off toggle/switch.

  • ​Image

    - Image upload or URL input.

  • ​Color picker

    - Color picking wheel w/ eyedrop tool.

  • ​Code

    - Ability to insert raw code.

How to get started?

Simply open up your Base or Block, depending on where you want your input, navigate to the Right panel, click the button called "Add input" and select your input type from the dropdown. Just like with Input Groups, the Name and Key needs to be inserted and given a proper name.

Notice the tag below the name, that's generated when you give your input a Key. Putting your cursor in the center panel and clicking the tag in the right panel will automatically insert the tag with correctly formatted syntax in the center panel for you.

Validate Inputs

Validating inputs and give warnings is an essential part of handing over your template to others users. By using validation rules you can add clarity to what the intended use for an input should be. All Input types have a dropdown option in the Template Editor where multiple validation rules can be added and they all come with an option to make a Custom Error Message per validation rule, for each input field.

In the image we see two Validations types, Required Field and Maximum Length set to 25 characters, has been added to a Text String

If an input is not validated in the Email Editor, the user will be informed of the error, taken to where the error is, have the error highlighted and prevented from saving the email before adhering to the specific input requirement.

Here we see a validation rule trigger, showcasing the error message, highlighting and prevention of saving
Validation types
Description
Applicable in Input type

Required field

This field must be blank

Must Not Be Default

This field must not be indentical to the default content

Maximum Length

This field may contain X amount of characters

Minimum Length

This field must be at least X amount of characters

Regex

Define any form of regular expression you want. Be that URL, numbers, wordings ect.

Last updated