<?xml version="1.0" encoding="utf-8"?>
<androidx.coordinatorlayout.widget.CoordinatorLayout 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/coordinatorLayout"
    android:layout_width="match_parent"
    android:layout_height="match_parent">

    <androidx.constraintlayout.widget.ConstraintLayout
        android:layout_width="match_parent"
        android:layout_height="match_parent">

        <com.google.android.material.appbar.AppBarLayout
            android:id="@+id/appBarLayout"
            android:layout_width="match_parent"
            android:layout_height="wrap_content"
            app:layout_constraintTop_toTopOf="parent">

            <com.google.android.material.appbar.MaterialToolbar
                android:id="@+id/phoneBookToolbar"
                android:layout_width="match_parent"
                android:layout_height="?actionBarSize"
                app:title="@string/contacts_book_title"/>

            <com.google.android.material.textfield.TextInputLayout
                android:id="@+id/phoneBookFilterContainer"
                android:layout_width="match_parent"
                android:layout_height="wrap_content"
                android:layout_marginStart="@dimen/layout_horizontal_margin"
                android:layout_marginTop="16dp"
                android:layout_marginEnd="@dimen/layout_horizontal_margin">

                <com.google.android.material.textfield.TextInputEditText
                    android:id="@+id/phoneBookFilter"
                    android:layout_width="match_parent"
                    android:layout_height="wrap_content"
                    android:hint="@string/search" />

            </com.google.android.material.textfield.TextInputLayout>

            <CheckBox
                android:id="@+id/phoneBookOnlyBoundContacts"
                android:layout_width="match_parent"
                android:layout_height="wrap_content"
                android:layout_marginStart="@dimen/layout_horizontal_margin"
                android:layout_marginTop="4dp"
                android:layout_marginEnd="@dimen/layout_horizontal_margin"
                android:text="@string/matrix_only_filter"
                android:visibility="gone"
                tools:visibility="visible" />

            <Button
                android:id="@+id/phoneBookSearchForMatrixContacts"
                style="@style/Widget.Vector.Button.Text"
                android:layout_width="wrap_content"
                android:layout_height="wrap_content"
                android:layout_marginStart="@dimen/layout_horizontal_margin"
                android:layout_marginTop="4dp"
                android:layout_marginEnd="@dimen/layout_horizontal_margin"
                android:text="@string/phone_book_perform_lookup"
                android:visibility="gone"
                tools:visibility="visible" />

        </com.google.android.material.appbar.AppBarLayout>

        <androidx.recyclerview.widget.RecyclerView
            android:id="@+id/phoneBookRecyclerView"
            android:layout_width="0dp"
            android:layout_height="0dp"
            android:fastScrollEnabled="true"
            android:overScrollMode="always"
            android:scrollbars="vertical"
            app:layout_constraintBottom_toBottomOf="parent"
            app:layout_constraintEnd_toEndOf="parent"
            app:layout_constraintStart_toStartOf="parent"
            app:layout_constraintTop_toBottomOf="@id/appBarLayout"
            tools:listitem="@layout/item_contact_main" />

    </androidx.constraintlayout.widget.ConstraintLayout>

</androidx.coordinatorlayout.widget.CoordinatorLayout>

