CSS Phase E: the paved path - jt-info-card component (21 instances single-sourced) + new-page checklist#380
Conversation
Co-Authored-By: Claude Fable 5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01GYRU9wGepomJo5hSuqtu7V
…ingle-sourced The pp-infobox card pattern repeated 21x across homepage (6), services (6), about-us (3), careers (6) with per-page class names. The measured 16-rule intersection now lives ONCE as the ADDITIVE .jt-info-card class (336 rule-instances deleted from the 4 page files); page variants (hover colors, equal-height framework, media tweaks) stay page-side and win by concat position - tie-scan showed one systematic tie (text-align) with identical values on both sides. Greedy purge entry /^jt-info-card/ added per the C2 lesson. New pages get a consistent card via <div class="fl-module fl-module-pp-infobox jt-info-card"> + pp-infobox markup - documented in docs/workflows/new-page.md (next commit). Gates: only the 4 card-page bundles' fingerprints changed; scoped screenshot gate green across all four pages. Co-Authored-By: Claude Fable 5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01GYRU9wGepomJo5hSuqtu7V
docs/workflows/new-page.md: the full recipe (template shell, bundle slice with order warning, component reuse table incl. jt-info-card, design tokens, the purge greedy-prefix trap, qtest/tests/map wiring, verification ladder). Every trap listed has bitten a real sprint. Co-Authored-By: Claude Fable 5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01GYRU9wGepomJo5hSuqtu7V
📝 WalkthroughWalkthroughThe PR introduces a shared ChangesInfo-card migration
Estimated code review effort: 4 (Complex) | ~60 minutes Possibly related PRs
🚥 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 |
There was a problem hiding this comment.
🧹 Nitpick comments (2)
themes/beaver/assets/css/components/info-card.css (2)
24-31: 📐 Maintainability & Code Quality | 🔵 Trivial | 💤 Low valueRemove redundant
flex-shrinkproperty.The
flex-shrink: 1;declaration is overridden by the shorthandflex: 1 1 auto;on line 31. You can safely remove it.♻️ Proposed fix
- flex-shrink: 1; min-width: 1px; max-width: 100%; -webkit-box-flex: 1 1 auto; -moz-box-flex: 1 1 auto; -webkit-flex: 1 1 auto; -ms-flex: 1 1 auto; flex: 1 1 auto;🤖 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 `@themes/beaver/assets/css/components/info-card.css` around lines 24 - 31, Remove the redundant flex-shrink declaration from the flex item rule in info-card.css, leaving the existing flex: 1 1 auto shorthand and related vendor-prefixed declarations unchanged.Source: Linters/SAST tools
55-57: 📐 Maintainability & Code Quality | 🔵 Trivial | 💤 Low valueRemove empty CSS blocks.
These CSS blocks are empty and serve no purpose.
themes/beaver/assets/css/components/info-card.css#L55-L57: remove the empty.jt-info-card .pp-infobox:hover .pp-infobox-image imgblock.themes/beaver/assets/css/components/info-card.css#L70-L72: remove the empty.jt-info-card .pp-infobox-wrap .layout-3-wrapper, .jt-info-card .pp-infobox-wrap .layout-4-wrapperblock.🤖 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 `@themes/beaver/assets/css/components/info-card.css` around lines 55 - 57, Remove both empty CSS rule blocks in themes/beaver/assets/css/components/info-card.css: the .jt-info-card .pp-infobox:hover .pp-infobox-image img block at lines 55-57 and the .jt-info-card .pp-infobox-wrap .layout-3-wrapper, .jt-info-card .pp-infobox-wrap .layout-4-wrapper block at lines 70-72. No replacement styles are needed.Source: Linters/SAST tools
🤖 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.
Nitpick comments:
In `@themes/beaver/assets/css/components/info-card.css`:
- Around line 24-31: Remove the redundant flex-shrink declaration from the flex
item rule in info-card.css, leaving the existing flex: 1 1 auto shorthand and
related vendor-prefixed declarations unchanged.
- Around line 55-57: Remove both empty CSS rule blocks in
themes/beaver/assets/css/components/info-card.css: the .jt-info-card
.pp-infobox:hover .pp-infobox-image img block at lines 55-57 and the
.jt-info-card .pp-infobox-wrap .layout-3-wrapper, .jt-info-card .pp-infobox-wrap
.layout-4-wrapper block at lines 70-72. No replacement styles are needed.
ℹ️ Review info
⚙️ Run configuration
Configuration used: Path: .coderabbit.yaml
Review profile: CHILL
Plan: Pro
Run ID: ceea195a-6484-490f-ad59-2181e47050d0
📒 Files selected for processing (14)
docs/projects/2509-css-migration/TASK-TRACKER.mddocs/workflows/new-page.mdpostcss.config.jsthemes/beaver/assets/css/components/info-card.cssthemes/beaver/assets/css/pages/about-us.cssthemes/beaver/assets/css/pages/careers.cssthemes/beaver/assets/css/pages/homepage.cssthemes/beaver/assets/css/pages/services.cssthemes/beaver/layouts/home.htmlthemes/beaver/layouts/page/about.htmlthemes/beaver/layouts/page/careers.htmlthemes/beaver/layouts/page/services.htmlthemes/beaver/layouts/partials/assets/careers-css-resources.htmlthemes/beaver/layouts/partials/assets/homepage-css-resources.html
💤 Files with no reviewable changes (3)
- themes/beaver/assets/css/pages/about-us.css
- themes/beaver/assets/css/pages/services.css
- themes/beaver/assets/css/pages/careers.css
What this is
Phase E — the paved path, per Paul's mandate: a person must be able to create a new page from scratch reusing existing components, consistently.
E1 —
components/info-card.css(.jt-info-card)The pp-infobox card pattern repeated 21× across homepage (6), services (6), about-us (3), careers (6), each under page-specific class names. The measured 16-rule intersection of all 21 instances now lives once, applied via the additive
jt-info-cardclass on each card module — 336 rule-instances deleted from the four page files. Page variants (hover colors, equal-height framework, media tweaks) stay page-side and win by concat position; the tie-scan found one systematic selector+property tie (text-align) with identical values on both sides. Greedy purge entry/^jt-info-card/added per the C2 lesson.Gates: only the 4 card-page bundles' fingerprints changed; scoped screenshot gate green on all four; full macOS suite 65/119 zero failures, zero baseline changes; Linux
dtest-allEXIT=0.E3 —
docs/workflows/new-page.mdThe complete recipe: template shell, the load-bearing bundle-slice order, the component reuse table (testimonials, cta-banner, info-card, header-cta, technologies), design tokens, and the traps that each bit a real sprint —
@importonly works in the prelude,bundleNamecollisions race, the PurgeCSS greedy-prefix requirement, qtest/tests/ownership-map wiring, the baseline-overwrite recovery.Still in Phase E (tracker):
🤖 Generated with Claude Code
https://claude.ai/code/session_01GYRU9wGepomJo5hSuqtu7V
Summary by CodeRabbit
New Features
Bug Fixes
Documentation