Skip to content

DS TextField & TextArea 변경 사항 반영#106

Merged
moondev03 merged 10 commits into
developfrom
refactor/ds-textfield-update
Apr 24, 2026
Merged

DS TextField & TextArea 변경 사항 반영#106
moondev03 merged 10 commits into
developfrom
refactor/ds-textfield-update

Conversation

@moondev03

@moondev03 moondev03 commented Apr 21, 2026

Copy link
Copy Markdown
Member

📌 작업 내용

색상 변경

state = typed, status = default -> text/medium

Typing -> Typed 상태 트리거 변경

기존에는 타이핑이 멈추면 일정 시간 뒤에 Typed로 상태가 변경되는 구조였는데
DS에 명시된 대로 Focus 유무로 판단하도록 변경


📢 논의하고 싶은 내용

Summary by CodeRabbit

릴리스 노트

  • 새로운 기능

    • 로티 애니메이션 재생을 위한 PrezelLottie 컴포넌트 추가
  • 개선 사항

    • 텍스트 필드 상태 모델 개선(상태 기반 표시, 입력 정책 강화, 플레이스홀더 동작 개선, 카운터/보조문구 표현 향상)
    • 약관 화면의 “전체 선택” 행 전체 영역이 탭 가능해짐
    • 프로필 화면에서 빈 영역 탭 시 포커스 해제 동작 추가

`core:ui` 모듈 내 공통으로 사용되는 UI 베이스 클래스들의 패키지 위치를 변경하고, 이를 참조하는 모든 피처 모듈의 임포트 경로를 업데이트했습니다.

* **refactor: BaseViewModel 위치 이동 및 패키지명 변경**
    * `com.team.prezel.core.ui.BaseViewModel` -> `com.team.prezel.core.ui.base.BaseViewModel`로 이동
    * `UiState`, `UiIntent`, `UiEffect` 인터페이스를 `com.team.prezel.core.ui.base` 패키지로 관리하도록 구조 개선

* **refactor: 피처 모듈 내 참조 경로 업데이트**
    * `home`, `profile`, `login`, `history`, `splash` 등 각 피처 모듈 내 `ViewModel`, `UiState`, `UiIntent`, `UiEffect`에서 변경된 `core.ui.base` 패키지를 참조하도록 수정했습니다.
* refactor: StatusView 패키지 위치 변경 및 코드 정리
    * `StatusView`를 `com.team.prezel.core.ui`에서 `com.team.prezel.core.ui.component` 패키지로 이동하였습니다.
    * `StatusView.kt` 내부에 정의되어 있던 `StatusLottie`와 로딩 프리뷰 코드를 제거하였습니다.

* feat: 공용 Lottie 컴포저블 `PrezelLottie` 구현
    * Lottie 애니메이션을 일관되게 사용하기 위해 `PrezelLottie` 컴포넌트를 새롭게 추가하였습니다.
    * `isPlaying`, `iterations`, `speed`, `onAnimationFrame` 등 다양한 속성을 제어할 수 있도록 파라미터를 제공합니다.

* refactor: HistoryEmptyContent 내 StatusView 참조 수정
    * `StatusView` 패키지 위치 변경에 따른 import 문을 업데이트하였습니다.
core:ui 모듈의 유지보수성을 높이기 위해 파일 위치를 기능별 패키지(`util`, `state`)로 재배치하고 관련 임포트를 업데이트했습니다.

* **refactor: 유틸리티 및 상태 관련 파일 패키지 이동**
    * `AdvancedImePadding.kt` 및 `OnHeightChanged.kt` 파일을 `com.team.prezel.core.ui.util` 패키지로 이동했습니다.
    * `LocalSnackbarHostState.kt` 파일을 `com.team.prezel.core.ui.state` 패키지로 이동했습니다.

* **style: 변경된 구조에 따른 임포트 경로 수정**
    * `ProfileScreen`, `HistoryScreen`, `HomeScreen`, `LoginScreen` 등 각 피처 모듈에서 변경된 패키지 경로를 반영하도록 수정했습니다.
    * `PrezelApp` 및 `DoubleBackToExitHandler` 내 `LocalSnackbarHostState` 참조 경로를 업데이트했습니다.
TextField와 TextArea의 상태 관리 로직을 단순화하고 명칭을 직관적으로 변경하여 유지보수성을 높였습니다.

