Skip to content

Allow extending domain if ReferenceLine is defined by segment#6592

Merged
ckifer merged 3 commits into
mainfrom
referenceline-segment-extenddomain
Nov 9, 2025
Merged

Allow extending domain if ReferenceLine is defined by segment#6592
ckifer merged 3 commits into
mainfrom
referenceline-segment-extenddomain

Conversation

@PavelVanecek

@PavelVanecek PavelVanecek commented Nov 9, 2025

Copy link
Copy Markdown
Collaborator

Description

I was going through the warnings where ReferenceLine is sometimes passing NaN to DOM and discovered #3379 so I fixed it.

Related Issue

Fixes #3379

How Has This Been Tested?

VR tests

Screenshots (if appropriate):

Types of changes

  • Bug fix (non-breaking change which fixes an issue)
  • New feature (non-breaking change which adds functionality)
  • Breaking change (fix or feature that would cause existing functionality to change)

Checklist:

  • My change requires a change to the documentation.
  • I have updated the documentation accordingly.
  • I have added tests to cover my changes.
  • I have added a storybook story or VR test, or extended an existing story or VR test to show my changes

Summary by CodeRabbit

  • New Features

    • Reference lines now accept two-point segment definitions for more flexible positioning.
    • Overflow handling improved so domains extend correctly when segments fall outside chart bounds.
  • Tests

    • Added visual regression and unit tests covering segment-based reference lines and all ifOverflow behaviors (hidden, visible, discard, extendDomain, default).

@coderabbitai

coderabbitai Bot commented Nov 9, 2025

Copy link
Copy Markdown
Contributor

Walkthrough

The PR introduces a public ReferenceLineSegment type, validates segment coordinates with isWellBehavedNumber, updates ReferenceLine props and related functions to use the new segment type, threads segment data into Redux state, updates domain calculation helpers/selectors to consider segment endpoints, and adds/updates tests and public exports (including IfOverflow).

Changes

Cohort / File(s) Summary
ReferenceLine Component Type & Validation
src/cartesian/ReferenceLine.tsx
Introduce and export ReferenceLineSegment; replace prior Segment usage with ReferenceLineSegment; add isWellBehavedNumber checks and guard rendering when any of x1,y1,x2,y2 are not valid; update ReferenceLineProps.segment and getSegmentLineEndPoints signatures; pass segment through to ReportReferenceLine.
Public API Exports
src/index.ts
Export ReferenceLineSegment alongside ReferenceLineProps; export IfOverflow from ./util/IfOverflow.
State Management
src/state/referenceElementsSlice.ts
Add optional segment?: ReferenceLineSegment to ReferenceLineSettings type and import the new type.
Domain Calculation / Selectors
src/state/selectors/axisSelectors.ts
Add extractXCoordinates and extractYCoordinates helpers to derive numeric coords from x/y or segment endpoints; update combineLinesDomain to use these helpers; change selectReferenceLinesDomain to a memoized selector with array input.
Visual Regression & Component Tests
test-vr/tests/ReferenceLine/ReferenceLineComponents.tsx, test-vr/tests/ReferenceLine/ifOverflow.spec-vr.tsx
Add IfOverflowTestWithSegment component and Playwright CT tests to verify ReferenceLine overflow behavior with a two-point segment across hidden, visible, discard, extendDomain, and undefined states.
Unit Tests: ReferenceLine & State
test/cartesian/ReferenceLine/ReferenceLine.spec.tsx, test/cartesian/ReferenceLine/getEndPoints.spec.tsx, test/state/referenceElementsSlice.spec.ts
Add tests asserting segment storage in Redux state; import/export and use ReferenceLineSegment in tests; add/adjust test data to include segment (including explicit undefined in one case).
YAxis Domain Tests
test/cartesian/YAxis/YAxis.spec.tsx
Update expectations to assert YAxis domain/ticks extend to include segment overflow points (e.g., domain extended up to 2000) when ifOverflow="extendDomain".
Omnidoc / Public surface tests
omnidoc/readProject.spec.ts
Add IfOverflow and ReferenceLineSegment to the expected exported symbol list.
Scripts / Config
package.json, vitest.config.mts
Rename Omnidoc test project from omnidocunit:omnidoc and update test-omnidoc script accordingly.

