Skip to content

Conversation

@bsunderhus
Copy link
Contributor

New Behavior

Follow up on #29310

getNativeElementProps has some type safety issues, allowing erroneous properties to be introduced.

  1. replaces use cases of getNativeElementProps with an equivalent but more restrict method getIntrinsicElementProps

@bsunderhus bsunderhus requested review from a team, chpalac and ling1726 as code owners October 4, 2023 07:55
@bsunderhus bsunderhus self-assigned this Oct 4, 2023
@github-actions github-actions bot added this to the October Project Cycle Q4 2023 milestone Oct 4, 2023
@bsunderhus bsunderhus marked this pull request as draft October 4, 2023 07:55
@fabricteam
Copy link
Collaborator

fabricteam commented Oct 4, 2023

📊 Bundle size report

Package & Exports Baseline (minified/GZIP) PR Change
react-alert
Alert
83.105 kB
23.051 kB
83.172 kB
23.078 kB
67 B
27 B
react-components
react-components: Button, FluentProvider & webLightTheme
68.675 kB
19.72 kB
68.748 kB
19.742 kB
73 B
22 B
react-components
react-components: Accordion, Button, FluentProvider, Image, Menu, Popover
206.231 kB
59.218 kB
206.308 kB
59.248 kB
77 B
30 B
react-components
react-components: FluentProvider & webLightTheme
40.793 kB
13.521 kB
40.866 kB
13.546 kB
73 B
25 B
react-dialog
Dialog (including children components)
88.307 kB
26.334 kB
88.365 kB
26.344 kB
58 B
10 B
react-infobutton
InfoButton
128.844 kB
40.576 kB
128.917 kB
40.599 kB
73 B
23 B
react-infobutton
InfoLabel
132.535 kB
41.752 kB
132.608 kB
41.776 kB
73 B
24 B
react-menu
Menu (including children components)
138.755 kB
42.86 kB
138.822 kB
42.876 kB
67 B
16 B
react-menu
Menu (including selectable components)
141.441 kB
43.37 kB
141.508 kB
43.389 kB
67 B
19 B
react-popover
Popover
117.589 kB
37.101 kB
117.662 kB
37.118 kB
73 B
17 B
react-provider
FluentProvider
21.338 kB
7.945 kB
21.411 kB
7.972 kB
73 B
27 B
react-table
DataGrid
155.92 kB
43.463 kB
155.989 kB
43.497 kB
69 B
34 B
react-table
Table (Primitives only)
42.715 kB
13.341 kB
42.788 kB
13.359 kB
73 B
18 B
react-table
Table as DataGrid
129.19 kB
34.771 kB
129.257 kB
34.79 kB
67 B
19 B
react-table
Table (Selection only)
74.557 kB
20.071 kB
74.624 kB
20.096 kB
67 B
25 B
react-table
Table (Sort only)
73.164 kB
19.67 kB
73.231 kB
19.694 kB
67 B
24 B
react-tags
InteractionTag
14.275 kB
5.717 kB
14.342 kB
5.736 kB
67 B
19 B
react-tags
Tag
28.998 kB
9.061 kB
29.065 kB
9.081 kB
67 B
20 B
react-tags
TagGroup
72.507 kB
21.605 kB
72.581 kB
21.631 kB
74 B
26 B
react-toast
Toast (including Toaster)
91.124 kB
27.293 kB
91.201 kB
27.314 kB
77 B
21 B
Unchanged fixtures
Package & Exports Size (minified/GZIP)
react-avatar
Avatar
49.185 kB
15.491 kB
react-avatar
AvatarGroup
18.716 kB
7.458 kB
react-avatar
AvatarGroupItem
63.841 kB
19.834 kB
react-datepicker-compat
DatePicker Compat
210.557 kB
58.665 kB
react-persona
Persona
56.076 kB
17.369 kB
react-portal-compat
PortalCompatProvider
6.503 kB
2.22 kB
🤖 This report was generated against 5ccd6610a7f86ea7d22aae7c0a62f3f0061f0bc5

