LinkAttachmentContent

fun LinkAttachmentContent(state: AttachmentState, modifier: Modifier = Modifier, onItemClick: (LinkAttachmentClickData) -> Unit = { onLinkAttachmentContentClick(it.context, it.url) })

Builds a link attachment message, which shows the link image preview, the title of the link as well as its description.

When clicking it, we open the preview link.

Parameters

state
  • The state of the attachment, holding the root modifier, the message and the onLongItemClick handler.

modifier

Modifier for styling.

onItemClick

Lambda called when an item gets clicked.