[Feature/#287] 타임라인 성과 패널 일별 변화 추이 ApexChart 연동#293
Conversation
|
Warning Review limit reached
Next review available in: 38 minutes Enable usage-based reviews in Billing to review now. Otherwise, wait until the next included review is available. How can I continue?After more reviews become available, a review can be triggered using the To avoid repeated limits, reduce automatic review volume by pausing incremental auto-reviews earlier, using label-based review opt-in, excluding WIP or generated PR titles, or requesting reviews manually when the PR is ready. If your team needs uninterrupted high-volume reviews, an organization admin can enable usage-based reviews. How do review limits work?CodeRabbit enforces per-developer PR review limits for each organization. Most developers receive the normal plan review availability. For paid Pro and Pro+ PR reviews, CodeRabbit uses adaptive limits for sustained high-volume activity. When a developer's recent PR review activity reaches the 95th percentile or higher among CodeRabbit users, additional reviews become available more gradually as earlier reviews age out of the rolling window. Please refer docs for additional details. Review details⚙️ Run configurationConfiguration used: Path: .coderabbit.yaml Review profile: CHILL Plan: Pro Run ID: 📒 Files selected for processing (1)
📝 WalkthroughWalkthrough타임라인 성과 상태의 null 및 비표준 값을 기본 상태로 정규화하고, 상세 API의 Changes타임라인 성과 패널
Estimated code review effort: 3 (Moderate) | ~25 minutes Sequence Diagram(s)sequenceDiagram
participant TimelinePerformancePanel
participant TimelineDailyTrendChart
participant buildTimelineChartSeries
participant ReactApexChart
TimelinePerformancePanel->>TimelineDailyTrendChart: dailyTrend와 metric 전달
TimelineDailyTrendChart->>buildTimelineChartSeries: 차트 시리즈 계산
buildTimelineChartSeries-->>TimelineDailyTrendChart: series와 축 범위 반환
TimelineDailyTrendChart->>ReactApexChart: area 차트 렌더링
Possibly related PRs
Suggested reviewers: 🚥 Pre-merge checks | ✅ 5✅ Passed checks (5 passed)
✨ Finishing Touches🧪 Generate unit tests (beta)
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. Comment |
📚 Storybook 배포 완료
|
There was a problem hiding this comment.
Actionable comments posted: 1
🧹 Nitpick comments (1)
src/utils/timeline/buildTimelineSummaryPanel.ts (1)
40-42: 📐 Maintainability & Code Quality | 🔵 Trivial | ⚡ Quick win지표 라벨 조회 로직이 중복되어 있습니다.
buildTimelineChartSeries.ts에서getTimelineMetricLabel으로 이미 내보낸 동일 로직이buildTimelineSummaryPanel.ts의 인라인 라벨 조회(TIMELINE_METRIC_OPTIONS.find(...)?.label ?? metricKey)와 중복됩니다. 하나의 소스 오브 트루스를 사용하면 향후 메트릭 옵션 변경 시 누락을 방지할 수 있습니다.
src/utils/timeline/buildTimelineSummaryPanel.ts#L40-L42:getTimelineMetricLabel을 import하여 인라인 조회를 대체하세요.src/utils/timeline/buildTimelineChartSeries.ts#L22-L27: 기존 export 그대로 유지하면 됩니다.♻️ 제안: buildTimelineSummaryPanel.ts에서 getTimelineMetricLabel 재사용
+ import { getTimelineMetricLabel } from "`@/utils/timeline/buildTimelineChartSeries`"; import { resolveTimelinePerformanceStatus } from "`@/constants/timeline/statusStyle`";const metrics = detail.metrics.map((metricKey) => { - const label = - TIMELINE_METRIC_OPTIONS.find((option) => option.value === metricKey) - ?.label ?? metricKey; + const label = getTimelineMetricLabel(metricKey);🤖 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 `@src/utils/timeline/buildTimelineSummaryPanel.ts` around lines 40 - 42, Replace the inline metric-label lookup in buildTimelineSummaryPanel.ts with the exported getTimelineMetricLabel helper from buildTimelineChartSeries.ts, adding the required import and passing metricKey to it. Keep the existing getTimelineMetricLabel export in buildTimelineChartSeries.ts unchanged; no direct change is required there.
🤖 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 `@src/utils/timeline/buildTimelineChartSeries.ts`:
- Around line 40-54: Update calcChartYMax so non-ROAS values use the computed
magnitude as the unit at every scale, removing the minimum-1000 behavior.
Preserve the existing 20% padding and ceiling logic so values such as 5, 50,
500, and 5000 produce appropriately scaled maxima.
---
Nitpick comments:
In `@src/utils/timeline/buildTimelineSummaryPanel.ts`:
- Around line 40-42: Replace the inline metric-label lookup in
buildTimelineSummaryPanel.ts with the exported getTimelineMetricLabel helper
from buildTimelineChartSeries.ts, adding the required import and passing
metricKey to it. Keep the existing getTimelineMetricLabel export in
buildTimelineChartSeries.ts unchanged; no direct change is required there.
🪄 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: 802cf93b-00cb-485c-8069-3098dce6d58a
📒 Files selected for processing (11)
src/components/timeline/TimelineBar.tsxsrc/components/timeline/TimelinePerformancePanel.tsxsrc/components/timeline/charts/TimelineDailyTrendChart.tsxsrc/components/timeline/charts/timelineDailyTrendChart.config.tssrc/constants/timeline/statusStyle.tssrc/types/timeline/api.tssrc/types/timeline/summary.tssrc/types/timeline/timeline.mock.tssrc/utils/timeline/buildTimelineChartSeries.tssrc/utils/timeline/buildTimelineGrid.tssrc/utils/timeline/buildTimelineSummaryPanel.ts
🚨 관련 이슈
Closed #287
✨ 변경사항
✏️ 작업 내용
ITimelineSummaryPanelData에dailyTrend/endDate/startDate추가하여buildTimelineSummaryPanel에서 상세 API dailyTrend를 패널 props로 전달buildtimelineChartSeriesutil 함수로dailyTrend를 Apex series({x, y})로 변환함timelineDailyTrendChart.config.ts,TimelineDailyTrendChart추가하여 lazy Apex과 option 분리TimelinePerformancePanel에 기존에 placeholder로 구현되어있던 부분을 일별 추이 차트로 교체metrics[0]으로 설정하였고, 없으면 CLICK(클릭수)로. legend는 선택 지표 라벨과 동기화😅 미완성 작업
TimelinePeriodSelector와 차트 데이터 slice/집계 연동 (현재는 UI만 유지)📢 논의 사항 및 참고 사항
Summary by CodeRabbit
새로운 기능
개선 사항