<?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"
    android:layout_width="match_parent"
    android:layout_height="match_parent">

    <com.google.android.material.appbar.AppBarLayout
        android:id="@+id/appbar"
        android:layout_width="match_parent"
        android:layout_height="wrap_content"
        app:liftOnScroll="true"
        app:liftOnScrollTargetViewId="@+id/item_list">

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

            <com.google.android.material.appbar.MaterialToolbar
                android:id="@+id/toolbar"
                android:layout_width="match_parent"
                android:layout_height="?attr/actionBarSize" />

            <include layout="@layout/connection_indicator" />

        </FrameLayout>

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

    <androidx.constraintlayout.widget.ConstraintLayout
        android:id="@+id/results_layout"
        android:layout_width="match_parent"
        android:layout_height="match_parent"
        android:background="?android:attr/colorBackground"
        app:layout_behavior="@string/appbar_scrolling_view_behavior">

        <com.google.android.material.chip.ChipGroup
            android:id="@+id/chip_group"
            android:layout_width="0dp"
            android:layout_height="wrap_content"
            android:animateLayoutChanges="true"
            android:paddingLeft="16dp"
            android:paddingTop="10dp"
            android:paddingRight="16dp"
            android:paddingBottom="10dp"
            android:visibility="visible"
            app:chipSpacingHorizontal="4dp"
            app:chipSpacingVertical="0dp"
            app:layout_constraintLeft_toLeftOf="parent"
            app:layout_constraintRight_toRightOf="parent"
            app:layout_constraintTop_toTopOf="parent"
            app:lineSpacing="4dp" />

        <ch.threema.app.ui.EmptyRecyclerView
            android:id="@+id/item_list"
            android:layout_width="match_parent"
            android:layout_height="0dp"
            android:paddingLeft="@dimen/grid_spacing"
            android:paddingRight="@dimen/grid_spacing"
            app:layout_constraintBottom_toBottomOf="parent"
            app:layout_constraintLeft_toLeftOf="parent"
            app:layout_constraintRight_toRightOf="parent"
            app:layout_constraintTop_toBottomOf="@+id/chip_group" />

    </androidx.constraintlayout.widget.ConstraintLayout>

</androidx.coordinatorlayout.widget.CoordinatorLayout>
