MessageAttributes

Attribute names of <vaadin-message>, for use with setAttribute.

Properties

Link copied to clipboard
const val theme: String

The theme variants to apply to the component.

Link copied to clipboard
const val time: String

Time of sending the message. It is rendered as-is to the part='time' slot, so the formatting is up to you.

Link copied to clipboard
const val userAbbr: String

The abbreviation of the user. The abbreviation will be passed on to avatar of the message. If the user does not have an avatar picture set with userImg, userAbbr will be shown in the avatar. Example: message.userAbbr = "JJ";

Link copied to clipboard

A color index to be used to render the color of the avatar. Also sets --vaadin-message-user-color custom CSS property.

Link copied to clipboard
const val userImg: String

An URL for a user image. The image will be used in the avatar component to show who has sent the message. Example: message.userImg = "/static/img/avatar.jpg";

Link copied to clipboard
const val userName: String

The name of the user posting the message. It will be placed in the name part to indicate who has sent the message. It is also used as a tooltip for the avatar. Example: message.userName = "Jessica Jacobs";