Wrap Recharts Sankey chart#6708
Conversation
Greptile SummaryThis PR wraps the Recharts
Confidence Score: 5/5Safe to merge — the implementation follows the established chart-wrapping pattern exactly and all TypedDict contracts are correctly modeled. The change is a straightforward addition of a new chart type. No existing behaviour is modified, TypedDict optionality is correctly modelled with NotRequired, and all wiring is consistent with every other chart in the package. The _valid_children list in the new SankeyChart class is the only spot worth a second look. Important Files Changed
Reviews (4): Last reviewed commit: "Add Sankey chart changelog fragment" | Re-trigger Greptile |
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: e94c1102db
ℹ️ About Codex in GitHub
Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you
- Open a pull request for review
- Mark a draft as ready
- Comment "@codex review".
If Codex has suggestions, it will comment; otherwise it will react with 👍.
Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".
Merging this PR will not alter performance
Comparing Footnotes
|
masenf
left a comment
There was a problem hiding this comment.
needs a changelog entry.
doesn't build
TypeError: Invalid var passed for prop SankeyChart.data, expected type <class
'reflex_components_recharts.charts.SankeyData'>, got value
reflex___state____state___docgen_exec___docs_library_graphing_charts_sankeychart_md____sankey_state
.data_rx_state_ of type collections.abc.Mapping[str,
collections.abc.Sequence[collections.abc.Mapping[str, int]] |
collections.abc.Sequence[collections.abc.Mapping[str, str]]].
While rendering demo block in docs/library/graphing/charts/sankeychart.md:
class SankeyState(rx.State):
data = {
"nodes": [
{"name": "Marketing"},
{"name": "Trial"},
{"name": "Sales"},
{"name": "Support"},
Happened while evaluating page 'library/graphing/charts/sankeychart'
|
Removed The earlier |
Closes #6558
Summary
rx.recharts.SankeyChart/rx.recharts.sankey_chartTests
uv run pytest tests/units/components/graphing/test_recharts.py -quv run ruff check ...uv run ruff format --check ...uv run pyright ...