-
Notifications
You must be signed in to change notification settings - Fork 2.8k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
feat: autocontrolled useTable
hook
#24688
feat: autocontrolled useTable
hook
#24688
Conversation
`useTable` hook now supports autoncontrolling sort and selection states
📊 Bundle size reportUnchanged fixtures
|
Perf Analysis (
|
Scenario | Render type | Master Ticks | PR Ticks | Iterations | Status |
---|---|---|---|---|---|
Avatar | mount | 1325 | 1260 | 5000 | |
Button | mount | 959 | 940 | 5000 | |
FluentProvider | mount | 1527 | 1552 | 5000 | |
FluentProviderWithTheme | mount | 635 | 628 | 10 | |
FluentProviderWithTheme | virtual-rerender | 592 | 589 | 10 | |
FluentProviderWithTheme | virtual-rerender-with-unmount | 631 | 560 | 10 | |
MakeStyles | mount | 1819 | 1776 | 50000 | |
SpinButton | mount | 2431 | 2439 | 5000 |
This pull request is automatically built and testable in CodeSandbox. To see build info of the built libraries, click here or the icon next to each commit SHA. Latest deployment of this branch, based on commit 6537229:
|
Asset size changesSize Auditor did not detect a change in bundle size for any component! Baseline commit: 4c31b27421360e80d8435235092a634a67b0418a (build) |
|
||
defaultSortState?: SortState; | ||
}; | ||
export type TableProps = ComponentProps<TableSlots> & {} & Partial<TableContextValue>; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
export type TableProps = ComponentProps<TableSlots> & {} & Partial<TableContextValue>; | |
export type TableProps = ComponentProps<TableSlots> & Partial<TableContextValue>; |
Do we need this {}
? 😅
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
nope
* master: (63 commits) feat: add helper types to assist DOM element handling (microsoft#24722) applying package updates Textarea/hc bug (microsoft#24701) Fix null ref in use slider (microsoft#24728) Add Field unit tests, and remove snapshot tests (microsoft#24706) Stress Test: add build commands (microsoft#24575) Coachmark - useOffsetHeight should cause re-render on each set state to match v7 functionality (microsoft#24702) Implement screener tests for Field components (microsoft#24684) Update Field types to clean up react-field.api.md (microsoft#24703) fix(Popup): remove rotate(360deg) from PopupContent content styles (microsoft#24432) fix(FocusZone): should reset tabindex when focus is outside the zone with prop `shouldResetActiveElementWhenTabFromZone` (microsoft#24463) Fix greyed out legend key contrast ratio (microsoft#24714) fix: Portal compat should apply `focus-visible` ponyfill (microsoft#24712) Fix artifact error (microsoft#24717) chore(react-dialog): remove localShorthands in favor of griffel shorthands (microsoft#24715) Skip screener checks for draft PRs with exception of appropriately la… (microsoft#24694) fix: Remove provider classname from focus styles (microsoft#24710) feat: autocontrolled `useTable` hook (microsoft#24688) feat: add dialog properties to getNativeElementProps (microsoft#24698) Using migrate rather than upgrade term (microsoft#24695) ...
useTable
hook now supports autoncontrolling sort and selection statesCurrent Behavior
useTable
is completely uncontrolledNew Behavior
useTable
can be controlled and uncontrolled, added extra stories to that effectRelated Issue(s)
Addresses #24226