Auxio/app/src/main/res/layout/fragment_search.xml
OxygenCobalt acabe9217b
ui: use colorOnSurface
Use colorOnSurface for the first time ever. I decided to pick a color
that was as non-intrusive as possible that was still differentiateable,
and I think it looks like a net improvement. It will probably be
tweaked a bit in the future as I expand it to other elevated views.
2021-08-30 20:19:52 -06:00

61 lines
No EOL
2.8 KiB
XML

<?xml version="1.0" encoding="utf-8"?>
<layout xmlns:android="http://schemas.android.com/apk/res/android"
xmlns:app="http://schemas.android.com/apk/res-auto"
xmlns:tools="http://schemas.android.com/tools">
<androidx.coordinatorlayout.widget.CoordinatorLayout
android:layout_width="match_parent"
android:layout_height="match_parent">
<org.oxycblt.auxio.ui.LiftAppBarLayout
android:id="@+id/search_appbar"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:background="?attr/colorSurface"
app:liftOnScroll="true">
<androidx.appcompat.widget.Toolbar
android:id="@+id/search_toolbar"
style="@style/Widget.Toolbar.Icon"
app:layout_scrollFlags="scroll|enterAlways"
app:menu="@menu/menu_search"
app:title="@string/lbl_search" />
<com.google.android.material.textfield.TextInputLayout
android:id="@+id/search_text_layout"
android:layout_width="match_parent"
android:layout_height="wrap_content"
app:boxBackgroundMode="filled"
app:boxStrokeColor="?attr/colorAccent"
app:boxStrokeWidth="0dp"
app:boxStrokeWidthFocused="@dimen/size_stroke_large"
app:endIconContentDescription="@string/desc_clear_search"
app:endIconDrawable="@drawable/ic_close"
app:endIconMode="clear_text"
app:endIconTint="?attr/colorControlNormal"
app:errorEnabled="false">
<com.google.android.material.textfield.TextInputEditText
android:id="@+id/search_edit_text"
android:layout_width="match_parent"
android:layout_height="wrap_content"
android:background="@android:color/transparent"
android:hint="@string/hint_search_library"
android:imeOptions="actionSearch|flagNoExtractUi"
android:inputType="textFilter"
android:padding="@dimen/spacing_medium"
android:textCursorDrawable="@drawable/ui_cursor" />
</com.google.android.material.textfield.TextInputLayout>
</org.oxycblt.auxio.ui.LiftAppBarLayout>
<androidx.recyclerview.widget.RecyclerView
android:id="@+id/search_recycler"
android:layout_width="match_parent"
android:layout_height="match_parent"
app:layoutManager="androidx.recyclerview.widget.LinearLayoutManager"
app:layout_behavior="com.google.android.material.appbar.AppBarLayout$ScrollingViewBehavior"
tools:listitem="@layout/item_song" />
</androidx.coordinatorlayout.widget.CoordinatorLayout>
</layout>