<?xml version="1.0" encoding="utf-8"?>
<RelativeLayout 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:layout_width="match_parent"
    android:layout_height="wrap_content"
    android:background="?attr/contrast_background_color">

    <org.schabi.newpipe.views.NewPipeTextView
        android:id="@+id/playlist_title_view"
        android:layout_width="match_parent"
        android:layout_height="wrap_content"
        android:ellipsize="end"
        android:maxLines="2"
        android:paddingHorizontal="@dimen/video_item_search_padding"
        android:paddingTop="@dimen/video_item_search_padding"
        android:textAppearance="?android:attr/textAppearanceLarge"
        android:textSize="@dimen/playlist_detail_title_text_size"
        tools:text="Mix musics #23 title Lorem ipsum dolor sit amet, consectetur adipiscing elit. Nunc tristique vitae sem vitae blanditLorem ipsumLorem ipsumLorem ipsumLorem ipsumLorem ipsumLorem ipsumLorem ipsum" />

    <RelativeLayout
        android:id="@+id/playlist_meta"
        android:layout_width="match_parent"
        android:layout_height="wrap_content"
        android:layout_below="@+id/playlist_title_view"
        android:paddingHorizontal="@dimen/video_item_search_padding"
        android:paddingTop="6dp">

        <RelativeLayout
            android:id="@+id/uploader_layout"
            android:layout_width="wrap_content"
            android:layout_height="@dimen/playlist_detail_uploader_layout_height"
            android:layout_toStartOf="@+id/playlist_stream_count"
            android:layout_toLeftOf="@+id/playlist_stream_count"
            android:background="?attr/selectableItemBackground"
            android:gravity="left|center_vertical"
            android:visibility="gone"
            tools:ignore="RtlHardcoded"
            tools:visibility="visible">

            <com.google.android.material.imageview.ShapeableImageView
                android:id="@+id/uploader_avatar_view"
                android:layout_width="@dimen/playlist_detail_uploader_image_size"
                android:layout_height="@dimen/playlist_detail_uploader_image_size"
                android:layout_alignParentLeft="true"
                android:layout_centerVertical="true"
                android:padding="0.7dp"
                android:src="@drawable/placeholder_person"
                app:shapeAppearance="@style/CircularImageView"
                app:strokeColor="#ffffff"
                app:strokeWidth="1dp" />

            <org.schabi.newpipe.views.NewPipeTextView
                android:id="@+id/uploader_name"
                android:layout_width="match_parent"
                android:layout_height="match_parent"
                android:layout_toRightOf="@+id/uploader_avatar_view"
                android:ellipsize="end"
                android:gravity="left|center_vertical"
                android:maxLines="1"
                android:paddingHorizontal="6dp"
                android:textSize="@dimen/playlist_detail_subtext_size"
                tools:ignore="RtlHardcoded"
                tools:text="Typical uploader name" />
        </RelativeLayout>

        <org.schabi.newpipe.views.NewPipeTextView
            android:id="@+id/playlist_stream_count"
            android:layout_width="wrap_content"
            android:layout_height="wrap_content"
            android:layout_alignTop="@+id/uploader_layout"
            android:layout_alignBottom="@+id/uploader_layout"
            android:layout_alignParentRight="true"
            android:layout_marginLeft="6dp"
            android:ellipsize="end"
            android:gravity="right|center_vertical"
            android:maxLines="1"
            android:textSize="@dimen/playlist_detail_subtext_size"
            tools:ignore="RtlHardcoded"
            tools:text="234 videos" />
    </RelativeLayout>

    <org.schabi.newpipe.views.NewPipeTextView
        android:id="@+id/playlist_description"
        android:layout_width="match_parent"
        android:layout_height="wrap_content"
        android:layout_below="@id/playlist_meta"
        android:paddingHorizontal="@dimen/video_item_search_padding"
        android:paddingTop="6dp"
        android:maxLines="5"
        tools:text="This is a multiline playlist description. Lorem ipsum dolor sit amet, consectetur adipiscing elit. Nunc tristique vitae sem vitae blandit Lorem ipsum dolor sit amet, consectetur adipiscing elit. Nunc tristique vitae sem vitae blandit. Lorem ipsum dolor sit amet, consectetur adipiscing elit. Nunc tristique vitae sem vitae blandit. Lorem ipsum dolor sit amet, consectetur adipiscing elit. Nunc tristique vitae sem vitae blandit" />

    <org.schabi.newpipe.views.NewPipeTextView
        android:id="@+id/playlist_description_read_more"
        android:layout_width="match_parent"
        android:layout_height="wrap_content"
        android:layout_below="@id/playlist_description"
        android:gravity="end"
        android:paddingHorizontal="@dimen/video_item_search_padding"
        android:paddingTop="6dp"
        android:text="@string/show_more"
        android:layout_marginBottom="6dp"
        android:textColor="?attr/colorPrimary" />

    <LinearLayout
        android:layout_width="match_parent"
        android:layout_height="wrap_content"
        android:layout_below="@id/playlist_description_read_more">

        <include
            android:id="@+id/playlist_control"
            layout="@layout/playlist_control" />
    </LinearLayout>

</RelativeLayout>