* **명칭 및 타입 변경**:
    * `PrezelTextFieldInteraction` -> `PrezelTextFieldState`로 변경 (DEFAULT, DISABLED, TYPING, TYPED)
    * `PrezelTextFieldFeedback` -> `PrezelTextFieldStatus`로 변경 (Default, Good, Bad)
    * `PrezelTextFieldState` -> `PrezelTextFieldStyle`로 변경 (State와 Status를 결합한 스타일 정보 객체)
* **로직 개선**:
    * `rememberPrezelTextFieldInteraction`의 복잡한 `debounce` 기반 Idle 상태 체크 로직을 제거하고, 포커스 여부와 값 존재 여부에 따라 상태를 결정하는 `rememberPrezelTextFieldState`로 단순화했습니다.
    * 공통 텍스트 입력 정책(`applyPrezelTextInputPolicy`)을 추출하여 TextField와 TextArea에서 공유하도록 수정했습니다.
    * 포커스 상태일 때 플레이스홀더를 숨기던 로직을 `showPlaceholder` 파라미터 제어를 통해 명확하게 처리했습니다.
* **UI 및 스타일 수정**:
    * `TYPING` 상태에서도 `Status`에 따라 배경색과 테두리 색상이 반영되도록 스타일 계산 로직을 업데이트했습니다.
    * `State`와 `Status` 조합에 따른 텍스트, 아이콘, 테두리 색상 적용 규칙을 세분화했습니다.
* **기타**:
    * Preview 코드를 상태별(Default, Disabled, Typing, Typed)로 분리하여 가독성을 개선했습니다.
    * 불필요한 import 문과 사용되지 않는 파라미터를 정리했습니다.
* **feat: 프로필 화면 배경 터치 시 키보드 숨김 기능 추가**
    * `ProfileContent` 컨테이너에 `pointerInput`과 `FocusManager`를 적용하여, 빈 영역을 탭했을 때 입력 포커스가 해제되도록 개선했습니다.

* **refactor: 디자인 시스템 변경에 따른 텍스트 필드 상태 관련 코드 수정**
    * `PrezelTextField`의 파라미터가 `feedback`에서 `status`로 변경됨에 따라 관련 로직을 수정했습니다.
    * `PrezelTextFieldFeedback`을 `PrezelTextFieldStatus`로 교체하였습니다.
    * `toNicknameFeedback` 확장 함수명을 `toNicknameStatus`로 변경하고, 내부 상태 매핑 로직(`NO_MESSAGE` -> `DEFAULT`, `Good` -> `Default`)을 최신 디자인 시스템 정의에 맞게 업데이트했습니다.
@moondev03 moondev03 self-assigned this Apr 21, 2026
@moondev03 moondev03 added the 🔨 refactor 기능 변경 없이 내부 구조, 설계, 가독성 개선 label Apr 21, 2026
@moondev03 moondev03 requested a review from HamBeomJoon as a code owner April 21, 2026 19:23
@coderabbitai

coderabbitai Bot commented Apr 21, 2026

Copy link
Copy Markdown
Contributor

Caution

Review failed

Pull request was closed or merged during review

📝 Walkthrough

Walkthrough

핵심 UI 패키지 구조를 하위 패키지로 재배치하고 텍스트 필드 API를 feedback→status 기반으로 리팩터링했으며, Lottie 컴포저블을 추가하고 모든 소비지의 임포트 경로를 업데이트했습니다.

Changes

