fix: type aggregatedCell against bound cellComponents in createAppColumnHelper - #6589
fix: type aggregatedCell against bound cellComponents in createAppColumnHelper#6589cpruijsen wants to merge 1 commit into
Conversation
…umnHelper AppColumnDefBase already omitted and retyped cell/header/footer so registered cellComponents appear on the render context. aggregatedCell uses the same cell context at runtime but was left on the core type, so bound components type-checked inside cell and failed inside aggregatedCell.
|
No actionable comments were generated in the recent review. 🎉 ℹ️ Recent review info⚙️ Run configurationConfiguration used: Path: .coderabbit.yaml Review profile: CHILL Plan: Advanced Run ID: 📒 Files selected for processing (10)
Included review availability: Your plan provides up to 10 included reviews per hour; 9 remain after this review. 📝 WalkthroughWalkthroughThis change updates app column definition types across eight table packages. ChangesAggregated cell component typing
Priority: ➖ Normal Estimated code review effort: 2 (Simple) | ~15 minutes Change: Bug fix · Severity of issue fixed: Medium Suggested reviewers: Merge Risk: ⚪ Minimal · up to The type updates consistently bind registered cell components for aggregated cells without changing runtime behavior. No actionable merge risk remains. 🚥 Pre-merge checks | ✅ 4 | ❌ 1❌ Failed checks (1 warning)
✅ Passed checks (4 passed)
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 1 functions across 9 files. (1 skipped: 1 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 |
Changes
aggregatedCellis now omitted and redeclared againstAppCellContext, matchingcell, onAppColumnDefBase,AppDisplayColumnDef, andAppGroupColumnDef. The same copy of those types exists in every adapter with a component registry (React, Preact, Solid, Svelte, Vue, Lit, Angular, Octane), so all of them are updated. Alpine and Ember do not bind cell components on this type and are unchanged. Type-only; no runtime change.createAppColumnHelperalready typedcell,header, andfooteragainst the registeredcellComponents/headerComponents.aggregatedCell(fromrowAggregationFeature) uses the same cell context at runtime:AppCellassigns those components onto the cell instance, andFlexRendercallsaggregatedCellwithcell.getContext(). Its column-def type stayed on the plainCell. Bound names such ascell.NameCelltype-checked incelland failed inaggregatedCell.Fixes #6583
The omit-and-redeclare is unconditional, matching
cell/header/footer. Closed #6584 was React-only; the other option is to showaggregatedCellonly whenrowAggregationFeatureis inTFeatures(core feature-gates the key; this type does not).aggregatedCellis the only other CellContext renderer. Can drop the extra adapters or gate the key on the feature.Checklist
pnpm testandpnpm test:e2e, or these tests do not apply to this pull request.Package
test:typeswas run for the eight affected adapters;@tanstack/react-tabletest:lib(34 tests) andtest:eslintalso passed. End-to-end tests do not apply.Release Impact
Summary by CodeRabbit
New Features
Bug Fixes