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: Revert #26931 change due to new bug it introduced #27323

Merged
merged 7 commits into from
Mar 24, 2023

Conversation

micahgodbolt
Copy link
Member

@micahgodbolt micahgodbolt commented Mar 24, 2023

fixes #27256

#26931 made a change where local state in autofill would not update if value was being controlled, as this caused a bug where cursor would jump to the end. #18499

Unfortunately, IME support relied on local state always being updated, so this broke IME support for Combobox in freeform mode.

As both bugs are affecting the same customer, they would rather revert and take on the smaller previous bug.

To address the original issue we need to determine how we can return the original behavior while not breaking IME (it looks like getDerivedStateFromProps is getting called multiple times during IME and sometimes the updateInputValue is an empty string, leaving the value empty in the end)

After this change is reverted we'll need to cherrypick it back to 8.106.1

@micahgodbolt micahgodbolt changed the title Revert 26931 Fix: Revert #26931 change due to new bug it introduced Mar 24, 2023
@behowell
Copy link
Contributor

behowell commented Mar 24, 2023

This should also be marked as fixing #27256 right?

@fabricteam
Copy link
Collaborator

fabricteam commented Mar 24, 2023

📊 Bundle size report

Unchanged fixtures
Package & Exports Size (minified/GZIP)
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-portal-compat
PortalCompatProvider
6.446 kB
2.185 kB
🤖 This report was generated against df9564ee42c12b0dfab646f9e4dd4038c636d3ee

@codesandbox-ci
Copy link

codesandbox-ci bot commented Mar 24, 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 35dc0f6:

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

@size-auditor
Copy link

size-auditor bot commented Mar 24, 2023

Asset size changes

Project Bundle Baseline Size New Size Difference
office-ui-fabric-react fluentui-react-Pickers 280.343 kB 280.291 kB BelowBaseline     -52 bytes
office-ui-fabric-react fluentui-react-TimePicker 227.313 kB 227.261 kB BelowBaseline     -52 bytes
office-ui-fabric-react fluentui-react-ComboBox 238.317 kB 238.265 kB BelowBaseline     -52 bytes
office-ui-fabric-react fluentui-react-ExtendedPicker 94.16 kB 94.108 kB BelowBaseline     -52 bytes
office-ui-fabric-react fluentui-react-Autofill 15.042 kB 14.99 kB BelowBaseline     -52 bytes

ExceedsTolerance Over Tolerance (1024 B) ExceedsBaseline Over Baseline BelowBaseline Below Baseline New New Deleted  Removed 1 kB = 1000 B

Baseline commit: df9564ee42c12b0dfab646f9e4dd4038c636d3ee (build)

@fabricteam
Copy link
Collaborator

fabricteam commented Mar 24, 2023

Perf Analysis (@fluentui/react-components)

No significant results to display.

All results

Scenario Render type Master Ticks PR Ticks Iterations Status
Avatar mount 886 872 5000
Button mount 583 589 5000
Field mount 1539 1525 5000
FluentProvider mount 1092 1083 5000
FluentProviderWithTheme mount 295 297 10
FluentProviderWithTheme virtual-rerender 272 276 10
FluentProviderWithTheme virtual-rerender-with-unmount 281 286 10
InfoButton mount 209 198 5000
MakeStyles mount 1388 1410 50000
Persona mount 2154 2051 5000
SpinButton mount 1846 1843 5000

@fabricteam
Copy link
Collaborator

fabricteam commented Mar 24, 2023

Perf Analysis (@fluentui/react)

No significant results to display.

All results