Sequence Diagram(s)

sequenceDiagram
    participant Chart as Chart Component
    participant RL as ReferenceLine
    participant Validate as isWellBehavedNumber
    participant State as Redux State
    participant Selector as Domain Selector
    participant Axis as YAxis

    Chart->>RL: render ReferenceLine(segment, ifOverflow)
    RL->>Validate: validate x1,y1,x2,y2
    alt all valid
        RL->>State: register/update line with `segment`
        State->>Selector: selectReferenceLinesDomain()
        Selector->>Selector: extractXCoordinates / extractYCoordinates
        Selector->>Axis: request domain including segment endpoints
        Axis->>Chart: re-render with extended domain (ifOverflow="extendDomain")
    else invalid coord
        RL-->>Chart: return null (do not render reference line)
    end
Loading

Estimated code review effort

🎯 3 (Moderate) | ⏱️ ~25 minutes

  • Attention areas:
    • Validation: ensure isWellBehavedNumber usage covers all segment endpoints and false positives/negatives are avoided.
    • Selector logic: verify extractXCoordinates/extractYCoordinates correctly handle mixed shapes (explicit x/y vs. segment) and filtering of non-numeric values.
    • State typing: confirm ReferenceLineSettings.segment addition aligns with persisted/consumed code paths.
    • Tests: ensure updated YAxis expectations and VR tests reliably reflect domain-extension behavior.

Possibly related PRs

Suggested labels

enhancement

Suggested reviewers

  • ckifer

Pre-merge checks and finishing touches

✅ Passed checks (5 passed)
Check name Status Explanation
Title check ✅ Passed The title directly and clearly describes the main change: enabling domain extension for ReferenceLine when defined by segment prop.
Description check ✅ Passed The description covers the main sections: it identifies the bug fix, links to the related issue, mentions testing approach, and completes the checklist appropriately.
Linked Issues check ✅ Passed The PR successfully addresses issue #3379 by implementing segment support, domain extension logic via helper functions, and adding comprehensive tests validating the fix.
Out of Scope Changes check ✅ Passed All changes align with the bug fix scope: ReferenceLine segment type introduction, domain computation logic, validation, test coverage, and necessary type/export updates are all directly related.
Docstring Coverage ✅ Passed No functions found in the changed files to evaluate docstring coverage. Skipping docstring coverage check.
✨ Finishing touches
  • 📝 Generate docstrings
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Post copyable unit tests in a comment
  • Commit unit tests in branch referenceline-segment-extenddomain

📜 Recent review details

Configuration used: CodeRabbit UI

Review profile: CHILL

Plan: Pro

📥 Commits

Reviewing files that changed from the base of the PR and between f2bd152 and 0760447.

📒 Files selected for processing (3)
  • omnidoc/readProject.spec.ts (2 hunks)
  • package.json (1 hunks)
  • vitest.config.mts (1 hunks)
🧰 Additional context used
🧠 Learnings (1)
📚 Learning: 2025-10-25T07:35:46.188Z
Learnt from: CR
Repo: recharts/recharts PR: 0
File: test/README.md:0-0
Timestamp: 2025-10-25T07:35:46.188Z
Learning: Write unit tests using Vitest and React Testing Library

Applied to files:

  • package.json
⏰ Context from checks skipped due to timeout of 90000ms. You can increase the timeout in your CodeRabbit configuration to a maximum of 15 minutes (900000ms). (2)
  • GitHub Check: Build, Test, Pack
  • GitHub Check: Analyze (javascript-typescript)
🔇 Additional comments (3)
package.json (1)

43-43: LGTM! Consistent project naming.

