146 lines
6.5 KiB
XML
146 lines
6.5 KiB
XML
<?xml version="1.0" encoding="utf-8"?>
|
|
<com.google.android.material.card.MaterialCardView 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/cv_content"
|
|
android:layout_width="match_parent"
|
|
android:layout_height="wrap_content"
|
|
app:cardBackgroundColor="@android:color/transparent"
|
|
android:layout_marginBottom="4dp"
|
|
android:clickable="true"
|
|
android:focusable="true"
|
|
app:strokeWidth="0dp"
|
|
app:layout_constraintTop_toTopOf="parent">
|
|
|
|
<LinearLayout
|
|
android:layout_width="match_parent"
|
|
android:layout_height="wrap_content"
|
|
android:orientation="vertical">
|
|
|
|
<com.google.android.material.card.MaterialCardView
|
|
android:id="@+id/cd_cover"
|
|
android:layout_width="match_parent"
|
|
android:layout_height="match_parent"
|
|
app:cardBackgroundColor="@android:color/transparent"
|
|
app:cardCornerRadius="6dp"
|
|
android:layout_marginHorizontal="8dp"
|
|
android:layout_marginTop="8dp"
|
|
android:transitionName="img_cover"
|
|
app:strokeWidth="0dp">
|
|
|
|
<androidx.constraintlayout.widget.ConstraintLayout
|
|
android:layout_width="match_parent"
|
|
android:layout_height="wrap_content">
|
|
|
|
<io.legado.app.ui.widget.image.CoverImageView
|
|
android:id="@+id/iv_cover"
|
|
android:layout_width="match_parent"
|
|
android:layout_height="match_parent"
|
|
android:scaleType="centerCrop"
|
|
android:src="@drawable/image_cover_default"
|
|
tools:ignore="ImageContrastCheck" />
|
|
|
|
<com.google.android.material.progressindicator.LinearProgressIndicator
|
|
android:id="@+id/rl_loading"
|
|
android:layout_width="match_parent"
|
|
android:layout_height="wrap_content"
|
|
android:layout_marginVertical="4dp"
|
|
android:layout_marginHorizontal="12dp"
|
|
android:indeterminate="true"
|
|
android:visibility="invisible"
|
|
android:layout_gravity="top"
|
|
app:layout_constraintEnd_toEndOf="parent"
|
|
app:layout_constraintStart_toStartOf="parent"
|
|
app:layout_constraintTop_toTopOf="parent" />
|
|
|
|
<com.google.android.material.card.MaterialCardView
|
|
android:id="@+id/cd_unread"
|
|
android:layout_width="wrap_content"
|
|
android:layout_height="wrap_content"
|
|
android:layout_margin="4dp"
|
|
android:visibility="visible"
|
|
app:cardCornerRadius="4dp"
|
|
app:strokeWidth="0dp"
|
|
app:cardBackgroundColor="?attr/colorSecondaryVariant"
|
|
app:layout_constraintEnd_toEndOf="parent"
|
|
app:layout_constraintTop_toTopOf="parent">
|
|
|
|
<LinearLayout
|
|
android:layout_width="match_parent"
|
|
android:layout_height="wrap_content"
|
|
android:gravity="center_vertical"
|
|
android:orientation="horizontal">
|
|
|
|
<com.google.android.material.circularreveal.cardview.CircularRevealCardView
|
|
android:id="@+id/new_chapter"
|
|
android:layout_width="6dp"
|
|
android:layout_height="6dp"
|
|
android:visibility="gone"
|
|
android:layout_marginStart="6dp"
|
|
app:strokeWidth="0dp"
|
|
app:cardBackgroundColor="?attr/colorSecondaryContainer" />
|
|
|
|
<TextView
|
|
android:id="@+id/tv_unread"
|
|
android:layout_width="wrap_content"
|
|
android:layout_height="wrap_content"
|
|
android:textColor="?attr/colorOnSecondary"
|
|
android:textSize="9sp"
|
|
android:padding="4dp"
|
|
android:textStyle="bold"
|
|
android:includeFontPadding="false"
|
|
tools:text="5"
|
|
tools:ignore="SmallSp" />
|
|
</LinearLayout>
|
|
|
|
</com.google.android.material.card.MaterialCardView>
|
|
|
|
<com.google.android.material.card.MaterialCardView
|
|
android:id="@+id/cd_tip"
|
|
android:layout_width="wrap_content"
|
|
android:layout_height="wrap_content"
|
|
android:layout_margin="4dp"
|
|
android:visibility="visible"
|
|
app:cardCornerRadius="4dp"
|
|
app:strokeWidth="0dp"
|
|
app:cardBackgroundColor="?attr/colorSecondaryVariant"
|
|
app:layout_constraintStart_toStartOf="parent"
|
|
app:layout_constraintBottom_toBottomOf="parent">
|
|
|
|
<TextView
|
|
android:id="@+id/tv_tip"
|
|
android:layout_width="wrap_content"
|
|
android:layout_height="wrap_content"
|
|
android:textColor="?attr/colorOnSecondary"
|
|
android:textSize="8sp"
|
|
android:padding="3dp"
|
|
android:textStyle="bold"
|
|
android:includeFontPadding="false"
|
|
tools:text="5"
|
|
tools:ignore="SmallSp" />
|
|
|
|
</com.google.android.material.card.MaterialCardView>
|
|
|
|
</androidx.constraintlayout.widget.ConstraintLayout>
|
|
|
|
</com.google.android.material.card.MaterialCardView>
|
|
|
|
<!-- 书名 -->
|
|
<TextView
|
|
android:id="@+id/tv_name"
|
|
android:layout_width="match_parent"
|
|
android:layout_height="wrap_content"
|
|
android:layout_marginTop="4dp"
|
|
android:layout_marginBottom="6dp"
|
|
android:layout_marginHorizontal="8dp"
|
|
android:ellipsize="end"
|
|
android:gravity="left"
|
|
android:lines="2"
|
|
android:text="@string/book_name"
|
|
android:textSize="12sp"
|
|
android:textStyle="bold"
|
|
tools:ignore="RtlHardcoded" />
|
|
</LinearLayout>
|
|
</com.google.android.material.card.MaterialCardView>
|
|
|