Skip to content

[FIX] 통계 페이지 스크롤 및 레이아웃 개선 - #171

Merged
kimminna merged 4 commits into
developfrom
fix/web/168-statistics-panel-layout
Jul 13, 2026
Merged

[FIX] 통계 페이지 스크롤 및 레이아웃 개선#171
kimminna merged 4 commits into
developfrom
fix/web/168-statistics-panel-layout

Conversation

@yumin-kim2

@yumin-kim2 yumin-kim2 commented Jul 13, 2026

Copy link
Copy Markdown
Contributor

ISSUE 🔗

clsoe #168



What is this PR? 🔍

1. 오른쪽 패널 배경이 투명하게 보이는 문제

기존에는 오른쪽 패널에 명시적인 배경색이 없어, 캘린더 아이콘이나 텍스트가 패널 뒤로 비쳐 보이는 문제가 있었습니다.

이를 해결하기 위해 StatisticsSidePanel의 공통 class에 bg-white를 추가했습니다. 월별 패널과 일별 패널이 같은 class를 공유하고 있어서, 한 곳에서 두 variant 모두 동일하게 흰 배경을 갖도록 처리했습니다.

2. 오른쪽 패널이 헤더 아래에서 시작하는 문제

기존 구조에서는 오른쪽 패널이 캘린더 content 영역 안에 들어가 있었습니다.

<StatisticsHeaderContainer />
<div>
  <StatisticsCalendarContainer />
  <StatisticsSidePanel />
</div>

이 구조에서는 패널이 헤더 아래부터 시작할 수밖에 없었습니다. 아무리 h-full이나 min-h-full을 줘도, 부모가 이미 헤더 아래 영역이기 때문입니다.
그래서 통계 화면 전체를 좌우 레이아웃으로 나누고, 왼쪽에는 헤더와 캘린더를 세로로 배치하고 오른쪽에는 패널을 독립적으로 배치하는 구조로 정리했어요.

<div>
  <div>
    <StatisticsHeaderContainer />
    <StatisticsCalendarContainer />
  </div>

  <StatisticsSidePanel />
</div>

이렇게 바꾸면서 오른쪽 패널이 헤더 높이까지 포함한 전체 높이를 차지할 수 있게 되었습니다!

3. 캘린더 세로 스크롤 시 월/날짜 제목과 요일이 같이 밀리는 문제

캘린더에서 날짜 아이콘이 많아져 세로 스크롤이 생길 때, 처음에는 월 제목과 요일 row까지 같이 스크롤되는 문제가 있었습니다.
처음에는 캘린더 구조를 크게 나누는 방식도 검토했지만, 실제로 필요한 수정은 <“고정되어야 하는 영역만 sticky로 묶는 것”>이었습니다. 그래서 큰 구조 변경 대신 기존 DOM 흐름을 최대한 유지하면서 다음 영역만 sticky 처리했습니다.

  • 월 제목
  • 날짜 설명
  • 요일 row
<div className="sticky top-0 z-10 bg-white pt-5 pb-5">
  ...
</div>

이제 세로 스크롤이 발생해도 위 영역은 고정되고, 날짜 아이콘 grid만 스크롤됩니다.

4. 요일과 날짜 아이콘 사이 간격 유지

요일 row를 sticky 영역으로 옮긴 뒤, 스크롤 시 요일과 날짜 아이콘 사이의 20px 간격이 유지되지 않는 문제가 있었습니다.
처음에는 날짜 grid 쪽에 pt-5를 주었지만, 이 경우 간격도 날짜 grid와 함께 스크롤되어 sticky 상태에서 간격이 사라져 보였습니다.
그래서 20px 간격을 날짜 grid가 아니라 sticky 영역의 하단 padding으로 옮겼습니다.

<div className="sticky top-0 z-10 bg-white pt-5 pb-5">

이렇게 해서 스크롤 중에도 요일과 날짜 아이콘 사이의 간격이 유지되도록 했습니다.


To Reviewers

이번 작업은 레이아웃을 크게 갈아엎기보다, 기존 캘린더 구조를 최대한 유지하면서 필요한 부분만 수정하는 방향으로 진행했습니다.

특히 캘린더 내부 스크롤 문제는 처음에 구조를 크게 분리하는 방식도 고민했지만, 변경 범위가 커지고 의도하지 않은 가로 스크롤까지 생길 수 있어 최종적으로는 sticky를 활용하는 방식으로 정리했습니다.



Screenshot 📷

2026-07-13.4.52.18.mov



Test Checklist ✔

  • pnpm --filter timo-web check-types 통과
  • pnpm --filter timo-web lint 통과
  • 오른쪽 패널에 흰 배경이 적용되는지 확인
  • 오른쪽 패널이 헤더 영역까지 포함해 표시되는지 확인
  • 세로 스크롤 시 월 제목/날짜 설명/요일 row가 고정되는지 확인
  • 날짜 아이콘 grid만 스크롤되는지 확인
  • 스크롤 중에도 요일과 날짜 아이콘 사이 20px 간격이 유지되는지 확인

@vercel

vercel Bot commented Jul 13, 2026

Copy link
Copy Markdown

The latest updates on your projects. Learn more about Vercel for GitHub.

Project Deployment Actions Updated (UTC)
timo Ready Ready Preview, Comment Jul 13, 2026 7:57am

Request Review

@github-actions
github-actions Bot requested review from ehye1 and kimminna July 13, 2026 07:57
@github-actions github-actions Bot added ⏰ Timo-web Timo 웹 서비스 🐛 Bug 기능이 정상적으로 작동하지 않는 문제 수정 ♣️ 유민 유민양 labels Jul 13, 2026
@coderabbitai

coderabbitai Bot commented Jul 13, 2026

Copy link
Copy Markdown

Review Change Stack

Walkthrough

통계 화면의 헤더와 캘린더를 좌측 컬럼으로 분리하고 사이드 패널을 형제 영역으로 재배치했습니다. 캘린더에는 스크롤 시 상단에 유지되는 헤더와 흰색 배경을 적용했으며, 사이드 패널의 높이와 배경 스타일을 조정했습니다.

Changes

통계 화면 레이아웃

Layer / File(s) Summary
콘텐츠 컬럼과 사이드 패널 배치
apps/timo-web/app/[locale]/(main)/statistics/_containers/StatisticsContainer.tsx
헤더와 캘린더를 좌측의 flex-1 컬럼으로 묶고, 사이드 패널을 해당 컬럼의 형제로 배치했습니다.
캘린더 고정 헤더와 패널 스타일
apps/timo-web/app/[locale]/(main)/statistics/_components/StatisticsCalendar.tsx, apps/timo-web/app/[locale]/(main)/statistics/_components/StatisticsSidePanel.tsx
캘린더에 가로 스크롤과 sticky 헤더를 적용하고, 캘린더 및 사이드 패널에 흰색 배경과 전체 높이 스타일을 설정했습니다.

Estimated code review effort: 2 (Simple) | ~10 minutes

Possibly related issues

Possibly related PRs

  • Team-Timo/Timo-client#128: 동일한 StatisticsSidePanel 컴포넌트의 동작과 스타일 영역을 구현한 PR입니다.
  • Team-Timo/Timo-client#133: 동일한 StatisticsCalendar 컴포넌트의 캘린더 그리드와 헤더 구현을 다룹니다.
  • Team-Timo/Timo-client#143: StatisticsCalendar, StatisticsSidePanel, StatisticsContainer의 통계 화면 레이아웃을 함께 변경한 PR입니다.

Suggested reviewers: jjangminii, ehye1

🚥 Pre-merge checks | ✅ 5
✅ Passed checks (5 passed)
Check name Status Explanation
Title check ✅ Passed 제목이 통계 페이지의 스크롤과 레이아웃 개선이라는 핵심 변경점을 간결하게 잘 담고 있습니다.
Description check ✅ Passed 설명이 실제 변경사항인 오른쪽 패널 배경, 좌우 레이아웃, sticky 캘린더 개선과 잘 맞습니다.
Docstring Coverage ✅ Passed No functions found in the changed files to evaluate docstring coverage. Skipping docstring coverage check.
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.
✨ Finishing Touches
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Commit unit tests in branch fix/web/168-statistics-panel-layout

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.

@github-actions

Copy link
Copy Markdown

Timo Performance Report

Bundle Size — timo-web
라우트 크기 First Load JS
/[locale]/home 194.75 kB 🔴 400.58 kB
/[locale]/today 154.53 kB 🔴 360.36 kB
/[locale]/focus 151.47 kB 🔴 357.30 kB
/[locale]/settings/account 0 B 🟡 205.83 kB
/[locale]/settings 161.46 kB 🔴 367.29 kB
/[locale]/statistics 150.06 kB 🔴 355.89 kB
/[locale]/[...rest] 0 B 🟡 205.83 kB
/[locale]/login 116.84 kB 🟡 322.67 kB
/[locale]/oauth/callback 116.86 kB 🟡 322.69 kB
/[locale]/onboarding 228.99 kB 🔴 434.82 kB
/[locale] 0 B 🟡 205.83 kB

공유 번들: 205.83 kB
🟢 < 200kB  |  🟡 < 350kB  |  🔴 ≥ 350kB (First Load JS · gzip)

Lighthouse — timo-web
URL Perf A11y LCP CLS TBT
/en/home 🔴 60 🟢 95 🔴 15.7s 🟢 0.000 🟡 580ms
/en/today 🔴 61 🟢 95 🔴 15.3s 🟢 0.000 🟡 549ms
/en/focus 🔴 59 🟢 95 🔴 15.3s 🟢 0.000 🔴 614ms
/en/statistics 🔴 61 🟢 95 🔴 15.5s 🟢 0.000 🟡 548ms

Perf ≥ 70 / A11y ≥ 85 목표
LCP 🟢 < 2.5s 🟡 < 4s 🔴 ≥ 4s  |  CLS 🟢 < 0.1 🟡 < 0.25 🔴 ≥ 0.25  |  TBT 🟢 < 200ms 🟡 < 600ms 🔴 ≥ 600ms

Image Optimization — timo-web
파일 크기 포맷 상태
images/google-calendar.png 36.20 kB PNG ⚠️ 🟢
images/google-logo.png 26.79 kB PNG ⚠️ 🟢

총 2개 · 63.00 kB  |  🟢 < 200KB  |  🟡 < 500KB  |  🔴 ≥ 500KB
⚠️ 2개 파일 WebP/AVIF 변환 권장

측정 커밋: ef0e44d

@coderabbitai coderabbitai Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

Actionable comments posted: 1

🤖 Prompt for all review comments with AI agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.

Inline comments:
In
`@apps/timo-web/app/`[locale]/(main)/statistics/_components/StatisticsSidePanel.tsx:
- Line 31: Update the StatisticsSidePanel base class list to add vertical
auto-overflow handling alongside h-full, so lengthy day-variant todo content
scrolls within the panel without changing the existing sizing or styling
classes.
🪄 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: ASSERTIVE

Plan: Pro Plus

Run ID: f7dfa96a-6046-4808-9564-b08415b607e5

📥 Commits

Reviewing files that changed from the base of the PR and between 8b39b01 and 8d5df34.

📒 Files selected for processing (3)
  • apps/timo-web/app/[locale]/(main)/statistics/_components/StatisticsCalendar.tsx
  • apps/timo-web/app/[locale]/(main)/statistics/_components/StatisticsSidePanel.tsx
  • apps/timo-web/app/[locale]/(main)/statistics/_containers/StatisticsContainer.tsx


const SIDE_PANEL_CLASS_NAME =
"border-timo-gray-500 min-h-full w-[304px] shrink-0 border-l text-timo-black";
"border-timo-gray-500 bg-white h-full w-[304px] shrink-0 border-l text-timo-black";

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

🩺 Stability & Availability | 🟠 Major | ⚡ Quick win

h-full 변경에 따른 세로 스크롤 처리가 필요합니다.

min-h-fullh-full 변경으로 패널 높이가 부모 컨테이너에 고정됩니다. day 변형에서 todo 리스트가 길어지면 콘텐츠가 패널 영역을 벗어나게 됩니다. overflow-y-auto를 추가하면 패널 내에서 독립적으로 스크롤할 수 있습니다.

CSS 스펙상 overflow-y: visible일 때 자식 콘텐츠가 넘치면 부모 영역 밖으로 보이게 되므로, 레이아웃이 깨질 수 있습니다. CSS Overflow Module Level 3 참고.

🔧 제안: overflow-y-auto 추가
 const SIDE_PANEL_CLASS_NAME =
-  "border-timo-gray-500 bg-white h-full w-[304px] shrink-0 border-l text-timo-black";
+  "border-timo-gray-500 bg-white h-full w-[304px] shrink-0 overflow-y-auto border-l text-timo-black";
📝 Committable suggestion

‼️ IMPORTANT
Carefully review the code before committing. Ensure that it accurately replaces the highlighted code, contains no missing lines, and has no issues with indentation. Thoroughly test & benchmark the code to ensure it meets the requirements.

Suggested change
"border-timo-gray-500 bg-white h-full w-[304px] shrink-0 border-l text-timo-black";
"border-timo-gray-500 bg-white h-full w-[304px] shrink-0 overflow-y-auto border-l text-timo-black";
🤖 Prompt for AI Agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.

In
`@apps/timo-web/app/`[locale]/(main)/statistics/_components/StatisticsSidePanel.tsx
at line 31, Update the StatisticsSidePanel base class list to add vertical
auto-overflow handling alongside h-full, so lengthy day-variant todo content
scrolls within the panel without changing the existing sizing or styling
classes.

@kimminna
kimminna merged commit cc776ec into develop Jul 13, 2026
18 checks passed
@kimminna
kimminna deleted the fix/web/168-statistics-panel-layout branch July 13, 2026 13:45
@kimminna kimminna mentioned this pull request Jul 14, 2026
@coderabbitai coderabbitai Bot mentioned this pull request Jul 15, 2026
5 tasks
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

⏰ Timo-web Timo 웹 서비스 ♣️ 유민 유민양 🐛 Bug 기능이 정상적으로 작동하지 않는 문제 수정

Projects

None yet

Development

Successfully merging this pull request may close these issues.

[FIX] 통계 페이지 오른쪽 패널 레이아웃 수정 및 캘린더 가로 스크롤

2 participants