docs: clarify custom labels and ticks need SVG elements#7524
Conversation
|
No actionable comments were generated in the recent review. 🎉 ℹ️ Recent review info⚙️ Run configurationConfiguration used: Organization UI Review profile: CHILL Plan: Pro Run ID: 📒 Files selected for processing (12)
✅ Files skipped from review due to trivial changes (11)
WalkthroughThis PR updates JSDoc comments across chart label, tick, and content props to clarify that custom React elements must use SVG elements, and adds a comment similarity exception for ChangesSVG-only prop documentation
Estimated code review effort: 1 (Trivial) | ~4 minutes 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 |
|
Can you double check the issue number? I don't think that's related. |
Bundle ReportBundle size has no change ✅ |
|
Good catch. #3177 includes the docs request for HTML elements used as labels, but the issue also has broader follow-up discussion. I changed this from |
Codecov Report✅ All modified and coverable lines are covered by tests. Additional details and impacted files@@ Coverage Diff @@
## main #7524 +/- ##
=======================================
Coverage 88.15% 88.15%
=======================================
Files 609 609
Lines 14227 14227
Branches 3568 3569 +1
=======================================
Hits 12542 12542
Misses 1495 1495
Partials 190 190 ☔ View full report in Codecov by Harness. 🚀 New features to boost your workflow:
|
Description
Clarifies that custom
label,Label,LabelList,XAxis tick, andYAxis tickReact elements need to be SVG elements/components, not HTML elements such as<div>.Related Issue
Refs #3177
Motivation and Context
Issue #3177 includes a request to document React DOM warnings when an HTML element is used as chart label/tick content. These prop comments feed the generated API documentation, so this makes the supported custom-rendering surface explicit near the affected props.
How Has This Been Tested?
git diff --check HEAD~1 HEADgrepScreenshots (if appropriate):
N/A
Types of changes
Checklist:
Summary by CodeRabbit
label,tick, and labelcontentto use SVG-based React elements (e.g.,<text>/<g>).<div>are invalid inside SVG-rendered charts and may trigger React DOM warnings.