diff --git a/app/src/main/java/com/teampome/pome/presentation/mypage/MarshmelloAdapter.kt b/app/src/main/java/com/teampome/pome/presentation/mypage/MarshmelloAdapter.kt
index 1fad78d9..c5b7743b 100644
--- a/app/src/main/java/com/teampome/pome/presentation/mypage/MarshmelloAdapter.kt
+++ b/app/src/main/java/com/teampome/pome/presentation/mypage/MarshmelloAdapter.kt
@@ -1,8 +1,10 @@
package com.teampome.pome.presentation.mypage
+import android.annotation.SuppressLint
import android.content.Context
import android.view.LayoutInflater
import android.view.ViewGroup
+import androidx.core.content.ContextCompat
import androidx.recyclerview.widget.DiffUtil
import androidx.recyclerview.widget.ListAdapter
import androidx.recyclerview.widget.RecyclerView
@@ -36,11 +38,67 @@ class MarshmelloAdapter(
binding.myTabMarshmello = myTabMarshmello
context?.let{
when(myTabMarshmello.marshmelloName) {
- "record" -> Glide.with(context).load(R.drawable.marshmallow_level_4_pink).into(binding.ivArticleImage)
- "emotion" -> Glide.with(context).load(R.drawable.marshmallow_level_2_yellow).into(binding.ivArticleImage)
- "growth" -> Glide.with(context).load(R.drawable.marshmallow_level_4_mint).into(binding.ivArticleImage)
- "honest" -> Glide.with(context).load(R.drawable.ic_mashmellow).into(binding.ivArticleImage)
- else -> Glide.with(context).load(R.drawable.ic_mashmellow).into(binding.ivArticleImage)
+ "record" -> binding.mypageCardRecordTv.text = "기록말랑"
+ "emotion" -> binding.mypageCardRecordTv.text = "공감말랑"
+ "growth" -> binding.mypageCardRecordTv.text = "발전말랑"
+ "honest" -> binding.mypageCardRecordTv.text = "솔직말랑"
+ }
+
+ if(myTabMarshmello.marshmelloLv == 0) {
+ Glide.with(context).load(R.drawable.ic_mashmellow).into(binding.ivArticleImage)
+ binding.mypageCardLevelTv.text = "Lv.1"
+ binding.mypageCardLevelTv.setTextColor(ContextCompat.getColor(context, R.color.grey_4))
+ binding.mypageCardLevelCl.setBackgroundResource(R.drawable.item_gray_oval)
+ binding.mypageCardRecordCl.setBackgroundResource(R.drawable.item_grey1_r8_background)
+ binding.mypageCardRecordTv.setTextColor(ContextCompat.getColor(context, R.color.grey_5))
+ } else if(myTabMarshmello.marshmelloLv == 1) {
+ binding.mypageCardLevelTv.text = "Lv.1"
+ if(myTabMarshmello.marshmelloName == "record") {
+ //기록
+ Glide.with(context).load(R.drawable.marshmallow_level_1_pink).into(binding.ivArticleImage)
+ } else if(myTabMarshmello.marshmelloName == "emotion") {
+ //공감
+ Glide.with(context).load(R.drawable.marshmallow_level_1_blue).into(binding.ivArticleImage)
+ } else if(myTabMarshmello.marshmelloName == "growth") {
+ //발전
+ Glide.with(context).load(R.drawable.marshmallow_level_1_yellow).into(binding.ivArticleImage)
+ } else {
+ //솔직
+ Glide.with(context).load(R.drawable.marshmallow_level_1_mint).into(binding.ivArticleImage)
+ }
+ } else if(myTabMarshmello.marshmelloLv == 2) {
+ binding.mypageCardLevelTv.text = "Lv.2"
+ if(myTabMarshmello.marshmelloName == "record") {
+ Glide.with(context).load(R.drawable.marshmallow_level_2_pink).into(binding.ivArticleImage)
+ } else if(myTabMarshmello.marshmelloName == "emotion") {
+ Glide.with(context).load(R.drawable.marshmallow_level_2_blue).into(binding.ivArticleImage)
+ } else if(myTabMarshmello.marshmelloName == "growth") {
+ Glide.with(context).load(R.drawable.marshmallow_level_2_yellow).into(binding.ivArticleImage)
+ } else {
+ Glide.with(context).load(R.drawable.marshmallow_level_2_mint).into(binding.ivArticleImage)
+ }
+ } else if(myTabMarshmello.marshmelloLv == 3) {
+ binding.mypageCardLevelTv.text = "Lv.3"
+ if(myTabMarshmello.marshmelloName == "record") {
+ Glide.with(context).load(R.drawable.marshmallow_level_3_pink).into(binding.ivArticleImage)
+ } else if(myTabMarshmello.marshmelloName == "emotion") {
+ Glide.with(context).load(R.drawable.marshmallow_level_3_blue).into(binding.ivArticleImage)
+ } else if(myTabMarshmello.marshmelloName == "growth") {
+ Glide.with(context).load(R.drawable.marshmallow_level_3_yellow).into(binding.ivArticleImage)
+ } else {
+ Glide.with(context).load(R.drawable.marshmallow_level_3_mint).into(binding.ivArticleImage)
+ }
+ } else {
+ binding.mypageCardLevelTv.text = "Lv.4"
+ if(myTabMarshmello.marshmelloName == "record") {
+ Glide.with(context).load(R.drawable.marshmallow_level_4_pink).into(binding.ivArticleImage)
+ } else if(myTabMarshmello.marshmelloName == "emotion") {
+ Glide.with(context).load(R.drawable.marshmallow_level_4_blue).into(binding.ivArticleImage)
+ } else if(myTabMarshmello.marshmelloName == "growth") {
+ Glide.with(context).load(R.drawable.marshmallow_level_4_yellow).into(binding.ivArticleImage)
+ } else {
+ Glide.with(context).load(R.drawable.marshmallow_level_4_mint).into(binding.ivArticleImage)
+ }
}
}
}
diff --git a/app/src/main/res/drawable/item_gray_oval.xml b/app/src/main/res/drawable/item_gray_oval.xml
new file mode 100644
index 00000000..0e5107ea
--- /dev/null
+++ b/app/src/main/res/drawable/item_gray_oval.xml
@@ -0,0 +1,4 @@
+
+
+
+
\ No newline at end of file
diff --git a/app/src/main/res/drawable/marshmallow_level_1_blue.png b/app/src/main/res/drawable/marshmallow_level_1_blue.png
new file mode 100644
index 00000000..98c69f9e
Binary files /dev/null and b/app/src/main/res/drawable/marshmallow_level_1_blue.png differ
diff --git a/app/src/main/res/drawable/marshmallow_level_1_mint.png b/app/src/main/res/drawable/marshmallow_level_1_mint.png
new file mode 100644
index 00000000..31418001
Binary files /dev/null and b/app/src/main/res/drawable/marshmallow_level_1_mint.png differ
diff --git a/app/src/main/res/drawable/marshmallow_level_1_pink.png b/app/src/main/res/drawable/marshmallow_level_1_pink.png
new file mode 100644
index 00000000..64748523
Binary files /dev/null and b/app/src/main/res/drawable/marshmallow_level_1_pink.png differ
diff --git a/app/src/main/res/drawable/marshmallow_level_1_yellow.png b/app/src/main/res/drawable/marshmallow_level_1_yellow.png
new file mode 100644
index 00000000..fb23d5ed
Binary files /dev/null and b/app/src/main/res/drawable/marshmallow_level_1_yellow.png differ
diff --git a/app/src/main/res/drawable/marshmallow_level_2_blue.png b/app/src/main/res/drawable/marshmallow_level_2_blue.png
new file mode 100644
index 00000000..e942cc88
Binary files /dev/null and b/app/src/main/res/drawable/marshmallow_level_2_blue.png differ
diff --git a/app/src/main/res/drawable/marshmallow_level_2_mint.png b/app/src/main/res/drawable/marshmallow_level_2_mint.png
new file mode 100644
index 00000000..a8bc8ff4
Binary files /dev/null and b/app/src/main/res/drawable/marshmallow_level_2_mint.png differ
diff --git a/app/src/main/res/drawable/marshmallow_level_2_pink.png b/app/src/main/res/drawable/marshmallow_level_2_pink.png
new file mode 100644
index 00000000..9bab1c3c
Binary files /dev/null and b/app/src/main/res/drawable/marshmallow_level_2_pink.png differ
diff --git a/app/src/main/res/drawable/marshmallow_level_3_blue.png b/app/src/main/res/drawable/marshmallow_level_3_blue.png
new file mode 100644
index 00000000..1db6cad3
Binary files /dev/null and b/app/src/main/res/drawable/marshmallow_level_3_blue.png differ
diff --git a/app/src/main/res/drawable/marshmallow_level_3_mint.png b/app/src/main/res/drawable/marshmallow_level_3_mint.png
new file mode 100644
index 00000000..e590feb6
Binary files /dev/null and b/app/src/main/res/drawable/marshmallow_level_3_mint.png differ
diff --git a/app/src/main/res/drawable/marshmallow_level_3_pink.png b/app/src/main/res/drawable/marshmallow_level_3_pink.png
new file mode 100644
index 00000000..c13ebcd0
Binary files /dev/null and b/app/src/main/res/drawable/marshmallow_level_3_pink.png differ
diff --git a/app/src/main/res/drawable/marshmallow_level_3_yellow.png b/app/src/main/res/drawable/marshmallow_level_3_yellow.png
new file mode 100644
index 00000000..69f8a953
Binary files /dev/null and b/app/src/main/res/drawable/marshmallow_level_3_yellow.png differ
diff --git a/app/src/main/res/drawable/marshmallow_level_4_blue.png b/app/src/main/res/drawable/marshmallow_level_4_blue.png
new file mode 100644
index 00000000..3faa799a
Binary files /dev/null and b/app/src/main/res/drawable/marshmallow_level_4_blue.png differ
diff --git a/app/src/main/res/drawable/marshmallow_level_4_yellow.png b/app/src/main/res/drawable/marshmallow_level_4_yellow.png
new file mode 100644
index 00000000..e82cbcff
Binary files /dev/null and b/app/src/main/res/drawable/marshmallow_level_4_yellow.png differ
diff --git a/app/src/main/res/layout/fragment_mypage.xml b/app/src/main/res/layout/fragment_mypage.xml
index b52cac16..91a9e762 100644
--- a/app/src/main/res/layout/fragment_mypage.xml
+++ b/app/src/main/res/layout/fragment_mypage.xml
@@ -16,121 +16,109 @@
android:id="@+id/mypage_setting_iv"
android:layout_width="wrap_content"
android:layout_height="wrap_content"
+ android:layout_marginTop="16dp"
+ android:layout_marginRight="20dp"
android:src="@drawable/ic_setting"
- app:layout_constraintTop_toTopOf="parent"
app:layout_constraintRight_toRightOf="parent"
- android:layout_marginTop="16dp"
- android:layout_marginRight="20dp"/>
+ app:layout_constraintTop_toTopOf="parent" />
+ app:layout_constraintRight_toRightOf="parent"
+ app:layout_constraintTop_toBottomOf="@+id/mypage_setting_iv" />
+ app:layout_constraintTop_toBottomOf="@id/mypage_profile_iv" />
+ android:background="@drawable/mypage_main_cl"
+ app:layout_constraintTop_toBottomOf="@id/mypage_profile_name_tv">
+ android:src="@drawable/ic_mypage_main_logo"
+ app:layout_constraintBottom_toBottomOf="parent"
+ app:layout_constraintLeft_toLeftOf="parent"
+ app:layout_constraintTop_toTopOf="parent" />
+ app:layout_constraintTop_toTopOf="@id/mypage_main_logo_iv" />
+ app:layout_constraintLeft_toRightOf="@id/mypage_main_logo_iv" />
-
-
+ app:layout_constraintTop_toTopOf="@id/mypage_main_goal_tv" />
+ android:text="@string/mypage_marshmallow_text"
+ android:textColor="@color/grey_9"
+ app:layout_constraintLeft_toLeftOf="parent"
+ app:layout_constraintTop_toBottomOf="@+id/mypage_main_cl" />
-
-
+ app:layout_constraintTop_toBottomOf="@id/mypage_marshmallow_tv"
+ tools:listitem="@layout/item_mypage_card" />
\ No newline at end of file
diff --git a/app/src/main/res/layout/item_mypage_card.xml b/app/src/main/res/layout/item_mypage_card.xml
index 8551de3a..efc8df3d 100644
--- a/app/src/main/res/layout/item_mypage_card.xml
+++ b/app/src/main/res/layout/item_mypage_card.xml
@@ -1,8 +1,7 @@
-
+ xmlns:tools="http://schemas.android.com/tools">
-
-
-
-
-
+
+
+ android:layout_height="wrap_content"
+ android:layout_marginTop="10dp"
+ app:cardCornerRadius="10dp"
+ app:layout_constraintStart_toStartOf="parent"
+ app:layout_constraintTop_toTopOf="parent"
+ app:strokeColor="@color/grey_2"
+ app:strokeWidth="1dp">
-
-
-
+ android:layout_width="match_parent"
+ android:layout_height="match_parent">
-
-
-
-
-
+ app:layout_constraintEnd_toEndOf="parent"
+ app:layout_constraintStart_toStartOf="parent"
+ app:layout_constraintTop_toTopOf="parent">
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
-
-
-
-
-
-
+
-
+
\ No newline at end of file