The script correctly references the renamed test project unit:omnidoc, matching the change in vitest.config.mts. This follows the naming pattern established by other unit test projects.

vitest.config.mts (1)

51-51: LGTM! Improved test project naming consistency.

The rename from omnidoc to unit:omnidoc aligns with the naming convention used by other unit test projects (unit:lib, unit:website), making the test organization clearer.

omnidoc/readProject.spec.ts (1)

47-47: LGTM! New public API exports properly tested.

The test correctly verifies that the new IfOverflow and ReferenceLineSegment types are exposed in the public API. Both symbols are placed in the correct alphabetical positions, and these additions align with the PR objective to support segment-based ReferenceLine with domain extension.

Also applies to: 91-91


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.

@coderabbitai coderabbitai Bot left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Actionable comments posted: 0

🧹 Nitpick comments (1)
test/cartesian/YAxis/YAxis.spec.tsx (1)

2042-2042: Consider reordering assertion for consistency.

The domain assertion appears before tick assertions, while similar tests place it after (e.g., line 2036). Reordering would improve consistency.

📜 Review details

Configuration used: CodeRabbit UI

Review profile: CHILL

Plan: Pro

📥 Commits

Reviewing files that changed from the base of the PR and between d3564e3 and f2bd152.

⛔ Files ignored due to path filters (15)
  • test-vr/__snapshots__/tests/ReferenceLine/ifOverflow.spec-vr.tsx-snapshots/ReferenceLine-ifOverflow-with-segment-ifOverfl-38027-xtends-the-domain-to-include-overflowed-parts-1-chromium-linux.png is excluded by !**/*.png
  • test-vr/__snapshots__/tests/ReferenceLine/ifOverflow.spec-vr.tsx-snapshots/ReferenceLine-ifOverflow-with-segment-ifOverfl-38027-xtends-the-domain-to-include-overflowed-parts-1-firefox-linux.png is excluded by !**/*.png
  • test-vr/__snapshots__/tests/ReferenceLine/ifOverflow.spec-vr.tsx-snapshots/ReferenceLine-ifOverflow-with-segment-ifOverfl-38027-xtends-the-domain-to-include-overflowed-parts-1-webkit-linux.png is excluded by !**/*.png
  • test-vr/__snapshots__/tests/ReferenceLine/ifOverflow.spec-vr.tsx-snapshots/ReferenceLine-ifOverflow-with-segment-ifOverflow-default-behavior-is-discard-1-chromium-linux.png is excluded by !**/*.png
  • test-vr/__snapshots__/tests/ReferenceLine/ifOverflow.spec-vr.tsx-snapshots/ReferenceLine-ifOverflow-with-segment-ifOverflow-default-behavior-is-discard-1-firefox-linux.png is excluded by !**/*.png
  • test-vr/__snapshots__/tests/ReferenceLine/ifOverflow.spec-vr.tsx-snapshots/ReferenceLine-ifOverflow-with-segment-ifOverflow-default-behavior-is-discard-1-webkit-linux.png is excluded by !**/*.png
  • test-vr/__snapshots__/tests/ReferenceLine/ifOverflow.spec-vr.tsx-snapshots/ReferenceLine-ifOverflow-with-segment-ifOverflow-discard-does-not-render-overflowed-parts-1-chromium-linux.png is excluded by !**/*.png
  • test-vr/__snapshots__/tests/ReferenceLine/ifOverflow.spec-vr.tsx-snapshots/ReferenceLine-ifOverflow-with-segment-ifOverflow-discard-does-not-render-overflowed-parts-1-firefox-linux.png is excluded by !**/*.png
  • test-vr/__snapshots__/tests/ReferenceLine/ifOverflow.spec-vr.tsx-snapshots/ReferenceLine-ifOverflow-with-segment-ifOverflow-discard-does-not-render-overflowed-parts-1-webkit-linux.png is excluded by !**/*.png
  • test-vr/__snapshots__/tests/ReferenceLine/ifOverflow.spec-vr.tsx-snapshots/ReferenceLine-ifOverflow-with-segment-ifOverflow-hidden-does-not-render-overflowed-parts-1-chromium-linux.png is excluded by !**/*.png
  • test-vr/__snapshots__/tests/ReferenceLine/ifOverflow.spec-vr.tsx-snapshots/ReferenceLine-ifOverflow-with-segment-ifOverflow-hidden-does-not-render-overflowed-parts-1-firefox-linux.png is excluded by !**/*.png
  • test-vr/__snapshots__/tests/ReferenceLine/ifOverflow.spec-vr.tsx-snapshots/ReferenceLine-ifOverflow-with-segment-ifOverflow-hidden-does-not-render-overflowed-parts-1-webkit-linux.png is excluded by !**/*.png
  • test-vr/__snapshots__/tests/ReferenceLine/ifOverflow.spec-vr.tsx-snapshots/ReferenceLine-ifOverflow-with-segment-ifOverflow-visible-renders-overflowed-parts-1-chromium-linux.png is excluded by !**/*.png
  • test-vr/__snapshots__/tests/ReferenceLine/ifOverflow.spec-vr.tsx-snapshots/ReferenceLine-ifOverflow-with-segment-ifOverflow-visible-renders-overflowed-parts-1-firefox-linux.png is excluded by !**/*.png
  • test-vr/__snapshots__/tests/ReferenceLine/ifOverflow.spec-vr.tsx-snapshots/ReferenceLine-ifOverflow-with-segment-ifOverflow-visible-renders-overflowed-parts-1-webkit-linux.png is excluded by !**/*.png
📒 Files selected for processing (10)
  • src/cartesian/ReferenceLine.tsx (6 hunks)
  • src/index.ts (2 hunks)
  • src/state/referenceElementsSlice.ts (2 hunks)
  • src/state/selectors/axisSelectors.ts (1 hunks)
  • test-vr/tests/ReferenceLine/ReferenceLineComponents.tsx (1 hunks)
  • test-vr/tests/ReferenceLine/ifOverflow.spec-vr.tsx (1 hunks)
  • test/cartesian/ReferenceLine/ReferenceLine.spec.tsx (2 hunks)
  • test/cartesian/ReferenceLine/getEndPoints.spec.tsx (5 hunks)
  • test/cartesian/YAxis/YAxis.spec.tsx (3 hunks)
  • test/state/referenceElementsSlice.spec.ts (1 hunks)
🧰 Additional context used
📓 Path-based instructions (1)
src/**/*.{js,jsx,ts,tsx}

