diff --git a/design/src/main/java/com/example/design/top/search/SearchBarTopSheet.kt b/design/src/main/java/com/example/design/top/search/SearchBarTopSheet.kt index 0e06fad9..da8cb6e7 100644 --- a/design/src/main/java/com/example/design/top/search/SearchBarTopSheet.kt +++ b/design/src/main/java/com/example/design/top/search/SearchBarTopSheet.kt @@ -146,7 +146,7 @@ fun SearchBarTopSheet( * - 350ms 디바운스 * - 동일 값 중복 호출 방지 */ - LaunchedEffect(text) { + LaunchedEffect(Unit) { snapshotFlow { text } .map { it.trim() } .filter { it.length >= 2 } diff --git a/feature/curation/src/main/java/com/example/curation/ui/CurationScreen.kt b/feature/curation/src/main/java/com/example/curation/ui/CurationScreen.kt index 1626fb18..72db2f38 100644 --- a/feature/curation/src/main/java/com/example/curation/ui/CurationScreen.kt +++ b/feature/curation/src/main/java/com/example/curation/ui/CurationScreen.kt @@ -4,17 +4,14 @@ package com.example.curation.ui import androidx.compose.foundation.Image import androidx.compose.foundation.background import androidx.compose.foundation.layout.Column -import androidx.compose.foundation.layout.Row import androidx.compose.foundation.layout.Spacer import androidx.compose.foundation.layout.fillMaxSize import androidx.compose.foundation.layout.fillMaxWidth import androidx.compose.foundation.layout.height import androidx.compose.foundation.layout.padding import androidx.compose.foundation.layout.size -import androidx.compose.foundation.shape.RoundedCornerShape import androidx.compose.material3.MaterialTheme import androidx.compose.material3.Text -import androidx.compose.material3.Icon import androidx.compose.runtime.Composable import androidx.compose.ui.Alignment import androidx.compose.ui.Modifier @@ -27,9 +24,7 @@ import com.example.curation.R import androidx.compose.foundation.lazy.LazyColumn import androidx.compose.foundation.lazy.items import androidx.compose.foundation.layout.PaddingValues -import androidx.compose.foundation.clickable import androidx.compose.foundation.layout.Arrangement -import androidx.compose.foundation.layout.Box import androidx.compose.foundation.layout.BoxWithConstraints import androidx.compose.foundation.layout.width import androidx.compose.material3.Scaffold @@ -37,7 +32,6 @@ import androidx.compose.runtime.LaunchedEffect import androidx.compose.runtime.collectAsState import androidx.compose.runtime.getValue import androidx.compose.runtime.remember -import androidx.compose.ui.draw.clip import androidx.compose.ui.layout.ContentScale import androidx.compose.ui.text.font.FontWeight import androidx.compose.ui.unit.sp @@ -46,8 +40,6 @@ import com.example.curation.CurationViewModel import com.example.curation.ui.list_card.LikedCurationCard import com.example.curation.Paperlogy import com.example.design.theme.LocalColorTheme -import com.example.design.theme.color.Basic -import com.example.design.R as Res import java.time.LocalDate import java.time.format.DateTimeFormatter import java.util.Locale diff --git a/feature/file/build.gradle.kts b/feature/file/build.gradle.kts index 7355fce8..7be8d8f5 100644 --- a/feature/file/build.gradle.kts +++ b/feature/file/build.gradle.kts @@ -53,7 +53,7 @@ dependencies { implementation(libs.androidx.ui.tooling.preview) implementation(libs.androidx.material3) implementation(libs.androidx.navigation.compose) - implementation(libs.androidx.compose.foundation.layout) + implementation(libs.androidx.compose.foundation) testImplementation(libs.junit) androidTestImplementation(libs.androidx.junit) androidTestImplementation(libs.androidx.espresso.core) diff --git a/feature/file/src/main/java/com/example/file/ui/bottom/sheet/FileBottomSheet.kt b/feature/file/src/main/java/com/example/file/ui/bottom/sheet/FileBottomSheet.kt index 97b93cee..1cc305bc 100644 --- a/feature/file/src/main/java/com/example/file/ui/bottom/sheet/FileBottomSheet.kt +++ b/feature/file/src/main/java/com/example/file/ui/bottom/sheet/FileBottomSheet.kt @@ -10,7 +10,6 @@ import androidx.compose.foundation.layout.fillMaxWidth import androidx.compose.foundation.layout.height import androidx.compose.foundation.layout.padding import androidx.compose.foundation.layout.size -import androidx.compose.foundation.layout.width import androidx.compose.foundation.layout.wrapContentHeight import androidx.compose.foundation.shape.CircleShape import androidx.compose.foundation.shape.RoundedCornerShape @@ -38,9 +37,9 @@ import androidx.compose.ui.text.style.TextAlign import androidx.compose.ui.tooling.preview.Preview import androidx.compose.ui.unit.dp import androidx.compose.ui.unit.sp -import com.example.file.R import com.example.design.modifier.noRippleClickable import com.example.design.theme.color.Basic +import com.example.file.R import com.example.file.ui.theme.Black import com.example.file.ui.theme.DefaultFont import com.example.file.ui.theme.Gray300 @@ -73,6 +72,9 @@ fun FileBottomSheet( color = Basic.gray[300] ) }, + + // 딤 효과 수치 + scrimColor = Basic.black.copy(alpha = 0.5f), sheetState = sheetState, onDismissRequest = onDismiss, tonalElevation = 8.dp, @@ -85,26 +87,29 @@ fun FileBottomSheet( .padding(bottom = 20.dp) .padding(horizontal = 20.dp), ) { + Text( modifier = Modifier .padding(start = 10.dp), text = title, fontSize = 18.sp, - lineHeight = 22.sp, fontFamily = DefaultFont, fontWeight = FontWeight(500), color = Black, ) + + Spacer(modifier = Modifier.height(11.dp)) + Text( modifier = Modifier - .padding(start = 10.dp, top = 14.dp), + .padding(start = 10.dp), text = body, fontSize = 15.sp, - lineHeight = 22.sp, fontFamily = DefaultFont, fontWeight = FontWeight.Normal, color = Gray600, ) + Spacer(modifier = Modifier.height(24.dp)) content() diff --git a/feature/file/src/main/java/com/example/file/ui/bottom/sheet/LinkCategorizationBottomSheet.kt b/feature/file/src/main/java/com/example/file/ui/bottom/sheet/LinkCategorizationBottomSheet.kt index ffe51487..5d044054 100644 --- a/feature/file/src/main/java/com/example/file/ui/bottom/sheet/LinkCategorizationBottomSheet.kt +++ b/feature/file/src/main/java/com/example/file/ui/bottom/sheet/LinkCategorizationBottomSheet.kt @@ -12,7 +12,7 @@ import androidx.compose.foundation.layout.fillMaxHeight import androidx.compose.foundation.layout.fillMaxWidth import androidx.compose.foundation.layout.height import androidx.compose.foundation.layout.heightIn -import androidx.compose.foundation.layout.padding +import androidx.compose.foundation.layout.offset import androidx.compose.foundation.layout.size import androidx.compose.foundation.lazy.LazyColumn import androidx.compose.foundation.lazy.items @@ -25,6 +25,7 @@ import androidx.compose.material3.Text import androidx.compose.material3.rememberModalBottomSheetState import androidx.compose.runtime.Composable import androidx.compose.runtime.getValue +import androidx.compose.runtime.mutableStateListOf import androidx.compose.runtime.mutableStateOf import androidx.compose.runtime.remember import androidx.compose.runtime.rememberCoroutineScope @@ -45,6 +46,7 @@ import com.example.core.model.LinkItemInfo import com.example.file.FileViewModel import com.example.file.R import com.example.design.modifier.noRippleClickable +import com.example.design.theme.color.Basic import com.example.file.ui.theme.Black import com.example.file.ui.theme.DefaultFont import com.example.file.ui.theme.Gray100 @@ -62,9 +64,9 @@ fun LinkCategorizationBottomSheet( ) { val links by fileViewModel.notCategorizationLinks.collectAsStateWithLifecycle() - var link by remember { mutableStateOf(null) } + //var link by remember { mutableStateOf(null) } - var selectedLinks = mutableListOf() + val selectedLinks = remember { mutableStateListOf() } val scope = rememberCoroutineScope() @@ -75,15 +77,17 @@ fun LinkCategorizationBottomSheet( title = "${folderStateViewModel.selectedTopFolder?.folderName?:""} 폴더의 미분류 링크 목록", body = "하위폴더에 추가하실 링크를 선택해주세요!", buttonText = "추가", + isReady = selectedLinks.isNotEmpty(), visible = folderStateViewModel.linkCategorizationBottomSheetVisible, onOkay = { scope.launch{ - selectedLinks.map { - fileViewModel.updateLinkFolder( - it, - folderStateViewModel.selectedBottomFolder?.folderId!! - ) + val folderId = requireNotNull(folderStateViewModel.selectedBottomFolder?.folderId) + + selectedLinks.forEach { + fileViewModel.updateLinkFolder(it, folderId) } + + selectedLinks.clear() } }, onDismiss = { folderStateViewModel.updateLinkCategorizationBottomSheetVisible(false) } @@ -95,7 +99,7 @@ fun LinkCategorizationBottomSheet( verticalArrangement = Arrangement.spacedBy(10.dp) ) { items(links) { - val l = it + val link = it val title = it.title val url = it.url val icon = domainLogoPainterOrNull(it.url)?:painterResource(R.drawable.link_categorization_default) @@ -104,64 +108,71 @@ fun LinkCategorizationBottomSheet( var checked by remember { mutableStateOf(false)} Row( modifier = Modifier - //.height(60.dp) + .height(60.dp) + .offset(x = (-20).dp) .noRippleClickable{ if(checked){ Log.d("LinkCategorizationBottomSheet", "checked: $it") - selectedLinks.remove(l) - checked = selectedLinks.contains(l) + selectedLinks.remove(link) + checked = selectedLinks.contains(link) } else { Log.d("LinkCategorizationBottomSheet", "checked: $it") - selectedLinks.add(l) - checked = selectedLinks.contains(l) + selectedLinks.add(link) + checked = selectedLinks.contains(link) } }, - horizontalArrangement = Arrangement.spacedBy(14.dp) + horizontalArrangement = Arrangement.spacedBy(10.dp), + verticalAlignment = Alignment.CenterVertically ) { Checkbox( - modifier = Modifier - .clip(RoundedCornerShape(18.dp)), checked = checked, onCheckedChange = { if(checked){ Log.d("LinkCategorizationBottomSheet", "checked: $it") - selectedLinks.remove(l) - checked = selectedLinks.contains(l) + selectedLinks.remove(link) + checked = selectedLinks.contains(link) } else { Log.d("LinkCategorizationBottomSheet", "checked: $it") - selectedLinks.add(l) - checked = selectedLinks.contains(l) + selectedLinks.add(link) + checked = selectedLinks.contains(link) } }, colors = CheckboxDefaults.colors( checkedColor = Purple200, + uncheckedColor = Basic.gray[200], ) ) Box( modifier = Modifier - .height(60.dp) - .background(Gray100), + //.height(60.dp) + .background( + color = Gray100, + shape = RoundedCornerShape(18.dp) + ) + /*.clip(RoundedCornerShape(18.dp))*/, contentAlignment = Alignment.Center ) { Image( modifier = Modifier - .fillMaxHeight() - .clip(RoundedCornerShape(18.dp)), + .fillMaxHeight(), painter = img, contentDescription = null ) } + Column( - modifier = Modifier - .fillMaxHeight() - .padding(vertical = 8.dp), + modifier = Modifier.fillMaxHeight(), + //verticalArrangement = Arrangement.SpaceBetween + ) { + // 링크 상단 패딩 + Spacer(modifier = Modifier.height(7.dp)) + Text( text = title, fontSize = 15.sp, - lineHeight = 22.sp, fontFamily = DefaultFont, fontWeight = FontWeight(500), color = Black, @@ -194,7 +205,6 @@ fun LinkCategorizationBottomSheet( Text( text = url, fontSize = 12.sp, - lineHeight = 14.sp, fontFamily = DefaultFont, fontWeight = FontWeight(400), color = Gray800, @@ -202,7 +212,10 @@ fun LinkCategorizationBottomSheet( overflow = TextOverflow.Ellipsis ) } + // 링크 하단 패딩 + Spacer(modifier = Modifier.height(7.dp)) } + } } } diff --git a/feature/file/src/main/java/com/example/file/ui/bottom/sheet/TextFieldFileBottomSheet.kt b/feature/file/src/main/java/com/example/file/ui/bottom/sheet/TextFieldFileBottomSheet.kt index 81c74d28..ff546f45 100644 --- a/feature/file/src/main/java/com/example/file/ui/bottom/sheet/TextFieldFileBottomSheet.kt +++ b/feature/file/src/main/java/com/example/file/ui/bottom/sheet/TextFieldFileBottomSheet.kt @@ -185,7 +185,10 @@ fun TextFieldFileBottomSheet( ) } - val rotation by animateFloatAsState(if (expanded) 180f else 0f, label = "") + val rotation by animateFloatAsState( + targetValue = if (expanded) 180f else 0f, + label = "화살표 회전 애니메이션" + ) val modifier = if(expanded) Modifier .padding(start = 10.dp) diff --git a/feature/file/src/main/java/com/example/file/ui/content/FolderIcons.kt b/feature/file/src/main/java/com/example/file/ui/content/FolderIcons.kt index 5cd753a6..65b6cd0b 100644 --- a/feature/file/src/main/java/com/example/file/ui/content/FolderIcons.kt +++ b/feature/file/src/main/java/com/example/file/ui/content/FolderIcons.kt @@ -19,7 +19,7 @@ import com.example.file.ui.theme.White // 공유 폴더 사람 아이콘 @Composable -fun ShareFolderIcon( +internal fun ShareFolderIcon( tint: Color ) { Icon( @@ -31,7 +31,7 @@ fun ShareFolderIcon( // 잠금 폴더 자물쇠 아이콘 @Composable -fun LockFolderIcon( +internal fun LockFolderIcon( tint: Color ) { Icon( @@ -43,7 +43,7 @@ fun LockFolderIcon( // 수정 연필 아이콘 @Composable -fun PencilIcon( +internal fun PencilIcon( tint: Color ) { Icon( @@ -55,7 +55,7 @@ fun PencilIcon( // 북마크 별 아이콘 @Composable -fun BookMarkStar( +internal fun BookMarkStar( isBookmarked: Boolean ) { val modifier = if(isBookmarked) Modifier diff --git a/feature/file/src/main/java/com/example/file/ui/content/LinksGrid.kt b/feature/file/src/main/java/com/example/file/ui/content/LinksGrid.kt index 179d2436..91591ab1 100644 --- a/feature/file/src/main/java/com/example/file/ui/content/LinksGrid.kt +++ b/feature/file/src/main/java/com/example/file/ui/content/LinksGrid.kt @@ -1,6 +1,5 @@ package com.example.file.ui.content -import androidx.lifecycle.lifecycleScope import android.util.Log import androidx.compose.foundation.Image import androidx.compose.foundation.layout.Arrangement @@ -12,7 +11,6 @@ import androidx.compose.runtime.Composable import androidx.compose.runtime.getValue import androidx.compose.runtime.mutableStateOf import androidx.compose.runtime.remember -import androidx.compose.runtime.rememberCoroutineScope import androidx.compose.runtime.setValue import androidx.compose.ui.Alignment import androidx.compose.ui.Modifier @@ -28,16 +26,15 @@ import androidx.lifecycle.compose.collectAsStateWithLifecycle import androidx.lifecycle.viewmodel.compose.viewModel import com.cheonjaeung.compose.grid.SimpleGridCells import com.cheonjaeung.compose.grid.VerticalGrid +import com.example.design.modifier.noRippleClickable import com.example.file.FileViewModel import com.example.file.R -import com.example.design.modifier.noRippleClickable import com.example.file.ui.item.LinkItemLayout import com.example.file.ui.modal.FileModalWindow -import com.example.file.viewmodel.folder.state.FolderStateViewModel import com.example.file.ui.theme.Black import com.example.file.ui.theme.DefaultFont import com.example.file.ui.theme.Gray600 -import kotlinx.coroutines.launch +import com.example.file.viewmodel.folder.state.FolderStateViewModel @Composable fun LinksGrid( @@ -164,8 +161,8 @@ fun LinksGrid( }, onDismiss = { deleteModalWindowVisible = false }, title = "해당 링크를 삭제하시겠습니까?", - positiveText = "삭제", - negativeText = "취소" + positiveText = "삭제하기", + negativeText = "취소하기" ) { Text( text = "삭제 시 해당 링크가 영구적으로 제거되며\n복구가 불가능합니다.", diff --git a/feature/file/src/main/java/com/example/file/ui/item/LinkItemLayout.kt b/feature/file/src/main/java/com/example/file/ui/item/LinkItemLayout.kt index 306ae4ee..8bc9fb37 100644 --- a/feature/file/src/main/java/com/example/file/ui/item/LinkItemLayout.kt +++ b/feature/file/src/main/java/com/example/file/ui/item/LinkItemLayout.kt @@ -6,6 +6,8 @@ import android.util.Log import androidx.compose.foundation.ExperimentalFoundationApi import androidx.compose.foundation.Image import androidx.compose.foundation.background +import androidx.compose.foundation.combinedClickable +import androidx.compose.foundation.interaction.MutableInteractionSource import androidx.compose.foundation.layout.Arrangement import androidx.compose.foundation.layout.Box import androidx.compose.foundation.layout.Column @@ -18,7 +20,6 @@ import androidx.compose.foundation.layout.padding import androidx.compose.foundation.layout.size import androidx.compose.foundation.layout.width import androidx.compose.foundation.layout.wrapContentHeight -import androidx.compose.foundation.layout.wrapContentSize import androidx.compose.foundation.lazy.LazyRow import androidx.compose.foundation.lazy.items import androidx.compose.foundation.shape.CircleShape @@ -28,25 +29,24 @@ import androidx.compose.material3.Icon import androidx.compose.material3.Surface import androidx.compose.material3.Text import androidx.compose.runtime.Composable -import androidx.compose.runtime.getValue -import androidx.compose.runtime.mutableStateOf import androidx.compose.runtime.remember -import androidx.compose.runtime.setValue import androidx.compose.ui.Alignment import androidx.compose.ui.Modifier import androidx.compose.ui.draw.alpha import androidx.compose.ui.draw.clip +import androidx.compose.ui.draw.shadow import androidx.compose.ui.layout.ContentScale import androidx.compose.ui.platform.LocalContext import androidx.compose.ui.res.painterResource +import androidx.compose.ui.text.ExperimentalTextApi +import androidx.compose.ui.text.PlatformTextStyle +import androidx.compose.ui.text.TextStyle import androidx.compose.ui.text.font.FontWeight import androidx.compose.ui.text.style.TextAlign import androidx.compose.ui.text.style.TextOverflow import androidx.compose.ui.tooling.preview.Preview import androidx.compose.ui.unit.dp import androidx.compose.ui.unit.sp -import androidx.lifecycle.viewmodel.compose.viewModel -import androidx.navigation.compose.rememberNavController import coil3.compose.AsyncImage import coil3.request.ImageRequest import coil3.request.crossfade @@ -54,8 +54,6 @@ import coil3.request.error import coil3.request.fallback import coil3.request.placeholder import com.example.core.model.LinkItemInfo -import com.example.design.modifier.noRippleClickable -import com.example.file.FileViewModel import com.example.file.R import com.example.file.ui.theme.Black import com.example.file.ui.theme.DefaultFont @@ -66,11 +64,12 @@ import com.example.file.ui.theme.Gray600 import com.example.file.ui.theme.Gray800 import com.example.file.ui.theme.White import com.example.file.ui.theme.domainLogoPainterOrNull -import androidx.compose.foundation.combinedClickable -import androidx.compose.foundation.interaction.MutableInteractionSource -import java.time.OffsetDateTime -@OptIn(ExperimentalMaterial3Api::class, ExperimentalFoundationApi::class) +@OptIn( + ExperimentalMaterial3Api::class, + ExperimentalFoundationApi::class, + ExperimentalTextApi::class +) @Composable fun LinkItemLayout( link: LinkItemInfo? = null, @@ -78,7 +77,6 @@ fun LinkItemLayout( onLongClick: (Long) -> Unit = {}, ) { val tags = link?.tags?:emptyList() - var showDialog by remember { mutableStateOf(false) } val domainIcon = link?.let{ domainLogoPainterOrNull(it.url) } @@ -99,28 +97,38 @@ fun LinkItemLayout( Box ( // 태그 배경: 크기 wrap, 둥근 모서리(6dp), Gray100 배경색 modifier = Modifier - .wrapContentSize() .background( shape = RoundedCornerShape(size = 6.dp), color = Gray100 - ), + ) + .padding(horizontal = 6.dp, vertical = 1.dp), + contentAlignment = Alignment.Center ) { + // 태그 텍스트 Text( - // 태그 텍스트를 Box 중앙에 정렬, 내부 여백(가로 6dp, 세로 3dp) + // 태그 텍스트를 Box 중앙에 정렬, 내부 여백(가로 1dp, 세로 2dp) modifier = Modifier - .align(Alignment.Center) - .padding(horizontal = 6.dp, vertical = 1.dp), + .padding(horizontal = 1.dp, vertical = 2.dp), text = tag, - // 폰트 크기(10sp) - fontSize = 10.sp, + // 폰트 크기(12sp) + fontSize = 12.sp, // 폰트 fontFamily = DefaultFont, // 폰트 굵기(Normal) fontWeight = FontWeight.Normal, // 글자색(Gray600) color = Gray600, + + textAlign = TextAlign.Center, + + style = TextStyle( + platformStyle = PlatformTextStyle( + includeFontPadding = false + ) + ) ) + } } @@ -128,7 +136,7 @@ fun LinkItemLayout( indication = null, interactionSource = remember { MutableInteractionSource() }, onClick = { - link?.linkuId?.let { + link.linkuId.let { Log.d("LinkItemLayout", "아이템 클릭: \"savelinkresult/${it}\"") onClick(link) } @@ -144,21 +152,17 @@ fun LinkItemLayout( // 카드 크기: 가로 181dp, 세로 267dp modifier = Modifier .width(181.dp) - //.height(267.dp) - then(modifier) - /*.pointerInput(Unit) { - detectTapGestures( - onLongPress = { - showDialog = true // 꾹 누르면 Dialog 띄우기 - } - ) - }*/, + .then(modifier) + .shadow( + elevation = 4.dp, + shape = RoundedCornerShape(18.dp) + ), // 모서리 둥글게(18dp) - shape = RoundedCornerShape(18.dp), + //shape = RoundedCornerShape(18.dp), // 카드 배경색(White) color = White, // 그림자(입체감) 효과(20dp) - shadowElevation = 5.dp//(if(painter == null) 0 else 5).dp, + //shadowElevation = 5.dp//(if(painter == null) 0 else 5).dp, ) { // 내용 전체를 세로로 배치하는 Column Column ( @@ -197,11 +201,13 @@ fun LinkItemLayout( } } + // 링크 메인 이미지, 제목 사이 간격 + Spacer(modifier = Modifier.height(10.dp)) + // (2) 링크 제목 Text( // 위쪽 여백(10dp) - modifier = Modifier - .padding(top = 10.dp), + modifier = Modifier, text = link?.title?:"제목", // 폰트 크기(15sp) fontSize = 15.sp, @@ -215,12 +221,14 @@ fun LinkItemLayout( overflow = TextOverflow.Ellipsis // 잘리면 ... 표시 ) + // 링크 제목, 태그 사이 간격 + Spacer(modifier = Modifier.height(1.dp)) + // (3) 링크 분류 태그(여러 개를 Row에 배치) LazyRow( // 가로 전체 채우기, 위쪽 여백(8dp) modifier = Modifier - .height(30.dp) - .padding(top = 8.dp), + .height(30.dp), // 태그 간 5dp 간격, 왼쪽 정렬 horizontalArrangement = Arrangement.spacedBy(5.dp, Alignment.Start), // 세로 중앙 정렬 @@ -232,8 +240,8 @@ fun LinkItemLayout( } } - // (4) 남은 공간 모두 차지하는 Spacer (아래로 밀어내기) - Spacer(modifier = Modifier.height(8.dp)) + // 링크 태그, 설명 프레임 사이 간격 + Spacer(modifier = Modifier.height(5.dp)) // (5) 링크 설명 프레임 (도메인, 아이콘 등) Row( @@ -300,7 +308,7 @@ private fun LinkItemTest() { contentAlignment = Alignment.TopCenter ){ Box( - modifier = Modifier.alpha(0.35f), + //modifier = Modifier.alpha(0.35f), ){ LinkItemLayout( link = null @@ -323,5 +331,6 @@ private fun LinkItemTest() { textAlign = TextAlign.Center, ) } -} + LinkItemLayout { } +} \ No newline at end of file diff --git a/feature/home/src/main/java/com/example/home/screen/HomeScreen.kt b/feature/home/src/main/java/com/example/home/screen/HomeScreen.kt index c0d46394..ee4db036 100644 --- a/feature/home/src/main/java/com/example/home/screen/HomeScreen.kt +++ b/feature/home/src/main/java/com/example/home/screen/HomeScreen.kt @@ -1,8 +1,5 @@ package com.example.home.screen -import androidx.compose.animation.AnimatedVisibility -import androidx.compose.animation.expandVertically -import androidx.compose.animation.shrinkVertically import androidx.compose.foundation.ExperimentalFoundationApi import androidx.compose.foundation.Image import androidx.compose.foundation.background @@ -16,8 +13,6 @@ import androidx.compose.foundation.layout.Spacer import androidx.compose.foundation.layout.fillMaxSize import androidx.compose.foundation.layout.fillMaxWidth import androidx.compose.foundation.layout.height -import androidx.compose.foundation.layout.navigationBarsPadding -import androidx.compose.foundation.layout.offset import androidx.compose.foundation.layout.padding import androidx.compose.foundation.layout.size import androidx.compose.foundation.layout.width @@ -25,7 +20,6 @@ import androidx.compose.foundation.lazy.LazyColumn import androidx.compose.foundation.lazy.rememberLazyListState import androidx.compose.foundation.shape.RoundedCornerShape import androidx.compose.material3.Icon -import androidx.compose.material3.IconButton import androidx.compose.material3.Text import androidx.compose.runtime.Composable import androidx.compose.runtime.LaunchedEffect @@ -38,18 +32,14 @@ import androidx.compose.runtime.setValue import androidx.compose.ui.Alignment import androidx.compose.ui.Modifier import androidx.compose.ui.draw.clip -import androidx.compose.ui.graphics.Brush import androidx.compose.ui.graphics.Color import androidx.compose.ui.layout.ContentScale import androidx.compose.ui.platform.LocalConfiguration import androidx.compose.ui.platform.LocalDensity import androidx.compose.ui.res.painterResource -import androidx.compose.ui.text.SpanStyle import androidx.compose.ui.text.TextStyle -import androidx.compose.ui.text.buildAnnotatedString import androidx.compose.ui.text.font.FontWeight import androidx.compose.ui.text.style.TextAlign -import androidx.compose.ui.text.withStyle import androidx.compose.ui.unit.dp import androidx.compose.ui.unit.sp import androidx.compose.ui.zIndex @@ -57,20 +47,16 @@ import coil3.compose.AsyncImage import com.example.core.model.LinkSimpleInfo import com.example.design.BrushText import com.example.design.top.search.SearchBarTopSheet -import com.example.design.modifier.noRippleClickable import com.example.design.theme.LocalColorTheme import com.example.design.theme.LocalFontTheme import com.example.design.theme.color.Basic import com.example.design.util.DesignSystemBars -import com.example.file.ui.theme.FileTopBarLinkUFont -import com.example.file.ui.theme.MainColor import com.example.home.HomeViewModel import com.example.home.R import com.example.home.component.ClipboardLinkPasteBanner import com.example.home.component.rememberClipboardUrl import com.example.home.ui.top.bar.HomeTopBar import kotlinx.coroutines.launch -import com.example.design.R as Res data class LinkItem( val imageResId: Int?, // 링크 대표 이미지 diff --git a/feature/login/src/main/java/com/example/login/ui/screen/EmailLoginScreen.kt b/feature/login/src/main/java/com/example/login/ui/screen/EmailLoginScreen.kt index 16e41c8a..9c36140f 100644 --- a/feature/login/src/main/java/com/example/login/ui/screen/EmailLoginScreen.kt +++ b/feature/login/src/main/java/com/example/login/ui/screen/EmailLoginScreen.kt @@ -237,28 +237,26 @@ fun EmailLoginScreen( val dividerStartPos = (220.scaler) // | 시작점 val signUpStartPos = (247.scaler) // 회원가입 시작점 - Box( + Row( modifier = Modifier + .align(Alignment.CenterHorizontally) .fillMaxWidth() .height((30.scaler)), // 클릭 영역 확보를 위한 높이 - contentAlignment = Alignment.CenterStart //세로 중앙 정렬 - ) { - // 1. 비밀번호 재설정 + horizontalArrangement = Arrangement.spacedBy(25.dp, alignment = Alignment.CenterHorizontally), + verticalAlignment = Alignment.CenterVertically + ){ Text( text = "비밀번호 재설정", fontSize = 15.sp, fontFamily = Paperlogy.font, color = Color(0xFF87898F), modifier = Modifier - .offset(x = resetStartPos) // 항상 101/412 지점 .noRippleClickable { //if (loginState !is LoginState.Loading) { -> 혹시 나중에 로딩중이 길어지면 사용해주세요. navigator.navigate("resetPassword") //} } ) - - // 2. 구분선 (|) // TODO : 비밀번호 재설정, 회원가입 대비 내려가서 부득이하게 약간 위로 올림. 다현이랑 조절해보기. Text( text = "|", fontSize = 14.sp, @@ -266,30 +264,23 @@ fun EmailLoginScreen( color = Color(0xFF87898F), style = TextStyle( baselineShift = BaselineShift(0.3f) // 약간 위로 올림 - ), - //style = TextStyle(baselineShift = BaselineShift(0.15f)), - modifier = Modifier - .offset(x = dividerStartPos) // 항상 220/412 지점 + ) ) - - // 3. 회원가입 Text( text = "회원가입", fontSize = 15.sp, fontFamily = Paperlogy.font, color = Color(0xFF87898F), modifier = Modifier - .offset(x = signUpStartPos) // 항상 247/412 지점 .noRippleClickable { focusManager.clearFocus() onSignUpClick() } ) } - - } } } +} diff --git a/gradle/libs.versions.toml b/gradle/libs.versions.toml index e56ea5bd..f315805b 100644 --- a/gradle/libs.versions.toml +++ b/gradle/libs.versions.toml @@ -34,8 +34,6 @@ foundation = "1.9.5" composeTesting = "1.0.0-alpha09" toolsCore = "1.0.0-alpha14" foundationVersion = "1.10.1" -foundationLayout = "1.10.0" - [libraries] @@ -86,8 +84,6 @@ androidx-compose-foundation = { group = "androidx.compose.foundation", name = "f androidx-compose-testing = { group = "androidx.xr.compose", name = "compose-testing", version.ref = "composeTesting" } androidx-tools-core = { group = "androidx.privacysandbox.tools", name = "tools-core", version.ref = "toolsCore" } androidx-foundation = { group = "androidx.compose.foundation", name = "foundation", version.ref = "foundationVersion" } -androidx-compose-foundation-layout = { group = "androidx.compose.foundation", name = "foundation-layout", version.ref = "foundationLayout" } -