Avatar
The Avatar component is perfect for adding a slot to insert a profile picture within your application. Designed exclusively for this purpose, it offers a set of customizations that can help you specialize the looks.
Note: The profile picture will be displayed as an icon.
Avatar Properties
Avatar Property | Description |
---|---|
Dimension | Set the size of the image |
URL | Link to the image source |
API Methods
setVisibility
Sets the Visibility flag for this component.
- Method
- Usage
setVisibility(visible: boolean): void
// Setting the visibility to "true" makes the element visible
a8forms.Avatar("avatarId").setVisibility(true)
// Setting the visibility to "false" makes the element invisible
a8forms.Avatar("avatarId").setVisibility(false)
setVisibilityCondition
Sets the visibility condition for this component.
- Method
- Usage
setVisibilityCondition(condition: string): void
// Sets a condition for changing the element's visibility status.
a8forms.Avatar("avatarId").setVisibilityCondition("1 === 1")
Event Handler
Event handlers allow you to set triggers for various actions based on the fired events. They are as follows:
onClick
onClick
- Sets the actions to be triggered when the component is clicked.