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

make-styles: fix types.ts compatibility with typescript < v4 #19281

Merged
merged 14 commits into from
Aug 6, 2021

Conversation

jspurlin
Copy link
Contributor

@jspurlin jspurlin commented Aug 5, 2021

Description of changes

PR #18169 updated types.ts in make-styles and that included adding names to some tuples which isn't supported in Typescript versions < v4 (see: labeled tuple elements in the Typescript v4 release notes).

This PR fixes that up. There is no functionality changes in the PR

Focus areas to test

Verified that resulting types.d.ts file is compatible with Typescript v3 (and v4)

@fabricteam
Copy link
Collaborator

fabricteam commented Aug 5, 2021

📊 Bundle size report

Unchanged fixtures
Package & Exports Size (minified/GZIP)
react-accordion
Accordion (including children components)
75.578 kB
22.287 kB
react-avatar
Avatar
56.558 kB
15.66 kB
react-badge
Badge
24.343 kB
7.165 kB
react-badge
CounterBadge
27.156 kB
7.851 kB
react-badge
PresenseBadge
237 B
177 B
react-button
Button
24.934 kB
8.001 kB
react-button
CompoundButton
30.226 kB
8.878 kB
react-button
MenuButton
26.521 kB
8.509 kB
react-button
ToggleButton
34.531 kB
8.637 kB
react-components
react-components: Accordion, Button, FluentProvider, Image, Menu, Popover
176.958 kB
50.08 kB
react-components
react-components: FluentProvider & webLightTheme
36.237 kB
11.596 kB
react-divider
Divider
15.889 kB
5.747 kB
react-image
Image
10.642 kB
4.264 kB
react-label
Label
9.397 kB
3.839 kB
react-link
Link
14.715 kB
6.012 kB
react-make-styles
makeStaticStyles (runtime)
7.59 kB
3.321 kB
react-make-styles
makeStyles + mergeClasses (runtime)
22.135 kB
8.356 kB
react-make-styles
makeStyles + mergeClasses (build time)
2.557 kB
1.202 kB
react-menu
Menu (including children components)
114.61 kB
34.554 kB
react-menu
Menu (including selectable components)
116.71 kB
34.824 kB
react-popover
Popover
124.181 kB
36.121 kB
react-portal
Portal
7.78 kB
2.672 kB
react-provider
FluentProvider
16.235 kB
5.972 kB
react-tooltip
Tooltip
45.281 kB
15.45 kB
🤖 This report was generated against d628c615678c61cc8ab7aa424d382527acb42a26

@codesandbox-ci
Copy link

codesandbox-ci bot commented Aug 5, 2021

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

Sandbox Source
Fluent UI React Starter Configuration

@size-auditor
Copy link

size-auditor bot commented Aug 5, 2021

Asset size changes

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

Baseline commit: d628c615678c61cc8ab7aa424d382527acb42a26 (build)

@fabricteam
Copy link
Collaborator

fabricteam commented Aug 5, 2021

Perf Analysis (@fluentui/react)

No significant results to display.

All results

Scenario Render type Master Ticks PR Ticks Iterations Status
Avatar mount 942 915 5000
BaseButton mount 995 959 5000
Breadcrumb mount 2614 2595 1000
ButtonNext mount 444 457 5000
Checkbox mount 1761 1684 5000
CheckboxBase mount 1433 1401 5000
ChoiceGroup mount 5140 5132 5000
ComboBox mount 1028 1036 1000
CommandBar mount 10480 10417 1000
ContextualMenu mount 6365 6335 1000
DefaultButton mount 1232 1225 5000
DetailsRow mount 3948 4025 5000
DetailsRowFast mount 4068 4030 5000
DetailsRowNoStyles mount 3741 3812 5000
Dialog mount 2205 2215 1000
DocumentCardTitle mount 143 163 1000
Dropdown mount 3456 3416 5000
FluentProviderNext mount 7205 7378 5000
FocusTrapZone mount 1847 1801 5000
FocusZone mount 1815 1893 5000
IconButton mount 1892 1924 5000
Label mount 342 357 5000
Layer mount 1891 1897 5000
Link mount 492 484 5000
MakeStyles mount 1795 1782 50000
MenuButton mount 1604 1541 5000
MessageBar mount 2026 2012 5000
Nav mount 3421 3471 1000
OverflowSet mount 1067 1049 5000
Panel mount 2106 2181 1000
Persona mount 888 855 1000
Pivot mount 1455 1464 1000
PrimaryButton mount 1375 1355 5000
Rating mount 8151 8124 5000
SearchBox mount 1452 1428 5000
Shimmer mount 2746 2733 5000
Slider mount 2057 2042 5000
SpinButton mount 5452 5332 5000
Spinner mount 429 444 5000
SplitButton mount 3359 3410 5000
Stack mount 542 538 5000
StackWithIntrinsicChildren mount 1634 1655 5000
StackWithTextChildren mount 4972 4871 5000
SwatchColorPicker mount 10857 10601 5000
Tabs mount 1436 1531 1000
TagPicker mount 2709 2713 5000
TeachingBubble mount 12199 12074 5000
Text mount 438 462 5000
TextField mount 1439 1416 5000
ThemeProvider mount 1215 1203 5000
ThemeProvider virtual-rerender 599 580 5000
Toggle mount 846 855 5000
buttonNative mount 114 120 5000

Perf Analysis (@fluentui/react-northstar)

Perf tests with no regressions
Scenario Current PR Ticks Baseline Ticks Ratio
FlexMinimalPerf.default 336 299 1.12:1
AttachmentMinimalPerf.default 175 158 1.11:1
SkeletonMinimalPerf.default 404 369 1.09:1
ChatDuplicateMessagesPerf.default 307 283 1.08:1
RefMinimalPerf.default 238 220 1.08:1
PortalMinimalPerf.default 181 169 1.07:1
TextMinimalPerf.default 379 353 1.07:1
ChatWithPopoverPerf.default 392 369 1.06:1
FormMinimalPerf.default 449 424 1.06:1
IconMinimalPerf.default 682 644 1.06:1
AvatarMinimalPerf.default 214 203 1.05:1
HeaderSlotsPerf.default 822 785 1.05:1
LabelMinimalPerf.default 435 413 1.05:1
MenuMinimalPerf.default 887 846 1.05:1
VideoMinimalPerf.default 704 672 1.05:1
ImageMinimalPerf.default 419 404 1.04:1
LayoutMinimalPerf.default 396 379 1.04:1
ListMinimalPerf.default 548 527 1.04:1
LoaderMinimalPerf.default 733 704 1.04:1
AnimationMinimalPerf.default 439 427 1.03:1
BoxMinimalPerf.default 366 354 1.03:1
DropdownManyItemsPerf.default 739 716 1.03:1
DropdownMinimalPerf.default 3195 3117 1.03:1
PopupMinimalPerf.default 595 579 1.03:1
RadioGroupMinimalPerf.default 487 471 1.03:1
TableMinimalPerf.default 447 435 1.03:1
TreeMinimalPerf.default 847 821 1.03:1
CardMinimalPerf.default 595 585 1.02:1
TreeWith60ListItems.default 177 173 1.02:1
AlertMinimalPerf.default 301 299 1.01:1
AttachmentSlotsPerf.default 1130 1116 1.01:1
ChatMinimalPerf.default 700 693 1.01:1
CheckboxMinimalPerf.default 2851 2830 1.01:1
ListCommonPerf.default 685 675 1.01:1
ProviderMinimalPerf.default 1044 1034 1.01:1
CustomToolbarPrototype.default 3938 3916 1.01:1
CarouselMinimalPerf.default 485 487 1:1
DatepickerMinimalPerf.default 5720 5708 1:1
DividerMinimalPerf.default 399 398 1:1
EmbedMinimalPerf.default 4300 4293 1:1
InputMinimalPerf.default 1294 1294 1:1
ItemLayoutMinimalPerf.default 1306 1310 1:1
MenuButtonMinimalPerf.default 1707 1702 1:1
ProviderMergeThemesPerf.default 1624 1625 1:1
SegmentMinimalPerf.default 376 377 1:1
SliderMinimalPerf.default 1626 1621 1:1
StatusMinimalPerf.default 747 748 1:1
DialogMinimalPerf.default 800 806 0.99:1
HeaderMinimalPerf.default 379 382 0.99:1
ToolbarMinimalPerf.default 997 1008 0.99:1
ButtonOverridesMissPerf.default 1757 1795 0.98:1
GridMinimalPerf.default 361 368 0.98:1
ListWith60ListItems.default 684 696 0.98:1
RosterPerf.default 1261 1286 0.98:1
ReactionMinimalPerf.default 398 406 0.98:1
SplitButtonMinimalPerf.default 4112 4189 0.98:1
TooltipMinimalPerf.default 1028 1048 0.98:1
ButtonMinimalPerf.default 180 185 0.97:1
ButtonSlotsPerf.default 576 602 0.96:1
TableManyItemsPerf.default 2066 2161 0.96:1
AccordionMinimalPerf.default 160 168 0.95:1
ListNestedPerf.default 597 626 0.95:1
TextAreaMinimalPerf.default 540 584 0.92:1

