-
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
Pass onRenderItem to onRenderContainer in the Dropdown component #25255
Pass onRenderItem to onRenderContainer in the Dropdown component #25255
Conversation
Asset size changes
Baseline commit: eff4a290cbb0ca8fd7023be1e46b2719564743e6 (build) |
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 77a64b1:
|
📊 Bundle size report🤖 This report was generated against eff4a290cbb0ca8fd7023be1e46b2719564743e6 |
Perf Analysis (
|
Scenario | Render type | Master Ticks | PR Ticks | Iterations | Status |
---|---|---|---|---|---|
BaseButton | mount | 1225 | 1198 | 5000 | |
Breadcrumb | mount | 2831 | 2819 | 1000 | |
Checkbox | mount | 2676 | 2655 | 5000 | |
CheckboxBase | mount | 2388 | 2396 | 5000 | |
ChoiceGroup | mount | 4251 | 4262 | 5000 | |
ComboBox | mount | 1176 | 1157 | 1000 | |
CommandBar | mount | 9435 | 9393 | 1000 | |
ContextualMenu | mount | 10759 | 10237 | 1000 | |
DefaultButton | mount | 1374 | 1361 | 5000 | |
DetailsRow | mount | 3368 | 3361 | 5000 | |
DetailsRowFast | mount | 3428 | 3357 | 5000 | |
DetailsRowNoStyles | mount | 3213 | 3289 | 5000 | |
Dialog | mount | 2965 | 2960 | 1000 | |
DocumentCardTitle | mount | 591 | 580 | 1000 | |
Dropdown | mount | 3191 | 3177 | 5000 | |
FocusTrapZone | mount | 1947 | 1960 | 5000 | |
FocusZone | mount | 1963 | 1948 | 5000 | |
GroupedList | mount | 48591 | 54643 | 2 | |
GroupedList | virtual-rerender | 23724 | 23457 | 2 | |
GroupedList | virtual-rerender-with-unmount | 83188 | 82891 | 2 | |
GroupedListV2 | mount | 564 | 551 | 2 | |
GroupedListV2 | virtual-rerender | 525 | 529 | 2 | |
GroupedListV2 | virtual-rerender-with-unmount | 568 | 574 | 2 | |
IconButton | mount | 1796 | 1820 | 5000 | |
Label | mount | 747 | 757 | 5000 | |
Layer | mount | 4149 | 4138 | 5000 | |
Link | mount | 860 | 872 | 5000 | |
MenuButton | mount | 1625 | 1624 | 5000 | |
MessageBar | mount | 2321 | 2338 | 5000 | |
Nav | mount | 3112 | 3101 | 1000 | |
OverflowSet | mount | 1444 | 1416 | 5000 | |
Panel | mount | 2522 | 2515 | 1000 | |
Persona | mount | 1240 | 1239 | 1000 | |
Pivot | mount | 1538 | 1521 | 1000 | |
PrimaryButton | mount | 1498 | 1491 | 5000 | |
Rating | mount | 7080 | 6986 | 5000 | |
SearchBox | mount | 1525 | 1528 | 5000 | |
Shimmer | mount | 2954 | 2945 | 5000 | |
Slider | mount | 2122 | 2114 | 5000 | |
SpinButton | mount | 4301 | 4296 | 5000 | |
Spinner | mount | 826 | 820 | 5000 | |
SplitButton | mount | 2848 | 2855 | 5000 | |
Stack | mount | 906 | 906 | 5000 | |
StackWithIntrinsicChildren | mount | 2263 | 2255 | 5000 | |
StackWithTextChildren | mount | 4974 | 4954 | 5000 | |
SwatchColorPicker | mount | 9585 | 9538 | 5000 | |
TagPicker | mount | 2338 | 2387 | 5000 | |
TeachingBubble | mount | 78718 | 78887 | 5000 | |
Text | mount | 823 | 833 | 5000 | |
TextField | mount | 1549 | 1554 | 5000 | |
ThemeProvider | mount | 1432 | 1463 | 5000 | |
ThemeProvider | virtual-rerender | 1146 | 1148 | 5000 | |
ThemeProvider | virtual-rerender-with-unmount | 1998 | 2015 | 5000 | |
Toggle | mount | 1135 | 1141 | 5000 | |
buttonNative | mount | 540 | 537 | 5000 |
…rosoft#25255) * Pass onRenderItem to onRenderContainer * Change file
Current Behavior
When attempting to use onRenderList with Dropdown, it is impossible to invoke onRenderItem from the props as it's not set. This was handled in ComboBox in a similar fashion but hasn't happened in Dropdown yet.
New Behavior
onRenderItem (default or custom, if set) is passed onRenderContainer, so now it is possible to invoke it through props for both onRenderList and onRenderContainer, similar to what is done in ComboBox.
Related Issue(s)
Fixes #12919, #3050