# UserInfoButton

The user information button.

# Properties

# string type

The button type.

Valid values of type

Value Description Minimum Version
text A button that can be configured with background color and text
image A button that can only be configured with background image. The background image is stretched to fit the button.

# string text

The text on the button. It is valid only when type is text.

# string image

The background image of the button. It is valid only when type is image.

# Object style

The button style.

Property Type Description
left number The x-coordinate of the top-left corner
top number The y-coordinate of the top-left corner
width number Width
height number Height
backgroundColor string Background color
borderColor string The color of the border
borderWidth number The width of the border
borderRadius number The radius of the rounded corner on the border
textAlign string Text alignment method
fontSize number Font size
lineHeight number The line height of the text

Valid values of style.textAlign

Value Description Minimum Version
left Left
center Center
right Right

# Methods

# UserInfoButton.show()

Shows the user information button.

# UserInfoButton.hide()

Hides the user information button.

# UserInfoButton.destroy()

Deletes the user information button.

# UserInfoButton.onTap(function callback)

Listens on the user information button tapping event.

# UserInfoButton.offTap(function callback)

Un-listens on the user information button tapping event.