<?xml version="1.0" encoding="utf-8"?>
<!--
  ~ Nextcloud Maps Geofavorites for Android
  ~
  ~ This program is free software: you can redistribute it and/or modify
  ~ it under the terms of the GNU General Public License as published by
  ~ the Free Software Foundation, either version 3 of the License, or
  ~ (at your option) any later version.
  ~
  ~ This program is distributed in the hope that it will be useful,
  ~ but WITHOUT ANY WARRANTY; without even the implied warranty of
  ~ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
  ~ GNU General Public License for more details.
  ~
  ~ You should have received a copy of the GNU General Public License
  ~ along with this program.  If not, see <http://www.gnu.org/licenses/>.
  -->

<LinearLayout
    xmlns:android="http://schemas.android.com/apk/res/android"
    xmlns:tools="http://schemas.android.com/tools"
    android:orientation="horizontal"
    android:layout_width="match_parent"
    android:layout_height="90dp"
    android:gravity="center_vertical"
    android:clickable="true"
    android:focusable="true">

    <TextView
        android:id="@+id/tv_category"
        android:layout_width="64dp"
        android:layout_height="64dp"
        android:layout_marginStart="4dp"
        android:layout_weight="0"
        android:background="@drawable/category_listitem_background"
        android:gravity="center"
        android:textSize="28dp"
        android:textAllCaps="true"
        android:textColor="@color/white"/>

    <LinearLayout
        android:orientation="vertical"
        android:layout_width="match_parent"
        android:layout_height="wrap_content"
        android:layout_marginStart="8dp"
        android:layout_marginEnd="8dp"
        android:layout_weight="1">

        <TextView
            android:id="@+id/title"
            android:layout_width="match_parent"
            android:layout_height="wrap_content"
            android:singleLine="true"
            android:maxLines="1"
            android:lines="1"
            android:ellipsize="middle"
            android:textColor="@color/text_color"
            android:textSize="@dimen/two_line_primary_text_size"
            tools:text="@tools:sample/lorem/random">
        </TextView>

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

            <TextView
                android:id="@+id/content"
                android:layout_width="0dp"
                android:layout_height="wrap_content"
                android:layout_weight="1"
                android:layout_marginEnd="10dp"
                android:textColor="@color/secondary_text_color"
                android:textSize="@dimen/two_line_secondary_text_size"
                android:maxLines="1"
                android:lines="1"
                android:ellipsize="end"
                android:gravity="center_vertical"
                tools:text="@tools:sample/lorem/random">
            </TextView>

            <TextView
                android:id="@+id/date"
                android:layout_width="wrap_content"
                android:layout_height="wrap_content"
                android:layout_weight="0"
                android:textColor="@color/secondary_text_color"
                android:textSize="@dimen/two_line_secondary_text_size"
                android:maxLines="1"
                android:lines="1"
                android:gravity="center_vertical"
                tools:text="00/00/0000">
            </TextView>

        </LinearLayout>

    </LinearLayout>

    <ImageView
        android:id="@+id/geofav_nav_bt"
        android:layout_width="wrap_content"
        android:layout_height="match_parent"
        android:layout_weight="0"
        android:padding="8dp"
        android:src="@drawable/ic_nav"
        android:tint="@color/secondary_text_color" /> <!-- TODO: app:tint is not working -->

    <ImageView
        android:id="@+id/geofav_context_menu_bt"
        android:layout_width="wrap_content"
        android:layout_height="match_parent"
        android:layout_weight="0"
        android:padding="8dp"
        android:src="@drawable/ic_more"
        android:tint="@color/secondary_text_color" /> <!-- TODO: app:tint is not working -->

</LinearLayout>