📄 CodeRabbit inference engine (AGENTS.md)

Do not hardcode any user-facing strings or formatting choices in the library code; leave internationalization to library users

Files:

  • src/state/referenceElementsSlice.ts
  • src/cartesian/ReferenceLine.tsx
  • src/index.ts
  • src/state/selectors/axisSelectors.ts
🧠 Learnings (6)
📚 Learning: 2025-10-25T07:35:46.188Z
Learnt from: CR
Repo: recharts/recharts PR: 0
File: test/README.md:0-0
Timestamp: 2025-10-25T07:35:46.188Z
Learning: Applies to test/**/*.test.{ts,tsx} : Mock getBoundingClientRect using test/helper/MockGetBoundingClientRect.ts when rendering Recharts components (e.g., Tooltip, Legend, charts)

Applied to files:

  • test-vr/tests/ReferenceLine/ifOverflow.spec-vr.tsx
  • test/cartesian/ReferenceLine/ReferenceLine.spec.tsx
  • test/cartesian/ReferenceLine/getEndPoints.spec.tsx
  • src/index.ts
  • test-vr/tests/ReferenceLine/ReferenceLineComponents.tsx
  • test/cartesian/YAxis/YAxis.spec.tsx
📚 Learning: 2025-10-25T07:35:46.188Z
Learnt from: CR
Repo: recharts/recharts PR: 0
File: test/README.md:0-0
Timestamp: 2025-10-25T07:35:46.188Z
Learning: Applies to test/**/*.test.{ts,tsx} : When testing selectors, verify render counts using the spy and rerenderSameComponent from createSelectorTestCase