@behowell behowell merged commit 8a09087 into microsoft:master Aug 6, 2021
@msft-fluent-ui-bot
Copy link
Collaborator

🎉@fluentui/[email protected] has been released which incorporates this pull request.:tada:

Handy links:

@msft-fluent-ui-bot
Copy link
Collaborator

🎉@fluentui/[email protected] has been released which incorporates this pull request.:tada:

Handy links:

@msft-fluent-ui-bot
Copy link
Collaborator

🎉@fluentui/[email protected] has been released which incorporates this pull request.:tada:

Handy links:

@msft-fluent-ui-bot
Copy link
Collaborator

🎉@fluentui/[email protected] has been released which incorporates this pull request.:tada:

Handy links:

@msft-fluent-ui-bot
Copy link
Collaborator

🎉@fluentui/[email protected] has been released which incorporates this pull request.:tada:

Handy links:

@msft-fluent-ui-bot
Copy link
Collaborator

🎉@fluentui/[email protected] has been released which incorporates this pull request.:tada:

Handy links:

@msft-fluent-ui-bot
Copy link
Collaborator

🎉@fluentui/[email protected] has been released which incorporates this pull request.:tada:

Handy links:

@msft-fluent-ui-bot
Copy link
Collaborator

🎉@fluentui/[email protected] has been released which incorporates this pull request.:tada:

Handy links:

@msft-fluent-ui-bot
Copy link
Collaborator

🎉@fluentui/[email protected] has been released which incorporates this pull request.:tada:

Handy links:

@msft-fluent-ui-bot
Copy link
Collaborator

🎉@fluentui/[email protected] has been released which incorporates this pull request.:tada:

Handy links:

@msft-fluent-ui-bot
Copy link
Collaborator

🎉@fluentui/[email protected] has been released which incorporates this pull request.:tada:

Handy links:

@msft-fluent-ui-bot
Copy link
Collaborator

🎉@fluentui/[email protected] has been released which incorporates this pull request.:tada:

Handy links:

@msft-fluent-ui-bot
Copy link
Collaborator

🎉@fluentui/[email protected] has been released which incorporates this pull request.:tada:

Handy links:

@msft-fluent-ui-bot
Copy link
Collaborator

🎉@fluentui/[email protected] has been released which incorporates this pull request.:tada:

Handy links:

@msft-fluent-ui-bot
Copy link
Collaborator

🎉@fluentui/[email protected] has been released which incorporates this pull request.:tada:

Handy links:

@msft-fluent-ui-bot
Copy link
Collaborator

🎉@fluentui/[email protected] has been released which incorporates this pull request.:tada:

Handy links:

@msft-fluent-ui-bot
Copy link
Collaborator

🎉@fluentui/[email protected] has been released which incorporates this pull request.:tada:

Handy links:

@msft-fluent-ui-bot
Copy link
Collaborator

🎉@fluentui/[email protected] has been released which incorporates this pull request.:tada:

Handy links:

@msft-fluent-ui-bot
Copy link
Collaborator

🎉@fluentui/[email protected] has been released which incorporates this pull request.:tada:

Handy links:

@msft-fluent-ui-bot
Copy link
Collaborator

🎉@fluentui/[email protected] has been released which incorporates this pull request.:tada:

Handy links:

@msft-fluent-ui-bot
Copy link
Collaborator

🎉@fluentui/[email protected] has been released which incorporates this pull request.:tada:

Handy links:

@layershifter
Copy link
Member

Ideally this should be solved by downleveling types (#18441) instead of fixing code 😥

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.

6 participants