@Suppress("FunctionName") public fun ImageAttachmentFactory(): AttachmentFactory = AttachmentFactory( canHandle = { attachments -> attachments.all { it.isMedia() } }, previewContent = { modifier, attachments, onAttachmentRemoved -> ImageAttachmentPreviewContent(modifier = modifier,attachments = attachments, onAttachmentRemoved = onAttachmentRemoved )},content = @Composable { modifier, state ->ImageAttachmentContent(modifier = modifier.width(ChatTheme.dimens.attachmentsContentImageWidth).wrapContentHeight().heightIn(max = ChatTheme.dimens.attachmentsContentImageMaxHeight),attachmentState = state)},)
An [AttachmentFactory] that validates attachments as images and uses [ImageAttachmentContent] to build the UI for the message.