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
what's new in Material Design で気になったトピック
Search
Sponsored
·
Your Podcast. Everywhere. Effortlessly.
Share. Educate. Inspire. Entertain. You do you. We'll handle the rest.
→
punchdrunker
May 26, 2023
Programming
650
1
Share
Embed
Copy iframe code
Copy JS code
Copy link
Start on current slide
what's new in Material Design で気になったトピック
punchdrunker
May 26, 2023
More Decks by punchdrunker
See All by punchdrunker
Kotlin2.0以降の新機能
punchdrunker
0
48
DnD in Compose
punchdrunker
0
330
7カ国語に対応したサービスでの翻訳管理システムの改善事例
punchdrunker
1
1.5k
Java Bytecode Vertical Tasting
punchdrunker
2
1.6k
getting started with dark theme
punchdrunker
2
1.1k
Practical Activity Transition in Android
punchdrunker
0
1.3k
今時のProgress indicator / Replacing ProgressDialog with ProgressBar
punchdrunker
0
740
レビュー評価4.7の秘密 / The Secret To A Better Reputation
punchdrunker
2
2.1k
Dynamic Feature Modules 入門
punchdrunker
2
2.8k
Other Decks in Programming
See All in Programming
「エンジニアインターン、どうやって取った?」準備のリアルを語るLT会 Progate BAR
akiomatic
0
130
Honoでのサプライチェーン侵害対策 〜 3つのライブラリに学ぶ
yusukebe
4
840
IBM Bobを活用したレガシーアプリの最新化
oniak3ibm
PRO
1
200
Java × distroless で 軽量なコンテナイメージを / Java on Distroless
contour_gara
0
540
Semantic Version 単位で戦略を柔軟に変えて、パッケージアップデートを自動化する
daitasu
1
240
Webフレームワークの ベンチマークについて
yusukebe
0
170
Signal Forms: Details & Live Coding @enterJS 2026 in Mannheim
manfredsteyer
PRO
0
130
Vue × Nuxt × Oxc どこまで使える?実運用の現在地
andpad
0
250
Inside Stream API
skrb
1
710
Claspは野良GASの夢をみるか
takter00
0
190
Agentic UI
manfredsteyer
PRO
0
160
Language Server 使ってる? 〜VSCode と Zed の場合〜 / Are you using a Language Server? ~For VS Code and Zed~
handlename
0
780
Featured
See All Featured
Design of three-dimensional binary manipulators for pick-and-place task avoiding obstacles (IECON2024)
konakalab
0
460
Lessons Learnt from Crawling 1000+ Websites
charlesmeaden
PRO
1
1.3k
Improving Core Web Vitals using Speculation Rules API
sergeychernyshev
21
1.5k
Bridging the Design Gap: How Collaborative Modelling removes blockers to flow between stakeholders and teams @FastFlow conf
baasie
0
580
Building an army of robots
kneath
306
46k
How to Think Like a Performance Engineer
csswizardry
28
2.6k
A better future with KSS
kneath
240
18k
What's in a price? How to price your products and services
michaelherold
247
13k
How People are Using Generative and Agentic AI to Supercharge Their Products, Projects, Services and Value Streams Today
helenjbeal
1
210
Between Models and Reality
mayunak
4
340
Navigating Team Friction
lara
192
16k
JAMstack: Web Apps at Ludicrous Speed - All Things Open 2022
reverentgeek
1
470
Transcript
Google I/O 2023での Material Designまわりの話 @punchdrunker
mixi, Inc. What’s new in Material Design https://io.google/2023/program/630ffaa3-9b3d-4e30-a89f-91ef3e8052cf/intl/ja/
mixi, Inc. Materilal DesignとかMaterial Youとか - Material Design - 2014に発表されたデザインフレームワーク(Lollipopのプレビューが出た頃!!)
- 画面に配置する部品の設計方針などをまとめたガイドライン - ガイドラインに従った実装をサポートするライブラリ群 - 今は最新バージョンのMaterial 3とか M3とか呼ぶ事が多そう - Material You - Google I/O 2021で発表された - Material Desingの枠の中でユーザーに提供されるイイカンジの機能の総称 - アプリアイコンの形を設定で変えられる - 色の具合を設定で変えられる - 壁紙をイイカンジに変えられる
mixi, Inc. Material Design関連の主なライブラリ 従来のView用のライブラリとCompose用のライブラリは分かれているので、調査が若干大変。。。 - Compose Material (Jetpack)
- compose用のMDライブラリ - Compose Material 3(Jetpack) - Material Design 2もあった気がするけど3からパッケージ名が別名 - Material Components Android(非Jetpack) - 昔からあるView用のMDライブラリ - Javaで書かれてる - 別名MDC-AndroidとかMDC - Composeと並行してメンテされてる - Jetpackには入っていない
mixi, Inc.
mixi, Inc.
mixi, Inc. What’s new in Material Designで気になったトピック - Carousel -
RecyclerView用の LayoutManager が追加された - Dynamic Color - Content-based color - これまで壁紙に合わせたColorScheme(色のセット)はあったが、画像リソースや単色を指定して、ColorSchemeを作っ てくれる
mixi, Inc. Carousel 現状はMDCの方でしか実装されていないがComposeでも開発は進んでいる。 カタログアプリで実装されている。 https://github.com/material-components/material-components-android
- RecyclerViewのLayoutManagerとしてCarouselLayoutManagerが追加 - CarouselLayoutManagerにStrategyを渡して見せ型調整 - MultiBrowseCarouselStrategy - なるべく多くのセルを表示 - HeroCarouselStrategy - 1つ1つを強調して表示
mixi, Inc. Dynamic Color - Content-based color 2022くらいから端末の壁紙に合わせたColor schemeを選んでくれる仕組みはあった。(Android12以上)
画像リソースやColor resを渡すと最適なColor schemeを選んでテーマに組み込んでくれる仕組みが追加されるらしい。 https://m3.material.io/styles/color/dynamic-color/overview こちらも現状ではMDCでしか対応されていなさそう。 内部ではMaterial Color Utilityが使われている https://github.com/material-foundation/material-color-utilities - 渡されたbitmapをQuantizeしてScoreクラスで評価するとbaseSeedColorが得られる - baseSeedColorをもとにSchemeContentが作成されて、それをContextに反映してinflate - Pixel 6aで3秒くらい掛かったので、いろんな部品に使いまくるものではなさそう(200kBのpng)
mixi, Inc. 5 Key colors
mixi, Inc. Content-based colorの使い方(Activity) @Override protected void onCreate(Bundle savedInstanceState) {
// Invoke before the view is inflated in your activity. DynamicColors.applyToActivityIfAvailable( this, new DynamicColorsOptions.Builder() .setContentBasedSource(bitmap) // @ColorRes Intも渡せる .build() ); setContentView(R.layout.xyz); }
mixi, Inc. @Override public View onCreateView(LayoutInflater layoutInflater, ViewGroup viewGroup, Bundle
bundle) { Context context = DynamicColors.wrapContextIfAvailable( requireContext(), new DynamicColorsOptions.Builder() .setContentBasedSource(sourceColor) .build()); return layoutInflater.cloneInContext(context).inflate(R.layout.xyz, viewGroup, false); } Content-based colorの使い方(Fragment/View)
mixi, Inc. Content-based colorの使いどころ UIのどこにコンテンツが存在し、コンテンツに基づくカラーが人の体験を向上させることができるかを考えてみま しょう。独立した画面や画面の一部など、明確に定義されたスペースにあるコンポーネントやコンポーネントのク ラスターを探します。これらのコンポーネントが個人のコンテンツと関連している場合、コンテンツベースの色を 継承する効果的な機会がある可能性があります。
mixi, Inc. Androidアプリエンジニア採用してます https://team.mitene.us/jobs
mixi, Inc. おわり