change notes edit textfield to material style

This commit is contained in:
osodebailar 2022-04-05 16:28:08 +02:00
parent 1d2ecb257c
commit 6c0668c069
4 changed files with 33 additions and 19 deletions

View file

@ -1,25 +1,35 @@
<?xml version="1.0" encoding="utf-8"?> <?xml version="1.0" encoding="utf-8"?>
<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android" <LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
android:id="@+id/notes_layout" xmlns:app="http://schemas.android.com/apk/res-auto"
android:id="@+id/notes_layout"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:orientation="horizontal">
<com.google.android.material.textfield.TextInputLayout
android:layout_width="match_parent" android:layout_width="match_parent"
android:layout_height="wrap_content" android:layout_height="wrap_content"
android:orientation="horizontal"> style="@style/Widget.MaterialComponents.TextInputLayout.OutlinedBox"
android:hint="@string/notes_label"
app:boxStrokeColor="@color/mtrl_textinput_default_box_stroke_color"
android:textColorHint="?attr/colorOnPrimary"
app:hintTextColor="?attr/colorOnPrimary"
app:endIconMode="clear_text">
<TextView <com.google.android.material.textfield.TextInputEditText
android:labelFor="@+id/notes"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:layout_gravity="center_horizontal"
android:width="120dp"
android:padding="10dp"
android:text="@string/notes_label"
android:textAppearance="@style/TextAppearance.AppCompat.Small"
android:textStyle="bold" />
<EditText
android:id="@+id/notes" android:id="@+id/notes"
android:layout_width="wrap_content" android:layout_width="match_parent"
android:layout_height="wrap_content" android:layout_height="wrap_content"
android:layout_marginStart="10dp"
android:layout_marginEnd="10dp"
android:layout_gravity="center_vertical"
android:layout_weight="1"
android:autofillHints="@string/notes_label"
android:gravity="start"
android:textStyle="bold"
android:width="180dp" android:width="180dp"
android:inputType="text" /> android:inputType="text|textCapSentences" />
</com.google.android.material.textfield.TextInputLayout>
</LinearLayout> </LinearLayout>

View file

@ -1,5 +1,5 @@
<?xml version="1.0" encoding="utf-8"?> <?xml version="1.0" encoding="utf-8"?>
<resources> <resources xmlns:tools="http://schemas.android.com/tools">
<!-- Default theme color --> <!-- Default theme color -->
<!-- This section describes the main theme colors --> <!-- This section describes the main theme colors -->
<color name="colorPrimary">#212121</color> <color name="colorPrimary">#212121</color>
@ -245,6 +245,8 @@
<!-- Button icons - general --> <!-- Button icons - general -->
<color name="pod_icon_outline">#9E9E9E</color> <color name="pod_icon_outline">#9E9E9E</color>
<color name="mtrl_textinput_default_box_stroke_color" tools:override="true" >#9E9E9E</color>
<!-- Omnipod Wizard --> <!-- Omnipod Wizard -->
<color name="omnipod_wizard_progress_bar">#0099CC</color> <color name="omnipod_wizard_progress_bar">#0099CC</color>
<color name="omnipod_wizard_finish_button">#ff669900</color> <color name="omnipod_wizard_finish_button">#ff669900</color>

View file

@ -96,7 +96,7 @@
<!---Toast --> <!---Toast -->
<item name="toastBaseTextColor">@color/toastBase</item> <item name="toastBaseTextColor">@color/toastBase</item>
<!---Input --> <!---Input -->
<item name="boxStrokeColor">@color/white</item> <item name="boxStrokeColor">@color/white_alpha_20</item>
<!---Profile Helper --> <!---Profile Helper -->
<item name="tabBgColorSelected">@color/tabBgColorSelected</item> <item name="tabBgColorSelected">@color/tabBgColorSelected</item>
<!---Dialog Helper --> <!---Dialog Helper -->

View file

@ -1,5 +1,5 @@
<?xml version="1.0" encoding="utf-8"?> <?xml version="1.0" encoding="utf-8"?>
<resources> <resources xmlns:tools="http://schemas.android.com/tools">
<!-- Default theme color --> <!-- Default theme color -->
<!-- This section describes the main theme colors --> <!-- This section describes the main theme colors -->
<color name="colorPrimary">#FBF9FF</color> <color name="colorPrimary">#FBF9FF</color>
@ -249,6 +249,8 @@
<!-- Button icons - general --> <!-- Button icons - general -->
<color name="pod_icon_outline">#9E9E9E</color> <color name="pod_icon_outline">#9E9E9E</color>
<color name="mtrl_textinput_default_box_stroke_color" tools:override="true" >#9E9E9E</color>
<!-- Omnipod Wizard --> <!-- Omnipod Wizard -->
<color name="omnipod_wizard_progress_bar">#0099CC</color> <color name="omnipod_wizard_progress_bar">#0099CC</color>
<color name="omnipod_wizard_finish_button">#ff669900</color> <color name="omnipod_wizard_finish_button">#ff669900</color>