<?xml version="1.0" encoding="utf-8"?>
<com.habitrpg.android.habitica.ui.MaxHeightLinearLayout 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="match_parent"


    android:orientation="vertical"
    app:maxHeightMultiplier="0.7">

    <!-- margins can't be at the first LinearLayout, it has to be the inner one -->

    <LinearLayout
        android:layout_width="match_parent"
        android:layout_height="match_parent"
        android:layout_marginEnd="@dimen/dialog_marginLeftRight"
        android:layout_marginLeft="@dimen/dialog_marginLeftRight"
        android:layout_marginRight="@dimen/dialog_marginLeftRight"
        android:layout_marginStart="@dimen/dialog_marginLeftRight"
        android:layout_marginTop="16dp"

        android:orientation="vertical">
        <View
            android:layout_width="match_parent"
            android:layout_height="1dp"
            android:background="#1f000000" />

        <LinearLayout
            android:layout_width="match_parent"
            android:layout_height="wrap_content"
            android:gravity="center">

            <TextView
                style="@style/Caption3"
                android:layout_width="0dp"
                android:layout_height="wrap_content"
                android:layout_weight="2"
                android:text="@string/groups"
                android:textAllCaps="true" />

            <Button
                android:id="@+id/challenge_filter_button_all"
                style="@style/Body1_Button"
                android:layout_width="wrap_content"
                android:layout_height="wrap_content"
                android:gravity="right|center_vertical"
                android:text="@string/all"
                android:textColor="#6133b4"
                android:textSize="16sp"
                android:padding="0dp" />

            <Button
                android:id="@+id/challenge_filter_button_none"
                style="@style/Body1_Button"
                android:layout_width="wrap_content"
                android:layout_height="wrap_content"
                android:gravity="right|center_vertical"
                android:text="@string/none"
                android:textColor="#6133b4"
                android:textSize="16sp"
                android:padding="0dp"/>
            </LinearLayout>

        <androidx.recyclerview.widget.RecyclerView
            android:id="@+id/challenge_filter_recycler_view"
            android:layout_width="match_parent"
            android:layout_height="wrap_content"
            tools:listitem="@layout/dialog_challenge_filter_group_item"
            tools:visibility="gone" />
            <TextView
                style="@style/Caption3"
                android:layout_width="wrap_content"
                android:layout_height="wrap_content"
                android:layout_marginTop="14dp"
                android:height="20dp"
                android:gravity="center_vertical"
                android:text="@string/ownership"
                android:textAllCaps="true" />

            <CheckBox
                style="@style/Subheader2"
                android:id="@+id/challenge_filter_owned"
                android:layout_width="match_parent"
                android:layout_height="wrap_content"
                android:checked="true"
                android:text="@string/owned"
                android:textColor="@color/textColorLight"
                android:paddingLeft="8dp" />

            <CheckBox
                style="@style/Subheader2"
                android:id="@+id/challenge_filter_not_owned"
                android:layout_width="match_parent"
                android:layout_height="wrap_content"
                android:checked="true"
                android:text="@string/not_owned"
                android:textColor="@color/textColorLight"
                android:paddingLeft="8dp"/>
    </LinearLayout>
</com.habitrpg.android.habitica.ui.MaxHeightLinearLayout>