Comment on page
An Alert Container is a basic container with one of the predefined Contexts (success, information, warning or error) to show information with that specific context. These are useful, but not limited, to displaying warning/error messages after validations (for example, validations after submitting a form).
Let's continue with the EMS use case from the last topic, Panel, where we had constructed the Employees Overview page. Let's now try to display a warning alert message within the Panel when the employee has no Role assigned.
This is what we had from the last topic, Panel.
1. Continuing from the above, add a conditional inside the Panel that checks whether the employee's role is empty.
2. Click on the 'Alert' icon in the Template Editor, drag and drop it on the canvas at the place where you would like to insert it.
By default, an Alert of 'warning' context is inserted.
2. Click on the flag icon under 'Icon' in the Properties pane and search for a warning icon.
3. Select an icon, click 'Ok'.
The icon is added to the Alert.
4. Add text to the Alert, either by typing in directly, or using a Label.
5. Save the Template Editor and Preview.