<?
xml version=
"1.0" encoding=
"utf-8"?>
<RelativeLayout
xmlns:android=
"http://schemas.android.com/apk/res/android"
xmlns:app=
"http://schemas.android.com/apk/res-auto"
xmlns:tools=
"http://schemas.android.com/tools"
android:layout_width=
"match_parent"
android:layout_height=
"wrap_content"
android:background=
"@drawable/listitem_background_selector"
android:orientation=
"vertical"
android:paddingHorizontal=
"@dimen/listitem_contacts_margin_left_right"
android:paddingVertical=
"@dimen/listitem_contacts_margin_top_bottom">
<ch.threema.app.ui.InitialAvatarView
android:
id=
"@+id/avatar_view"
android:layout_width=
"@dimen/avatar_size_small"
android:layout_height=
"@dimen/avatar_size_small"
android:layout_alignParentLeft=
"true"
android:layout_centerVertical=
"true"
android:layout_toEndOf=
"@id/status"
android:clickable=
"false"
android:contentDescription=
"@string/mime_contact" />
<RelativeLayout
android:layout_width=
"wrap_content"
android:layout_height=
"wrap_content"
android:layout_centerVertical=
"true"
android:layout_marginLeft=
"@dimen/messagelist_avatar_padding"
android:layout_toLeftOf=
"@id/status"
android:layout_toRightOf=
"@id/avatar_view">
<TextView
android:
id=
"@+id/name"
android:layout_width=
"wrap_content"
android:layout_height=
"wrap_content"
android:layout_alignWithParentIfMissing=
"true"
android:layout_alignParentLeft=
"true"
android:layout_toLeftOf=
"@+id/identity"
android:ellipsize=
"end"
android:singleLine=
"true"
android:textAppearance=
"@style/Threema.TextAppearance.List.FirstLine"
tools:text=
"@tools:sample/first_names" />
<TextView
android:
id=
"@+id/identity"
android:layout_width=
"wrap_content"
android:layout_height=
"wrap_content"
android:layout_alignWithParentIfMissing=
"true"
android:layout_alignBaseline=
"@id/name"
android:layout_alignParentRight=
"true"
android:ellipsize=
"none"
android:singleLine=
"true"
android:textAppearance=
"@style/Threema.TextAppearance.List.ThirdLine"
tools:text=
"00000000" />
<com.google.android.material.chip.Chip
android:
id=
"@+id/organization"
android:layout_width=
"wrap_content"
android:layout_height=
"wrap_content"
android:layout_alignBaseline=
"@+id/categories"
android:layout_alignParentLeft=
"true"
android:layout_marginRight=
"6dp"
android:checkable=
"false"
android:clickable=
"false"
android:ellipsize=
"end"
android:maxWidth=
"128dp"
android:singleLine=
"true"
android:textAppearance=
"?android:attr/textAppearanceSmall"
android:textColor=
"@android:color/white"
app:chipBackgroundColor=
"?attr/colorPrimary"
app:chipEndPadding=
"0dp"
app:chipMinHeight=
"0dp"
app:chipMinTouchTargetSize=
"0dp"
app:chipStartPadding=
"0dp"
app:ensureMinTouchTargetSize=
"false"
app:shapeAppearance=
"@style/Threema.ShapeAppearanceDirectoryOrganization"
app:textEndPadding=
"8dp"
app:textStartPadding=
"8dp"
tools:text=
"Organization name" />
<TextView
android:
id=
"@+id/categories"
android:layout_width=
"wrap_content"
android:layout_height=
"wrap_content"
android:layout_below=
"@id/name"
android:layout_toRightOf=
"@+id/organization"
android:ellipsize=
"end"
android:fontFamily=
"sans-serif-light"
android:singleLine=
"true"
android:textAppearance=
"?android:attr/textAppearanceSmall"
tools:text=
"category1, category2" />
</RelativeLayout>
<ImageView
android:
id=
"@+id/status"
android:layout_width=
"28dp"
android:layout_height=
"28dp"
android:layout_alignParentRight=
"true"
android:layout_centerVertical=
"true"
android:layout_marginLeft=
"8dp"
android:background=
"?selectableItemBackground"
android:clickable=
"true"
android:contentDescription=
"@string/menu_add_contact"
android:focusable=
"true"
android:visibility=
"visible"
app:srcCompat=
"@drawable/ic_add_circle_outline_black_24dp"
app:tint=
"?attr/colorOnSurface" />
</RelativeLayout>