Applied to files:

  • test-vr/tests/ReferenceLine/ifOverflow.spec-vr.tsx
  • test/cartesian/ReferenceLine/ReferenceLine.spec.tsx
  • test/cartesian/YAxis/YAxis.spec.tsx
📚 Learning: 2025-10-25T07:35:46.188Z
Learnt from: CR
Repo: recharts/recharts PR: 0
File: test/README.md:0-0
Timestamp: 2025-10-25T07:35:46.188Z
Learning: Applies to test/**/*.test.{ts,tsx} : In tests not using createSelectorTestCase, advance timers after renders with vi.runOnlyPendingTimers()

Applied to files:

  • test-vr/tests/ReferenceLine/ifOverflow.spec-vr.tsx
📚 Learning: 2025-10-25T07:35:46.188Z
Learnt from: CR
Repo: recharts/recharts PR: 0
File: test/README.md:0-0
Timestamp: 2025-10-25T07:35:46.188Z
Learning: Write unit tests using Vitest and React Testing Library

Applied to files:

  • test-vr/tests/ReferenceLine/ifOverflow.spec-vr.tsx
  • test/cartesian/ReferenceLine/getEndPoints.spec.tsx
📚 Learning: 2025-10-25T07:35:46.188Z
Learnt from: CR
Repo: recharts/recharts PR: 0
File: test/README.md:0-0
Timestamp: 2025-10-25T07:35:46.188Z
Learning: Applies to test/**/*.test.{ts,tsx} : Use expectLastCalledWith instead of toHaveBeenLastCalledWith for typed last-call assertions

Applied to files:

  • test/cartesian/ReferenceLine/getEndPoints.spec.tsx
  • test/cartesian/YAxis/YAxis.spec.tsx
📚 Learning: 2025-10-25T07:35:46.188Z
Learnt from: CR
Repo: recharts/recharts PR: 0
File: test/README.md:0-0
Timestamp: 2025-10-25T07:35:46.188Z
Learning: Applies to test/**/*.test.{ts,tsx} : Avoid vi.runAllTimers() in tests to prevent infinite loops caused by chained scheduled timers

Applied to files:

  • test/cartesian/ReferenceLine/getEndPoints.spec.tsx
🧬 Code graph analysis (7)
test-vr/tests/ReferenceLine/ifOverflow.spec-vr.tsx (1)
test-vr/tests/ReferenceLine/ReferenceLineComponents.tsx (1)
  • IfOverflowTestWithSegment (5-21)
src/state/referenceElementsSlice.ts (2)
src/cartesian/ReferenceLine.tsx (1)
  • ReferenceLineSegment (36-45)
src/index.ts (1)
  • ReferenceLineSegment (64-64)
test/cartesian/ReferenceLine/ReferenceLine.spec.tsx (4)
src/state/hooks.ts (1)
  • useAppSelector (40-50)
src/state/selectors/axisSelectors.ts (1)
  • selectReferenceLinesByAxis (908-915)
test/_data.ts (1)
  • PageData (4-11)
src/cartesian/ReferenceLine.tsx (1)
  • ReferenceLine (305-320)
test/cartesian/ReferenceLine/getEndPoints.spec.tsx (2)
src/cartesian/ReferenceLine.tsx (1)
  • ReferenceLineSegment (36-45)
src/index.ts (1)
  • ReferenceLineSegment (64-64)
src/cartesian/ReferenceLine.tsx (2)
src/index.ts (1)
  • ReferenceLineSegment (64-64)
src/util/isWellBehavedNumber.ts (1)
  • isWellBehavedNumber (1-3)
test-vr/tests/ReferenceLine/ReferenceLineComponents.tsx (2)
storybook/stories/data/Page.ts (1)
  • pageData (259-259)
