Skip to content

[codex] add list content card bounds css vars#387

Draft
zombieJ wants to merge 1 commit intomasterfrom
codex/list-content-card-bounds-var
Draft

[codex] add list content card bounds css vars#387
zombieJ wants to merge 1 commit intomasterfrom
codex/list-content-card-bounds-var

Conversation

@zombieJ
Copy link
Copy Markdown
Member

@zombieJ zombieJ commented Apr 29, 2026

Summary

Expose the front notification card bounds on the list content element as CSS custom properties.

  • Track the front notice bounds while calculating list positions.
  • Write --notification-top and --notification-bottom onto .rc-notification-list-content.
  • Normalize bottom placements so the variables still represent top-edge coordinates within the list content.
  • Add a regression test for the emitted list content variables.

Validation

  • npm test -- tests/index.test.tsx
  • npm test
  • npm run lint (passes with existing hook dependency warnings)
  • npx tsc --noEmit

@vercel
Copy link
Copy Markdown

vercel Bot commented Apr 29, 2026

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

Project Deployment Actions Updated (UTC)
notification Ready Ready Preview, Comment Apr 29, 2026 10:13am

@coderabbitai
Copy link
Copy Markdown

coderabbitai Bot commented Apr 29, 2026

Important

Review skipped

Draft detected.

Please check the settings in the CodeRabbit UI or the .coderabbit.yaml file in this repository. To trigger a single review, invoke the @coderabbitai review command.

⚙️ Run configuration

Configuration used: Organization UI

Review profile: CHILL

Plan: Pro

Run ID: e10d55a8-dfb0-4f4f-a7e8-30f68f111ad6

You can disable this status message by setting the reviews.review_status to false in the CodeRabbit configuration file.

Use the checkbox below for a quick retry:

  • 🔍 Trigger review
✨ Finishing Touches
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Commit unit tests in branch codex/list-content-card-bounds-var

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 and usage tips.

@codecov
Copy link
Copy Markdown

codecov Bot commented Apr 29, 2026

Codecov Report

✅ All modified and coverable lines are covered by tests.
✅ Project coverage is 99.20%. Comparing base (ecadd8c) to head (3b8840d).

Additional details and impacted files
@@            Coverage Diff             @@
##           master     #387      +/-   ##
==========================================
+ Coverage   99.17%   99.20%   +0.02%     
==========================================
  Files          13       13              
  Lines        1336     1377      +41     
  Branches      178      185       +7     
==========================================
+ Hits         1325     1366      +41     
  Misses         11       11              

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.
  • 📦 JS Bundle Analysis: Save yourself from yourself by tracking and limiting bundle sizes in JS merges.

Copy link
Copy Markdown

@gemini-code-assist gemini-code-assist Bot left a comment

Choose a reason for hiding this comment

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

Code Review

This pull request introduces the tracking and exposure of the top notification's bounds within the notification list. It updates the useListPosition hook to calculate these bounds and passes them down to the Content component, which then sets --notification-top and --notification-bottom CSS variables. This includes logic to adjust coordinates for bottom-aligned placements and a new test case to verify the style application. I have no feedback to provide.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant