element-android/vector/src/main/res/layout/item_thread.xml

111 lines
4.8 KiB
XML
Raw Normal View History

<?xml version="1.0" encoding="utf-8"?>
<androidx.constraintlayout.widget.ConstraintLayout xmlns:android="http://schemas.android.com/apk/res/android"
xmlns:app="http://schemas.android.com/apk/res-auto"
xmlns:tools="http://schemas.android.com/tools"
android:id="@+id/threadSummaryRootConstraintLayout"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:background="?android:colorBackground"
android:clickable="true"
android:focusable="true"
android:foreground="?attr/selectableItemBackground"
android:paddingStart="12dp"
android:paddingTop="12dp"
android:paddingEnd="0dp">
<ImageView
android:id="@+id/threadSummaryAvatarImageView"
android:layout_width="40dp"
android:layout_height="40dp"
android:contentDescription="@string/avatar"
app:layout_constraintStart_toStartOf="parent"
app:layout_constraintTop_toTopOf="parent"
tools:src="@sample/user_round_avatars" />
<TextView
android:id="@+id/threadSummaryTitleTextView"
style="@style/Widget.Vector.TextView.Body.Medium"
android:layout_width="0dp"
android:layout_height="wrap_content"
android:layout_marginStart="8dp"
android:layout_marginEnd="8dp"
android:ellipsize="end"
android:maxLines="1"
android:textColor="@color/element_name_04"
android:textStyle="bold"
app:layout_constraintEnd_toStartOf="@id/threadSummaryDateTextView"
app:layout_constraintStart_toEndOf="@id/threadSummaryAvatarImageView"
app:layout_constraintTop_toTopOf="parent"
tools:text="Aris Kots" />
<TextView
android:id="@+id/threadSummaryDateTextView"
style="@style/Widget.Vector.TextView.Caption"
android:layout_width="0dp"
android:layout_height="wrap_content"
android:layout_marginStart="8dp"
android:layout_marginEnd="28dp"
android:gravity="end"
android:maxLines="1"
android:textColor="?vctr_content_secondary"
app:layout_constraintBottom_toBottomOf="@id/threadSummaryTitleTextView"
app:layout_constraintEnd_toEndOf="parent"
app:layout_constraintTop_toTopOf="@id/threadSummaryTitleTextView"
tools:text="10 minutes" />
<ImageView
android:id="@+id/threadSummaryUnreadImageView"
android:layout_width="8dp"
android:layout_height="8dp"
android:src="@drawable/notification_badge"
android:visibility="gone"
app:layout_constraintBottom_toBottomOf="@id/threadSummaryDateTextView"
app:layout_constraintEnd_toEndOf="parent"
app:layout_constraintStart_toEndOf="@id/threadSummaryDateTextView"
app:layout_constraintTop_toTopOf="@id/threadSummaryDateTextView"
app:tint="@color/palette_gray_200"
tools:ignore="ContentDescription"
tools:visibility="visible" />
<TextView
android:id="@+id/threadSummaryRootMessageTextView"
style="@style/Widget.Vector.TextView.Body"
android:layout_width="0dp"
android:layout_height="wrap_content"
android:layout_marginTop="3dp"
android:layout_marginEnd="25dp"
android:ellipsize="end"
android:maxLines="2"
android:textColor="?vctr_content_primary"
app:layout_constraintEnd_toEndOf="parent"
app:layout_constraintStart_toStartOf="@id/threadSummaryTitleTextView"
app:layout_constraintTop_toBottomOf="@id/threadSummaryTitleTextView"
tools:text="Its really encouraging to feel like you are a part of something greater than yourself. I Its really encouraging to feel like you are a part of something greater than yourself. I " />
<androidx.constraintlayout.widget.ConstraintLayout
android:id="@+id/threadSummaryConstraintLayout"
android:layout_width="0dp"
android:layout_height="wrap_content"
android:layout_marginEnd="25dp"
android:contentDescription="@string/room_threads_filter"
android:maxWidth="496dp"
android:minWidth="144dp"
android:paddingTop="10dp"
android:paddingBottom="12dp"
app:layout_constraintEnd_toEndOf="parent"
app:layout_constraintStart_toStartOf="@id/threadSummaryTitleTextView"
app:layout_constraintTop_toBottomOf="@id/threadSummaryRootMessageTextView"
tools:visibility="visible">
<include layout="@layout/view_thread_room_summary" />
</androidx.constraintlayout.widget.ConstraintLayout>
<View
android:layout_width="0dp"
android:layout_height="1dp"
android:background="?vctr_content_quinary"
app:layout_constraintEnd_toEndOf="parent"
app:layout_constraintStart_toStartOf="@id/threadSummaryConstraintLayout"
app:layout_constraintTop_toBottomOf="@id/threadSummaryConstraintLayout" />
</androidx.constraintlayout.widget.ConstraintLayout>