Improve link preview cards (#1330)
* improve card frame * add placeholder for empty image * improve layout, Pleroma compatibility, show author name as description fallback * reset okhttp logging level * remove unneeded statement
This commit is contained in:
parent
e6d91c1cf3
commit
b825f42c7a
13 changed files with 69 additions and 31 deletions
|
@ -16,13 +16,17 @@
|
|||
package com.keylesspalace.tusky.entity
|
||||
|
||||
import android.os.Parcelable
|
||||
import android.text.Spanned
|
||||
import com.google.gson.annotations.SerializedName
|
||||
import kotlinx.android.parcel.Parcelize
|
||||
import kotlinx.android.parcel.WriteWith
|
||||
|
||||
@Parcelize
|
||||
data class Card(
|
||||
val url: String,
|
||||
val title: String,
|
||||
val description: String,
|
||||
val title: @WriteWith<SpannedParceler>() Spanned,
|
||||
val description: @WriteWith<SpannedParceler>() Spanned,
|
||||
@SerializedName("author_name") val authorName: String,
|
||||
val image: String,
|
||||
val type: String,
|
||||
val width: Int,
|
||||
|
|
|
@ -130,7 +130,7 @@ data class Status(
|
|||
|
||||
data class Application (
|
||||
val name: String,
|
||||
val website: String
|
||||
val website: String?
|
||||
)
|
||||
|
||||
companion object {
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue