Upgrade to Pro — share decks privately, control downloads, hide ads and more …

Material Components for Android触ってみる

Material Components for Android触ってみる

きりみん

May 23, 2018
Tweet

More Decks by きりみん

Other Decks in Programming

Transcript

  1. compileSdk • compileSdkVersionΛ'android-P'ʹ android { compileSdkVersion 'android-P' defaultConfig { applicationId

    "com.example.m00008.trymaterialcomponents" minSdkVersion 21 targetSdkVersion 27 ...
  2. Material Components Theme Λ࢖͏ • Theme.MaterialComponents • Theme.MaterialComponents.NoActionBar • Theme.MaterialComponents.Light

    • Theme.MaterialComponents.Light.NoActionBar • Theme.MaterialComponents.Light.DarkActionBar
  3. Text field • styleΛมߋ <com.google.android.material.textfield.TextInputLayout style="@style/ Widget.MaterialComponents.TextInputLayout.OutlineBox" android:layout_width="match_parent" android:layout_height="wrap_content" android:hint="test">

    <com.google.android.material.textfield.TextInputEditText android:layout_width="match_parent" android:layout_height="wrap_content" /> </com.google.android.material.textfield.TextInputLayout>