Cohort / File(s) Summary
코어 UI 패키지 재배치
Prezel/core/ui/src/main/java/com/team/prezel/core/ui/base/BaseViewModel.kt, Prezel/core/ui/src/main/java/com/team/prezel/core/ui/state/LocalSnackbarHostState.kt, Prezel/core/ui/src/main/java/com/team/prezel/core/ui/util/AdvancedImePadding.kt, Prezel/core/ui/src/main/java/com/team/prezel/core/ui/util/OnHeightChanged.kt
패키지 선언을 com.team.prezel.core.ui → 하위 패키지(.base, .state, .util)로 이동.
앱 진입점 임포트 업데이트
Prezel/app/src/main/java/com/team/prezel/ui/DoubleBackToExitHandler.kt, Prezel/app/src/main/java/com/team/prezel/ui/PrezelApp.kt
LocalSnackbarHostState 임포트 경로를 com.team.prezel.core.ui.state로 변경.
텍스트필드 모델 및 API 리팩터링
Prezel/core/designsystem/.../component/textfield/PrezelTextFieldState.kt, Prezel/core/designsystem/.../component/textfield/PrezelTextField.kt, Prezel/core/designsystem/.../component/textfield/PrezelTextArea.kt
interaction/feedback 모델을 state/status 모델로 재명명(예: PrezelTextFieldInteraction→PrezelTextFieldState, PrezelTextFieldFeedback→PrezelTextFieldStatus), 스타일 컨테이너를 PrezelTextFieldStyle로 변경, 입력 정책을 applyPrezelTextInputPolicy로 통합, placeholder/지원 텍스트 렌더링 로직 조정 및 공개 시그니처(피드백→status) 변경.
텍스트필드 서포팅 컴포넌트
Prezel/core/designsystem/.../component/textfield/component/PrezelTextFieldSupportingText.kt
서포팅 텍스트 컴포저블 시그니처를 state 기반에서 text: String, textColor: Color 직접 인수로 변경(구현 소비 경로 업데이트).
Lottie 컴포저블 추가
Prezel/core/ui/src/main/java/com/team/prezel/core/ui/component/PrezelLottie.kt
raw 리소스 기반 Lottie 컴포저블 PrezelLottie 추가(재생 제어, 반복, 속도, 프레임 콜백 지원, 프리뷰 포함).
StatusView 변경
Prezel/core/ui/src/main/java/com/team/prezel/core/ui/component/StatusView.kt
파일 패키지를 .component로 이동하고 내부 StatusLottie 컴포저블 및 해당 프리뷰를 제거.
기능 모듈들의 import 경로 업데이트
Prezel/feature/.../impl/** (예: feature/history/..., feature/home/..., feature/login/..., feature/profile/..., feature/splash/...)
각 화면/뷰모델/contract 파일에서 LocalSnackbarHostState, BaseViewModel, advancedImePadding/onHeightChanged, 및 UI 계약 타입(UiEffect, UiIntent, UiState)의 임포트 경로를 새 하위 패키지로 변경. 일부 파일은 추가로 탭 클리어(포커스) 처리 혹은 클릭 범위 확대(terms screen) 같은 UI 수정을 포함.
Profile 닉네임 텍스트필드 적응
Prezel/feature/profile/impl/src/main/java/.../component/NicknameTextField.kt
NicknameTextField에서 PrezelTextFieldFeedbackPrezelTextFieldStatus로 매핑 함수/파라미터명 변경(매핑 로직 조정).

Possibly related PRs

🚥 Pre-merge checks | ✅ 4 | ❌ 1

❌ Failed checks (1 warning)

Check name Status Explanation Resolution
Docstring Coverage ⚠️ Warning Docstring coverage is 17.24% which is insufficient. The required threshold is 80.00%. Write docstrings for the functions missing them to satisfy the coverage threshold.
✅ Passed checks (4 passed)
Check name Status Explanation
Title check ✅ Passed PR 제목 'DS TextField & TextArea 변경 사항 반영'은 주요 변경 내용(디자인 시스템 TextField와 TextArea 업데이트)을 명확하게 요약하고 있습니다.
Description check ✅ Passed PR 설명에 작업 내용(색상 변경, Typing→Typed 상태 트리거 변경)과 논의 사항이 포함되어 있으나, 관련 이슈와 스크린샷은 제공되지 않았습니다.
Linked Issues check ✅ Passed Check skipped because no linked issues were found for this pull request.
Out of Scope Changes check ✅ Passed Check skipped because no linked issues were found for this pull request.

✏️ Tip: You can configure your own custom pre-merge checks in the settings.


Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands and usage tips.

@coderabbitai coderabbitai Bot left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Actionable comments posted: 3

Caution

Some comments are outside the diff and can’t be posted inline due to platform limitations.

⚠️ Outside diff range comments (1)
Prezel/feature/profile/impl/src/main/java/com/team/prezel/feature/profile/impl/component/NicknameTextField.kt (1)

26-45: ⚠️ Potential issue | 🟡 Minor

TooLong 상태에서 사용자에게 아무 피드백도 노출되지 않습니다.

현재 PrezelTextField 호출에 maxLength가 지정되지 않아(Int.MAX_VALUE 기본값) 사용자는 자유롭게 긴 닉네임을 입력할 수 있습니다. 반면 ViewModel 검증 결과 TooLong이 들어오면 DEFAULT(빈 메시지)로 매핑되어 오류 안내가 전혀 표시되지 않습니다. 다음 중 하나로 정리를 권장합니다:

  1. PrezelTextField에 닉네임 최대 길이를 maxLength로 지정해 UI 레벨에서 초과 입력 자체를 차단(이 경우 TooLong이 실제로 발생하지 않으므로 현재 매핑 유지 가능).
  2. TooLongBad로 매핑하고 해당 메시지 문자열을 표시.
🤖 Prompt for AI Agents
Verify each finding against the current code and only fix it if needed.

In
`@Prezel/feature/profile/impl/src/main/java/com/team/prezel/feature/profile/impl/component/NicknameTextField.kt`
around lines 26 - 45, The NicknameTextField currently neither limits input nor
surfaces the TooLong validation state; update the PrezelTextField call in
NicknameTextField (the PrezelTextField(...) invocation) to include a maxLength
parameter (e.g. match your ViewModel limit) so the UI prevents over-long input,
or change the mapping in NicknameValidationState.toNicknameStatus() to map
NicknameValidationState.TooLong -> PrezelTextFieldStatus.BAD and ensure the
corresponding error message string is provided to the PrezelTextField so users
see the TooLong feedback.
🧹 Nitpick comments (3)
Prezel/core/designsystem/src/main/java/com/team/prezel/core/designsystem/component/textfield/PrezelTextArea.kt (1)

186-223: 프리뷰에서 PrezelTextField와 SupportingText 노출 설정이 엇갈립니다.

PrezelTextField.kt의 Default/Disabled/Typing-Default 프리뷰는 모두 PrezelTextFieldStatus.Default("헬퍼 메시지")를 명시해 supporting text가 함께 렌더되지만, PrezelTextArea의 동일 상태 프리뷰는 status를 생략해 DEFAULT(빈 메시지)로 떨어지면서 supporting text 영역이 사라집니다. 디자인 검수 일관성을 위해 두 파일의 프리뷰 구성 방식을 맞추시길 권장합니다.

🤖 Prompt for AI Agents
Verify each finding against the current code and only fix it if needed.

In
`@Prezel/core/designsystem/src/main/java/com/team/prezel/core/designsystem/component/textfield/PrezelTextArea.kt`
around lines 186 - 223, PrezelTextArea preview functions
(PrezelTextAreaDefaultStatePreview, PrezelTextAreaDisabledStatePreview,
PrezelTextAreaTypingStatePreview) omit the status/supporting text while the
PrezelTextField previews set PrezelTextFieldStatus.Default("헬퍼 메시지"); to fix,
update each PrezelTextAreaPreviewItem invocation to include status =
PrezelTextFieldStatus.Default("헬퍼 메시지") (or the same helper text used by
PrezelTextField previews) so the supportingText renders consistently across
Default/Disabled/Typing previews.
Prezel/core/designsystem/src/main/java/com/team/prezel/core/designsystem/component/textfield/PrezelTextFieldState.kt (1)

214-222: remember 키 구성이 메모이제이션 효과가 없어 단순화 가능합니다.

remember(value, enabled, focused)가 입력 인자 전체를 키로 사용하므로 입력 중 매 컴포지션마다 캐시가 무효화되어 매번 재계산됩니다. 내부 로직(calculate)은 순수 when 분기라 할당 비용도 없으므로 remember 래핑이 실질적 이득 없이 슬롯만 차지합니다. 단순 계산 함수로 바꾸는 편이 더 읽기 쉽습니다.

♻️ 제안 diff
 `@Composable`
 internal fun rememberPrezelTextFieldState(
     value: String,
     enabled: Boolean,
     focused: Boolean,
 ): PrezelTextFieldState =
-    remember(value, enabled, focused) {
-        PrezelTextFieldState.calculate(enabled = enabled, focused = focused, hasValue = value.isNotEmpty())
-    }
+    PrezelTextFieldState.calculate(
+        enabled = enabled,
+        focused = focused,
+        hasValue = value.isNotEmpty(),
+    )

네이밍 컨벤션(remember*)을 유지하려면 최소한 remember(enabled, focused, value.isNotEmpty())로 키를 좁혀 실제 상태 변화에만 재계산이 일어나도록 조정할 수도 있습니다.

🤖 Prompt for AI Agents
Verify each finding against the current code and only fix it if needed.

In
`@Prezel/core/designsystem/src/main/java/com/team/prezel/core/designsystem/component/textfield/PrezelTextFieldState.kt`
around lines 214 - 222, 현재 rememberPrezelTextFieldState의 remember 호출은 value 전체를
키로 사용해 매입력마다 캐시가 무효화됩니다; 내부가 순수 계산인 PrezelTextFieldState.calculate를 감안하여
remember를 제거하고 단순히 PrezelTextFieldState.calculate(enabled = enabled, focused =
focused, hasValue = value.isNotEmpty())를 반환하거나, 네이밍을 유지하려면
rememberPrezelTextFieldState 내부의 remember 키를 remember(enabled, focused,
value.isNotEmpty())로 좁혀 실제 상태 변경에만 재계산되도록 수정하세요.
Prezel/core/designsystem/src/main/java/com/team/prezel/core/designsystem/component/textfield/component/PrezelTextFieldSupportingText.kt (1)

14-17: 파라미터 이름 state가 타입 PrezelTextFieldStyle과 불일치합니다.

PrezelTextFieldStyle 내부에 이미 state: PrezelTextFieldState 프로퍼티가 존재하기 때문에, 외부 호출부에서 state = PrezelTextFieldStyle(state = ..., status = ...) 형태로 중복된 이름이 섞여 읽기 어렵습니다. 네이밍을 style로 변경하면 의도가 더 명확해집니다. PrezelTextField.kt / PrezelTextArea.kt의 내부 composable들(PrezelTextFieldDecorationBox, PrezelTextAreaDecorationBox, Counter, PreviewTextFieldItem, PrezelTextAreaPreviewItem)도 동일하게 state: PrezelTextFieldStyle를 사용하므로 함께 정리하시길 권장합니다.

♻️ 제안 diff
 `@Composable`
 internal fun PrezelTextFieldSupportingText(
-    state: PrezelTextFieldStyle,
+    style: PrezelTextFieldStyle,
     modifier: Modifier = Modifier,
 ) {
     Text(
-        text = state.supportingText,
+        text = style.supportingText,
         style = PrezelTheme.typography.body3Regular,
-        color = state.supportingTextColor(),
+        color = style.supportingTextColor(),
         modifier = modifier,
         maxLines = 1,
     )
 }
🤖 Prompt for AI Agents
Verify each finding against the current code and only fix it if needed.

In
`@Prezel/core/designsystem/src/main/java/com/team/prezel/core/designsystem/component/textfield/component/PrezelTextFieldSupportingText.kt`
around lines 14 - 17, Rename the parameter named "state" of the
PrezelTextFieldSupportingText function to "style" to reflect its
PrezelTextFieldStyle type and avoid confusion with the nested
PrezelTextFieldState; update the function signature and all internal references
accordingly. Apply the same rename in related composables that currently take a
PrezelTextFieldStyle named "state"—specifically PrezelTextFieldDecorationBox,
PrezelTextAreaDecorationBox, Counter, PreviewTextFieldItem, and
PrezelTextAreaPreviewItem—so callers use style = PrezelTextFieldStyle(...)
without mixing names; ensure you update all call sites and any property
accessors (e.g., style.state) to the new parameter name to keep behavior
unchanged.
🤖 Prompt for all review comments with AI agents
Verify each finding against the current code and only fix it if needed.

Inline comments:
In
`@Prezel/core/ui/src/main/java/com/team/prezel/core/ui/component/PrezelLottie.kt`:
- Around line 39-43: The current composable directly invokes the callback in the
body (using updatedCallback from rememberUpdatedState), causing the callback to
run on every recomposition; instead wrap the invocation in a LaunchedEffect
keyed to progress so it only runs when progress changes. Locate the
rememberUpdatedState(onAnimationFrame) usage and remove the direct
updatedCallback?.invoke(progress) call from the composable body; add a
LaunchedEffect(progress) { updatedCallback?.invoke(progress) } so the callback
executes only when progress updates and still uses the latest onAnimationFrame
reference.

In
`@Prezel/feature/profile/impl/src/main/java/com/team/prezel/feature/profile/impl/component/NicknameTextField.kt`:
- Around line 47-49: The Available case in the NicknameTextField mapping
currently returns PrezelTextFieldStatus.Default which is neutral; change the
mapping for NicknameValidationState.Available to return
PrezelTextFieldStatus.Good (keeping the same message
stringResource(R.string.feature_profile_impl_nickname_helper_available)) so the
UI shows positive feedback (feedbackGoodRegular color/border) instead of neutral
styling; update the match/when branch in NicknameTextField.kt where
NicknameValidationState.Available is handled accordingly and, if this affects
design intent, confirm with Design as noted in the PR.

In
`@Prezel/feature/profile/impl/src/main/java/com/team/prezel/feature/profile/impl/ProfileScreen.kt`:
- Around line 147-154: The detectTapGestures that clears focus is applied only
to the inner Column in ProfileScreenContent (using LocalFocusManager.current and
detectTapGestures) so taps on ProfileScreenTopAppBar or PrezelButtonArea don’t
clear focus; move the pointerInput { detectTapGestures(onTap = {
focusManager.clearFocus() }) } from the inner Column to the top-level Column
that composes the whole screen (the Column around the top app bar and button
area) so that all external taps clear focus, and verify behavior also for child
views that may consume down events like ProfileImageEditor and
NicknameTextField.

---

Outside diff comments:
In
`@Prezel/feature/profile/impl/src/main/java/com/team/prezel/feature/profile/impl/component/NicknameTextField.kt`:
- Around line 26-45: The NicknameTextField currently neither limits input nor
surfaces the TooLong validation state; update the PrezelTextField call in
NicknameTextField (the PrezelTextField(...) invocation) to include a maxLength
parameter (e.g. match your ViewModel limit) so the UI prevents over-long input,
or change the mapping in NicknameValidationState.toNicknameStatus() to map
NicknameValidationState.TooLong -> PrezelTextFieldStatus.BAD and ensure the
corresponding error message string is provided to the PrezelTextField so users
see the TooLong feedback.

---

Nitpick comments:
In
`@Prezel/core/designsystem/src/main/java/com/team/prezel/core/designsystem/component/textfield/component/PrezelTextFieldSupportingText.kt`:
- Around line 14-17: Rename the parameter named "state" of the
PrezelTextFieldSupportingText function to "style" to reflect its
PrezelTextFieldStyle type and avoid confusion with the nested
PrezelTextFieldState; update the function signature and all internal references
accordingly. Apply the same rename in related composables that currently take a
PrezelTextFieldStyle named "state"—specifically PrezelTextFieldDecorationBox,
PrezelTextAreaDecorationBox, Counter, PreviewTextFieldItem, and
PrezelTextAreaPreviewItem—so callers use style = PrezelTextFieldStyle(...)
without mixing names; ensure you update all call sites and any property
accessors (e.g., style.state) to the new parameter name to keep behavior
unchanged.

In
`@Prezel/core/designsystem/src/main/java/com/team/prezel/core/designsystem/component/textfield/PrezelTextArea.kt`:
- Around line 186-223: PrezelTextArea preview functions
(PrezelTextAreaDefaultStatePreview, PrezelTextAreaDisabledStatePreview,
PrezelTextAreaTypingStatePreview) omit the status/supporting text while the
PrezelTextField previews set PrezelTextFieldStatus.Default("헬퍼 메시지"); to fix,
update each PrezelTextAreaPreviewItem invocation to include status =
PrezelTextFieldStatus.Default("헬퍼 메시지") (or the same helper text used by
PrezelTextField previews) so the supportingText renders consistently across
Default/Disabled/Typing previews.

In
`@Prezel/core/designsystem/src/main/java/com/team/prezel/core/designsystem/component/textfield/PrezelTextFieldState.kt`:
- Around line 214-222: 현재 rememberPrezelTextFieldState의 remember 호출은 value 전체를
키로 사용해 매입력마다 캐시가 무효화됩니다; 내부가 순수 계산인 PrezelTextFieldState.calculate를 감안하여
remember를 제거하고 단순히 PrezelTextFieldState.calculate(enabled = enabled, focused =
focused, hasValue = value.isNotEmpty())를 반환하거나, 네이밍을 유지하려면
rememberPrezelTextFieldState 내부의 remember 키를 remember(enabled, focused,
value.isNotEmpty())로 좁혀 실제 상태 변경에만 재계산되도록 수정하세요.
🪄 Autofix (Beta)

Fix all unresolved CodeRabbit comments on this PR:

  • Push a commit to this branch (recommended)
  • Create a new PR with the fixes

ℹ️ Review info
⚙️ Run configuration

Configuration used: Path: .coderabbit.yaml

Review profile: CHILL

Plan: Pro

Run ID: 96f18461-8393-4fe4-a765-273b84fc0822

📥 Commits

Reviewing files that changed from the base of the PR and between 4739f93 and 3cd99c5.

📒 Files selected for processing (43)
  • Prezel/app/src/main/java/com/team/prezel/ui/DoubleBackToExitHandler.kt
  • Prezel/app/src/main/java/com/team/prezel/ui/PrezelApp.kt
  • Prezel/core/designsystem/src/main/java/com/team/prezel/core/designsystem/component/textfield/PrezelTextArea.kt
  • Prezel/core/designsystem/src/main/java/com/team/prezel/core/designsystem/component/textfield/PrezelTextField.kt
  • Prezel/core/designsystem/src/main/java/com/team/prezel/core/designsystem/component/textfield/PrezelTextFieldState.kt
  • Prezel/core/designsystem/src/main/java/com/team/prezel/core/designsystem/component/textfield/component/PrezelTextFieldSupportingText.kt
  • Prezel/core/ui/src/main/java/com/team/prezel/core/ui/base/BaseViewModel.kt
  • Prezel/core/ui/src/main/java/com/team/prezel/core/ui/component/PrezelLottie.kt
  • Prezel/core/ui/src/main/java/com/team/prezel/core/ui/component/StatusView.kt
  • Prezel/core/ui/src/main/java/com/team/prezel/core/ui/state/LocalSnackbarHostState.kt
  • Prezel/core/ui/src/main/java/com/team/prezel/core/ui/util/AdvancedImePadding.kt
  • Prezel/core/ui/src/main/java/com/team/prezel/core/ui/util/OnHeightChanged.kt
  • Prezel/feature/history/impl/src/main/java/com/team/prezel/feature/history/impl/HistoryScreen.kt
  • Prezel/feature/history/impl/src/main/java/com/team/prezel/feature/history/impl/HistoryViewModel.kt
  • Prezel/feature/history/impl/src/main/java/com/team/prezel/feature/history/impl/component/HistoryEmptyContent.kt
  • Prezel/feature/history/impl/src/main/java/com/team/prezel/feature/history/impl/contract/HistoryUiEffect.kt
  • Prezel/feature/history/impl/src/main/java/com/team/prezel/feature/history/impl/contract/HistoryUiIntent.kt
  • Prezel/feature/history/impl/src/main/java/com/team/prezel/feature/history/impl/contract/HistoryUiState.kt
  • Prezel/feature/home/impl/src/main/java/com/team/prezel/feature/home/impl/HomeScreen.kt
  • Prezel/feature/home/impl/src/main/java/com/team/prezel/feature/home/impl/HomeViewModel.kt
  • Prezel/feature/home/impl/src/main/java/com/team/prezel/feature/home/impl/component/HomePageLayout.kt
  • Prezel/feature/home/impl/src/main/java/com/team/prezel/feature/home/impl/contract/HomeUiEffect.kt
  • Prezel/feature/home/impl/src/main/java/com/team/prezel/feature/home/impl/contract/HomeUiIntent.kt
  • Prezel/feature/home/impl/src/main/java/com/team/prezel/feature/home/impl/contract/HomeUiState.kt
  • Prezel/feature/login/impl/src/main/java/com/team/prezel/feature/login/impl/landing/LoginScreen.kt
  • Prezel/feature/login/impl/src/main/java/com/team/prezel/feature/login/impl/landing/LoginViewModel.kt
  • Prezel/feature/login/impl/src/main/java/com/team/prezel/feature/login/impl/landing/contract/LoginUiEffect.kt
  • Prezel/feature/login/impl/src/main/java/com/team/prezel/feature/login/impl/landing/contract/LoginUiIntent.kt
  • Prezel/feature/login/impl/src/main/java/com/team/prezel/feature/login/impl/landing/contract/LoginUiState.kt
  • Prezel/feature/login/impl/src/main/java/com/team/prezel/feature/login/impl/terms/TermsViewModel.kt
  • Prezel/feature/login/impl/src/main/java/com/team/prezel/feature/login/impl/terms/contract/TermsUiEffect.kt
  • Prezel/feature/login/impl/src/main/java/com/team/prezel/feature/login/impl/terms/contract/TermsUiIntent.kt
  • Prezel/feature/login/impl/src/main/java/com/team/prezel/feature/login/impl/terms/contract/TermsUiState.kt
  • Prezel/feature/profile/impl/src/main/java/com/team/prezel/feature/profile/impl/ProfileScreen.kt
  • Prezel/feature/profile/impl/src/main/java/com/team/prezel/feature/profile/impl/ProfileViewModel.kt
  • Prezel/feature/profile/impl/src/main/java/com/team/prezel/feature/profile/impl/component/NicknameTextField.kt
  • Prezel/feature/profile/impl/src/main/java/com/team/prezel/feature/profile/impl/contract/ProfileUiEffect.kt
  • Prezel/feature/profile/impl/src/main/java/com/team/prezel/feature/profile/impl/contract/ProfileUiIntent.kt
  • Prezel/feature/profile/impl/src/main/java/com/team/prezel/feature/profile/impl/contract/ProfileUiState.kt
  • Prezel/feature/splash/impl/src/main/java/com/team/prezel/feature/splash/impl/SplashViewModel.kt
  • Prezel/feature/splash/impl/src/main/java/com/team/prezel/feature/splash/impl/contract/SplashUiEffect.kt
  • Prezel/feature/splash/impl/src/main/java/com/team/prezel/feature/splash/impl/contract/SplashUiIntent.kt
  • Prezel/feature/splash/impl/src/main/java/com/team/prezel/feature/splash/impl/contract/SplashUiState.kt

* `onAnimationFrame` 콜백이 `progress` 상태 변화에 따라 실행되도록 `LaunchedEffect`를 적용하였습니다.
* 기존 컴포저블 본문에서 직접 호출하던 방식에서 Side-effect API를 사용하는 구조로 변경하여 안정성을 높였습니다.
`PrezelTextField`의 상태 관리 로직을 최적화하고 가독성을 위해 코드 포맷을 수정했습니다.

* **refactor: remember 블록 제거 및 상태 계산 로직 최적화**
    * `rememberPrezelTextFieldState` 함수에서 불필요한 `remember` 블록을 제거하여 호출부에서 상태를 직접 계산하도록 변경했습니다.

* **style: 코드 포맷팅 및 들여쓰기 수정**
    * `PrezelTextFieldStyle` 내 `backgroundColor`, `iconColor`, `border` 관련 `when` 조건문의 들여쓰기를 수정하여 가독성을 개선했습니다.
    * 불필요한 import(`androidx.compose.runtime.remember`)를 제거했습니다.
`PrezelTextField` 및 `PrezelTextArea` 컴포넌트의 가독성을 높이고 내부 로직을 정리하였습니다.

* **refactor: TextField 및 TextArea 파라미터 명칭 변경**
    * 내부 UI 구성에 사용되는 `PrezelTextFieldStyle` 타입의 파라미터 명칭을 `state`에서 `style`로 변경하여 역할을 명확히 함
    * `rememberPrezelTextFieldState` 결과값 변수명을 `state`에서 `style`로 변경

* **refactor: PrezelTextFieldSupportingText 구조 개선**
    * 기존에 `PrezelTextFieldStyle` 객체 전체를 전달받던 방식에서 `text`와 `textColor`를 개별 파라미터로 직접 전달받도록 수정하여 결합도를 낮춤
    * 변경된 구조에 맞춰 Preview 코드 및 호출부 로직 수정

* **style: 코드 포맷팅 및 정렬 수정**
    * `PrezelTextFieldState.kt` 내 `when` 문 및 함수 반환 타입 선언부의 들여쓰기와 줄바꿈을 일관성 있게 수정하여 가독성 개선
`TermsScreen`의 전체 동의 리스트 아이템(`PrezelList`)에 `clickable` 수식어를 추가하여, 체크박스뿐만 아니라 텍스트 영역을 클릭해도 `onToggleAll` 이벤트가 발생하도록 개선했습니다. 리플 효과(indication)와 상호작용 소스(interactionSource)를 `null`로 설정하여 불필요한 시각적 효과를 제거했습니다.

@HamBeomJoon HamBeomJoon left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

고생하셨습니다 👍

@moondev03 moondev03 merged commit 5ac10b1 into develop Apr 24, 2026
1 of 2 checks passed
@moondev03 moondev03 deleted the refactor/ds-textfield-update branch April 24, 2026 12:03
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

🔨 refactor 기능 변경 없이 내부 구조, 설계, 가독성 개선

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants