item_spec_rule.xml 1.66 KB
Newer Older
wjg committed
1
<?xml version="1.0" encoding="utf-8"?>
wjg committed
2 3
<androidx.constraintlayout.widget.ConstraintLayout xmlns:android="http://schemas.android.com/apk/res/android"
    xmlns:app="http://schemas.android.com/apk/res-auto"
wjg committed
4
    android:layout_width="wrap_content"
wjg committed
5 6 7 8 9 10 11 12 13 14 15 16
    android:layout_height="wrap_content">
    <TextView
        android:id="@+id/butn_rule"
        android:layout_width="wrap_content"
        android:layout_height="wrap_content"
        android:layout_marginTop="@dimen/padding5"
        android:layout_marginEnd="@dimen/padding10"
        android:background="@drawable/sel_spec_bg"
        android:paddingHorizontal="@dimen/padding10"
        android:paddingVertical="@dimen/rule_vertical_padding"
        android:singleLine="true"
        android:text="加糖"
wjg committed
17
        android:foreground="?selectableItemBackground"
wjg committed
18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37
        android:textColor="@drawable/sel_spec_color"
        android:textSize="@dimen/ts_detail_rule"
        app:layout_constraintLeft_toLeftOf="parent"
        app:layout_constraintRight_toRightOf="parent"
        app:layout_constraintTop_toTopOf="parent" />

    <TextView
        android:id="@+id/txt_recommend"
        android:layout_width="wrap_content"
        android:layout_height="wrap_content"
        android:background="@drawable/bg_spec_recommend"
        android:paddingHorizontal="@dimen/padding5"
        android:paddingVertical="@dimen/padding3"
        android:text="推荐"
        android:textColor="@color/white"
        android:textSize="@dimen/ts_detail_spec_rec"
        android:visibility="gone"
        app:layout_constraintRight_toRightOf="parent"
        app:layout_constraintTop_toTopOf="parent" />
</androidx.constraintlayout.widget.ConstraintLayout>