fix: some UI changes pt:2
This commit is contained in:
parent
2742f58af5
commit
e0cd43c63c
14 changed files with 96 additions and 62 deletions
|
@ -115,7 +115,7 @@
|
||||||
android:windowSoftInputMode="adjustResize|stateHidden"
|
android:windowSoftInputMode="adjustResize|stateHidden"
|
||||||
android:parentActivityName=".MainActivity" />
|
android:parentActivityName=".MainActivity" />
|
||||||
<activity
|
<activity
|
||||||
android:name=".profile.ActivityActivity"
|
android:name=".profile.activity.ActivityActivity"
|
||||||
android:label="Inbox Activity"
|
android:label="Inbox Activity"
|
||||||
android:parentActivityName=".MainActivity" >
|
android:parentActivityName=".MainActivity" >
|
||||||
</activity>
|
</activity>
|
||||||
|
|
|
@ -2,6 +2,7 @@ package ani.dantotsu.profile
|
||||||
|
|
||||||
import android.content.Intent
|
import android.content.Intent
|
||||||
import android.os.Bundle
|
import android.os.Bundle
|
||||||
|
import android.view.View
|
||||||
import android.view.ViewGroup.MarginLayoutParams
|
import android.view.ViewGroup.MarginLayoutParams
|
||||||
import android.widget.ImageButton
|
import android.widget.ImageButton
|
||||||
import androidx.appcompat.app.AppCompatActivity
|
import androidx.appcompat.app.AppCompatActivity
|
||||||
|
@ -47,7 +48,7 @@ class FollowActivity : AppCompatActivity(){
|
||||||
false
|
false
|
||||||
)
|
)
|
||||||
binding.listRecyclerView.adapter = adapter
|
binding.listRecyclerView.adapter = adapter
|
||||||
|
binding.listProgressBar.visibility = View.VISIBLE
|
||||||
binding.listBack.setOnClickListener { finish() }
|
binding.listBack.setOnClickListener { finish() }
|
||||||
|
|
||||||
val title = intent.getStringExtra("title")
|
val title = intent.getStringExtra("title")
|
||||||
|
@ -63,6 +64,7 @@ class FollowActivity : AppCompatActivity(){
|
||||||
users = respond
|
users = respond
|
||||||
withContext(Dispatchers.Main) {
|
withContext(Dispatchers.Main) {
|
||||||
fillList()
|
fillList()
|
||||||
|
binding.listProgressBar.visibility = View.GONE
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
binding.followerList.setOnClickListener {
|
binding.followerList.setOnClickListener {
|
||||||
|
@ -86,7 +88,7 @@ class FollowActivity : AppCompatActivity(){
|
||||||
}
|
}
|
||||||
users?.forEach { user ->
|
users?.forEach { user ->
|
||||||
if (getLayoutType(selected) == 0) {
|
if (getLayoutType(selected) == 0) {
|
||||||
adapter.add(FollowerItem(user.id, user.name ?: "Unknown", user.avatar?.medium, user.bannerImage) { onUserClick(it) })
|
adapter.add(FollowerItem(user.id, user.name ?: "Unknown", user.avatar?.medium, user.bannerImage ?: user.avatar?.medium ) { onUserClick(it) })
|
||||||
} else {
|
} else {
|
||||||
adapter.add(GridFollowerItem(user.id, user.name ?: "Unknown", user.avatar?.medium) { onUserClick(it) })
|
adapter.add(GridFollowerItem(user.id, user.name ?: "Unknown", user.avatar?.medium) { onUserClick(it) })
|
||||||
}
|
}
|
||||||
|
|
|
@ -33,7 +33,7 @@ class FollowerItem(
|
||||||
Glide.with(context as Context)
|
Glide.with(context as Context)
|
||||||
.load(GlideUrl(banner))
|
.load(GlideUrl(banner))
|
||||||
.diskCacheStrategy(DiskCacheStrategy.ALL).override(400)
|
.diskCacheStrategy(DiskCacheStrategy.ALL).override(400)
|
||||||
.apply(RequestOptions.bitmapTransform(BlurTransformation(2, 6)))
|
.apply(RequestOptions.bitmapTransform(BlurTransformation(2, 2)))
|
||||||
.into(binding.profileBannerImage)
|
.into(binding.profileBannerImage)
|
||||||
} else {
|
} else {
|
||||||
binding.profileBannerImage.setImageResource(R.drawable.linear_gradient_bg)
|
binding.profileBannerImage.setImageResource(R.drawable.linear_gradient_bg)
|
||||||
|
|
|
@ -22,6 +22,7 @@ import ani.dantotsu.initActivity
|
||||||
import ani.dantotsu.loadImage
|
import ani.dantotsu.loadImage
|
||||||
import ani.dantotsu.navBarHeight
|
import ani.dantotsu.navBarHeight
|
||||||
import ani.dantotsu.others.ImageViewDialog
|
import ani.dantotsu.others.ImageViewDialog
|
||||||
|
import ani.dantotsu.profile.activity.ActivityActivity
|
||||||
import ani.dantotsu.settings.saving.PrefManager
|
import ani.dantotsu.settings.saving.PrefManager
|
||||||
import ani.dantotsu.settings.saving.PrefName
|
import ani.dantotsu.settings.saving.PrefName
|
||||||
import ani.dantotsu.snackString
|
import ani.dantotsu.snackString
|
||||||
|
|
|
@ -1,4 +1,4 @@
|
||||||
package ani.dantotsu.profile
|
package ani.dantotsu.profile.activity
|
||||||
|
|
||||||
import android.annotation.SuppressLint
|
import android.annotation.SuppressLint
|
||||||
import android.os.Bundle
|
import android.os.Bundle
|
||||||
|
@ -11,11 +11,12 @@ import ani.dantotsu.connections.anilist.Anilist
|
||||||
import ani.dantotsu.connections.anilist.api.Activity
|
import ani.dantotsu.connections.anilist.api.Activity
|
||||||
import ani.dantotsu.databinding.ActivityFollowBinding
|
import ani.dantotsu.databinding.ActivityFollowBinding
|
||||||
import ani.dantotsu.initActivity
|
import ani.dantotsu.initActivity
|
||||||
import ani.dantotsu.profile.activity.ActivityItem
|
|
||||||
import ani.dantotsu.statusBarHeight
|
import ani.dantotsu.statusBarHeight
|
||||||
import ani.dantotsu.themes.ThemeManager
|
import ani.dantotsu.themes.ThemeManager
|
||||||
import com.xwray.groupie.GroupieAdapter
|
import com.xwray.groupie.GroupieAdapter
|
||||||
|
import kotlinx.coroutines.Dispatchers
|
||||||
import kotlinx.coroutines.launch
|
import kotlinx.coroutines.launch
|
||||||
|
import kotlinx.coroutines.withContext
|
||||||
|
|
||||||
class ActivityActivity : AppCompatActivity() {
|
class ActivityActivity : AppCompatActivity() {
|
||||||
private lateinit var binding: ActivityFollowBinding
|
private lateinit var binding: ActivityFollowBinding
|
||||||
|
@ -39,16 +40,20 @@ class ActivityActivity : AppCompatActivity() {
|
||||||
binding.listBack.setOnClickListener {
|
binding.listBack.setOnClickListener {
|
||||||
onBackPressed()
|
onBackPressed()
|
||||||
}
|
}
|
||||||
|
binding.listProgressBar.visibility = ViewGroup.VISIBLE
|
||||||
var userId: Int? = intent.getIntExtra("userId", -1)
|
var userId: Int? = intent.getIntExtra("userId", -1)
|
||||||
if (userId == -1) userId = null
|
if (userId == -1) userId = null
|
||||||
val global = intent.getBooleanExtra("global", false)
|
val global = intent.getBooleanExtra("global", false)
|
||||||
|
|
||||||
lifecycleScope.launch {
|
lifecycleScope.launch(Dispatchers.IO) {
|
||||||
val res = Anilist.query.getFeed(userId, global)
|
val res = Anilist.query.getFeed(userId, global)
|
||||||
res?.data?.page?.activities?.let { activities ->
|
|
||||||
activityList = activities
|
withContext(Dispatchers.Main){
|
||||||
adapter.update(activityList.map { ActivityItem(it){} })
|
res?.data?.page?.activities?.let { activities ->
|
||||||
|
activityList = activities
|
||||||
|
adapter.update(activityList.map { ActivityItem(it){} })
|
||||||
|
}
|
||||||
|
binding.listProgressBar.visibility = ViewGroup.GONE
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
|
@ -1,5 +1,6 @@
|
||||||
package ani.dantotsu.profile.activity
|
package ani.dantotsu.profile.activity
|
||||||
|
|
||||||
|
import android.annotation.SuppressLint
|
||||||
import android.content.Context
|
import android.content.Context
|
||||||
import android.view.View
|
import android.view.View
|
||||||
import androidx.core.content.ContextCompat
|
import androidx.core.content.ContextCompat
|
||||||
|
@ -19,6 +20,7 @@ class ActivityItem(
|
||||||
val clickCallback: (Int) -> Unit
|
val clickCallback: (Int) -> Unit
|
||||||
): BindableItem<ItemActivityBinding>() {
|
): BindableItem<ItemActivityBinding>() {
|
||||||
private lateinit var binding: ItemActivityBinding
|
private lateinit var binding: ItemActivityBinding
|
||||||
|
@SuppressLint("SetTextI18n")
|
||||||
override fun bind(viewBinding: ItemActivityBinding, position: Int) {
|
override fun bind(viewBinding: ItemActivityBinding, position: Int) {
|
||||||
binding = viewBinding
|
binding = viewBinding
|
||||||
when (activity.typename) {
|
when (activity.typename) {
|
||||||
|
@ -31,19 +33,20 @@ class ActivityItem(
|
||||||
else
|
else
|
||||||
ContextCompat.getColor(binding.root.context, R.color.bg_opp)
|
ContextCompat.getColor(binding.root.context, R.color.bg_opp)
|
||||||
binding.activityFavorite.setColorFilter(color)
|
binding.activityFavorite.setColorFilter(color)
|
||||||
|
binding.activityFavoriteCount.text = activity.likeCount.toString()
|
||||||
binding.activityMediaName.text = activity.media?.title?.userPreferred
|
binding.activityMediaName.text = activity.media?.title?.userPreferred
|
||||||
binding.activityText.text = "${activity.user!!.name} ${activity.status} ${activity.media!!.title!!.userPreferred}"
|
binding.activityText.text = "${activity.user!!.name} ${activity.status} ${activity.progress ?: ""}"
|
||||||
binding.activityCover.loadImage(activity.media.coverImage?.medium)
|
binding.activityCover.loadImage(activity.media?.coverImage?.large)
|
||||||
val context = binding.root.context
|
val context = binding.root.context
|
||||||
val banner = activity.media.bannerImage
|
val banner = activity.media?.bannerImage ?: activity.media?.coverImage?.large
|
||||||
if (banner != null) {
|
if (banner != null) {
|
||||||
if (!(context as android.app.Activity).isDestroyed)
|
if (!(context as android.app.Activity).isDestroyed) {
|
||||||
Glide.with(context as Context)
|
Glide.with(context as Context)
|
||||||
.load(GlideUrl(banner))
|
.load(GlideUrl(banner))
|
||||||
.diskCacheStrategy(DiskCacheStrategy.ALL).override(400)
|
.diskCacheStrategy(DiskCacheStrategy.ALL).override(400)
|
||||||
.apply(RequestOptions.bitmapTransform(BlurTransformation(2, 2)))
|
.apply(RequestOptions.bitmapTransform(BlurTransformation(2, 2)))
|
||||||
.into(binding.activityBannerImage)
|
.into(binding.activityBannerImage)
|
||||||
|
}
|
||||||
} else {
|
} else {
|
||||||
binding.activityBannerImage.setImageResource(R.drawable.linear_gradient_bg)
|
binding.activityBannerImage.setImageResource(R.drawable.linear_gradient_bg)
|
||||||
}
|
}
|
||||||
|
|
|
@ -18,7 +18,9 @@ import ani.dantotsu.profile.ProfileActivity
|
||||||
import ani.dantotsu.statusBarHeight
|
import ani.dantotsu.statusBarHeight
|
||||||
import ani.dantotsu.themes.ThemeManager
|
import ani.dantotsu.themes.ThemeManager
|
||||||
import com.xwray.groupie.GroupieAdapter
|
import com.xwray.groupie.GroupieAdapter
|
||||||
|
import kotlinx.coroutines.Dispatchers
|
||||||
import kotlinx.coroutines.launch
|
import kotlinx.coroutines.launch
|
||||||
|
import kotlinx.coroutines.withContext
|
||||||
|
|
||||||
class NotificationActivity : AppCompatActivity() {
|
class NotificationActivity : AppCompatActivity() {
|
||||||
private lateinit var binding: ActivityFollowBinding
|
private lateinit var binding: ActivityFollowBinding
|
||||||
|
@ -41,13 +43,16 @@ class NotificationActivity : AppCompatActivity() {
|
||||||
binding.listBack.setOnClickListener {
|
binding.listBack.setOnClickListener {
|
||||||
onBackPressed()
|
onBackPressed()
|
||||||
}
|
}
|
||||||
|
binding.listProgressBar.visibility = ViewGroup.VISIBLE
|
||||||
lifecycleScope.launch {
|
lifecycleScope.launch {
|
||||||
val res = Anilist.query.getNotifications(Anilist.userid?:0)
|
val res = Anilist.query.getNotifications(Anilist.userid?:0)
|
||||||
res?.data?.page?.notifications?.let { notifications ->
|
res?.data?.page?.notifications?.let { notifications ->
|
||||||
notificationList = notifications
|
notificationList = notifications
|
||||||
adapter.update(notificationList.map { NotificationItem(it, ::onNotificationClick) })
|
adapter.update(notificationList.map { NotificationItem(it, ::onNotificationClick) })
|
||||||
}
|
}
|
||||||
|
withContext(Dispatchers.Main){
|
||||||
|
binding.listProgressBar.visibility = ViewGroup.GONE
|
||||||
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -38,7 +38,7 @@ class NotificationItem(
|
||||||
|
|
||||||
private fun image(user: Boolean = false) {
|
private fun image(user: Boolean = false) {
|
||||||
val context = binding.notificationBannerImage.context
|
val context = binding.notificationBannerImage.context
|
||||||
val cover = if (user) notification.user?.bannerImage else notification.media?.bannerImage
|
val cover = if (user) notification.user?.bannerImage ?: notification.user?.avatar?.medium else notification.media?.bannerImage ?: notification.media?.coverImage?.large
|
||||||
if (cover != null) {
|
if (cover != null) {
|
||||||
if (!(context as Activity).isDestroyed)
|
if (!(context as Activity).isDestroyed)
|
||||||
Glide.with(context as Context)
|
Glide.with(context as Context)
|
||||||
|
@ -50,7 +50,7 @@ class NotificationItem(
|
||||||
binding.notificationBannerImage.setImageResource(R.drawable.linear_gradient_bg)
|
binding.notificationBannerImage.setImageResource(R.drawable.linear_gradient_bg)
|
||||||
}
|
}
|
||||||
val defaultHeight = TypedValue.applyDimension(TypedValue.COMPLEX_UNIT_DIP, 170f, context.resources.displayMetrics).toInt()
|
val defaultHeight = TypedValue.applyDimension(TypedValue.COMPLEX_UNIT_DIP, 170f, context.resources.displayMetrics).toInt()
|
||||||
val userHeight = TypedValue.applyDimension(TypedValue.COMPLEX_UNIT_DIP, 80f, context.resources.displayMetrics).toInt()
|
val userHeight = TypedValue.applyDimension(TypedValue.COMPLEX_UNIT_DIP, 90f, context.resources.displayMetrics).toInt()
|
||||||
|
|
||||||
if (user) {
|
if (user) {
|
||||||
binding.notificationCover.visibility = View.GONE
|
binding.notificationCover.visibility = View.GONE
|
||||||
|
@ -58,14 +58,12 @@ class NotificationItem(
|
||||||
binding.notificationCoverUserContainer.visibility = View.VISIBLE
|
binding.notificationCoverUserContainer.visibility = View.VISIBLE
|
||||||
binding.notificationCoverUser.loadImage(notification.user?.avatar?.large)
|
binding.notificationCoverUser.loadImage(notification.user?.avatar?.large)
|
||||||
binding.notificationBannerImage.layoutParams.height = userHeight
|
binding.notificationBannerImage.layoutParams.height = userHeight
|
||||||
binding.notificationBannerGradient.layoutParams.height = userHeight
|
|
||||||
} else{
|
} else{
|
||||||
binding.notificationCover.visibility = View.VISIBLE
|
binding.notificationCover.visibility = View.VISIBLE
|
||||||
binding.notificationCoverUser.visibility = View.VISIBLE
|
binding.notificationCoverUser.visibility = View.VISIBLE
|
||||||
binding.notificationCoverUserContainer.visibility = View.GONE
|
binding.notificationCoverUserContainer.visibility = View.GONE
|
||||||
binding.notificationCover.loadImage(notification.media?.coverImage?.large)
|
binding.notificationCover.loadImage(notification.media?.coverImage?.large)
|
||||||
binding.notificationBannerImage.layoutParams.height = defaultHeight
|
binding.notificationBannerImage.layoutParams.height = defaultHeight
|
||||||
binding.notificationBannerGradient.layoutParams.height = defaultHeight
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -65,7 +65,6 @@ class SettingsDialogFragment : BottomSheetDialogFragment() {
|
||||||
R.drawable.ic_round_notifications_none_24
|
R.drawable.ic_round_notifications_none_24
|
||||||
}
|
}
|
||||||
binding.settingsNotification.setImageResource(notificationIcon)
|
binding.settingsNotification.setImageResource(notificationIcon)
|
||||||
binding.settingsNotification.visibility = View.VISIBLE
|
|
||||||
|
|
||||||
if (Anilist.token != null) {
|
if (Anilist.token != null) {
|
||||||
binding.settingsLogin.setText(R.string.logout)
|
binding.settingsLogin.setText(R.string.logout)
|
||||||
|
|
|
@ -6,13 +6,18 @@
|
||||||
android:layout_height="match_parent"
|
android:layout_height="match_parent"
|
||||||
android:orientation="vertical">
|
android:orientation="vertical">
|
||||||
|
|
||||||
<ProgressBar
|
<LinearLayout
|
||||||
android:id="@+id/listProgressBar"
|
android:id="@+id/listProgressBar"
|
||||||
style="?android:attr/progressBarStyle"
|
android:layout_width="match_parent"
|
||||||
android:layout_width="wrap_content"
|
android:layout_height="match_parent"
|
||||||
android:layout_height="wrap_content"
|
android:gravity="center"
|
||||||
android:layout_gravity="center"
|
tools:visibility="gone">
|
||||||
android:visibility="gone" />
|
|
||||||
|
<ProgressBar
|
||||||
|
style="?android:attr/progressBarStyle"
|
||||||
|
android:layout_width="wrap_content"
|
||||||
|
android:layout_height="wrap_content" />
|
||||||
|
</LinearLayout>
|
||||||
|
|
||||||
<FrameLayout
|
<FrameLayout
|
||||||
android:id="@+id/listToolbar"
|
android:id="@+id/listToolbar"
|
||||||
|
|
|
@ -78,13 +78,14 @@
|
||||||
|
|
||||||
<FrameLayout
|
<FrameLayout
|
||||||
android:layout_width="wrap_content"
|
android:layout_width="wrap_content"
|
||||||
android:layout_height="wrap_content">
|
android:layout_height="wrap_content"
|
||||||
|
android:layout_marginTop="4dp"
|
||||||
|
android:layout_marginEnd="16dp">
|
||||||
|
|
||||||
<com.google.android.material.card.MaterialCardView
|
<com.google.android.material.card.MaterialCardView
|
||||||
android:layout_width="52dp"
|
android:layout_width="52dp"
|
||||||
android:layout_height="52dp"
|
android:layout_height="52dp"
|
||||||
android:layout_marginTop="4dp"
|
|
||||||
android:layout_marginEnd="16dp"
|
|
||||||
android:backgroundTint="@color/nav_bg_inv"
|
android:backgroundTint="@color/nav_bg_inv"
|
||||||
app:cardCornerRadius="26dp">
|
app:cardCornerRadius="26dp">
|
||||||
|
|
||||||
|
|
|
@ -18,8 +18,9 @@
|
||||||
android:layout_height="64dp"
|
android:layout_height="64dp"
|
||||||
android:layout_gravity="start|center_vertical"
|
android:layout_gravity="start|center_vertical"
|
||||||
android:layout_marginStart="16dp"
|
android:layout_marginStart="16dp"
|
||||||
android:backgroundTint="@color/bg_white"
|
android:backgroundTint="@color/transparent"
|
||||||
app:cardCornerRadius="64dp">
|
app:cardCornerRadius="64dp"
|
||||||
|
app:strokeColor="@color/transparent">
|
||||||
|
|
||||||
<com.google.android.material.imageview.ShapeableImageView
|
<com.google.android.material.imageview.ShapeableImageView
|
||||||
android:id="@+id/activityUserAvatar"
|
android:id="@+id/activityUserAvatar"
|
||||||
|
@ -60,21 +61,35 @@
|
||||||
|
|
||||||
</LinearLayout>
|
</LinearLayout>
|
||||||
|
|
||||||
<ImageView
|
<LinearLayout
|
||||||
android:id="@+id/activityFavorite"
|
|
||||||
android:layout_width="wrap_content"
|
android:layout_width="wrap_content"
|
||||||
android:layout_height="wrap_content"
|
android:layout_height="wrap_content"
|
||||||
android:layout_gravity="end|center"
|
android:layout_gravity="end|center"
|
||||||
android:layout_marginEnd="16dp"
|
android:layout_marginEnd="16dp"
|
||||||
android:src="@drawable/ic_round_favorite_24"
|
android:orientation="vertical">
|
||||||
tools:ignore="ContentDescription" />
|
|
||||||
|
<ImageView
|
||||||
|
android:id="@+id/activityFavorite"
|
||||||
|
android:layout_width="wrap_content"
|
||||||
|
android:layout_height="wrap_content"
|
||||||
|
android:src="@drawable/ic_round_favorite_24"
|
||||||
|
tools:ignore="ContentDescription" />
|
||||||
|
|
||||||
|
<TextView
|
||||||
|
android:id="@+id/activityFavoriteCount"
|
||||||
|
android:layout_width="wrap_content"
|
||||||
|
android:layout_height="wrap_content"
|
||||||
|
android:layout_gravity="center"
|
||||||
|
android:fontFamily="@font/poppins_semi_bold"
|
||||||
|
android:textSize="15sp"
|
||||||
|
tools:text="12" />
|
||||||
|
</LinearLayout>
|
||||||
|
|
||||||
</LinearLayout>
|
</LinearLayout>
|
||||||
|
|
||||||
<FrameLayout
|
<FrameLayout
|
||||||
android:layout_width="match_parent"
|
android:layout_width="match_parent"
|
||||||
android:layout_height="180dp"
|
android:layout_height="180dp">
|
||||||
android:layout_marginTop="8dp">
|
|
||||||
|
|
||||||
<com.google.android.material.card.MaterialCardView
|
<com.google.android.material.card.MaterialCardView
|
||||||
android:layout_width="match_parent"
|
android:layout_width="match_parent"
|
||||||
|
@ -86,15 +101,15 @@
|
||||||
<ImageView
|
<ImageView
|
||||||
android:id="@+id/activityBannerImage"
|
android:id="@+id/activityBannerImage"
|
||||||
android:layout_width="match_parent"
|
android:layout_width="match_parent"
|
||||||
android:layout_height="153dp"
|
android:layout_height="169dp"
|
||||||
android:scaleType="centerCrop"
|
android:scaleType="centerCrop"
|
||||||
tools:srcCompat="@tools:sample/backgrounds/scenic"
|
tools:ignore="ContentDescription"
|
||||||
tools:ignore="ContentDescription" />
|
tools:srcCompat="@tools:sample/backgrounds/scenic" />
|
||||||
|
|
||||||
<ImageView
|
<ImageView
|
||||||
android:id="@+id/imageView"
|
android:id="@+id/imageView"
|
||||||
android:layout_width="match_parent"
|
android:layout_width="match_parent"
|
||||||
android:layout_height="153dp"
|
android:layout_height="170dp"
|
||||||
app:srcCompat="@drawable/linear_gradient_nav"
|
app:srcCompat="@drawable/linear_gradient_nav"
|
||||||
tools:ignore="ContentDescription" />
|
tools:ignore="ContentDescription" />
|
||||||
|
|
||||||
|
@ -113,6 +128,7 @@
|
||||||
android:layout_width="102dp"
|
android:layout_width="102dp"
|
||||||
android:layout_height="154dp"
|
android:layout_height="154dp"
|
||||||
android:layout_gravity="center"
|
android:layout_gravity="center"
|
||||||
|
android:scaleType="centerCrop"
|
||||||
app:srcCompat="@drawable/ic_round_add_circle_24"
|
app:srcCompat="@drawable/ic_round_add_circle_24"
|
||||||
tools:ignore="ContentDescription,ImageContrastCheck"
|
tools:ignore="ContentDescription,ImageContrastCheck"
|
||||||
tools:tint="@color/transparent" />
|
tools:tint="@color/transparent" />
|
||||||
|
|
|
@ -9,7 +9,7 @@
|
||||||
|
|
||||||
<com.google.android.material.card.MaterialCardView
|
<com.google.android.material.card.MaterialCardView
|
||||||
android:layout_width="match_parent"
|
android:layout_width="match_parent"
|
||||||
android:layout_height="80dp"
|
android:layout_height="90dp"
|
||||||
android:layout_gravity="start|center_vertical"
|
android:layout_gravity="start|center_vertical"
|
||||||
android:backgroundTint="@color/bg_white"
|
android:backgroundTint="@color/bg_white"
|
||||||
app:cardCornerRadius="24dp">
|
app:cardCornerRadius="24dp">
|
||||||
|
|
|
@ -1,8 +1,8 @@
|
||||||
<?xml version="1.0" encoding="utf-8"?>
|
<?xml version="1.0" encoding="utf-8"?>
|
||||||
<FrameLayout xmlns:android="http://schemas.android.com/apk/res/android"
|
<FrameLayout xmlns:android="http://schemas.android.com/apk/res/android"
|
||||||
android:id="@+id/notificationContainer"
|
|
||||||
xmlns:app="http://schemas.android.com/apk/res-auto"
|
xmlns:app="http://schemas.android.com/apk/res-auto"
|
||||||
xmlns:tools="http://schemas.android.com/tools"
|
xmlns:tools="http://schemas.android.com/tools"
|
||||||
|
android:id="@+id/notificationContainer"
|
||||||
android:layout_width="match_parent"
|
android:layout_width="match_parent"
|
||||||
android:layout_height="wrap_content"
|
android:layout_height="wrap_content"
|
||||||
android:layout_margin="8dp"
|
android:layout_margin="8dp"
|
||||||
|
@ -20,13 +20,12 @@
|
||||||
android:layout_width="match_parent"
|
android:layout_width="match_parent"
|
||||||
android:layout_height="170dp"
|
android:layout_height="170dp"
|
||||||
android:scaleType="centerCrop"
|
android:scaleType="centerCrop"
|
||||||
tools:srcCompat="@tools:sample/backgrounds/scenic"
|
tools:ignore="ContentDescription"
|
||||||
tools:ignore="ContentDescription" />
|
tools:srcCompat="@tools:sample/backgrounds/scenic" />
|
||||||
|
|
||||||
<ImageView
|
<ImageView
|
||||||
android:id="@+id/notificationBannerGradient"
|
|
||||||
android:layout_width="match_parent"
|
android:layout_width="match_parent"
|
||||||
android:layout_height="170dp"
|
android:layout_height="match_parent"
|
||||||
app:srcCompat="@drawable/linear_gradient_nav"
|
app:srcCompat="@drawable/linear_gradient_nav"
|
||||||
tools:ignore="ContentDescription" />
|
tools:ignore="ContentDescription" />
|
||||||
|
|
||||||
|
@ -37,30 +36,30 @@
|
||||||
android:layout_gravity="start|center_vertical"
|
android:layout_gravity="start|center_vertical"
|
||||||
android:layout_marginStart="16dp"
|
android:layout_marginStart="16dp"
|
||||||
android:backgroundTint="@color/transparent"
|
android:backgroundTint="@color/transparent"
|
||||||
app:strokeColor="@color/transparent"
|
app:cardCornerRadius="16dp"
|
||||||
app:cardCornerRadius="16dp">
|
app:strokeColor="@color/transparent">
|
||||||
|
|
||||||
<com.google.android.material.imageview.ShapeableImageView
|
<com.google.android.material.imageview.ShapeableImageView
|
||||||
android:id="@+id/notificationCover"
|
android:id="@+id/notificationCover"
|
||||||
android:layout_width="96dp"
|
android:layout_width="96dp"
|
||||||
android:layout_height="144dp"
|
android:layout_height="144dp"
|
||||||
android:layout_gravity="center"
|
android:layout_gravity="center"
|
||||||
android:scaleType="centerCrop"
|
|
||||||
app:srcCompat="@drawable/ic_round_add_circle_24"
|
app:srcCompat="@drawable/ic_round_add_circle_24"
|
||||||
tools:ignore="ContentDescription,ImageContrastCheck"
|
tools:ignore="ContentDescription,ImageContrastCheck"
|
||||||
tools:tint="@color/transparent" />
|
tools:tint="@color/transparent" />
|
||||||
|
|
||||||
</com.google.android.material.card.MaterialCardView>
|
</com.google.android.material.card.MaterialCardView>
|
||||||
|
|
||||||
<com.google.android.material.card.MaterialCardView
|
<com.google.android.material.card.MaterialCardView
|
||||||
android:id="@+id/notificationCoverUserContainer"
|
android:id="@+id/notificationCoverUserContainer"
|
||||||
android:layout_width="wrap_content"
|
android:layout_width="wrap_content"
|
||||||
android:layout_height="wrap_content"
|
android:layout_height="wrap_content"
|
||||||
android:visibility="gone"
|
|
||||||
android:layout_gravity="start|center_vertical"
|
android:layout_gravity="start|center_vertical"
|
||||||
android:layout_marginStart="23dp"
|
android:layout_marginStart="23dp"
|
||||||
android:backgroundTint="@color/transparent"
|
android:backgroundTint="@color/transparent"
|
||||||
app:strokeColor="@color/transparent"
|
android:visibility="gone"
|
||||||
app:cardCornerRadius="64dp">
|
app:cardCornerRadius="64dp"
|
||||||
|
app:strokeColor="@color/transparent">
|
||||||
|
|
||||||
<com.google.android.material.imageview.ShapeableImageView
|
<com.google.android.material.imageview.ShapeableImageView
|
||||||
android:id="@+id/notificationCoverUser"
|
android:id="@+id/notificationCoverUser"
|
||||||
|
@ -77,8 +76,8 @@
|
||||||
android:layout_width="wrap_content"
|
android:layout_width="wrap_content"
|
||||||
android:layout_height="wrap_content"
|
android:layout_height="wrap_content"
|
||||||
android:layout_gravity="start|center"
|
android:layout_gravity="start|center"
|
||||||
android:orientation="vertical"
|
android:layout_marginStart="125dp"
|
||||||
android:layout_marginStart="125dp">
|
android:orientation="vertical">
|
||||||
|
|
||||||
<TextView
|
<TextView
|
||||||
android:id="@+id/notificationText"
|
android:id="@+id/notificationText"
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue