Round manga info cover

This commit is contained in:
arkon 2020-04-18 11:59:22 -04:00
parent 85e7b78b21
commit e388f0d563
3 changed files with 24 additions and 15 deletions

View File

@ -20,7 +20,7 @@
android:layout_width="0dp" android:layout_width="0dp"
android:layout_height="0dp" android:layout_height="0dp"
android:layout_marginTop="16dp" android:layout_marginTop="16dp"
app:layout_constraintTop_toBottomOf="@+id/manga_cover" /> app:layout_constraintTop_toBottomOf="@+id/manga_cover_card" />
<androidx.constraintlayout.widget.Guideline <androidx.constraintlayout.widget.Guideline
android:id="@+id/guideline2" android:id="@+id/guideline2"
@ -40,20 +40,28 @@
app:layout_constraintTop_toTopOf="parent" app:layout_constraintTop_toTopOf="parent"
tools:background="@color/material_grey_700" /> tools:background="@color/material_grey_700" />
<ImageView <androidx.cardview.widget.CardView
android:id="@+id/manga_cover" android:id="@+id/manga_cover_card"
android:layout_width="0dp" android:layout_width="0dp"
android:layout_height="0dp" android:layout_height="0dp"
android:layout_marginStart="16dp" android:layout_marginStart="16dp"
android:layout_marginTop="16dp" android:layout_marginTop="16dp"
android:layout_marginEnd="16dp" android:layout_marginEnd="16dp"
android:layout_marginBottom="16dp" android:layout_marginBottom="16dp"
android:contentDescription="@string/description_cover" app:cardCornerRadius="@dimen/card_radius"
app:layout_constraintDimensionRatio="h,2:3" app:layout_constraintDimensionRatio="h,2:3"
app:layout_constraintEnd_toStartOf="@+id/guideline2" app:layout_constraintEnd_toStartOf="@+id/guideline2"
app:layout_constraintStart_toStartOf="parent" app:layout_constraintStart_toStartOf="parent"
app:layout_constraintTop_toTopOf="parent" app:layout_constraintTop_toTopOf="parent">
tools:background="@color/material_grey_700" />
<ImageView
android:id="@+id/manga_cover"
android:layout_width="match_parent"
android:layout_height="match_parent"
android:contentDescription="@string/description_cover"
tools:background="@color/material_grey_700" />
</androidx.cardview.widget.CardView>
<androidx.constraintlayout.widget.ConstraintLayout <androidx.constraintlayout.widget.ConstraintLayout
android:layout_width="0dp" android:layout_width="0dp"
@ -195,14 +203,14 @@
android:text="@string/add_to_library" android:text="@string/add_to_library"
app:icon="@drawable/ic_add_to_library_24dp" /> app:icon="@drawable/ic_add_to_library_24dp" />
<!-- <com.google.android.material.button.MaterialButton--> <!-- <com.google.android.material.button.MaterialButton-->
<!-- android:id="@+id/btn_tracking"--> <!-- android:id="@+id/btn_tracking"-->
<!-- style="@style/Theme.Widget.Button.Icon"--> <!-- style="@style/Theme.Widget.Button.Icon"-->
<!-- android:layout_width="wrap_content"--> <!-- android:layout_width="wrap_content"-->
<!-- android:layout_height="wrap_content"--> <!-- android:layout_height="wrap_content"-->
<!-- android:layout_marginStart="8dp"--> <!-- android:layout_marginStart="8dp"-->
<!-- android:text="@string/manga_tracking_tab"--> <!-- android:text="@string/manga_tracking_tab"-->
<!-- app:icon="@drawable/ic_sync_24dp" />--> <!-- app:icon="@drawable/ic_sync_24dp" />-->
<com.google.android.material.button.MaterialButton <com.google.android.material.button.MaterialButton
android:id="@+id/btn_share" android:id="@+id/btn_share"

View File

@ -11,7 +11,7 @@
android:id="@+id/card" android:id="@+id/card"
android:layout_width="wrap_content" android:layout_width="wrap_content"
android:layout_height="220dp" android:layout_height="220dp"
app:cardCornerRadius="4dp"> app:cardCornerRadius="@dimen/card_radius">
<ImageView <ImageView
android:id="@+id/thumbnail" android:id="@+id/thumbnail"

View File

@ -7,6 +7,7 @@
<dimen name="margin_left">16dp</dimen> <dimen name="margin_left">16dp</dimen>
<dimen name="margin_right">16dp</dimen> <dimen name="margin_right">16dp</dimen>
<dimen name="space_between_cards">4dp</dimen> <dimen name="space_between_cards">4dp</dimen>
<dimen name="card_radius">4dp</dimen>
<dimen name="fab_size">56dp</dimen> <dimen name="fab_size">56dp</dimen>
<dimen name="fab_margin">16dp</dimen> <dimen name="fab_margin">16dp</dimen>