102 lines
4.4 KiB
XML
102 lines
4.4 KiB
XML
<?xml version="1.0" encoding="utf-8"?>
|
|
<FrameLayout
|
|
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"
|
|
android:layout_width="match_parent"
|
|
android:layout_height="wrap_content"
|
|
android:layout_marginTop="10dp">
|
|
|
|
<androidx.appcompat.widget.Toolbar
|
|
android:id="@+id/toolbar"
|
|
android:layout_width="match_parent"
|
|
android:layout_height="match_parent"
|
|
android:visibility="visible"
|
|
app:contentInsetStartWithNavigation="0dp"
|
|
app:titleMarginStart="0dp"
|
|
tools:title="@string/app_name">
|
|
|
|
<androidx.appcompat.widget.SearchView
|
|
android:id="@+id/search_view"
|
|
android:layout_width="match_parent"
|
|
android:layout_height="wrap_content"
|
|
android:layout_marginStart="30dp"
|
|
android:layout_marginEnd="30dp"
|
|
android:background="@color/translucent">
|
|
</androidx.appcompat.widget.SearchView>
|
|
|
|
</androidx.appcompat.widget.Toolbar>
|
|
|
|
<com.google.android.material.card.MaterialCardView
|
|
android:id="@+id/home_toolbar"
|
|
android:layout_width="match_parent"
|
|
android:layout_height="wrap_content"
|
|
android:layout_marginStart="@dimen/spacer_2x"
|
|
android:layout_marginTop="@dimen/spacer_1hx"
|
|
android:layout_marginEnd="@dimen/spacer_2x"
|
|
android:layout_marginBottom="@dimen/spacer_1hx"
|
|
app:cardBackgroundColor="@color/toolbar_background"
|
|
app:cardCornerRadius="30dp"
|
|
app:cardElevation="2dp"
|
|
app:strokeWidth="0dp">
|
|
|
|
<LinearLayout
|
|
android:layout_width="match_parent"
|
|
android:layout_height="wrap_content"
|
|
android:orientation="horizontal">
|
|
|
|
<androidx.appcompat.widget.AppCompatImageButton
|
|
android:id="@+id/menu_button"
|
|
android:layout_width="?android:attr/actionBarSize"
|
|
android:layout_height="?android:attr/actionBarSize"
|
|
android:background="?android:attr/selectableItemBackgroundBorderless"
|
|
android:layout_gravity="center_vertical|start"
|
|
android:paddingStart="@dimen/spacer_1x"
|
|
android:paddingTop="@dimen/spacer_2x"
|
|
android:paddingEnd="@dimen/spacer_1x"
|
|
android:paddingBottom="@dimen/spacer_2x"
|
|
android:tint="@color/text_color"
|
|
android:src="@drawable/ic_menu_grey"
|
|
android:contentDescription="@string/menu"/>
|
|
<androidx.appcompat.widget.AppCompatTextView
|
|
android:id="@+id/search_text"
|
|
android:layout_width="0dp"
|
|
android:layout_height="wrap_content"
|
|
android:layout_gravity="center_vertical"
|
|
android:layout_marginStart="@dimen/spacer_1x"
|
|
android:layout_marginEnd="@dimen/spacer_1x"
|
|
android:layout_weight="1"
|
|
android:ellipsize="end"
|
|
android:gravity="start"
|
|
android:lines="1"
|
|
android:textSize="16sp"
|
|
android:text="@string/search_in_all"/>
|
|
|
|
<!-- Filter button -->
|
|
<ImageButton
|
|
android:id="@+id/search_filter"
|
|
android:layout_width="?android:attr/actionBarSize"
|
|
android:layout_height="?android:attr/actionBarSize"
|
|
android:src="@drawable/ic_filter_off"
|
|
app:tint="@color/inactive"
|
|
android:background="@color/transparent"/>
|
|
|
|
<!-- User badge -->
|
|
<FrameLayout
|
|
android:id="@+id/user_badge_container"
|
|
android:layout_width="?android:attr/actionBarSize"
|
|
android:layout_height="?android:attr/actionBarSize">
|
|
<androidx.appcompat.widget.AppCompatImageView
|
|
android:id="@+id/user_badge"
|
|
android:layout_width="match_parent"
|
|
android:layout_height="match_parent"
|
|
android:padding="10dp"/>
|
|
<View
|
|
android:layout_width="match_parent"
|
|
android:layout_height="match_parent"
|
|
android:background="@drawable/user_badge_mask"/>
|
|
</FrameLayout>
|
|
</LinearLayout>
|
|
|
|
</com.google.android.material.card.MaterialCardView>
|
|
</FrameLayout> |