<?xml version="1.0" encoding="utf-8"?>
<RelativeLayout 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="match_parent"
    android:background="@color/backgroundColor"
    tools:context=".navfragment.GreetingFragment">


    <LinearLayout
        android:id="@+id/title_lay"
        android:layout_width="match_parent"
        android:layout_height="wrap_content"
        android:orientation="vertical">

        <androidx.cardview.widget.CardView
            android:id="@+id/toolbar"
            app:cardBackgroundColor="@color/cardBackgroundColor"
            android:layout_width="match_parent"
            android:layout_height="50dp"
            app:cardElevation="@dimen/_10sdp">

            <RelativeLayout
                android:layout_width="match_parent"
                android:layout_height="55dp">

                <TextView
                    android:layout_width="wrap_content"
                    android:layout_height="wrap_content"
                    android:layout_centerVertical="true"
                    android:layout_marginLeft="@dimen/_10sdp"
                    android:text="@string/greeting"
                    android:textStyle="bold"
                    android:textColor="@color/textColor"
                    android:textSize="@dimen/_18sdp" />


            </RelativeLayout>

        </androidx.cardview.widget.CardView>

    </LinearLayout>
    <LinearLayout
        android:id="@+id/searchLay"
        android:layout_below="@id/title_lay"
        android:layout_marginHorizontal="@dimen/_8sdp"
        android:layout_marginBottom="@dimen/_8sdp"
        android:gravity="center"
        android:background="@drawable/strock_bg"
        android:backgroundTint="@color/lightgraycolor"
        android:layout_width="match_parent"
        android:layout_height="43dp"
        android:orientation="horizontal"
        app:layout_constraintEnd_toEndOf="parent"
        app:layout_constraintStart_toStartOf="parent"
        app:layout_constraintTop_toTopOf="parent">
        <EditText
            android:id="@+id/search_et"
            android:background="@null"
            android:layout_marginLeft="@dimen/_8sdp"
            android:layout_weight="1"
            android:inputType="text"
            android:imeOptions="actionSearch"
            android:layout_width="wrap_content"
            android:layout_height="wrap_content"
            android:hint="@string/search_post"
            android:textColor="@color/gray_darl"
            android:textSize="@dimen/_14sdp"/>
        <ImageView
            android:id="@+id/search_btn"
            android:layout_marginRight="@dimen/_5sdp"
            android:background="@drawable/btn"
            android:backgroundTint="@color/app_color"
            android:layout_width="@dimen/_35sdp"
            android:layout_height="@dimen/_35sdp"
            android:src="@drawable/ic_search"
            android:padding="@dimen/_8sdp"
            app:tint="@color/white" />
    </LinearLayout>

    <androidx.swiperefreshlayout.widget.SwipeRefreshLayout
        android:id="@+id/refereshLayout"
        android:orientation="vertical"
        android:layout_width="match_parent"
        android:layout_height="match_parent"
        android:layout_below="@+id/searchLay">
        <androidx.core.widget.NestedScrollView
            android:id="@+id/nestedScroll"
            android:layout_width="match_parent"
            android:layout_height="match_parent">
            <LinearLayout
                android:layout_width="match_parent"
                android:layout_height="match_parent"
                android:orientation="vertical">
                <androidx.recyclerview.widget.RecyclerView
                    android:id="@+id/recyclerview"
                    android:layout_width="match_parent"
                    android:layout_height="match_parent"
                    app:layoutManager="androidx.recyclerview.widget.LinearLayoutManager"
                    android:orientation="vertical"/>
                <com.facebook.shimmer.ShimmerFrameLayout
                    android:layout_below="@id/toolbar"
                    android:id="@+id/shimmerLay"
                    android:layout_width="match_parent"
                    android:layout_height="match_parent">
                    <include
                        layout="@layout/section_placeholder"/>
                </com.facebook.shimmer.ShimmerFrameLayout>
            </LinearLayout>
        </androidx.core.widget.NestedScrollView>
    </androidx.swiperefreshlayout.widget.SwipeRefreshLayout>

    <LinearLayout
        android:id="@+id/no_data_layout"
        android:layout_width="wrap_content"
        android:layout_height="wrap_content"
        android:layout_centerInParent="true"
        android:gravity="center"
        android:orientation="vertical"
        android:visibility="gone">

        <TextView
            android:layout_width="wrap_content"
            android:layout_height="wrap_content"
            android:text="@string/no_item_found"
            android:textColor="@color/textColor"
            android:textSize="15dp"
            android:textStyle="bold" />

        <TextView
            android:layout_width="wrap_content"
            android:layout_height="wrap_content"
            android:text="@string/there_is_no_data_so"
            android:textColor="@color/darkgray"
            android:textSize="15dp" />
    </LinearLayout>

</RelativeLayout>