Skip to content

Commit

Permalink
[FEATURE] #129 : 오늘 날 이미지 애니메이션 적용
Browse files Browse the repository at this point in the history
  • Loading branch information
tgyuuAn committed Feb 18, 2024
1 parent 2827d61 commit 5e9ffce
Showing 1 changed file with 15 additions and 8 deletions.
Original file line number Diff line number Diff line change
@@ -1,5 +1,8 @@
package com.wap.wapp.feature.notice

import androidx.compose.animation.AnimatedVisibility
import androidx.compose.animation.fadeIn
import androidx.compose.animation.fadeOut
import androidx.compose.foundation.Image
import androidx.compose.foundation.background
import androidx.compose.foundation.clickable
Expand Down Expand Up @@ -155,18 +158,22 @@ private fun CalendarHeader(
)
}

if (selectedDate != generateNowDate()) {
AnimatedVisibility(
visible = selectedDate != generateNowDate(),
enter = fadeIn(),
exit = fadeOut(),
modifier = Modifier
.align(Alignment.CenterEnd)
.padding(end = 16.dp),
) {
Image(
painter = painterResource(id = drawable.ic_return),
contentDescription =
stringResource(R.string.return_today_content_description),
modifier = Modifier
.align(Alignment.CenterEnd)
.clickable {
onDateSelected(generateNowDate())
onCalendarMonthChanged()
}
.padding(end = 16.dp),
modifier = Modifier.clickable {
onDateSelected(generateNowDate())
onCalendarMonthChanged()
},
)
}
}
Expand Down

0 comments on commit 5e9ffce

Please sign in to comment.