I am using a password toggle to show and hide the password. And I do not want to use the custom drawable. But, when this edit text generate error it overrides the toggle password icon and unable to add padding or margin to that icon. If there is any solution to this, it will be a pleasure. This is the code I am using:
<com.google.android.material.textfield.TextInputLayout
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:layout_marginTop="10dp"
android:textColorHint="@color/white"
app:passwordToggleEnabled="true"
app:passwordToggleTint="@color/white">
<EditText
android:id="@+id/et_password"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:backgroundTint="@color/white"
android:hint="@string/password"
android:imeOptions="actionDone"
android:inputType="textPassword"
android:maxLength="40"
android:maxLines="1"
android:textColor="@color/white"
android:textColorHint="@color/app_green_color" />
</com.google.android.material.textfield.TextInputLayout>