Scenario Render type Master Ticks PR Ticks Iterations Status
BaseButton mount 940 937 5000
Breadcrumb mount 2181 2194 1000
Checkbox mount 2166 2195 5000
CheckboxBase mount 1923 1953 5000
ChoiceGroup mount 3678 3694 5000
ComboBox mount 945 951 1000
CommandBar mount 7902 7942 1000
ContextualMenu mount 13669 13757 1000
DefaultButton mount 1070 1101 5000
DetailsRow mount 2814 2818 5000
DetailsRowFast mount 2795 2793 5000
DetailsRowNoStyles mount 2573 2612 5000
Dialog mount 3107 3153 1000
DocumentCardTitle mount 417 430 1000
Dropdown mount 2610 2637 5000
FocusTrapZone mount 1563 1548 5000
FocusZone mount 1533 1562 5000
GroupedList mount 45789 52721 2
GroupedList virtual-rerender 22495 22478 2
GroupedList virtual-rerender-with-unmount 63451 62839 2
GroupedListV2 mount 415 408 2
GroupedListV2 virtual-rerender 388 399 2
GroupedListV2 virtual-rerender-with-unmount 407 402 2
IconButton mount 1439 1464 5000
Label mount 564 570 5000
Layer mount 3509 3553 5000
Link mount 656 667 5000
MenuButton mount 1318 1308 5000
MessageBar mount 25944 25917 5000
Nav mount 2500 2566 1000
OverflowSet mount 1133 1155 5000
Panel mount 2064 2080 1000
Persona mount 1042 1050 1000
Pivot mount 1221 1233 1000
PrimaryButton mount 1179 1189 5000
Rating mount 5816 5901 5000
SearchBox mount 1214 1228 5000
Shimmer mount 2449 2459 5000
Slider mount 1778 1744 5000
SpinButton mount 3578 3556 5000
Spinner mount 624 638 5000
SplitButton mount 2419 2383 5000
Stack mount 664 648 5000
StackWithIntrinsicChildren mount 1205 1211 5000
StackWithTextChildren mount 3553 3563 5000
SwatchColorPicker mount 7644 7549 5000
TagPicker mount 1859 1993 5000
Text mount 628 624 5000
TextField mount 1227 1259 5000
ThemeProvider mount 1107 1108 5000
ThemeProvider virtual-rerender 906 910 5000
ThemeProvider virtual-rerender-with-unmount 1649 1641 5000
Toggle mount 872 895 5000
buttonNative mount 369 382 5000

@fabricteam
Copy link
Collaborator

🕵 fluentuiv8 No visual regressions between this PR and main

@behowell
Copy link
Contributor

Force merging: the build failures are timeouts in v9 SSR tests, which are unrelated to this change. This is a high priority issue to resolve, so we can't wait for the tests to be fixed.

@behowell behowell merged commit 0f112dc into microsoft:master Mar 24, 2023
@micahgodbolt micahgodbolt deleted the revert-26931 branch March 24, 2023 21:51
marcosmoura added a commit to marcosmoura/fluentui that referenced this pull request Mar 27, 2023
* master: (47 commits)
  fix: Fix vertical alignment of inline Checkbox when checked vs. unchecked (microsoft#27324)
  applying package updates
  Fix: Revert microsoft#26931 change due to new bug it introduced (microsoft#27323)
  chore(react-infobutton): Renaming content slot to info (microsoft#27316)
  applying package updates
  Fix bad release mismatch of react-select (microsoft#27321)
  applying package updates
  Fix react-combobox mismatch after bad release (microsoft#27319)
  docs: add section about media query sorting (microsoft#27307)
  applying package updates
  fix: sync packages and changefiles after bad release (microsoft#27317)
  applying package updates
  chore(react-datepicker-compat): Cleanup types, unused code, and restore utils tests (microsoft#27297)
  [Fluent 2 Theme] Fixing link color in dark theme (microsoft#27203)
  Tree documentation and stories (microsoft#27270)
  feat: Render theme CSS variables in SSR style element (microsoft#27277)
  chore (scripts): update create-package plop templates to use swc/helpers in deps (microsoft#27286)
  fix(DialogContent): adds padding to allow focus visibility (microsoft#27248)
  Adding Card component style hooks to shared context (microsoft#27295)
  Virtualizer: Static scroll hooks and embedded scrollview (microsoft#26985)
  ...
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.

[Bug]: ComboBox: 'allowFreeform' does not accept IME input
4 participants