fix(resume): PDFのプロジェクト見出しがページ跨ぎで繰り返すのを解消#434
Conversation
経歴書PDFでプロジェクトの詳細がページを跨ぐと、WeasyPrintが thead を各ページ先頭で繰り返し、見出し(期間/役割/体制/工程・ スキルセット)が毎ページ表示されていた。見出し行を thead から tbody の先頭行へ移し、見出しは1回のみ表示・詳細はページ境界で 見切れる挙動にする。 Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
|
No actionable comments were generated in the recent review. 🎉 ℹ️ Recent review info⚙️ Run configurationConfiguration used: defaults Review profile: CHILL Plan: Pro Plus Run ID: 📒 Files selected for processing (3)
📝 WalkthroughWalkthroughThe project table header row in ChangesProject table thead → tbody migration
Estimated code review effort🎯 1 (Trivial) | ⏱️ ~3 minutes Possibly related PRs
Poem
🚥 Pre-merge checks | ✅ 5✅ Passed checks (5 passed)
✨ Finishing Touches📝 Generate docstrings
🧪 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 |
概要
経歴書PDFでプロジェクトの詳細がページを跨ぐとき、プロジェクト見出し(期間/役割/体制/工程・スキルセット)が各ページの先頭で繰り返し表示されていた。これを「見出しは1回のみ表示し、長い詳細はページ境界で見切れる」挙動に変更する。
原因
_build_project_htmlで見出しを<thead>に置いていたため、WeasyPrint が表のページ跨ぎ時に thead を各ページ先頭で自動的に繰り返していた。変更内容
backend/app/services/pdf/generators/resume_generator.py: 見出し行を<thead>から<tbody>の先頭行へ移動。backend/app/services/pdf/templates/resume.css: 古いコメント(「分割時は thead で繰り返す」)を実挙動に合わせて修正。backend/tests/test_pdf_generator.py: 回帰テストとして<thead>が出力に含まれないことを assert 追加。挙動変更
ページを跨ぐ長いプロジェクトで、2ページ目以降の先頭に出ていた見出しが出なくなり、詳細がページ境界で見切れる(ご依頼どおりの仕様)。
テスト
make ci全パス(backend 631 / web 365+4、build OK)。🤖 Generated with Claude Code
Summary by CodeRabbit
Bug Fixes
Tests