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

fix(react-positioning): autoSize causing position update to reach maximum #28689

Merged
merged 5 commits into from
Aug 1, 2023

Conversation

YuanboXue-Amber
Copy link
Contributor

@YuanboXue-Amber YuanboXue-Amber commented Jul 31, 2023

#28649 introduced resetMaxSize middleware - when autoSize is specified, resetMaxSize middleware is used to reset the styles from previous life cycle and set a flag to not reset again. But the flag didn't work because of a stupid mistake in the check. This PR corrects it.

@YuanboXue-Amber YuanboXue-Amber marked this pull request as ready for review July 31, 2023 19:37
@YuanboXue-Amber YuanboXue-Amber requested a review from a team as a code owner July 31, 2023 19:37
@YuanboXue-Amber YuanboXue-Amber changed the title fix(react-positioning): autoSize causing infinite position update fix(react-positioning): autoSize causing position update to reach maximum Jul 31, 2023
@fabricteam
Copy link
Collaborator

fabricteam commented Jul 31, 2023

Perf Analysis (@fluentui/react-components)

No significant results to display.

All results

Scenario Render type Master Ticks PR Ticks Iterations Status
Avatar mount 617 618 5000
Button mount 300 286 5000
Field mount 1059 1064 5000
FluentProvider mount 645 650 5000
FluentProviderWithTheme mount 86 78 10
FluentProviderWithTheme virtual-rerender 70 73 10
FluentProviderWithTheme virtual-rerender-with-unmount 74 84 10
InfoButton mount 15 11 5000
MakeStyles mount 851 828 50000
Persona mount 1696 1622 5000
SpinButton mount 1371 1285 5000

@codesandbox-ci
Copy link

codesandbox-ci bot commented Jul 31, 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 889af91:

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

@fabricteam
Copy link
Collaborator

fabricteam commented Jul 31, 2023

📊 Bundle size report

Package & Exports Baseline (minified/GZIP) PR Change
react-combobox
Combobox (including child components)
87.958 kB
28.359 kB
88.007 kB
28.369 kB
49 B
10 B
react-combobox
Dropdown (including child components)
86.382 kB
27.983 kB
86.431 kB
28 kB
49 B
17 B
react-components
react-components: Accordion, Button, FluentProvider, Image, Menu, Popover
206.083 kB
57.397 kB
206.144 kB
57.411 kB
61 B
14 B
react-datepicker-compat
DatePicker Compat
218.141 kB
58.186 kB
218.19 kB
58.196 kB
49 B
10 B
react-infobutton
InfoButton
126.753 kB
39.348 kB
126.802 kB
39.356 kB
49 B
8 B
react-infobutton
InfoLabel
130.343 kB
40.471 kB
130.392 kB
40.474 kB
49 B
3 B
react-menu
Menu (including children components)
134.132 kB
40.977 kB
134.181 kB
40.988 kB
49 B
11 B
react-menu
Menu (including selectable components)
136.896 kB
41.456 kB
136.945 kB
41.467 kB
49 B
11 B
react-popover
Popover
115.312 kB
35.916 kB
115.361 kB
35.927 kB
49 B
11 B
react-positioning
usePositioning
25.062 kB
9.087 kB
25.111 kB
9.1 kB
49 B
13 B
react-tooltip
Tooltip
48.261 kB
16.86 kB
48.31 kB
16.87 kB
49 B
10 B
Unchanged fixtures
Package & Exports Size (minified/GZIP)
react-alert
Alert
84.992 kB
22.03 kB
react-avatar
Avatar
47.739 kB
14.521 kB
react-avatar
AvatarGroup
15.695 kB
6.314 kB
react-avatar
AvatarGroupItem
63.915 kB
19.001 kB
react-components
react-components: Button, FluentProvider & webLightTheme
67.576 kB
18.225 kB
react-components
react-components: FluentProvider & webLightTheme
36.409 kB
12.003 kB
react-persona
Persona
55.293 kB
16.535 kB
react-portal-compat
PortalCompatProvider
6.48 kB
2.203 kB
react-table
DataGrid
158.433 kB
42.451 kB
react-table
Table (Primitives only)
43.95 kB
12.263 kB
react-table
Table as DataGrid
132.237 kB
33.887 kB
react-table
Table (Selection only)
77.612 kB
19.179 kB
react-table
Table (Sort only)
76.231 kB
18.783 kB
react-tags-preview
InteractionTag
34.171 kB
9.199 kB
react-tags-preview
Tag
25.962 kB
8.49 kB
react-tags-preview
TagGroup
69.398 kB
20.364 kB
🤖 This report was generated against 937b241d624114c181ea1521d0d4ead1068ddfa3

@size-auditor
Copy link

size-auditor bot commented Jul 31, 2023

Asset size changes

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

Baseline commit: 937b241d624114c181ea1521d0d4ead1068ddfa3 (build)

@YuanboXue-Amber YuanboXue-Amber enabled auto-merge (squash) August 1, 2023 08:57
@YuanboXue-Amber YuanboXue-Amber merged commit 412d815 into microsoft:master Aug 1, 2023
20 of 24 checks passed
marcosmoura added a commit to marcosmoura/fluentui that referenced this pull request Aug 1, 2023
* master: (37 commits)
  release (microsoft#28696)
  Fixing re-render issue for all charts when empty (microsoft#28321)
  feat(FluentProvider): emit errors on duplicate IDs (microsoft#28670)
  applying package updates
  fix(react-positioning): autoSize causing position update to reach maximum (microsoft#28689)
  fix(react-tags-preview): fix InteractionTag hover styles (microsoft#28686)
  Accordion: export AccordionHeaderProvider (microsoft#28542)
  feat(react-shared-contexts): add AnnounceContext (microsoft#28654)
  Added VR tests for Breadcrumb (microsoft#28653)
  fix(react-menu): use outline for menuItem focus ring (microsoft#28685)
  [Bug]: Tree, vertical spacing of branches and children is inconsistent (microsoft#28681)
  feaTt(react-tree): adds openItems and checkedItems to tree callback data (microsoft#28669)
  applying package updates
  Add mountNode prop to combos (microsoft#28661)
  react-tags-preview: add more vr test (microsoft#28582)
  chore: migrate to nx 16.1.4 (microsoft#28583)
  applying package updates
  chore: improves internal headless signature (microsoft#28651)
  fix: remove margin from icon when ToolbarButton is vertical (microsoft#28658)
  applying package updates
  ...
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

4 participants