|
| 1 | +<?xml version="1.0" encoding="utf-8"?> |
| 2 | +<androidx.constraintlayout.widget.ConstraintLayout xmlns:android="http://schemas.android.com/apk/res/android" |
| 3 | + xmlns:app="http://schemas.android.com/apk/res-auto" |
| 4 | + xmlns:tools="http://schemas.android.com/tools" |
| 5 | + android:layout_width="match_parent" |
| 6 | + android:layout_height="match_parent" |
| 7 | + android:background="?attr/colorSurface" |
| 8 | + tools:context=".feature.detail.DetailFragment"> |
| 9 | + |
| 10 | + <Toolbar |
| 11 | + android:id="@+id/toolbar" |
| 12 | + android:layout_width="match_parent" |
| 13 | + android:layout_height="wrap_content" |
| 14 | + android:background="?attr/colorPrimary" |
| 15 | + app:layout_constraintEnd_toEndOf="parent" |
| 16 | + app:layout_constraintStart_toStartOf="parent" |
| 17 | + app:layout_constraintTop_toTopOf="parent" /> |
| 18 | + |
| 19 | + <TextView |
| 20 | + android:id="@+id/textView" |
| 21 | + android:layout_width="wrap_content" |
| 22 | + android:layout_height="wrap_content" |
| 23 | + android:text="@string/product_details" |
| 24 | + android:textColor="?attr/colorSurface" |
| 25 | + android:textStyle="bold" |
| 26 | + app:layout_constraintBottom_toBottomOf="@+id/toolbar" |
| 27 | + app:layout_constraintEnd_toEndOf="parent" |
| 28 | + app:layout_constraintStart_toStartOf="parent" |
| 29 | + app:layout_constraintTop_toTopOf="@+id/toolbar" /> |
| 30 | + |
| 31 | + <ImageButton |
| 32 | + android:id="@+id/btn_cancel" |
| 33 | + android:layout_width="wrap_content" |
| 34 | + android:layout_height="wrap_content" |
| 35 | + android:layout_marginStart="16dp" |
| 36 | + android:background="@null" |
| 37 | + android:contentDescription="@string/cancel" |
| 38 | + android:src="@drawable/ic_cancel" |
| 39 | + app:layout_constraintBottom_toBottomOf="@id/toolbar" |
| 40 | + app:layout_constraintStart_toStartOf="parent" |
| 41 | + app:layout_constraintTop_toTopOf="@id/toolbar" /> |
| 42 | + |
| 43 | + <include |
| 44 | + android:id="@+id/layout_total_price_card" |
| 45 | + layout="@layout/total_price_card" |
| 46 | + android:layout_width="wrap_content" |
| 47 | + android:layout_height="wrap_content" |
| 48 | + android:layout_marginEnd="8dp" |
| 49 | + android:visibility="gone" |
| 50 | + app:layout_constraintBottom_toBottomOf="@+id/toolbar" |
| 51 | + app:layout_constraintEnd_toEndOf="parent" |
| 52 | + app:layout_constraintTop_toTopOf="@+id/toolbar" /> |
| 53 | + |
| 54 | + <ScrollView |
| 55 | + android:id="@+id/scrollView" |
| 56 | + android:layout_width="0dp" |
| 57 | + android:layout_height="0dp" |
| 58 | + app:layout_constraintBottom_toTopOf="@id/frameLayout" |
| 59 | + app:layout_constraintEnd_toEndOf="parent" |
| 60 | + app:layout_constraintStart_toStartOf="parent" |
| 61 | + app:layout_constraintTop_toBottomOf="@id/toolbar"> |
| 62 | + |
| 63 | + <LinearLayout |
| 64 | + android:layout_width="match_parent" |
| 65 | + android:layout_height="wrap_content" |
| 66 | + android:layout_marginBottom="16dp" |
| 67 | + android:gravity="center" |
| 68 | + android:orientation="vertical"> |
| 69 | + |
| 70 | + <ImageView |
| 71 | + android:id="@+id/iv_food" |
| 72 | + android:layout_width="@dimen/detail_image_size" |
| 73 | + android:layout_height="@dimen/detail_image_size" |
| 74 | + android:layout_marginTop="16dp" |
| 75 | + android:contentDescription="@string/food_image" |
| 76 | + android:scaleType="centerCrop" |
| 77 | + tools:src="@drawable/food" /> |
| 78 | + |
| 79 | + <TextView |
| 80 | + android:id="@+id/tv_food_price" |
| 81 | + android:layout_width="match_parent" |
| 82 | + android:layout_height="wrap_content" |
| 83 | + android:layout_marginHorizontal="16dp" |
| 84 | + android:layout_marginTop="16dp" |
| 85 | + android:ellipsize="end" |
| 86 | + android:gravity="center" |
| 87 | + android:maxLines="1" |
| 88 | + android:textColor="?attr/colorPrimary" |
| 89 | + android:textSize="20sp" |
| 90 | + android:textStyle="bold" |
| 91 | + tools:text="@string/_0_00" /> |
| 92 | + |
| 93 | + <TextView |
| 94 | + android:id="@+id/tv_product_name" |
| 95 | + android:layout_width="match_parent" |
| 96 | + android:layout_height="wrap_content" |
| 97 | + android:layout_marginHorizontal="16dp" |
| 98 | + android:ellipsize="end" |
| 99 | + android:gravity="center" |
| 100 | + android:maxLines="2" |
| 101 | + android:textColor="?attr/colorOnSurface" |
| 102 | + android:textAlignment="center" |
| 103 | + android:textFontWeight="600" |
| 104 | + android:textSize="16sp" |
| 105 | + tools:text="Product Name" /> |
| 106 | + |
| 107 | + <TextView |
| 108 | + android:id="@+id/tv_product_attribute" |
| 109 | + android:layout_width="match_parent" |
| 110 | + android:layout_height="wrap_content" |
| 111 | + android:layout_marginHorizontal="16dp" |
| 112 | + android:ellipsize="end" |
| 113 | + android:gravity="center" |
| 114 | + android:maxLines="1" |
| 115 | + android:textColor="?attr/colorSecondary" |
| 116 | + android:textFontWeight="600" |
| 117 | + android:textSize="12sp" |
| 118 | + tools:text="Attribute" /> |
| 119 | + |
| 120 | + <View |
| 121 | + android:layout_width="match_parent" |
| 122 | + android:layout_height="3dp" |
| 123 | + android:layout_marginTop="16dp" |
| 124 | + android:background="@drawable/bg_top_shadow" /> |
| 125 | + </LinearLayout> |
| 126 | + |
| 127 | + </ScrollView> |
| 128 | + |
| 129 | + |
| 130 | + <FrameLayout |
| 131 | + android:id="@+id/frameLayout" |
| 132 | + android:layout_width="match_parent" |
| 133 | + android:layout_height="90dp" |
| 134 | + android:background="?attr/colorSurface" |
| 135 | + app:layout_constraintBottom_toBottomOf="parent" |
| 136 | + app:layout_constraintEnd_toEndOf="parent" |
| 137 | + app:layout_constraintStart_toStartOf="parent"> |
| 138 | + |
| 139 | + <Button |
| 140 | + android:id="@+id/btn_add_to_basket" |
| 141 | + android:layout_width="match_parent" |
| 142 | + android:layout_height="54dp" |
| 143 | + android:layout_gravity="center" |
| 144 | + android:layout_marginHorizontal="16dp" |
| 145 | + android:layout_marginTop="5dp" |
| 146 | + android:background="@drawable/bg_button" |
| 147 | + android:foreground="?attr/selectableItemBackground" |
| 148 | + android:text="@string/add_to_basket" |
| 149 | + android:textStyle="bold" |
| 150 | + android:visibility="gone" /> |
| 151 | + |
| 152 | + <com.patika.getir_lite.ui.ActionCardView |
| 153 | + android:id="@+id/item_action_view" |
| 154 | + android:layout_width="wrap_content" |
| 155 | + android:layout_height="wrap_content" |
| 156 | + android:layout_gravity="center" |
| 157 | + android:translationZ="3dp" |
| 158 | + android:visibility="visible" /> |
| 159 | + |
| 160 | + <View |
| 161 | + android:layout_width="match_parent" |
| 162 | + android:layout_height="10dp" |
| 163 | + android:background="@drawable/bg_top_shadow" /> |
| 164 | + </FrameLayout> |
| 165 | +</androidx.constraintlayout.widget.ConstraintLayout> |
0 commit comments