Added Android code
[wl-app.git] / Android / app / src / main / res / layout / news_item.xml
1 <?xml version="1.0" encoding="utf-8"?>
2 <RelativeLayout 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="wrap_content"
7                 android:padding="10dp">
8
9     <android.support.v7.widget.CardView
10         android:id="@+id/cvNewsThumb"
11         android:layout_width="@dimen/thumb_size"
12         android:layout_height="@dimen/thumb_size"
13         android:layout_centerVertical="true"
14         app:cardCornerRadius="@dimen/thumb_corners">
15
16         <ImageView
17             android:id="@+id/ivNewsThumb"
18             android:layout_width="match_parent"
19             android:layout_height="wrap_content"
20             android:scaleType="centerCrop"
21             android:src="@drawable/list_nocover"
22             tools:ignore="ContentDescription"/>
23     </android.support.v7.widget.CardView>
24
25     <LinearLayout
26         android:layout_width="match_parent"
27         android:layout_height="wrap_content"
28         android:layout_marginStart="@dimen/news_text_box_padding"
29         android:layout_toEndOf="@id/cvNewsThumb"
30         android:orientation="vertical"
31         android:paddingBottom="5dp"
32         android:paddingTop="5dp"
33         tools:ignore="SpUsage">
34
35         <TextView
36             android:id="@+id/textViewDate"
37             style="@style/NewsText.Black"
38             android:layout_width="wrap_content"
39             android:layout_height="wrap_content"
40             android:textAllCaps="true"
41             android:textSize="15dp"/>
42
43         <View
44             android:layout_width="match_parent"
45             android:layout_height="1dp"
46             android:background="@color/gray_dark"/>
47
48         <TextView
49             android:id="@+id/textViewLead"
50             android:layout_width="wrap_content"
51             android:layout_height="wrap_content"
52             android:textColor="@color/colorPrimary"
53             android:textSize="18dp"/>
54     </LinearLayout>
55 </RelativeLayout>