src/cartesian/ReferenceLine.tsx (1)
  • ReferenceLine (305-320)
src/state/selectors/axisSelectors.ts (4)
src/state/referenceElementsSlice.ts (1)
  • ReferenceLineSettings (26-30)
src/state/selectors/selectTooltipAxisType.ts (1)
  • XorYType (13-13)
src/util/types.ts (1)
  • NumberDomain (686-686)
src/state/selectors/pickAxisType.ts (1)
  • pickAxisType (3-3)
⏰ Context from checks skipped due to timeout of 90000ms. You can increase the timeout in your CodeRabbit configuration to a maximum of 15 minutes (900000ms). (1)
  • GitHub Check: Build, Test, Pack
🔇 Additional comments (24)
test/state/referenceElementsSlice.spec.ts (1)

67-67: LGTM! Test data aligns with updated type.

The explicit segment: undefined correctly reflects the new optional property in ReferenceLineSettings.

src/state/referenceElementsSlice.ts (2)

5-5: LGTM! Correct import for the new segment type.


29-29: LGTM! Type extension properly adds segment support.

The optional segment property allows ReferenceLine to work with both traditional coordinate-based definitions and segment-based definitions.

test-vr/tests/ReferenceLine/ifOverflow.spec-vr.tsx (1)

1-30: LGTM! Comprehensive VR test coverage for segment-based ReferenceLine.

The test suite covers all ifOverflow values including the critical extendDomain behavior that fixes the reported issue. Screenshot-based assertions are appropriate for visual regression testing.

test/cartesian/ReferenceLine/getEndPoints.spec.tsx (6)

2-2: LGTM! Correct import for explicit type annotations.


359-360: LGTM! Proper documentation of intentional type violation.

The ts-expect-error comment correctly indicates that the test is verifying error handling for invalid input (empty segment array).


367-380: LGTM! Explicit type annotation improves test clarity.


384-395: LGTM! Type annotation ensures test data matches API.


398-408: LGTM! Explicit typing for discard overflow test.


411-421: LGTM! Type safety in segment coordinate test.

test/cartesian/ReferenceLine/ReferenceLine.spec.tsx (2)

21-21: LGTM! Test data import for segment testing.


521-555: LGTM! Comprehensive state integration test for segment prop.

The test verifies that ReferenceLine with a segment is correctly reported to Redux state, including all associated properties. This validates the state layer changes introduced by the PR.

test-vr/tests/ReferenceLine/ReferenceLineComponents.tsx (1)

1-21: LGTM! Well-designed test component for overflow scenarios.

The component correctly sets up a ReferenceLine with a segment where the second point (y: 2000) intentionally falls outside the chart domain, making it ideal for testing ifOverflow="extendDomain" behavior. The inline comment clearly documents this design choice.

src/index.ts (2)

64-64: LGTM! Public API export for ReferenceLineSegment type.

The export enables consumers to use the new segment type when defining ReferenceLine components.


111-111: LGTM! Public API export for IfOverflow type.

This export provides type information for the ifOverflow prop, improving type safety for library consumers.

src/state/selectors/axisSelectors.ts (3)

945-965: LGTM! Helper functions correctly extract coordinates from segments.

The extractXCoordinates and extractYCoordinates helpers properly handle both traditional coordinate-based (line.x, line.y) and segment-based ReferenceLine definitions. The fallback to segment coordinates enables domain extension when ifOverflow="extendDomain" is used with segments, fixing the reported issue.


967-978: LGTM! Domain calculation now accounts for segment coordinates.

The updated combineLinesDomain correctly uses the extraction helpers to compute domains from both traditional and segment-based coordinates.


980-980: LGTM! Selector signature updated to use array input.

The array input syntax [selectReferenceLinesByAxis, pickAxisType] is the correct pattern for createSelector with multiple input selectors.

test/cartesian/YAxis/YAxis.spec.tsx (1)

2135-2169: LGTM! Test correctly validates domain extension for segment-based ReferenceLine.

