Skip to content

Latest commit

 

History

History
43 lines (34 loc) · 1.36 KB

README.md

File metadata and controls

43 lines (34 loc) · 1.36 KB

Bottom Navigation

This application is example of how to use BottomNavigationView.

  • Implement com.google.android.material.bottomnavigation.BottomNavigationView
  • This app is implemented in Kotlin
  • Disable BottomNavigationView shift mode.
    screenshot

Prerequisites

  • Android SDK 33
  • Android Build Tool 30.0.2
  • Androidx 1.6.1
  • Android Plugin for Gradle 7.4.2
  • Kotlin gradle plugin 1.8.0

Getting Started

Build with the Android Studio Electric Eel | 2022.1.1 Patch 2

Disable shifting mode

Since Support library 28

    <android.support.design.widget.BottomNavigationView
        ・・・
        app:labelVisibilityMode="labeled"
        ・・・
    />

Support library 27 or lower (target-sdk-27)

Use the extension of BottomNavigationView.

bottomNavigationView.disableShiftMode()

You need to configure proguard-rules.pro file if you want use ProGuard. Such as below:

-keepclassmembers class android.support.design.internal.BottomNavigationMenuView { 
    boolean mShiftingMode; 
}