Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[MOD/#143] empty 뷰 이미지 추가 및 수정 #145

Merged
merged 5 commits into from
Jul 18, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -52,7 +52,7 @@ import com.terning.feature.home.changefilter.navigation.navigateChangeFilter
import com.terning.feature.home.home.component.HomeFilteringEmptyIntern
import com.terning.feature.home.home.component.HomeFilteringScreen
import com.terning.feature.home.home.component.HomeRecommendEmptyIntern
import com.terning.feature.home.home.component.HomeTodayEmptyIntern
import com.terning.feature.home.home.component.HomeTodayEmptyWithImg
import com.terning.feature.home.home.component.HomeTodayIntern
import com.terning.feature.home.home.navigation.navigateHome
import com.terning.feature.intern.navigation.navigateIntern
Expand Down Expand Up @@ -301,7 +301,7 @@ private fun ShowMainTitleWithName(userName: String) {
@Composable
private fun ShowTodayIntern(homeTodayInternList: List<HomeTodayInternModel>) {
if (homeTodayInternList.isEmpty()) {
HomeTodayEmptyIntern(isButtonExist = false)
HomeTodayEmptyWithImg()
} else {
HomeTodayIntern(internList = homeTodayInternList)
}
Expand Down
Original file line number Diff line number Diff line change
@@ -1,19 +1,15 @@
package com.terning.feature.home.home.component

import androidx.compose.foundation.layout.Arrangement
import androidx.compose.foundation.layout.Box
import androidx.compose.foundation.layout.Column
import androidx.compose.foundation.layout.fillMaxHeight
import androidx.compose.foundation.layout.fillMaxSize
import androidx.compose.foundation.layout.fillMaxWidth
import androidx.compose.foundation.layout.padding
import androidx.compose.material3.Text
import androidx.compose.runtime.Composable
import androidx.compose.ui.Alignment
import androidx.compose.ui.Modifier
import androidx.compose.ui.res.stringResource
import androidx.compose.ui.text.style.TextAlign
import androidx.compose.ui.unit.dp
import com.terning.core.designsystem.component.image.TerningImage
import com.terning.feature.R

@Composable
Expand All @@ -22,20 +18,18 @@ fun HomeFilteringEmptyIntern(
) {
Column(
modifier = modifier,
verticalArrangement = Arrangement.Bottom
verticalArrangement = Arrangement.Center
) {
Box(

TerningImage(
painter = R.drawable.ic_home_empty_filtering,
modifier = Modifier
.padding(
top = 16.dp,
bottom = 12.dp
)
.align(Alignment.CenterHorizontally)
)
Text(
text = stringResource(id = R.string.home_recommend_no_filtering),
modifier = Modifier
.fillMaxWidth()
.padding(bottom = 25.dp)
.align(Alignment.CenterHorizontally),
textAlign = TextAlign.Center,
)
Expand Down
Original file line number Diff line number Diff line change
@@ -0,0 +1,62 @@
package com.terning.feature.home.home.component

import androidx.compose.foundation.background
import androidx.compose.foundation.layout.Arrangement
import androidx.compose.foundation.layout.Column
import androidx.compose.foundation.layout.fillMaxWidth
import androidx.compose.foundation.layout.padding
import androidx.compose.foundation.layout.wrapContentWidth
import androidx.compose.foundation.shape.RoundedCornerShape
import androidx.compose.material3.Text
import androidx.compose.runtime.Composable
import androidx.compose.ui.Alignment
import androidx.compose.ui.Modifier
import androidx.compose.ui.res.stringResource
import androidx.compose.ui.text.style.TextAlign
import androidx.compose.ui.unit.dp
import com.terning.core.designsystem.component.image.TerningImage
import com.terning.core.designsystem.theme.Grey200
import com.terning.core.designsystem.theme.Grey500
import com.terning.core.designsystem.theme.TerningTheme
import com.terning.core.designsystem.theme.White
import com.terning.core.extension.customShadow
import com.terning.feature.R

@Composable
fun HomeTodayEmptyWithImg(
modifier: Modifier = Modifier,
) {
Column(
modifier = modifier
.fillMaxWidth()
.padding(top = 19.dp)
.padding(horizontal = 24.dp)
.customShadow(
color = Grey200,
shadowRadius = 5.dp,
shadowWidth = 2.dp
)
.background(
color = White,
shape = RoundedCornerShape(5.dp)
),
verticalArrangement = Arrangement.Center
) {
TerningImage(
painter = R.drawable.ic_home_scrap_empty,
modifier = Modifier
.align(Alignment.CenterHorizontally)
.padding(top = 24.dp)
)
Text(
text = stringResource(id = R.string.home_scrap_empty),
modifier = modifier
.padding(top = 8.dp, bottom = 25.dp)
.fillMaxWidth()
.wrapContentWidth(Alignment.CenterHorizontally),
textAlign = TextAlign.Center,
style = TerningTheme.typography.detail3,
color = Grey500,
)
}
}
Loading
Loading