fix(profile): 프로필 후원 랭킹 왕관 UI 위치와 크기를 통일한다
This commit is contained in:
@@ -14,7 +14,7 @@ class UserProfileDonationAdapter : RecyclerView.Adapter<UserProfileDonationAdapt
|
||||
|
||||
val items = mutableListOf<UserDonationRankingResponse>()
|
||||
|
||||
inner class ViewHolder(
|
||||
class ViewHolder(
|
||||
private val binding: ItemUserProfileDonationBinding
|
||||
) : RecyclerView.ViewHolder(binding.root) {
|
||||
fun bind(item: UserDonationRankingResponse, position: Int) {
|
||||
@@ -28,32 +28,21 @@ class UserProfileDonationAdapter : RecyclerView.Adapter<UserProfileDonationAdapt
|
||||
|
||||
when (position) {
|
||||
0 -> {
|
||||
binding.ivBg.setImageResource(R.drawable.bg_circle_ffdc00_ffb600)
|
||||
binding.ivBg.visibility = View.VISIBLE
|
||||
|
||||
binding.ivCrown.setImageResource(R.drawable.ic_crown_1)
|
||||
binding.ivCrown.setImageResource(R.drawable.img_rank_1)
|
||||
binding.ivCrown.visibility = View.VISIBLE
|
||||
}
|
||||
|
||||
1 -> {
|
||||
binding.ivBg.setImageResource(R.drawable.bg_circle_ffffff_9f9f9f)
|
||||
binding.ivBg.visibility = View.VISIBLE
|
||||
|
||||
binding.ivCrown.setImageResource(R.drawable.ic_crown_2)
|
||||
binding.ivCrown.setImageResource(R.drawable.img_rank_2)
|
||||
binding.ivCrown.visibility = View.VISIBLE
|
||||
}
|
||||
|
||||
2 -> {
|
||||
binding.ivBg.setImageResource(R.drawable.bg_circle_e6a77a_c67e4a)
|
||||
binding.ivBg.visibility = View.VISIBLE
|
||||
|
||||
binding.ivCrown.setImageResource(R.drawable.ic_crown_3)
|
||||
binding.ivCrown.setImageResource(R.drawable.img_rank_3)
|
||||
binding.ivCrown.visibility = View.VISIBLE
|
||||
}
|
||||
|
||||
else -> {
|
||||
binding.ivBg.setImageResource(0)
|
||||
binding.ivBg.visibility = View.GONE
|
||||
binding.ivCrown.visibility = View.GONE
|
||||
}
|
||||
}
|
||||
|
||||
@@ -1,20 +1,14 @@
|
||||
<?xml version="1.0" encoding="utf-8"?>
|
||||
<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
|
||||
xmlns:tools="http://schemas.android.com/tools"
|
||||
android:layout_width="76dp"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:gravity="center"
|
||||
android:orientation="vertical">
|
||||
|
||||
<RelativeLayout
|
||||
android:layout_width="76dp"
|
||||
android:layout_height="76dp">
|
||||
|
||||
<ImageView
|
||||
android:id="@+id/iv_bg"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="match_parent"
|
||||
android:contentDescription="@null" />
|
||||
android:layout_width="90dp"
|
||||
android:layout_height="87.5dp">
|
||||
|
||||
<ImageView
|
||||
android:id="@+id/iv_profile"
|
||||
@@ -26,10 +20,10 @@
|
||||
|
||||
<ImageView
|
||||
android:id="@+id/iv_crown"
|
||||
android:layout_width="wrap_content"
|
||||
android:layout_height="wrap_content"
|
||||
android:layout_alignParentEnd="true"
|
||||
android:layout_alignParentBottom="true"
|
||||
android:layout_width="match_parent"
|
||||
android:layout_height="match_parent"
|
||||
android:layout_centerInParent="true"
|
||||
android:layout_gravity="center"
|
||||
android:contentDescription="@null" />
|
||||
</RelativeLayout>
|
||||
|
||||
|
||||
Reference in New Issue
Block a user