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
Material Components ことはじめ / Get Started Materia...
Search
Sho Masegi
September 28, 2018
Technology
810
0
Share
Embed
Copy iframe code
Copy JS code
Copy link
Start on current slide
Material Components ことはじめ / Get Started Material Components
Sho Masegi
September 28, 2018
More Decks by Sho Masegi
See All by Sho Masegi
独自の共通認証基盤を用いているサービスでアカウント削除機能を提供したときの道程
shomasegi
1
3.3k
Migrate Swift 4.2 to 5.2
shomasegi
4
900
今更ながらEpoxy / Lateinit Epoxy
shomasegi
2
900
Other Decks in Technology
See All in Technology
Digital Credentials API × OpenID4VP ブラウザ完結型本人確認の実装知見(OAuth/OIDC Numa (Immersion) Workshop 2026)
oidfj
PRO
0
260
All About Sansan – for New Global Engineers
sansan33
PRO
1
1.5k
Oracle AI Databaseデータベース・サービス: BaseDB/ExaDB-Dの可用性
oracle4engineer
PRO
1
900
markdown-poster Introduction
kazamori
0
160
国家プロジェクトを支える「さくらONE」 大規模LLM開発におけるGPU障害を乗り越えるクラスター運用戦略
gpuunite_official
0
290
AWSとGitHub Actionsの責任境界と 組織で安全に使用する取り組み
nealle
0
160
Kiro Crew で始める マルチエージェント開発
miu_crescent
PRO
0
180
AI駆動開発はどこまで来たのか? ファインディの最新実態調査で読み解く現在地 Devin Con Tokyo
akiratom
1
1k
わたしが知り合いゼロの勉強会に 行けるようになるまで
r5ni4
2
790
パスキーでドライブする アカウント統合(OAuth/OIDC Numa (Immersion) Workshop 2026)
oidfj
PRO
0
280
AI画像認識を活用したゲーム内決済処理検証の自動化
gree_tech
PRO
0
500
電話に出る Python のログの話
shinnosuke_kishida
0
220
Featured
See All Featured
The Invisible Side of Design
smashingmag
301
52k
Optimising Largest Contentful Paint
csswizardry
37
3.9k
We Analyzed 250 Million AI Search Results: Here's What I Found
joshbly
1
1.9k
Chrome DevTools: State of the Union 2024 - Debugging React & Beyond
addyosmani
10
1.3k
A better future with KSS
kneath
240
18k
The World Runs on Bad Software
bkeepers
PRO
72
12k
The browser strikes back
jonoalderson
0
1.5k
[RailsConf 2023] Rails as a piece of cake
palkan
59
6.9k
Why You Should Never Use an ORM
jnunemaker
PRO
61
10k
Building Better People: How to give real-time feedback that sticks.
wjessup
370
20k
Design and Strategy: How to Deal with People Who Don’t "Get" Design
morganepeng
133
19k
Code Reviewing Like a Champion
maltzj
528
40k
Transcript
Material Components ͜ͱ͡Ίɹ Sho Masegi
ࣗݾհ • όέπඃͬͯ·͢ɻ • େֶੜͰ͢ɻ • Androidɺ࣌ʑiOS • ॳΊͯͷLT @boc_sho
Material Componentsͱʁ Material DesignΛ࣮ݱ͢ΔͨΊͷUI෦܈ ͷ͜ͱɻ ࠷ۙɺ1.0.0͕ϦϦʔε͞Εͨ
ࠓճ͢͜ͱ - BottomAppBar - Chip
ͬͨ͜ͱ͋Δํ͍·͔͢ʁ
ກΛଓ͚͍ͯͩ͘͞ɻ
Material Components in library - AppBarLayout - Backdrop - Banner
- BottomAppBar - BottomNavigationView - BottomSheetBehavior - BottomSheetDialogFragment - CheckBox - Chip - CollapsingToolbarLayout - DataTable - Dialog - Divider - ExtendedFloatingActionButton - FloatingActionButton - ImageList - List - MaterialButton - MaterialCardView - Menu - NavigationView - ProgressIndicator - RadioButton - SideSheetBehavior - Slider - Snackbar - Switch - TabLayout - TextInputLayout - Tooltip
New Components - AppBarLayout - Backdrop - Banner - BottomAppBar
- BottomNavigationView - BottomSheetBehavior - BottomSheetDialogFragment - CheckBox - Chip - CollapsingToolbarLayout - DataTable - Dialog - Divider - ExtendedFloatingActionButton - FloatingActionButton - ImageList - List - MaterialButton - MaterialCardView - Menu - NavigationView - ProgressIndicator - RadioButton - SideSheetBehavior - Slider - Snackbar - Switch - TabLayout - TextInputLayout - Tooltip
ݱࡏ͑Δͷ…. ( - 1.0.0) - AppBarLayout - Backdrop - Banner
- BottomAppBar - BottomNavigationView - BottomSheetBehavior - BottomSheetDialogFragment - CheckBox - Chip - CollapsingToolbarLayout - DataTable - Dialog - Divider - ExtendedFloatingActionButton - FloatingActionButton - ImageList - List - MaterialButton - MaterialCardView - Menu - NavigationView - ProgressIndicator - RadioButton - SideSheetBehavior - Slider - Snackbar - Switch - TabLayout - TextInputLayout - Tooltip
ݱࡏ͑Δͷ…. - BottomAppBar - Chip - MaterialButton - MaterialCardView -
TextInputLayout
ͬͯΈΑ͏ʂ
४උ allprojets { repositories { google() jcenter() } } build.gradle
४උ dependencies { // . . . implementation ‘com.google.android.material:material:1.0.0’ //
. . . } build.gradle
४උ android { compileSdkVersion 28 defaultConfig { // . .
. build.gradle
४උ ThemeΛ”Theme.MaterialComponents.~”ʹ͑Δ <style name=“AppTheme” parent=“Theme.MaterialComponents.Light.NoActionBar”>
४උ AndroidXʹϦϑΝΫλϦϯά͢Δ Refactor -> Migrate to AndroidX
४උྃʂ
BottomAppBar
BottomAppBar <androidx.coordinatorlayout.widget.CoordinatorLayout > <com.google.android.material.bottomappbar.BottomAppBar . . . app:backgroundTint="@color/colorPrimary" app:fabAlignmentMode="center" app:fabAttached="true"
app:navigationIcon="@drawable/menu"/> <com.google.android.material.floatingactionbutton.FloatingActionButton . . . app:layout_anchor="@id/bottom_app_bar" /> </androidx.coordinatorlayout.widget.CoordinatorLayout>
BottomAppBar <androidx.coordinatorlayout.widget.CoordinatorLayout > <com.google.android.material.bottomappbar.BottomAppBar . . . app:backgroundTint="@color/colorPrimary" app:fabAlignmentMode="center" app:fabAttached="true"
app:navigationIcon="@drawable/menu"/> <com.google.android.material.floatingactionbutton.FloatingActionButton . . . app:layout_anchor="@id/bottom_app_bar" /> </androidx.coordinatorlayout.widget.CoordinatorLayout>
- fabAlignmentMode - fabCradleMargin - fabCradleRoundedCornerRadius - fabCradleVerticalOffset BottomAppBarͷଐੑ
- fabAlignmentMode BottomAppBarͷଐੑ start end
- fabCradleMargin BottomAppBarͷଐੑ default 10dp
- fabCradleRoundedCornerRadius BottomAppBarͷଐੑ default 30dp
- fabCradleVerticalOffset BottomAppBarͷଐੑ default 15dp
Chip
Chip <com.google.android.material.chip.ChipGroup . . . app:chipSpacing="4dp" app:chipSpacingHorizontal="2dp" app:chipSpacingVertival="2dp" app:singleSelection=“true” app:singleLine=“true"/>
<com.google.android.material.chip.Chip . . . /> </com.google.android.material.chip.ChipGroup>
Chip <com.google.android.material.chip.ChipGroup . . . app:chipSpacing="4dp" app:chipSpacingHorizontal="2dp" app:chipSpacingVertival="2dp" app:singleSelection=“true” app:singleLine=“true"/>
<com.google.android.material.chip.Chip . . . /> </com.google.android.material.chip.ChipGroup>
ChipGroup: singleLine false true
Chip val chip = Chip(context) chip.text = "Chip" chip.chipIcon =
ContextCompat.getDrawable(requiredContext(), icon) chip.isCloseIconEnabled = true chip.isCheckable = false chipGroup.addView(chip as View) chip.setOnCloseIconClickListener { chipGroup.removeView(chip as View) } - ChipͷՃํ๏
Chip val chip = Chip(context) chip.text = "Chip" chip.chipIcon =
ContextCompat.getDrawable(requiredContext(), icon) chip.isCloseIconEnabled = true chip.isCheckable = false chip.setOnCloseIconClickListener { chipGroup.removeView(chip as View) } chipGroup.addView(chip as View) - ChipͷՃํ๏
Chip chip.chipIcon = locationIcon chip.isCloseIconEnabled = true chip.setOnCloseIconClickListener { …
} chip.isCheckable = true
MaterialButton MaterialCardView TextInputLayout ʹ͍ͭͯ. . . .
CodelabͰʂ
https:// codelabs.developers.google.com/ codelabs/mdc-101-kotlin/#0
͜Μͳྑ͍ͷΛ༻ҙ͠ ͯ͘ΕΔͳΜͯ. . . .
Google࠷ߴʂ
Android࠷ߴʂ
Material Design Roadmap
Material Design Roadmap
Material Design Roadmap
None