Я пытаюсь внедрить BottomAppBar
в свое приложение и не могу отобразить FAB или BottomAppBar
внизу. Вот мой макет:
<?xml version="1.0" encoding="utf-8"?>
<android.support.constraint.ConstraintLayout xmlns:android="https://schemas.android.com/apk/res/android"
xmlns:app="https://schemas.android.com/apk/res-auto"
xmlns:tools="https://schemas.android.com/tools"
android:layout_width="match_parent"
android:layout_height="match_parent"
tools:context=".dashboard.DashboardActivity">
<android.support.design.widget.FloatingActionButton
android:id="@+id/fab"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:src="@drawable/ic_add_white_24dp"
app:layout_anchor="@id/bottom_bar"/>
<android.support.design.bottomappbar.BottomAppBar
android:id="@+id/bottom_bar"
android:layout_width="match_parent"
android:layout_height="@dimen/mtrl_bottomappbar_height"
android:layout_gravity="bottom"
app:backgroundTint="@color/colorPrimary"
app:fabAttached="true"
app:fabCradleVerticalOffset="12dp"
app:fabAlignmentMode="center"/>
</android.support.constraint.ConstraintLayout>
Однако вот что отображается в эмуляторе:
Как выровнять по низу?