mirror of
https://github.com/sudoxnym/habitica-android.git
synced 2026-07-30 10:40:37 +00:00
44 lines
1.9 KiB
XML
44 lines
1.9 KiB
XML
|
|
<?xml version="1.0" encoding="utf-8"?>
|
||
|
|
<layout xmlns:android="http://schemas.android.com/apk/res/android"
|
||
|
|
xmlns:bind="http://schemas.android.com/apk/res-auto"
|
||
|
|
xmlns:tools="http://schemas.android.com/tools">
|
||
|
|
<data>
|
||
|
|
<variable name="text" type="String"/>
|
||
|
|
<variable name="notes" type="String"/>
|
||
|
|
<variable name="imageNamed" type="String"/>
|
||
|
|
</data>
|
||
|
|
<LinearLayout
|
||
|
|
android:layout_width="match_parent"
|
||
|
|
android:layout_height="wrap_content"
|
||
|
|
android:minHeight="60dp"
|
||
|
|
android:padding="5dp"
|
||
|
|
android:paddingTop="8dp"
|
||
|
|
android:paddingBottom="8dp"
|
||
|
|
android:clickable="true"
|
||
|
|
android:background="@drawable/btn_habit_background">
|
||
|
|
<ImageView
|
||
|
|
android:layout_width="@dimen/avatar_width"
|
||
|
|
android:layout_height="@dimen/avatar_height"
|
||
|
|
bind:imageName='@{imageNamed == null ? "head_0" : imageNamed}'
|
||
|
|
android:contentDescription="@{imageNamed}"
|
||
|
|
android:alpha="@{imageNamed == null ? 0.4f : 1.0f}"
|
||
|
|
android:scaleType="fitEnd"/>
|
||
|
|
<LinearLayout
|
||
|
|
android:layout_width="match_parent"
|
||
|
|
android:layout_height="wrap_content"
|
||
|
|
android:orientation="vertical">
|
||
|
|
<TextView android:layout_margin="5dp"
|
||
|
|
android:layout_width="match_parent"
|
||
|
|
android:layout_height="wrap_content"
|
||
|
|
android:text="@{text != null ? text : @string/avatar_nothing}"
|
||
|
|
tools:text="Text"
|
||
|
|
android:textStyle="bold"/>
|
||
|
|
<TextView android:layout_margin="5dp"
|
||
|
|
android:layout_width="match_parent"
|
||
|
|
android:layout_height="wrap_content"
|
||
|
|
android:textColor="@android:color/darker_gray"
|
||
|
|
tools:text="Value"
|
||
|
|
android:text="@{notes}" />
|
||
|
|
</LinearLayout>
|
||
|
|
</LinearLayout>
|
||
|
|
</layout>
|