Skip to content

chore(frontend/ui): page-hero rollout + date-picker icon polish (#344 follow-up) - #367

Merged
cristim merged 2 commits into
feat/multicloud-web-frontendfrom
chore/page-hero-rollout
May 13, 2026
Merged

chore(frontend/ui): page-hero rollout + date-picker icon polish (#344 follow-up)#367
cristim merged 2 commits into
feat/multicloud-web-frontendfrom
chore/page-hero-rollout

Conversation

@cristim

@cristim cristim commented May 13, 2026

Copy link
Copy Markdown
Member

Summary

Two small frontend-polish items from the issue #344 deferral list. Independent visual changes; bundled because both are tiny and trivially reviewable.

1 — Page-hero rollout

Extends the .page-hero typographic treatment to two natural-fit section titles that were missed in PR #343:

  • #planned-purchases-header (Plans → Planned Purchases) — <h2> now reads at hero size like the sibling "Purchase Plans" header; help-text paragraph picks up page-hero-description for matching muted-body styling.
  • #savings-history-section (Purchases → Savings History) — outer <h2> gets hero treatment. The .page-hero CSS only targets h1/h2 + .page-hero-description so inner h3/h4 are unaffected.

Skipped intentionally: #apikeys-section (Admin → API Keys) uses <fieldset>/<legend> instead of an <h2>, so applying page-hero meaningfully needs restructuring. Out of scope here. Home + Opportunities have no section title.

2 new regression tests in html.test.ts assert the class is present on both sections.

2 — Date-picker icon polish

The deferral note in #344 called out Chrome's default ::-webkit-calendar-picker-indicator — a hard black square that fights the rounded chip-pill silhouette of .date-range-picker and #history-controls date inputs. The full custom-date-picker rebuild would replace the native widget entirely (meaningful effort: keyboard / screenreader / locale-aware calendar grid). This PR ships the visible-mismatch fix as a 2-rule CSS tweak:

  • Indicator at 55 % opacity by default — reads as a hint glyph, not a button.
  • Returns to 100 % opacity on input hover / focus — still clearly interactive.

Platform accessibility wiring (keyboard nav, AT, calendar grid) is preserved.

Verification

  • Tests: 1662/1663 pass / 1 skipped. 2 new tests.
  • Build: 529 KiB. Within ±10 % of the 512 baseline.

Summary by CodeRabbit

  • Style

    • Updated Savings History section with enhanced visual styling.
    • Redesigned Planned Purchases section with new visual treatment and added descriptive text.
    • Refined date picker indicator styling across date inputs for improved visual consistency and better appearance on interaction.
  • Tests

    • Added validation tests for UI structure updates.

Review Change Stack

… History (#344 follow-up)

Issue #344 deferred extending the .page-hero typographic treatment to
the remaining section titles. Two natural drop-ins:

- `#planned-purchases-header` (Plans tab → "Planned Purchases") now
  carries `page-hero` so its <h2> reads at hero size like the sibling
  "Purchase Plans" header. The help-text paragraph picks up
  `page-hero-description` so it inherits the muted body styling used
  on the other hero sections.
- `#savings-history-section` (Purchases tab → "Savings History") now
  carries `page-hero`. The inner section-header's <h2> gets hero
  treatment; the deeper h3/h4 stay unchanged (.page-hero CSS only
  targets h1/h2 + .page-hero-description).

Skipped here intentionally:
- `#apikeys-section` (Admin → API Keys) uses <fieldset>/<legend>
  instead of an h2, so applying page-hero meaningfully would require
  restructuring. Bigger change — left for a follow-up if/when the
  layout there is otherwise revisited.
- Home + Opportunities don't have a section title (they render KPI
  tiles / list directly). Page-hero doesn't apply.

Regression tests added in html.test.ts: assert the page-hero class
(and page-hero-description) are present on both newly-promoted
sections.

Verification: 1662/1663 pass / 1 skipped. Build 528 KiB (within ±10%
of the 512 baseline).
@coderabbitai

coderabbitai Bot commented May 13, 2026

Copy link
Copy Markdown
Contributor

No actionable comments were generated in the recent review. 🎉

ℹ️ Recent review info
⚙️ Run configuration

Configuration used: defaults

Review profile: CHILL

Plan: Pro

Run ID: 2e795e27-e825-49ec-9158-ccc3c261e5c0

📥 Commits

Reviewing files that changed from the base of the PR and between f5fe319 and 3ba113d.

📒 Files selected for processing (1)
  • frontend/src/styles/forms.css
✅ Files skipped from review due to trivial changes (1)
  • frontend/src/styles/forms.css

📝 Walkthrough

Walkthrough

Apply page-hero styling to Planned Purchases and Savings History (add description paragraph for Planned Purchases), adjust WebKit date-picker indicator opacity for date inputs, and add tests asserting the new DOM structure.

Changes

Page-Hero Styling Updates

Layer / File(s) Summary
Page-hero styling and date-input CSS updates
frontend/src/index.html, frontend/src/styles/forms.css
Planned Purchases container changed to card page-hero and now includes a page-hero-description paragraph; Savings History container changed to card page-hero; WebKit calendar picker indicator opacity reduced by default and restored on hover/focus-visible for date inputs.
HTML structure validation tests
frontend/src/__tests__/html.test.ts
Added tests asserting #savings-history-section includes page-hero class and #planned-purchases-header includes page-hero class and contains a .page-hero-description element.

Estimated code review effort

🎯 2 (Simple) | ⏱️ ~10 minutes

Possibly related PRs

  • LeanerCloud/CUDly#343: Related reskin-driven HTML assertion updates that also adjust tests for page-hero-style DOM changes.

Suggested labels

urgency/eventually, impact/many, effort/xs

Poem

🐰 I hopped through HTML under moonlit glow,
Gave headers new robes with a gentle show,
Little date pickers now whisper light,
Tests nod kindly — everything's right. ✨

🚥 Pre-merge checks | ✅ 5
✅ Passed checks (5 passed)
Check name Status Explanation
Description Check ✅ Passed Check skipped - CodeRabbit’s high-level summary is enabled.
Title check ✅ Passed The title accurately and specifically describes the main changes: page-hero styling rollout and date-picker icon polish, with clear reference to the parent issue.
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.

✏️ Tip: You can configure your own custom pre-merge checks in the settings.

✨ Finishing Touches
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Commit unit tests in branch chore/page-hero-rollout

Tip

💬 Introducing Slack Agent: The best way for teams to turn conversations into code.

Slack Agent is built on CodeRabbit's deep understanding of your code, so your team can collaborate across the entire SDLC without losing context.

  • Generate code and open pull requests
  • Plan features and break down work
  • Investigate incidents and troubleshoot customer tickets together
  • Automate recurring tasks and respond to alerts with triggers
  • Summarize progress and report instantly

Built for teams:

  • Shared memory across your entire org—no repeating context
  • Per-thread sandboxes to safely plan and execute work
  • Governance built-in—scoped access, auditability, and budget controls

One agent for your entire SDLC. Right inside Slack.

👉 Get started


Comment @coderabbitai help to get the list of available commands and usage tips.

@cristim cristim added triaged Item has been triaged priority/p3 Polish / idea / may never ship severity/low Minor harm urgency/this-quarter Within the quarter impact/all-users Affects every user effort/s Hours type/chore Maintenance / non-user-visible labels May 13, 2026
@cristim

cristim commented May 13, 2026

Copy link
Copy Markdown
Member Author

@coderabbitai review

@coderabbitai

coderabbitai Bot commented May 13, 2026

Copy link
Copy Markdown
Contributor
✅ Actions performed

Review triggered.

Note: CodeRabbit is an incremental review system and does not re-review already reviewed commits. This command is applicable only when automatic reviews are paused.

…l date inputs

The deferral from issue #344 noted Chrome's default calendar-picker
indicator (the small calendar glyph at the right edge of every
<input type="date">) doesn't match the chip-pill design — it renders
as a hard black square that fights the rounded silhouette of the
inputs in #history-controls and .date-range-picker.

The full custom date-picker rebuild that #344's deferral envisioned
would replace the native widget entirely (meaningful effort,
re-implementing keyboard / screenreader / locale-aware calendar grid
support). This commit covers the visible mismatch in the meantime
with a 2-rule CSS tweak: dim the indicator to 55 % opacity by
default, return to 100 % on input hover / focus so it still reads
as interactive. Platform accessibility wiring is preserved.

Scope: 2 rules in forms.css. No tests (CSS-only visual). Build 529
KiB (within ±10 % of the 512 baseline).
@cristim cristim changed the title chore(frontend/ui): roll out page-hero to Planned Purchases + Savings History (#344 follow-up) chore(frontend/ui): page-hero rollout + date-picker icon polish (#344 follow-up) May 13, 2026
@cristim

cristim commented May 13, 2026

Copy link
Copy Markdown
Member Author

@coderabbitai review

@coderabbitai

coderabbitai Bot commented May 13, 2026

Copy link
Copy Markdown
Contributor
✅ Actions performed

Review triggered.

Note: CodeRabbit is an incremental review system and does not re-review already reviewed commits. This command is applicable only when automatic reviews are paused.

@cristim
cristim merged commit c7a11b9 into feat/multicloud-web-frontend May 13, 2026
5 checks passed
@cristim
cristim deleted the chore/page-hero-rollout branch June 3, 2026 21:53
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

effort/s Hours impact/all-users Affects every user priority/p3 Polish / idea / may never ship severity/low Minor harm triaged Item has been triaged type/chore Maintenance / non-user-visible urgency/this-quarter Within the quarter

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant