More rounded corners for Home banner
This commit is contained in:
parent
30282e79fe
commit
3fe882c79c
6 changed files with 8 additions and 8 deletions
|
@ -96,7 +96,7 @@
|
||||||
|
|
||||||
<style name="circleImageView" parent="">
|
<style name="circleImageView" parent="">
|
||||||
<item name="cornerFamily">rounded</item>
|
<item name="cornerFamily">rounded</item>
|
||||||
<item name="cornerSize">16dp</item>
|
<item name="cornerSize">40dp</item>
|
||||||
</style>
|
</style>
|
||||||
|
|
||||||
<style name="BottomSheetItemTextAppearance" parent="Widget.MaterialComponents.BottomNavigationView.Colored">
|
<style name="BottomSheetItemTextAppearance" parent="Widget.MaterialComponents.BottomNavigationView.Colored">
|
||||||
|
|
|
@ -83,10 +83,9 @@ class HomeFragment :
|
||||||
|
|
||||||
private fun setupListeners() {
|
private fun setupListeners() {
|
||||||
binding.bannerImage?.setOnClickListener {
|
binding.bannerImage?.setOnClickListener {
|
||||||
binding.userImage.transitionName = "userImage"
|
|
||||||
findNavController().navigate(
|
findNavController().navigate(
|
||||||
R.id.user_info_fragment, null, null, FragmentNavigatorExtras(
|
R.id.user_info_fragment, null, null, FragmentNavigatorExtras(
|
||||||
binding.userImage to "userImage"
|
binding.userImage to "user_image"
|
||||||
)
|
)
|
||||||
)
|
)
|
||||||
reenterTransition = null
|
reenterTransition = null
|
||||||
|
|
|
@ -39,7 +39,6 @@ import code.name.monkey.retromusic.R
|
||||||
import code.name.monkey.retromusic.databinding.FragmentUserInfoBinding
|
import code.name.monkey.retromusic.databinding.FragmentUserInfoBinding
|
||||||
import code.name.monkey.retromusic.extensions.accentColor
|
import code.name.monkey.retromusic.extensions.accentColor
|
||||||
import code.name.monkey.retromusic.extensions.applyToolbar
|
import code.name.monkey.retromusic.extensions.applyToolbar
|
||||||
import code.name.monkey.retromusic.extensions.resolveColor
|
|
||||||
import code.name.monkey.retromusic.fragments.LibraryViewModel
|
import code.name.monkey.retromusic.fragments.LibraryViewModel
|
||||||
import code.name.monkey.retromusic.glide.GlideApp
|
import code.name.monkey.retromusic.glide.GlideApp
|
||||||
import code.name.monkey.retromusic.glide.RetroGlideExtension
|
import code.name.monkey.retromusic.glide.RetroGlideExtension
|
||||||
|
@ -54,6 +53,7 @@ import com.bumptech.glide.request.target.Target
|
||||||
import com.github.dhaval2404.imagepicker.ImagePicker
|
import com.github.dhaval2404.imagepicker.ImagePicker
|
||||||
import com.github.dhaval2404.imagepicker.constant.ImageProvider
|
import com.github.dhaval2404.imagepicker.constant.ImageProvider
|
||||||
import com.google.android.material.transition.MaterialContainerTransform
|
import com.google.android.material.transition.MaterialContainerTransform
|
||||||
|
import com.google.android.material.transition.MaterialSharedAxis
|
||||||
import kotlinx.coroutines.CoroutineScope
|
import kotlinx.coroutines.CoroutineScope
|
||||||
import kotlinx.coroutines.Dispatchers
|
import kotlinx.coroutines.Dispatchers
|
||||||
import kotlinx.coroutines.launch
|
import kotlinx.coroutines.launch
|
||||||
|
@ -79,7 +79,6 @@ class UserInfoFragment : Fragment() {
|
||||||
drawingViewId = R.id.fragment_container
|
drawingViewId = R.id.fragment_container
|
||||||
duration = 300L
|
duration = 300L
|
||||||
scrimColor = Color.TRANSPARENT
|
scrimColor = Color.TRANSPARENT
|
||||||
setAllContainerColors(requireContext().resolveColor(R.attr.colorSurface))
|
|
||||||
}
|
}
|
||||||
_binding = FragmentUserInfoBinding.inflate(layoutInflater)
|
_binding = FragmentUserInfoBinding.inflate(layoutInflater)
|
||||||
return binding.root
|
return binding.root
|
||||||
|
|
|
@ -79,6 +79,7 @@
|
||||||
android:layout_height="0dp"
|
android:layout_height="0dp"
|
||||||
app:cardCornerRadius="24dp"
|
app:cardCornerRadius="24dp"
|
||||||
app:cardUseCompatPadding="true"
|
app:cardUseCompatPadding="true"
|
||||||
|
android:transitionName="banner_image"
|
||||||
app:layout_constraintDimensionRatio="21:7"
|
app:layout_constraintDimensionRatio="21:7"
|
||||||
app:layout_constraintEnd_toEndOf="parent"
|
app:layout_constraintEnd_toEndOf="parent"
|
||||||
app:layout_constraintStart_toStartOf="parent"
|
app:layout_constraintStart_toStartOf="parent"
|
||||||
|
|
|
@ -74,8 +74,8 @@
|
||||||
android:id="@+id/imageContainer"
|
android:id="@+id/imageContainer"
|
||||||
android:layout_width="0dp"
|
android:layout_width="0dp"
|
||||||
android:layout_height="0dp"
|
android:layout_height="0dp"
|
||||||
app:cardCornerRadius="16dp"
|
app:cardCornerRadius="40dp"
|
||||||
app:cardUseCompatPadding="true"
|
android:layout_margin="16dp"
|
||||||
app:layout_constraintDimensionRatio="21:10"
|
app:layout_constraintDimensionRatio="21:10"
|
||||||
app:layout_constraintEnd_toEndOf="parent"
|
app:layout_constraintEnd_toEndOf="parent"
|
||||||
app:layout_constraintStart_toStartOf="parent"
|
app:layout_constraintStart_toStartOf="parent"
|
||||||
|
|
|
@ -35,12 +35,13 @@
|
||||||
android:id="@+id/bannerImage"
|
android:id="@+id/bannerImage"
|
||||||
android:layout_width="0dp"
|
android:layout_width="0dp"
|
||||||
android:layout_height="0dp"
|
android:layout_height="0dp"
|
||||||
android:layout_margin="8dp"
|
android:layout_margin="16dp"
|
||||||
android:scaleType="centerCrop"
|
android:scaleType="centerCrop"
|
||||||
app:layout_constraintDimensionRatio="21:10"
|
app:layout_constraintDimensionRatio="21:10"
|
||||||
app:layout_constraintEnd_toEndOf="parent"
|
app:layout_constraintEnd_toEndOf="parent"
|
||||||
app:layout_constraintStart_toStartOf="parent"
|
app:layout_constraintStart_toStartOf="parent"
|
||||||
app:layout_constraintTop_toTopOf="parent"
|
app:layout_constraintTop_toTopOf="parent"
|
||||||
|
android:transitionName="banner_image"
|
||||||
app:shapeAppearanceOverlay="@style/circleImageView"
|
app:shapeAppearanceOverlay="@style/circleImageView"
|
||||||
app:srcCompat="@drawable/material_design_default" />
|
app:srcCompat="@drawable/material_design_default" />
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue