mirror of
https://github.com/signalapp/Signal-Android.git
synced 2026-02-22 18:55:12 +00:00
Add description to story link previews.
This commit is contained in:
committed by
Cody Henthorne
parent
dabea5169b
commit
6054285ddb
@@ -34,6 +34,7 @@ class StoryLinkPreviewView @JvmOverloads constructor(
|
||||
private val image: OutlinedThumbnailView = findViewById(R.id.link_preview_image)
|
||||
private val title: TextView = findViewById(R.id.link_preview_title)
|
||||
private val url: TextView = findViewById(R.id.link_preview_url)
|
||||
private val description: TextView = findViewById(R.id.link_preview_description)
|
||||
|
||||
fun bind(linkPreview: LinkPreview?, hiddenVisibility: Int = View.INVISIBLE): ListenableFuture<Boolean> {
|
||||
var listenableFuture: ListenableFuture<Boolean>? = null
|
||||
@@ -54,6 +55,8 @@ class StoryLinkPreviewView @JvmOverloads constructor(
|
||||
}
|
||||
|
||||
title.text = linkPreview.title
|
||||
description.text = linkPreview.description
|
||||
description.visible = linkPreview.description.isNotEmpty()
|
||||
|
||||
formatUrl(linkPreview)
|
||||
} else {
|
||||
|
||||
Reference in New Issue
Block a user