Allow configuring line caps on line marks - #120
Conversation
|
Warning Review limit reachedNext included review available in 33 minutes. View limit detailsLimit details: You’ve used all 4 included reviews currently available. You've used all free OSS reviews for now. Wait for the free limit to reset to keep reviewing this public repository. Review configuration: ⚙️ Run configurationConfiguration used: defaults Review profile: CHILL Plan: Pro Plus Run ID: 📒 Files selected for processing (4)
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 ignored due to path filters (1)
📒 Files selected for processing (20)
Included review availability: Your plan provides up to 4 included reviews per hour; 3 remain after this review. 📝 WalkthroughWalkthroughChangesLine style options
Estimated code review effort: 3 (Moderate) | ~20 minutes Merge Risk: ⚪ Minimal · up to The PR adds optional line-cap and line-join styling while preserving existing round defaults and rendering behavior; no actionable merge-blocking risk remains after normal checks and review. Sequence Diagram(s)sequenceDiagram
participant ChartDefinition
participant ScenePolyline
participant CanvasRenderer
participant SVGExporter
ChartDefinition->>ScenePolyline: provide lineCap and lineJoin
ScenePolyline->>CanvasRenderer: apply resolved stroke styles
ScenePolyline->>SVGExporter: serialize resolved stroke styles
CanvasRenderer-->>SceneDefinition: paint configured line
SVGExporter-->>ChartDefinition: return SVG stroke attributes
Suggested reviewers: 🚥 Pre-merge checks | ✅ 4 | ❌ 1❌ Failed checks (1 warning)
✅ Passed checks (4 passed)
Full details: Linked Issues checkExplanation The pull request implements configurable lineCap and lineJoin options for lineY and lineX using SceneStyle values, preserves round defaults, and verifies SVG, Canvas, motion, export, and React Native behavior. This satisfies issue Full details: Docstring CoverageExplanation Docstring coverage is 0.00% which is insufficient. The required threshold is 80.00%. Docstring coverage is scoped to functions touched by this diff. Analyzed 2 functions across 7 files. (13 skipped: 13 unsupported.) ✨ 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 |
ba8c895 to
090006a
Compare
Adds
lineCapandlineJointo the shared options used bylineYandlineX. Both are typed fromSceneStyle, and omitted values continue to render asround, so existing charts keep their current appearance.lineCap: 'butt'gives Recharts/SVG-default migrations a direct consumer configuration without patching rendered output.The options flow through the renderer-neutral scene style contract to SVG, Canvas, motion updates, static export, and React Native. The composed-chart catalog case demonstrates the butt endpoint, and the reference and example documentation cover both line directions.
No dependency or eager renderer import was added. The repository's exact bundle policy reports +23 B minified and +8–9 B gzip for line consumers, with renderer hosts and unrelated locked bundles unchanged. Public type and renderer-path coverage, bundle checks, package checks, docs, catalog checks, typechecking, and framework suites pass; the DOM suite also passes when run without concurrent workspace validation load.
Closes #119
Summary by CodeRabbit
New Features
lineCapandlineJoinoptions tolineXandlineYcharts.butt,square, andbevel.roundwhen options are omitted.Documentation
Tests