app/src/main/res/layout/fragment_events.xml
<?xml version="1.0" encoding="utf-8"?>
<androidx.constraintlayout.widget.ConstraintLayout 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/id_fragment_event_list"
android:layout_width="match_parent"
android:layout_height="match_parent"
app:layout_behavior="@string/appbar_scrolling_view_behavior"
tools:context=".view.fragments.EventListFragment">
<com.google.android.material.switchmaterial.SwitchMaterial
android:id="@+id/event_list_my_events_switch"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:text="@string/my_events"
app:layout_constraintBottom_toTopOf="@id/recycler_events_list"
app:layout_constraintEnd_toEndOf="parent"
app:layout_constraintTop_toBottomOf="parent"
app:layout_constraintTop_toTopOf="parent" />
<TextView
android:id="@+id/fragment_events_no_upcoming_events_text_view"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:text="@string/no_upcoming_events"
android:visibility="gone"
app:layout_constraintBottom_toBottomOf="parent"
app:layout_constraintEnd_toEndOf="parent"
app:layout_constraintStart_toStartOf="parent"
app:layout_constraintTop_toTopOf="parent" />
<androidx.recyclerview.widget.RecyclerView
android:id="@+id/recycler_events_list"
android:layout_width="0dp"
android:layout_height="0dp"
android:scrollbars="vertical"
app:layoutManager="LinearLayoutManager"
app:layout_constraintBottom_toBottomOf="parent"
app:layout_constraintLeft_toLeftOf="parent"
app:layout_constraintRight_toRightOf="parent"
app:layout_constraintTop_toBottomOf="@id/event_list_my_events_switch"
tools:listitem="@layout/card_event" />
</androidx.constraintlayout.widget.ConstraintLayout>