Android の material-components 1.1.0-alpha06 で BottomNavigation (よく下タブと呼ばれるもの)に Badge が表示できるようになりました👏 (ガイドラインに記載はあったけど標準ライブラリの対応がまだでした) Badge のパターン ドットだけのもの 数字をセットしなければドットだけの表示になります。(画像一番左) bottomNavigationView.showBadge(menuItemId)数字のもの デフォルトでは 3 桁までしか表示できず、それ以上の場合は xxx+ という表示になります。(画像右から 2 つ目) もちろん Max の桁数を変更すればそれ以上の表示も可能になります。(画像一番右) bottomNavigationView.showBadge(menuItemId).apply { setNumber(
![BottomNavigation に Badge が表示できるようになった!|Nabe](https://cdn-ak-scissors.b.st-hatena.com/image/square/028c4fb075460039b8d5b63985139949e3a8761c/height=288;version=1;width=512/https%3A%2F%2Fassets.st-note.com%2Fproduction%2Fuploads%2Fimages%2F11453498%2Frectangle_large_type_2_579ed07e2004da3f569cdb6183c5d068.png%3Ffit%3Dbounds%26quality%3D85%26width%3D1280)