The test properly validates that when a ReferenceLine with a segment is used with ifOverflow="extendDomain", the domain extends to include both segment points. The expectations correctly reflect the extended domain [0, 2000] and corresponding ticks.

src/cartesian/ReferenceLine.tsx (5)

24-24: LGTM! Appropriate import for coordinate validation.


36-45: LGTM! Type definition is clear and well-structured.

The tuple type correctly represents a segment as exactly two points with optional x/y coordinates in data space. The type aligns with the JSDoc above and supports both numeric and categorical axes.


92-92: LGTM! Property type is consistent with the new ReferenceLineSegment definition.


190-190: LGTM! Changes correctly wire segment data through the component.

The function signature update and prop passing ensure segment data flows properly for domain calculation.

Also applies to: 315-315


125-132: Verify whether coordinate validation should apply to custom shapes.

The validation guard at lines 125-132 correctly prevents NaN from reaching the default <line> element. However, this validation pattern is inconsistent with the stated PR goal. When custom shapes (element or function) are provided, validation is bypassed—allowing NaN coordinates to reach custom rendering logic. This same bypass pattern exists across multiple reference components (ReferenceArea, ReferenceDot, Scatter, CartesianGrid), suggesting it's intentional design.

This raises a clarification question: Is the bypass intentional (custom shapes own responsibility for validation), or is the validation added in this PR incomplete? If the goal is to prevent NaN from reaching the DOM, coordinate validation should apply to all rendering paths, not just the default shape.

@codecov

codecov Bot commented Nov 9, 2025

Copy link
Copy Markdown

Codecov Report

❌ Patch coverage is 91.42857% with 3 lines in your changes missing coverage. Please review.
✅ Project coverage is 94.59%. Comparing base (d3564e3) to head (0760447).
⚠️ Report is 1 commits behind head on main.

Files with missing lines Patch % Lines
src/state/selectors/axisSelectors.ts 87.50% 3 Missing ⚠️
Additional details and impacted files
@@            Coverage Diff             @@
##             main    #6592      +/-   ##
==========================================
+ Coverage   94.53%   94.59%   +0.06%     
==========================================
  Files         491      491              
  Lines       40761    40793      +32     
  Branches     4752     4769      +17     
==========================================
+ Hits        38532    38587      +55     
+ Misses       2224     2201      -23     
  Partials        5        5              

☔ 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.

@codecov

codecov Bot commented Nov 9, 2025

Copy link
Copy Markdown

Bundle Report

Changes will increase total bundle size by 2.7kB (0.1%) ⬆️. This is within the configured threshold ✅

Detailed changes
Bundle name Size Change
recharts/bundle-cjs 1.12MB 1.2kB (0.11%) ⬆️
recharts/bundle-es6 966.89kB 1.09kB (0.11%) ⬆️
recharts/bundle-umd 509.07kB 416 bytes (0.08%) ⬆️

Affected Assets, Files, and Routes:

view changes for bundle: recharts/bundle-cjs

Assets Changed:

Asset Name Size Change Total Size Change (%)
state/selectors/axisSelectors.js 828 bytes 63.07kB 1.33%
cartesian/ReferenceLine.js 368 bytes 10.14kB 3.76%
view changes for bundle: recharts/bundle-umd

Assets Changed:

Asset Name Size Change Total Size Change (%)
Recharts.js 416 bytes 509.07kB 0.08%
view changes for bundle: recharts/bundle-es6

Assets Changed:

Asset Name Size Change Total Size Change (%)
state/selectors/axisSelectors.js 828 bytes 53.3kB 1.58%
cartesian/ReferenceLine.js 264 bytes 8.85kB 3.08%

@ckifer
ckifer merged commit 037fc28 into main Nov 9, 2025
28 of 29 checks passed
@PavelVanecek
PavelVanecek deleted the referenceline-segment-extenddomain branch November 9, 2025 22:59
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.

ReferenceLine: Domain is not extended if used with segment prop and ifOverflow="extendDomain"

2 participants