<?xml version="1.0" encoding="utf-8"?>
<com.tubb.smrv.SwipeHorizontalMenuLayout
    xmlns:android="http://schemas.android.com/apk/res/android"
    xmlns:sml="http://schemas.android.com/apk/res-auto"
    xmlns:tools="http://schemas.android.com/tools"
    android:id="@+id/swipe_layout"
    android:layout_width="match_parent"
    android:layout_height="wrap_content"
    sml:sml_auto_open_percent="0.2"
    sml:sml_scroller_duration="250"
    sml:sml_scroller_interpolator="@android:anim/bounce_interpolator">

    <LinearLayout
        android:id="@id/smMenuViewLeft"
        android:layout_width="wrap_content"
        android:layout_height="match_parent"
        android:orientation="horizontal">

        <TextView
            android:id="@+id/btn_add_main"
            android:layout_width="wrap_content"
            android:layout_height="@dimen/item_menu_height"
            android:layout_gravity="left|center_vertical"
            android:background="@drawable/blue"
            android:textAppearance="@style/TextAppearance.AppCompat.Body1"
            android:gravity="center"
            android:text="@string/card_add_main"
            android:textColor="@color/white"/>

        <TextView
            android:id="@+id/btn_add_side"
            android:layout_width="wrap_content"
            android:layout_height="@dimen/item_menu_height"
            android:layout_gravity="right|center_vertical"
            android:background="@drawable/red"
            android:gravity="center"
            android:textAppearance="@style/TextAppearance.AppCompat.Body1"
            android:text="@string/card_add_side"
            android:textColor="@color/white"/>

    </LinearLayout>

    <LinearLayout
        android:id="@id/smContentView"
        android:layout_width="match_parent"
        android:layout_height="wrap_content"
        android:layout_margin="@dimen/padding"
        android:orientation="horizontal" >

        <RelativeLayout
            android:layout_width="@dimen/card_small_width"
            android:layout_height="@dimen/card_small_height">

            <ImageView
                android:id="@+id/card_image"
                android:layout_width="match_parent"
                android:layout_height="match_parent"
                android:layout_centerHorizontal="true"
                android:layout_centerVertical="true"
                android:layout_gravity="center_vertical"
                android:scaleType="fitXY"
                tools:src="@drawable/unknown"/>

            <ImageView
                android:id="@+id/right_top"
                android:layout_width="@dimen/right_size"
                android:layout_height="@dimen/right_size"
                android:layout_alignParentRight="true"
                android:visibility="visible"
                tools:src="@drawable/ic_close_black_24dp"/>
        </RelativeLayout>

        <LinearLayout
            android:layout_width="match_parent"
            android:layout_height="wrap_content"
            android:layout_marginLeft="10dp"
            android:orientation="vertical"
            >

            <cn.garymb.ygomobile.ui.widget.AlwaysMarqueeTextView
                android:id="@+id/card_name"
                android:layout_width="match_parent"
                android:layout_height="wrap_content"
                android:maxLines="1"
                android:shadowColor="@color/black"
                android:shadowDx="1"
                android:shadowDy="2"
                android:shadowRadius="2"
                android:singleLine="true"
                android:textAppearance="@style/TextAppearance.AppCompat.Title"
                android:textColor="@color/item_title"
                android:textSize="18sp"
                tools:text="Card Name"/>

            <TextView
                android:id="@+id/card_level"
                android:layout_width="match_parent"
                android:layout_height="wrap_content"
                android:maxLines="1"
                android:shadowColor="@color/black"
                android:shadowDx="1"
                android:shadowDy="1"
                android:shadowRadius="2"
                android:singleLine="true"
                android:textAppearance="@style/TextAppearance.AppCompat.Body1"
                android:textColor="@color/star"
                tools:text="★★★★"/>

            <TextView
                android:id="@+id/card_type"
                android:layout_width="match_parent"
                android:layout_height="wrap_content"
                android:maxLines="1"
                android:singleLine="true"
                android:textAppearance="@style/TextAppearance.AppCompat.Body1"
                android:textColor="@color/holo_blue_bright"
                android:textSize="15sp"
                tools:text="[A/XYZ]"/>

            <View
                android:id="@+id/view_bar"
                android:layout_width="match_parent"
                android:layout_height="1dp"
                android:layout_marginTop="3dp"
                android:background="@color/gray"/>

            <LinearLayout
                android:layout_width="match_parent"
                android:layout_height="wrap_content"
                android:layout_marginTop="3dp"
                android:orientation="horizontal"
                >

                <TextView
                    android:id="@+id/card_code"
                    android:layout_width="wrap_content"
                    android:layout_height="match_parent"
                    android:gravity="center_vertical"
                    android:maxLines="1"
                    android:singleLine="true"
                    android:textAppearance="@style/TextAppearance.AppCompat.Caption"
                    android:textColor="@color/holo_blue_bright"
                    tools:text="123456789"/>

                <TextView
                    android:layout_width="1px"
                    android:layout_height="wrap_content"
                    android:text="A"
                    android:textAppearance="@style/TextAppearance.AppCompat.Body1"
                    android:textColor="@color/colorPrimary"
                    android:visibility="invisible"/>

                <View
                    android:layout_width="0dp"
                    android:layout_height="1dp"
                    android:layout_weight="1"
                    />

                <LinearLayout
                    android:id="@+id/layout_atk"
                    android:layout_width="wrap_content"
                    android:layout_height="wrap_content">

                    <TextView
                        android:layout_width="wrap_content"
                        android:layout_height="wrap_content"
                        android:maxLines="1"
                        android:singleLine="true"
                        android:text="ATK/"
                        android:textAppearance="@style/TextAppearance.AppCompat.Body1"
                        android:textColor="@android:color/holo_green_light"/>

                    <TextView
                        android:id="@+id/card_atk"
                        android:layout_width="wrap_content"
                        android:layout_height="wrap_content"
                        android:gravity="right"
                        android:maxLines="1"
                        android:minWidth="@dimen/label_width_small_32dp"
                        android:singleLine="true"
                        android:textAppearance="@style/TextAppearance.AppCompat.Body1"
                        android:textColor="@color/holo_blue_bright"
                        tools:text="2500"/>

                    <View
                        android:layout_width="5dp"
                        android:layout_height="1dp"/>


                </LinearLayout>

                <LinearLayout
                    android:id="@+id/layout_def"
                    android:layout_width="wrap_content"
                    android:layout_height="wrap_content">

                    <TextView
                        android:id="@+id/TextDef"
                        android:layout_width="wrap_content"
                        android:layout_height="wrap_content"
                        android:maxLines="1"
                        android:singleLine="true"
                        android:text="DEF/"
                        android:textAppearance="@style/TextAppearance.AppCompat.Body1"
                        android:textColor="@android:color/holo_green_light"/>

                    <TextView
                        android:id="@+id/card_def"
                        android:layout_width="wrap_content"
                        android:layout_height="wrap_content"
                        android:gravity="right"
                        android:maxLines="1"
                        android:minWidth="@dimen/label_width_small_32dp"
                        android:singleLine="true"
                        android:textAppearance="@style/TextAppearance.AppCompat.Body1"
                        android:textColor="@color/holo_blue_bright"
                        tools:text="2500"/>
                </LinearLayout>
            </LinearLayout>
        </LinearLayout>
    </LinearLayout>
</com.tubb.smrv.SwipeHorizontalMenuLayout>