Tag
Introduction
The tag component is a basic Mobi component used for marking and categorization.
Configuration items
Category |
Configuration |
Example |
Description |
Content |
Tag name |
|
The text content of the tag. |
Icon |
|
The icon that precedes the tag. |
|
Interaction |
Hide |
|
Hides the component. For more information, see Common properties. |
Keep layout when hidden |
|
Keeps the layout space when the component is hidden. For more information, see Common properties. |
|
Selectable |
|
Tags can be selected. |
|
Selected by default |
|
This option is selected by default. |
|
Style |
Margin |
|
The outer margin. For more information, see Common properties. |
Layout |
|
The position of the tag in the container. |
|
Theme |
|
The theme color of the tag. Options include the following: Success, Processing, Error, Warning, Default, Magenta, Red, Volcano, Orange, Gold, Lime, Green, Cyan, Blue, Geek Blue, and Purple. |
|
Show border |
|
Specifies whether to show the border. |
|
Customize the subject? |
|
Specifies whether to use a custom theme. |
|
Custom theme color |
|
The custom theme color. |
|
CSS style |
Font size |
|
The font size of the tag text. |
Content color |
|
The color of the tag text. |
|
Border radius |
|
The border radius. For more information, see Common properties. |
|
Border |
|
The border. For more information, see Common properties. |
|
Top border |
|
The top border. For more information, see Common properties. |
|
Right border |
|
The right border. For more information, see Common properties. |
|
Bottom border |
|
The bottom border. For more information, see Common properties. |
|
Left border |
|
The left border. For more information, see Common properties. |
Properties and methods
Name |
Type |
Example |
Description |
name |
string |
|
The current name of the tag. |
theme |
string |
|
Read-only. The current theme of the tag. |
checked |
boolean |
|
The selected state. |
setName |
func |
|
Sets the current name of the tag. |
setChecked |
func |
|
Sets the selected state. |
Event callbacks
Configuration |
Description |
|
The callback that is triggered when the selected state changes. |




















