85 lines
3.6 KiB
XML
85 lines
3.6 KiB
XML
<?xml version="1.0" encoding="utf-8"?>
|
||
<!-- This Source Code Form is subject to the terms of the Mozilla Public
|
||
- License, v. 2.0. If a copy of the MPL was not distributed with this
|
||
- file, You can obtain one at http://mozilla.org/MPL/2.0/. -->
|
||
<androidx.cardview.widget.CardView 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:id="@+id/collection_item_tab"
|
||
android:layout_width="match_parent"
|
||
android:layout_height="wrap_content"
|
||
android:layout_marginBottom="8dp"
|
||
android:layout_marginTop="8dp"
|
||
android:clickable="true"
|
||
android:clipToPadding="false"
|
||
android:focusable="true"
|
||
android:foreground="?android:attr/selectableItemBackground"
|
||
app:cardBackgroundColor="?above"
|
||
app:cardCornerRadius="@dimen/tab_corner_radius"
|
||
app:cardElevation="5dp">
|
||
|
||
<androidx.constraintlayout.widget.ConstraintLayout
|
||
android:layout_width="match_parent"
|
||
android:layout_height="wrap_content">
|
||
|
||
<ImageView
|
||
android:id="@+id/favicon_image"
|
||
android:layout_width="0dp"
|
||
android:layout_height="0dp"
|
||
android:layout_margin="8dp"
|
||
android:adjustViewBounds="true"
|
||
android:importantForAccessibility="no"
|
||
android:scaleType="fitCenter"
|
||
app:layout_constraintBottom_toBottomOf="parent"
|
||
app:layout_constraintDimensionRatio="1:1"
|
||
app:layout_constraintStart_toStartOf="parent"
|
||
app:layout_constraintTop_toTopOf="parent"
|
||
tools:srcCompat="@tools:sample/avatars" />
|
||
|
||
<TextView
|
||
android:id="@+id/hostname"
|
||
android:layout_width="0dp"
|
||
android:layout_height="wrap_content"
|
||
android:layout_marginStart="8dp"
|
||
android:ellipsize="none"
|
||
android:singleLine="true"
|
||
android:textColor="?secondaryText"
|
||
android:textSize="12sp"
|
||
android:textStyle="bold"
|
||
app:layout_constraintStart_toEndOf="@id/favicon_image"
|
||
app:layout_constraintTop_toTopOf="@id/favicon_image"
|
||
tools:text="@tools:sample/lorem" />
|
||
|
||
<TextView
|
||
android:id="@+id/tab_title"
|
||
android:layout_width="0dp"
|
||
android:layout_height="wrap_content"
|
||
android:layout_marginStart="8dp"
|
||
android:layout_marginTop="4dp"
|
||
android:layout_marginBottom="8dp"
|
||
android:ellipsize="end"
|
||
android:maxLines="2"
|
||
android:minLines="2"
|
||
android:textColor="?primaryText"
|
||
android:textSize="15sp"
|
||
app:layout_constraintBottom_toBottomOf="parent"
|
||
app:layout_constraintEnd_toStartOf="@id/tab_selected_checkbox"
|
||
app:layout_constraintStart_toEndOf="@id/favicon_image"
|
||
app:layout_constraintTop_toBottomOf="@id/hostname"
|
||
tools:text="@tools:sample/lorem/random" />
|
||
|
||
<CheckBox
|
||
android:id="@+id/tab_selected_checkbox"
|
||
android:layout_width="wrap_content"
|
||
android:layout_height="wrap_content"
|
||
android:layout_margin="8dp"
|
||
android:buttonTint="@color/tab_checkbox_tint"
|
||
android:clickable="false"
|
||
android:elevation="1dp"
|
||
app:layout_constraintBottom_toBottomOf="parent"
|
||
app:layout_constraintEnd_toEndOf="parent"
|
||
app:layout_constraintTop_toTopOf="parent"
|
||
tools:text="" />
|
||
</androidx.constraintlayout.widget.ConstraintLayout>
|
||
</androidx.cardview.widget.CardView>
|