Skip to content
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

bugfix(react-utilities): change SlotRenderFunction signature to include children #27377

Conversation

bsunderhus
Copy link
Contributor

@bsunderhus bsunderhus commented Mar 30, 2023

New Behavior

This is a bug fix! types for SlotRenderFunction should properly include children as an option, and they currently don't.

  1. Adds children as a possible value on the properties for SlotRenderFunction
  2. This PR is solely about type fixing no functionality will change.

Related Issue(s)

#27089

@github-actions github-actions bot added this to the March Project Cycle Q1 2023 milestone Mar 30, 2023
@bsunderhus bsunderhus force-pushed the react-utilities/bugfix--updates-SlotRenderFunction-signature-to-include-children branch from 2b5c7e6 to bec10cf Compare March 30, 2023 14:04
@size-auditor
Copy link

size-auditor bot commented Mar 30, 2023

Asset size changes

Size Auditor did not detect a change in bundle size for any component!

Baseline commit: 2bea5b29844ac124b923a40e20e135e5b25668c6 (build)

@codesandbox-ci
Copy link

codesandbox-ci bot commented Mar 30, 2023

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 ca3efca:

Sandbox Source
@fluentui/react 8 starter Configuration
@fluentui/react-components 9 starter Configuration

@fabricteam
Copy link
Collaborator

fabricteam commented Mar 30, 2023

📊 Bundle size report

Unchanged fixtures
Package & Exports Size (minified/GZIP)
global-context
createContext
533 B
341 B
global-context
createContextSelector
560 B
352 B
react-accordion
Accordion (including children components)
88.882 kB
26.551 kB
react-alert
Alert
96.647 kB
23.133 kB
react-avatar
Avatar
60.312 kB
15.579 kB
react-avatar
AvatarGroup
18.178 kB
6.683 kB
react-avatar
AvatarGroupItem
76.573 kB
20.086 kB
react-badge
Badge
25.85 kB
7.585 kB
react-badge
CounterBadge
26.833 kB
7.889 kB
react-badge
PresenceBadge
34.458 kB
8.693 kB
react-button
Button
39.749 kB
9.959 kB
react-button
CompoundButton
46.921 kB
11.428 kB
react-button
MenuButton
44.437 kB
11.306 kB
react-button
SplitButton
52.931 kB
12.872 kB
react-button
ToggleButton
58.121 kB
11.878 kB
react-card
Card - All
83.489 kB
23.894 kB
react-card
Card
78.308 kB
22.431 kB
react-card
CardFooter
9.035 kB
3.799 kB
react-card
CardHeader
10.959 kB
4.503 kB
react-card
CardPreview
9.84 kB
4.153 kB
react-checkbox
Checkbox
36.067 kB
10.856 kB
react-checkbox
CheckboxField
43.019 kB
12.787 kB
react-combobox
Combobox (including child components)
88.73 kB
28.105 kB
react-combobox
ComboboxField
85.147 kB
27.871 kB
react-combobox
Dropdown (including child components)
87.428 kB
27.853 kB
react-components
react-components: Button, FluentProvider & webLightTheme
67.994 kB
18.395 kB
react-components
react-components: Accordion, Button, FluentProvider, Image, Menu, Popover
207.4 kB
57.516 kB
react-components
react-components: FluentProvider & webLightTheme
38.819 kB
12.351 kB
react-datepicker-compat
DatePicker Compat
250.208 kB
66.95 kB
react-dialog
Dialog (including children components)
93.388 kB
27.408 kB
react-divider
Divider
19.863 kB
6.697 kB
react-field
Field
20.552 kB
7.092 kB
react-image
Image
14.011 kB
4.993 kB
react-infobutton
InfoButton
130.577 kB
39.439 kB
react-infobutton
InfoLabel
133.874 kB
40.488 kB
react-input
Input
25.747 kB
7.697 kB
react-input
InputField
35.723 kB
10.637 kB
react-label
Label
12.57 kB
4.586 kB
react-link
Link
12.301 kB
5.07 kB
react-menu
Menu (including children components)
130.926 kB
39.629 kB
react-menu
Menu (including selectable components)
134.062 kB
40.161 kB
react-overflow
hooks only
11.214 kB
4.271 kB
react-persona
Persona
67.338 kB
17.524 kB
react-popover
Popover
117.58 kB
35.828 kB
react-portal
Portal
11.649 kB
4.263 kB
react-portal-compat
PortalCompatProvider
6.446 kB
2.185 kB
react-positioning
usePositioning
24.008 kB
8.798 kB
react-progress
ProgressBar
15.961 kB
5.675 kB
react-progress
ProgressField
26.435 kB
8.859 kB
react-provider
FluentProvider
20.766 kB
7.119 kB
react-radio
Radio
35.48 kB
11.126 kB
react-radio
RadioGroup
17.988 kB
6.544 kB
react-radio
RadioGroupField
28.166 kB
9.735 kB
react-select
Select
26.957 kB
8.766 kB
react-select
SelectField
36.293 kB
11.316 kB
react-slider
Slider
35.919 kB
11.059 kB
react-slider
SliderField
45.847 kB
14.005 kB
react-spinbutton
SpinButton
35.648 kB
10.348 kB
react-spinbutton
SpinButtonField
44.671 kB
12.812 kB
react-spinner
Spinner
23.425 kB
7.195 kB
react-switch
Switch
31.413 kB
9.294 kB
react-switch
SwitchField
38.317 kB
11.21 kB
react-table
DataGrid
149.878 kB
40.662 kB
react-table
Table (Primitives only)
47.119 kB
12.703 kB
react-table
Table as DataGrid
138.018 kB
35.282 kB
react-table
Table (Selection only)
85.849 kB
21.303 kB
react-table
Table (Sort only)
85.179 kB
21.113 kB
react-text
Text - Default
15.018 kB
5.327 kB
react-text
Text - Wrappers
15.572 kB
5.23 kB
react-textarea
Textarea
29.07 kB
9.081 kB
react-textarea
TextareaField
39.454 kB
12.055 kB
react-tooltip
Tooltip
49.388 kB
16.815 kB
react-utilities
SSRProvider
180 B
159 B
🤖 This report was generated against 2bea5b29844ac124b923a40e20e135e5b25668c6

