feat(label, switch): add static classes - #20456
Merged
Merged
Conversation
Collaborator
📊 Bundle size reportUnchanged fixtures
|
|
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 3774b9b:
|
Asset size changesSize Auditor did not detect a change in bundle size for any component! Baseline commit: e42f50656c1b703d88c398b114f225ba5f1f5f22 (build) |
Collaborator
Perf Analysis (
|
| Scenario | Render type | Master Ticks | PR Ticks | Iterations | Status |
|---|---|---|---|---|---|
| Avatar | mount | 978 | 1004 | 5000 | |
| BaseButton | mount | 916 | 929 | 5000 | |
| Breadcrumb | mount | 2702 | 2673 | 1000 | |
| ButtonNext | mount | 548 | 506 | 5000 | |
| Checkbox | mount | 1637 | 1578 | 5000 | |
| CheckboxBase | mount | 1374 | 1429 | 5000 | |
| ChoiceGroup | mount | 4892 | 4791 | 5000 | |
| ComboBox | mount | 1005 | 1026 | 1000 | |
| CommandBar | mount | 10657 | 10641 | 1000 | |
| ContextualMenu | mount | 6681 | 6678 | 1000 | |
| DefaultButton | mount | 1162 | 1186 | 5000 | |
| DetailsRow | mount | 3972 | 3923 | 5000 | |
| DetailsRowFast | mount | 3844 | 4008 | 5000 | |
| DetailsRowNoStyles | mount | 3785 | 3875 | 5000 | |
| Dialog | mount | 2643 | 2661 | 1000 | |
| DocumentCardTitle | mount | 166 | 180 | 1000 | |
| Dropdown | mount | 3310 | 3399 | 5000 | |
| FluentProviderNext | mount | 3520 | 3588 | 5000 | |
| FluentProviderWithTheme | mount | 221 | 215 | 10 | |
| FluentProviderWithTheme | virtual-rerender | 100 | 109 | 10 | |
| FluentProviderWithTheme | virtual-rerender-with-unmount | 256 | 243 | 10 | |
| FocusTrapZone | mount | 1856 | 1882 | 5000 | |
| FocusZone | mount | 1872 | 1859 | 5000 | |
| IconButton | mount | 1857 | 1763 | 5000 | |
| Label | mount | 354 | 368 | 5000 | |
| Layer | mount | 3148 | 3163 | 5000 | |
| Link | mount | 514 | 487 | 5000 | |
| MakeStyles | mount | 1919 | 1973 | 50000 | |
| MenuButton | mount | 1514 | 1585 | 5000 | |
| MessageBar | mount | 2122 | 2057 | 5000 | |
| Nav | mount | 3411 | 3430 | 1000 | |
| OverflowSet | mount | 1181 | 1130 | 5000 | |
| Panel | mount | 2615 | 2556 | 1000 | |
| Persona | mount | 899 | 879 | 1000 | |
| Pivot | mount | 1576 | 1476 | 1000 | |
| PrimaryButton | mount | 1304 | 1392 | 5000 | |
| Rating | mount | 8128 | 8298 | 5000 | |
| SearchBox | mount | 1397 | 1383 | 5000 | |
| Shimmer | mount | 2679 | 2637 | 5000 | |
| Slider | mount | 2068 | 2104 | 5000 | |
| SpinButton | mount | 5146 | 5272 | 5000 | |
| Spinner | mount | 474 | 460 | 5000 | |
| SplitButton | mount | 3323 | 3257 | 5000 | |
| Stack | mount | 520 | 552 | 5000 | |
| StackWithIntrinsicChildren | mount | 1784 | 1814 | 5000 | |
| StackWithTextChildren | mount | 4683 | 4828 | 5000 | |
| SwatchColorPicker | mount | 10843 | 10644 | 5000 | |
| TagPicker | mount | 2743 | 2751 | 5000 | |
| TeachingBubble | mount | 13524 | 13504 | 5000 | |
| Text | mount | 441 | 453 | 5000 | |
| TextField | mount | 1466 | 1474 | 5000 | |
| ThemeProvider | mount | 1264 | 1219 | 5000 | |
| ThemeProvider | virtual-rerender | 658 | 625 | 5000 | |
| ThemeProvider | virtual-rerender-with-unmount | 2001 | 1943 | 5000 | |
| Toggle | mount | 841 | 815 | 5000 | |
| buttonNative | mount | 150 | 143 | 5000 |
Perf Analysis (@fluentui/react-northstar)
Potential regressions comparing to master
| Scenario | Current PR Ticks | Baseline Ticks | Ratio | Regression Analysis |
|---|---|---|---|---|
| ChatDuplicateMessagesPerf.default | 310 | 306 | 1.01:1 | analysis |
Perf tests with no regressions
| Scenario | Current PR Ticks | Baseline Ticks | Ratio |
|---|---|---|---|
| TreeWith60ListItems.default | 216 | 186 | 1.16:1 |
| ButtonMinimalPerf.default | 199 | 174 | 1.14:1 |
| LabelMinimalPerf.default | 426 | 395 | 1.08:1 |
| PortalMinimalPerf.default | 198 | 183 | 1.08:1 |
| ChatWithPopoverPerf.default | 408 | 386 | 1.06:1 |
| SkeletonMinimalPerf.default | 376 | 356 | 1.06:1 |
| IconMinimalPerf.default | 632 | 597 | 1.06:1 |
| ButtonSlotsPerf.default | 596 | 566 | 1.05:1 |
| CarouselMinimalPerf.default | 505 | 480 | 1.05:1 |
| ImageMinimalPerf.default | 397 | 378 | 1.05:1 |
| ItemLayoutMinimalPerf.default | 1256 | 1195 | 1.05:1 |
| ListCommonPerf.default | 664 | 632 | 1.05:1 |
| SliderMinimalPerf.default | 1836 | 1752 | 1.05:1 |
| AttachmentMinimalPerf.default | 174 | 167 | 1.04:1 |
| DropdownManyItemsPerf.default | 735 | 706 | 1.04:1 |
| LayoutMinimalPerf.default | 386 | 372 | 1.04:1 |
| AvatarMinimalPerf.default | 204 | 198 | 1.03:1 |
| HeaderSlotsPerf.default | 782 | 757 | 1.03:1 |
| MenuButtonMinimalPerf.default | 1708 | 1659 | 1.03:1 |
| TooltipMinimalPerf.default | 1087 | 1052 | 1.03:1 |
| AnimationMinimalPerf.default | 437 | 428 | 1.02:1 |
| ButtonOverridesMissPerf.default | 1886 | 1852 | 1.02:1 |
| DividerMinimalPerf.default | 371 | 363 | 1.02:1 |
| InputMinimalPerf.default | 1389 | 1368 | 1.02:1 |
| ProviderMergeThemesPerf.default | 1792 | 1754 | 1.02:1 |
| CustomToolbarPrototype.default | 4239 | 4149 | 1.02:1 |
| ChatMinimalPerf.default | 694 | 689 | 1.01:1 |
| CheckboxMinimalPerf.default | 2869 | 2854 | 1.01:1 |
| EmbedMinimalPerf.default | 4377 | 4316 | 1.01:1 |
| HeaderMinimalPerf.default | 367 | 364 | 1.01:1 |
| ListMinimalPerf.default | 541 | 536 | 1.01:1 |
| ListWith60ListItems.default | 671 | 666 | 1.01:1 |
| PopupMinimalPerf.default | 623 | 614 | 1.01:1 |
| ReactionMinimalPerf.default | 404 | 400 | 1.01:1 |
| RefMinimalPerf.default | 241 | 238 | 1.01:1 |
| SplitButtonMinimalPerf.default | 4382 | 4349 | 1.01:1 |
| TableMinimalPerf.default | 427 | 423 | 1.01:1 |
| ToolbarMinimalPerf.default | 969 | 960 | 1.01:1 |
| AlertMinimalPerf.default | 279 | 279 | 1:1 |
| AttachmentSlotsPerf.default | 1163 | 1163 | 1:1 |
| BoxMinimalPerf.default | 356 | 356 | 1:1 |
| DatepickerMinimalPerf.default | 5736 | 5738 | 1:1 |
| DialogMinimalPerf.default | 790 | 789 | 1:1 |
| DropdownMinimalPerf.default | 3275 | 3261 | 1:1 |
| FormMinimalPerf.default | 418 | 416 | 1:1 |
| RadioGroupMinimalPerf.default | 473 | 474 | 1:1 |
| StatusMinimalPerf.default | 689 | 689 | 1:1 |
| TableManyItemsPerf.default | 1991 | 1987 | 1:1 |
| TreeMinimalPerf.default | 829 | 831 | 1:1 |
| FlexMinimalPerf.default | 311 | 313 | 0.99:1 |
| RosterPerf.default | 1240 | 1258 | 0.99:1 |
| ProviderMinimalPerf.default | 1164 | 1180 | 0.99:1 |
| ListNestedPerf.default | 574 | 586 | 0.98:1 |
| MenuMinimalPerf.default | 870 | 894 | 0.97:1 |
| VideoMinimalPerf.default | 620 | 636 | 0.97:1 |
| SegmentMinimalPerf.default | 375 | 389 | 0.96:1 |
| AccordionMinimalPerf.default | 157 | 166 | 0.95:1 |
| LoaderMinimalPerf.default | 701 | 735 | 0.95:1 |
| TextMinimalPerf.default | 360 | 379 | 0.95:1 |
| GridMinimalPerf.default | 347 | 369 | 0.94:1 |
| TextAreaMinimalPerf.default | 524 | 556 | 0.94:1 |
| CardMinimalPerf.default | 558 | 598 | 0.93:1 |
layershifter
marked this pull request as ready for review
November 2, 2021 18:37
layershifter
requested review from
a team,
behowell,
czearing,
ecraig12345 and
khmakoto
as code owners
November 2, 2021 18:37
khmakoto
approved these changes
Nov 2, 2021
khmakoto
reviewed
Nov 2, 2021
Comment on lines
+6
to
+7
| const trackClassName = `${switchClassName}-track`; | ||
| const thumbClassName = `${switchClassName}-thumb`; |
Member
Author
There was a problem hiding this comment.
May be, but not in this PR. If we would like to do this, we should have some naming convention/consistency around it, see #19937 (comment).
Co-authored-by: Makoto Morimoto <humbertomakotomorimoto@gmail.com>
layershifter
enabled auto-merge (squash)
November 3, 2021 11:11
layershifter
disabled auto-merge
November 3, 2021 11:14
…eat/classname-p8 � Conflicts: � packages/react-checkbox/src/components/Checkbox/__snapshots__/Checkbox.test.tsx.snap
…ntui into feat/classname-p8
layershifter
enabled auto-merge (squash)
November 3, 2021 11:18
layershifter
disabled auto-merge
November 3, 2021 11:22
layershifter
enabled auto-merge (squash)
November 3, 2021 11:41
mlp73
pushed a commit
to mlp73/fluentui
that referenced
this pull request
Jan 17, 2022
* feat(label, switch): add static classes * fix snapshots * Change files * Update packages/react-switch/Spec.md Co-authored-by: Makoto Morimoto <humbertomakotomorimoto@gmail.com> * fix snapshots Co-authored-by: Makoto Morimoto <humbertomakotomorimoto@gmail.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Pull request checklist
$ yarn changeDescription of changes
✅ Extracted from #20383, these changes passed conformance test on that PR
This PR adds static classes to components
@fluentui/react-avatar&@fluentui/react-badge.fui-ComponentNamecomponentNameClassName