Skip to content

[#334] TodoList의 헤더가 보이지 않는 현상을 해결한다#335

Merged
opficdev merged 1 commit intodevelopfrom
fix/#334-header
Mar 30, 2026
Merged

[#334] TodoList의 헤더가 보이지 않는 현상을 해결한다#335
opficdev merged 1 commit intodevelopfrom
fix/#334-header

Conversation

@opficdev
Copy link
Copy Markdown
Owner

@opficdev opficdev self-assigned this Mar 30, 2026
Copy link
Copy Markdown
Contributor

@gemini-code-assist gemini-code-assist bot left a comment

Choose a reason for hiding this comment

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

Code Review

This pull request simplifies the header height logic in TodoListView.swift by removing dynamic height tracking via GeometryReader and replacing it with a static calculation based on the body font's line height. A review comment was provided suggesting that the hardcoded magic number 20 used in the height calculation be replaced with a named constant to improve maintainability and clarity.

.scrollDisabled(!isScrollTrackingEnabled)
.contentMargins(.leading, 16, for: .scrollContent)
.frame(height: headerHeight)
.frame(height: UIFont.preferredFont(forTextStyle: .body).lineHeight.rounded(.up) + 20)
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.

medium

하드코딩된 값 20은 헤더의 높이를 결정하는 중요한 값입니다. 이 값은 adaptiveButtonStyle의 패딩(상하 8pt씩 총 16pt)과 추가 여백(4pt)으로 계산된 것으로 보입니다. 가독성과 유지보수성을 위해 이 값을 headerVerticalPadding과 같은 이름의 상수로 정의하고, 주석으로 산출 근거를 남기는 것을 권장합니다.

@opficdev opficdev merged commit 15cb106 into develop Mar 30, 2026
1 check passed
@opficdev opficdev deleted the fix/#334-header branch March 30, 2026 00:46
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

ToooList의 헤더가 보이지 않는 현상을 해결한다

1 participant