@bsunderhus bsunderhus force-pushed the react-utilities/chore--migrate-from-getNativeElementProps-to-getIntrinsicElementProps branch from e457df2 to cf5b015 Compare October 4, 2023 08:05
@fabricteam
Copy link
Collaborator

fabricteam commented Oct 4, 2023

Perf Analysis (@fluentui/react-components)

Scenario Render type Master Ticks PR Ticks Iterations Status
InfoButton mount 12 13 5000 Possible regression
All results

Scenario Render type Master Ticks PR Ticks Iterations Status
Avatar mount 622 635 5000
Button mount 309 318 5000
Field mount 1086 1133 5000
FluentProvider mount 691 690 5000
FluentProviderWithTheme mount 76 84 10
FluentProviderWithTheme virtual-rerender 60 60 10
FluentProviderWithTheme virtual-rerender-with-unmount 72 73 10
InfoButton mount 12 13 5000 Possible regression
MakeStyles mount 870 841 50000
Persona mount 1776 1662 5000
SpinButton mount 1377 1417 5000

@bsunderhus bsunderhus force-pushed the react-utilities/chore--migrate-from-getNativeElementProps-to-getIntrinsicElementProps branch from cf5b015 to 86b584e Compare October 4, 2023 08:20
@codesandbox-ci
Copy link

codesandbox-ci bot commented Oct 4, 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 27bb961:

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

@fabricteam
Copy link
Collaborator

fabricteam commented Oct 4, 2023

🕵 fluentuiv9 No visual regressions between this PR and main

@bsunderhus bsunderhus force-pushed the react-utilities/chore--migrate-from-getNativeElementProps-to-getIntrinsicElementProps branch from 86b584e to 17e6662 Compare October 4, 2023 08:56
@size-auditor
Copy link

size-auditor bot commented Oct 4, 2023

Asset size changes

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

Baseline commit: 5ccd6610a7f86ea7d22aae7c0a62f3f0061f0bc5 (build)

@bsunderhus bsunderhus force-pushed the react-utilities/chore--migrate-from-getNativeElementProps-to-getIntrinsicElementProps branch from 17e6662 to 27bb961 Compare October 4, 2023 10:04
@bsunderhus bsunderhus marked this pull request as ready for review October 4, 2023 10:49
@bsunderhus bsunderhus merged commit 86dd769 into microsoft:master Oct 4, 2023
@bsunderhus bsunderhus deleted the react-utilities/chore--migrate-from-getNativeElementProps-to-getIntrinsicElementProps branch October 4, 2023 12:13
marcosmoura added a commit to marcosmoura/fluentui that referenced this pull request Oct 4, 2023
* master: (35 commits)
  bugfix(react-dialog): removes context hooks invocations from styles hook (microsoft#29396)
  chore(react-dialog): exports DialogSurface context types and hooks (microsoft#29397)
  Minimum height feature for bar chart (microsoft#29359)
  (feat) Breadcrumb - register items via context (microsoft#29393)
  fix: Consider all parents as scroll parents (microsoft#29378)
  Changes to enable charting on fluent docsite (microsoft#29210)
  bugfix: ensure TreeItem emits events properly (microsoft#29390)
  chore(deps): bump get-func-name from 2.0.0 to 2.0.2 (microsoft#29320)
  chore: migrate from getNativeElementProps to getIntrinsicElementProps (microsoft#29387)
  applying package updates
  applying package updates
  fix: Icon in disabled Button shouldn't change color on hover or pressed (microsoft#29342)
  Squish changes for rebase (microsoft#28705)
  fix: GroupedListV2 scrollToIndex now works correctly (microsoft#29332)
  Fix 27482: ProgressBar has an optional state variable  (microsoft#29366)
  remove a11y test ux from theme designer (microsoft#29379)
  feat: preview release (microsoft#29377)
  Fixed divider in the tooltip (microsoft#29357)
  fix (microsoft#29376)
  docs: Initial documentation pass (microsoft#29372)
  ...
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.

3 participants