Upgrade to Pro
— share decks privately, control downloads, hide ads and more …
Speaker Deck
Features
Speaker Deck
PRO
Sign in
Sign up for free
Search
Search
Badging for Tabs and Bottom Navigation
Search
umechanhika
February 12, 2020
Programming
390
0
Share
Embed
Copy iframe code
Copy JS code
Copy link
Start on current slide
Badging for Tabs and Bottom Navigation
umechanhika
February 12, 2020
More Decks by umechanhika
See All by umechanhika
My Workspace [2020/08版]
umechanhika
0
110
My Workspace [2020/06版]
umechanhika
0
57
Capture view and Register to gallery
umechanhika
0
73
Shape Design with Material Components
umechanhika
3
270
Firebase MLKit AutoML Vision Edgeを触ってみた
umechanhika
3
590
Google Play Consoleの時間指定公開のハマりポイント
umechanhika
1
1.6k
UIテスト初心者のチームにUIテスト自動化を導入した話
umechanhika
0
120
GoogleI/Oアプリのようなフィルター機能を実装する
umechanhika
2
550
Jenkins + Bitbucketでアプリリリースを自動化してみた
umechanhika
1
700
Other Decks in Programming
See All in Programming
いまどきの Codex で開発する visionOS アプリの開発スタイルについて
karad
0
140
komatsuna「分散システムにおけるバグ分析手法」
komatsunaqa
0
260
VibeCodingからAgenticWorkflowへ
starfish719
0
430
Laravel Boostに学ぶ、AIにPHPを書かせる技術 〜OSSの実装から蒸留するエージェント制御の王道〜
kentaroutakeda
3
690
S3 を使うアプリケーションをローカル完結で動かすことに全力を注いでみた / Running S3 Apps Offline
contour_gara
0
460
ルールを書いて終わらせないハーネスエンジニアリング
yug1224
4
1.9k
AI Engineeringは、AIプロダクトだけのものか? 〜AIがソフトウェアを作る時代の新しい当たり前〜 / No AI in your product. AI Engineering in your development.
rkaga
4
400
ソフトウェア設計に溶けるインフラ ― AWS CDK のインフラ認識論
konokenj
3
780
プロポーザルを書いてもらう
pvcresin
0
480
メールのエイリアス機能を履き違えない
isshinfunada
0
230
仕様駆動開発の消費期限
watany
20
8.2k
型も通る、synthも通る、それでも危ない 〜AIのCDKの権限とコストを機械で検証する〜 / It Passes Type Checks, It Passes Synth Checks, but It’s Still Risky — Automatically Verifying Permissions and Costs in AI’s CDK —
seike460
PRO
1
550
Featured
See All Featured
The Mindset for Success: Future Career Progression
greggifford
PRO
0
440
The State of eCommerce SEO: How to Win in Today's Products SERPs - #SEOweek
aleyda
2
11k
Code Review Best Practice
trishagee
74
20k
Learning to Love Humans: Emotional Interface Design
aarron
275
41k
Why Your Marketing Sucks and What You Can Do About It - Sophie Logan
marketingsoph
0
370
Fantastic passwords and where to find them - at NoRuKo
philnash
52
3.8k
Digital Ethics as a Driver of Design Innovation
axbom
PRO
1
360
Hiding What from Whom? A Critical Review of the History of Programming languages for Music
tomoyanonymous
3
1.1k
Stewardship and Sustainability of Urban and Community Forests
pwiseman
0
460
The Hidden Cost of Media on the Web [PixelPalooza 2025]
tammyeverts
2
460
It's Worth the Effort
3n
188
29k
4 Signs Your Business is Dying
shpigford
187
22k
Transcript
Badging for Tabs and Bottom Navigation
About me Hikaru Umetsu (@umechanhika) Fintech startup Individual developer Fav:
Android & Flutter Individual Job ?
Material Components 1.1.0 released !
Today’s topic
Badging for Tabs and Bottom Navigation Reference:https://material.io/develop/android/components/tab-layout/
Use “BadgeDrawable” val tabBadge: BadgeDrawable = tabLayout.getTabAt(0)?.orCreateBadge val navBadge: BadgeDrawable
= bottomNavigation.getOrCreateBadge(R.id.menu1)
Use “BadgeDrawable” val tabBadge: BadgeDrawable = tabLayout.getTabAt(0)?.orCreateBadge val navBadge: BadgeDrawable
= bottomNavigation.getOrCreateBadge(R.id.menu1)
val tabBadge: BadgeDrawable = tabLayout.getTabAt(0)?.orCreateBadge tabBadge.isVisible = true Show “Dot
badge” Reference:https://material.io/develop/android/components/tab-layout/
Show “Badge with number” val tabBadge: BadgeDrawable = tabLayout.getTabAt(0)?.orCreateBadge tabBadge.number
= 99 tabBadge.isVisible = true Reference:https://material.io/develop/android/components/tab-layout/
Show “Badge with a maximum count” val tabBadge: BadgeDrawable =
tabLayout.getTabAt(0)?.orCreateBadge tabBadge.maxCharacterCount = 3 tabBadge.number = 1000 tabBadge.isVisible = true Reference:https://material.io/develop/android/components/tab-layout/
Caution max “character” count It can shows “9+”, “99+” or
etc. It cannot shows “5+”, “10+” or etc. Reference:https://material.io/develop/android/components/tab-layout/
Remove badges tabLayout.getTabAt(0)?.removeBadge() Reference:https://material.io/develop/android/components/tab-layout/
Demo Reference:https://github.com/umechanhika/playground/tree/master/android/BadgeDrawableSample
Tab and BottomNav can show badges since MDC 1.1.0 Use
BadgeDrawable It can show “Dot”, “Number” and “Maximum count” badge Summary
Thanks!