diff --git a/core/designresource/src/main/res/drawable/ic_return.xml b/core/designresource/src/main/res/drawable/ic_return.xml new file mode 100644 index 000000000..6ff659c14 --- /dev/null +++ b/core/designresource/src/main/res/drawable/ic_return.xml @@ -0,0 +1,9 @@ + + + diff --git a/feature/notice/src/main/java/com/wap/wapp/feature/notice/BottomSheetContent.kt b/feature/notice/src/main/java/com/wap/wapp/feature/notice/BottomSheetContent.kt index 026b044b0..b2080d045 100644 --- a/feature/notice/src/main/java/com/wap/wapp/feature/notice/BottomSheetContent.kt +++ b/feature/notice/src/main/java/com/wap/wapp/feature/notice/BottomSheetContent.kt @@ -97,7 +97,9 @@ private fun EventsList( LazyColumn( contentPadding = PaddingValues(horizontal = 15.dp), verticalArrangement = Arrangement.spacedBy(12.dp), - modifier = Modifier.fillMaxWidth(), + modifier = Modifier + .fillMaxWidth() + .padding(top = 12.dp), ) { items( items = events, @@ -118,11 +120,11 @@ private fun EventsList( ) { Image( painter = painterResource(id = R.drawable.ic_cat), - contentDescription = stringResource(id = R.string.bottomSheetCatContentDescription), + contentDescription = stringResource(id = R.string.cat_content_description), ) Text( - text = stringResource(id = R.string.bottomSheetNoEvent), + text = stringResource(id = R.string.bottomSheet_no_event), style = WappTheme.typography.titleMedium, color = WappTheme.colors.white, textAlign = TextAlign.Center, diff --git a/feature/notice/src/main/java/com/wap/wapp/feature/notice/Calendar.kt b/feature/notice/src/main/java/com/wap/wapp/feature/notice/Calendar.kt index d4b3e894e..abf870e94 100644 --- a/feature/notice/src/main/java/com/wap/wapp/feature/notice/Calendar.kt +++ b/feature/notice/src/main/java/com/wap/wapp/feature/notice/Calendar.kt @@ -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 @@ -35,7 +38,9 @@ import com.wap.wapp.core.commmon.util.DateUtil.DAYS_IN_WEEK import com.wap.wapp.core.commmon.util.DateUtil.DaysOfWeek import com.wap.wapp.core.commmon.util.DateUtil.YEAR_MONTH_END_INDEX import com.wap.wapp.core.commmon.util.DateUtil.YEAR_MONTH_START_INDEX +import com.wap.wapp.core.commmon.util.DateUtil.generateNowDate import com.wap.wapp.core.commmon.util.DateUtil.yyyyMMddFormatter +import com.wap.wapp.core.designresource.R.drawable import kotlinx.coroutines.CoroutineScope import kotlinx.coroutines.launch import java.time.DayOfWeek @@ -104,7 +109,7 @@ private fun CalendarHeader( Image( painter = painterResource(id = R.drawable.ic_threelines), contentDescription = - stringResource(R.string.calendarToggleImageContextDescription), + stringResource(R.string.calendar_content_description), modifier = Modifier .align(Alignment.CenterStart) .clickable { @@ -121,8 +126,8 @@ private fun CalendarHeader( modifier = Modifier.align(Alignment.Center), ) { Image( - painter = painterResource(id = com.wap.wapp.core.designresource.R.drawable.ic_back), - contentDescription = stringResource(id = R.string.backMonthArrowContentDescription), + painter = painterResource(id = drawable.ic_back), + contentDescription = stringResource(id = R.string.back_month_arrow_content_description), modifier = Modifier .padding(end = 20.dp) .clickable { @@ -141,8 +146,9 @@ private fun CalendarHeader( ) Image( - painter = painterResource(id = com.wap.wapp.core.designresource.R.drawable.ic_forward), - contentDescription = stringResource(id = R.string.forwardMonthArrowContentDescription), + painter = painterResource(id = drawable.ic_forward), + contentDescription = + stringResource(id = R.string.forward_month_arrow_content_description), modifier = Modifier .padding(start = 20.dp) .clickable { @@ -151,6 +157,25 @@ private fun CalendarHeader( }, ) } + + 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.clickable { + onDateSelected(generateNowDate()) + onCalendarMonthChanged() + }, + ) + } } @Composable diff --git a/feature/notice/src/main/res/values/strings.xml b/feature/notice/src/main/res/values/strings.xml index f978b7ac2..9240c522d 100644 --- a/feature/notice/src/main/res/values/strings.xml +++ b/feature/notice/src/main/res/values/strings.xml @@ -1,8 +1,9 @@ - 공지사항 목록만을 보여주거나, 캘린더를 다시 보여줍니다. - 공지사항을 보여주는 달력입니다. - 일정이 없을 때 보여주는 작고 귀여운 고양이 입니다. - 일정이 없습니다. - "이전 달을 보여주는 화살표 입니다." - "다음 달을 보여주는 화살표 입니다." + 공지사항 목록만을 보여주거나, 캘린더를 다시 보여줍니다. + 공지사항을 보여주는 달력입니다. + 일정이 없을 때 보여주는 작고 귀여운 고양이 입니다. + 일정이 없습니다. + "이전 달을 보여주는 버튼 입니다." + "다음 달을 보여주는 버튼 입니다." + 오늘 날짜로 이동하는 버튼 입니다.