@fabricteam
Copy link
Collaborator

fabricteam commented Mar 30, 2023

Perf Analysis (@fluentui/react-components)

No significant results to display.

All results

Scenario Render type Master Ticks PR Ticks Iterations Status
Avatar mount 897 890 5000
Button mount 595 585 5000
Field mount 1542 1540 5000
FluentProvider mount 1101 1111 5000
FluentProviderWithTheme mount 286 316 10
FluentProviderWithTheme virtual-rerender 290 281 10
FluentProviderWithTheme virtual-rerender-with-unmount 296 296 10
InfoButton mount 202 203 5000
MakeStyles mount 1406 1388 50000
Persona mount 2153 2093 5000
SpinButton mount 1835 1793 5000

@fabricteam
Copy link
Collaborator

fabricteam commented Mar 30, 2023

🕵 fluentuiv9 No visual regressions between this PR and main

@bsunderhus bsunderhus changed the title Breaking Change: Fixes SlotRenderFunction signature to include children bugfix(react-utilities): change SlotRenderFunction signature to include children Mar 30, 2023
@bsunderhus bsunderhus removed the Needs: API Breaking Change Tracking breaking changes for API surface area label Mar 31, 2023
@bsunderhus bsunderhus marked this pull request as ready for review April 3, 2023 10:07
@bsunderhus bsunderhus requested a review from a team as a code owner April 3, 2023 10:08
@bsunderhus bsunderhus force-pushed the react-utilities/bugfix--updates-SlotRenderFunction-signature-to-include-children branch from bec10cf to ca3efca Compare April 3, 2023 10:16
@bsunderhus bsunderhus merged commit 60f7139 into microsoft:master Apr 3, 2023
@bsunderhus bsunderhus deleted the react-utilities/bugfix--updates-SlotRenderFunction-signature-to-include-children branch April 3, 2023 11:38
marcosmoura added a commit to marcosmoura/fluentui that referenced this pull request Apr 4, 2023
* master: (39 commits)
  Added merge tests for custom styles (microsoft#27086)
  fix: make Option's checkIcon slot render conditionally (microsoft#27409)
  docs: add subcomponents to Combobox and Dropdown docs (microsoft#27410)
  Breadcrumb spec (microsoft#26742)
  bugfix(react-utilities): increments SlotRenderFunction signature to include children (microsoft#27377)
  fix: Menu should not steal focus on close (microsoft#27414)
  Fixed Overflow component when there's more then one children element (microsoft#27402)
  feat(scripts-executors): support custom base and printing all affected packages for checkIfPackagesAffected (microsoft#27364)
  applying package updates
  feat(scripts-tasks): make perf test setup generic (microsoft#26920)
  fix: ColorPicker preview color updated to ignore forced colors (microsoft#27394)
  fix: Fix babel build error on windows (microsoft#27406)
  chore(react-datepicker-compat): Add vr-tests and bundle-size fixtures for DatePicker (microsoft#27351)
  fix(react-dialog): DialogContent scrollbar always visible (microsoft#27367)
  docs: Add tokens search (microsoft#27265)
  chore(scripts-tasks): remove not needed api-extractor task logs (microsoft#27094)
  chore(react-tree): adds e2e flat tree tests (microsoft#27318)
  applying package updates
  Accessibility fix for empty vertical bar chart (microsoft#26254)
  fix(react-datepicker-compat): Fix theming issues with all themes and WHCM (microsoft#27361)
  ...
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

5 participants