<?xml version="1.0" encoding="utf-8"?>
<LinearLayout
    xmlns:android="http://schemas.android.com/apk/res/android"
    xmlns:app="http://schemas.android.com/apk/res-auto"
    android:layout_width="match_parent"
    android:layout_height="wrap_content"
    xmlns:tools="http://schemas.android.com/tools"
    android:gravity="center_vertical"
    android:orientation="horizontal">

    <View
        android:id="@+id/accentView"
        android:layout_width="@dimen/accent_line_thickness"
        android:layout_height="match_parent"
        android:background="@color/accent" />

    <org.thoughtcrime.securesms.components.ProfilePictureView
        android:id="@+id/profilePictureView"
        android:layout_width="@dimen/medium_profile_picture_size"
        android:layout_height="@dimen/medium_profile_picture_size"
        android:layout_marginTop="@dimen/medium_spacing"
        android:layout_marginStart="@dimen/medium_spacing"
        android:layout_marginBottom="@dimen/medium_spacing" />

    <FrameLayout
        android:layout_width="match_parent"
        android:layout_height="match_parent">

        <LinearLayout
            android:layout_width="match_parent"
            android:layout_height="wrap_content"
            android:layout_marginStart="@dimen/medium_spacing"
            android:layout_marginEnd="@dimen/medium_spacing"
            android:layout_gravity="center_vertical"
            android:orientation="vertical">

            <LinearLayout
                android:layout_width="match_parent"
                android:layout_height="wrap_content"
                android:orientation="horizontal"
                android:gravity="center_vertical">

                <LinearLayout
                    android:layout_width="0dp"
                    android:layout_height="wrap_content"
                    android:layout_weight="1"
                    android:orientation="horizontal"
                    android:gravity="center_vertical">

                    <TextView
                        android:id="@+id/conversationViewDisplayNameTextView"
                        android:layout_width="wrap_content"
                        android:layout_height="wrap_content"
                        android:drawablePadding="4dp"
                        android:maxLines="1"
                        android:ellipsize="end"
                        android:textAlignment="viewStart"
                        android:textSize="@dimen/medium_font_size"
                        android:textStyle="bold"
                        android:textColor="@color/text"
                        tools:drawableRight="@drawable/ic_pin"
                        tools:text="I'm a very long display name. What are you going to do about it?" />

                    <RelativeLayout
                        android:id="@+id/unreadCountIndicator"
                        android:layout_width="20dp"
                        android:layout_height="20dp"
                        android:layout_marginStart="4dp"
                        android:background="@drawable/circle_tintable"
                        android:backgroundTint="@color/conversation_unread_count_indicator_background">

                        <TextView
                            android:id="@+id/unreadCountTextView"
                            android:layout_width="wrap_content"
                            android:layout_height="wrap_content"
                            android:layout_centerInParent="true"
                            android:textSize="@dimen/very_small_font_size"
                            android:textColor="@color/text"
                            android:textStyle="bold"
                            android:text="8" />

                    </RelativeLayout>

                </LinearLayout>

                <TextView
                    android:id="@+id/timestampTextView"
                    android:layout_width="wrap_content"
                    android:layout_height="wrap_content"
                    android:layout_marginStart="@dimen/medium_spacing"
                    android:maxLines="1"
                    android:ellipsize="end"
                    android:textSize="@dimen/small_font_size"
                    android:textColor="@color/text"
                    android:alpha="0.4"
                    tools:text="9:41 AM" />

            </LinearLayout>

            <LinearLayout
                android:layout_width="match_parent"
                android:layout_height="wrap_content"
                android:orientation="horizontal"
                android:gravity="center_vertical">

                <ImageView
                    android:id="@+id/muteIndicatorImageView"
                    android:layout_width="18dp"
                    android:layout_height="18dp"
                    android:layout_gravity="center"
                    android:src="@drawable/ic_outline_notifications_off_24"
                    android:layout_marginTop="1dp"
                    android:layout_marginEnd="6dp" />

                <RelativeLayout
                    android:layout_weight="1"
                    android:layout_width="0dp"
                    android:layout_height="wrap_content">

                    <TextView
                        android:id="@+id/snippetTextView"
                        android:layout_width="wrap_content"
                        android:layout_height="wrap_content"
                        android:maxLines="1"
                        android:ellipsize="end"
                        android:textSize="@dimen/medium_font_size"
                        android:textColor="@color/text"
                        tools:text="Sorry, gotta go fight crime again" />

                    <org.thoughtcrime.securesms.conversation.v2.components.TypingIndicatorView
                        android:id="@+id/typingIndicatorView"
                        android:layout_width="wrap_content"
                        android:layout_height="wrap_content"
                        android:layout_marginTop="4dp"
                        app:typingIndicator_tint="@color/text" />

                </RelativeLayout>

                <ImageView
                    android:id="@+id/statusIndicatorImageView"
                    android:layout_width="@dimen/conversation_view_status_indicator_size"
                    android:layout_height="@dimen/conversation_view_status_indicator_size"
                    android:layout_marginStart="@dimen/medium_spacing" />

            </LinearLayout>

        </LinearLayout>

    </FrameLayout>

</LinearLayout>