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

chore(react-aria): migrate to new package structure #25199

Merged
merged 11 commits into from
Oct 26, 2022

Conversation

TristanWatanabe
Copy link
Member

@TristanWatanabe TristanWatanabe commented Oct 12, 2022

Changes:

Issue:

@TristanWatanabe TristanWatanabe self-assigned this Oct 12, 2022
@fabricteam
Copy link
Collaborator

fabricteam commented Oct 12, 2022

📊 Bundle size report

Unchanged fixtures
Package & Exports Size (minified/GZIP)
react-accordion
Accordion (including children components)
79.243 kB
24.436 kB
react-alert
Alert
84.688 kB
21.233 kB
react-avatar
Avatar
48.874 kB
13.864 kB
react-avatar
AvatarGroup
14.996 kB
6.013 kB
react-avatar
AvatarGroupItem
68.842 kB
19.205 kB
react-button
Button
36.849 kB
9.907 kB
react-button
CompoundButton
43.874 kB
11.123 kB
react-button
MenuButton
39.543 kB
10.807 kB
react-button
SplitButton
46.989 kB
12.192 kB
react-button
ToggleButton
52.716 kB
11.381 kB
react-card
Card - All
67.664 kB
19.635 kB
react-card
Card
63.346 kB
18.539 kB
react-card
CardFooter
8.607 kB
3.622 kB
react-card
CardHeader
9.65 kB
3.962 kB
react-card
CardPreview
8.708 kB
3.678 kB
react-components
react-components: Button, FluentProvider & webLightTheme
62.94 kB
17.663 kB
react-components
react-components: Accordion, Button, FluentProvider, Image, Menu, Popover
189.603 kB
52.909 kB
react-components
react-components: FluentProvider & webLightTheme
33.446 kB
11.033 kB
react-dialog
Dialog (including children components)
83.147 kB
24.799 kB
react-menu
Menu (including children components)
116.78 kB
36.112 kB
react-menu
Menu (including selectable components)
119.849 kB
36.635 kB
react-persona
Persona
53.992 kB
15.25 kB
react-popover
Popover
103.342 kB
31.82 kB
react-portal-compat
PortalCompatProvider
5.857 kB
1.978 kB
🤖 This report was generated against f6f3e4b27f850577890dce15000bf8d4dedc4381

@size-auditor
Copy link

size-auditor bot commented Oct 12, 2022

Asset size changes

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

Baseline commit: f6f3e4b27f850577890dce15000bf8d4dedc4381 (build)

@TristanWatanabe
Copy link
Member Author

This is currently throwing an error in react-accordion because it depends on react-aria's useAriaButtonProps which is marked as internal so it's now not being included in the react-aria's api after the changes in #23369 is applied to the package. There are other instances where other v9 components are depending on react-aria types and methods which are also marked as internal. What should be done in this case? Remove the internal tag from these methods? @Hotell @microsoft/teams-prg

image

@@ -1,6 +1,6 @@
import * as React from 'react';
Copy link
Contributor

@bsunderhus bsunderhus Oct 17, 2022

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Honestly, I was planing to simply remove storybook from this package at the moment, since this is an internal package (internal in the meaning of not being re-exported by react-components), and this documentation is not being very helpful at the moment

@bsunderhus
Copy link
Contributor

bsunderhus commented Oct 17, 2022

As far as I understood changes made on the new API extraction (correct me if I'm wrong @Hotell), if the method is marked as internal it'll mean it won't be available on the surface of that package API, which is not the case for useARIAButtonProps. So yeah @TristanWatanabe, we should remove @internal form those surface API methods.

The way to ensure this will keep being an internally used dependency is by simply not re-exporting it from @fluentui/react-components, Thx for the awesome PR btw! 💪🏻

@codesandbox-ci
Copy link

codesandbox-ci bot commented Oct 21, 2022

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 58710fa:

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

@fabricteam
Copy link
Collaborator

fabricteam commented Oct 21, 2022

Perf Analysis (@fluentui/react-components)

No significant results to display.

All results

Scenario Render type Master Ticks PR Ticks Iterations Status
Avatar mount 1266 1238 5000
Button mount 939 866 5000
FluentProvider mount 1535 1447 5000
FluentProviderWithTheme mount 556 635 10
FluentProviderWithTheme virtual-rerender 523 582 10
FluentProviderWithTheme virtual-rerender-with-unmount 630 625 10
MakeStyles mount 1903 1787 50000
SpinButton mount 2550 2453 5000

@TristanWatanabe
Copy link
Member Author

TristanWatanabe commented Oct 21, 2022

@bsunderhus Pulling out API stripping #23369 and export map changes #25033 from this PR to reduce scope. Those changes will now be applied by #25319

@TristanWatanabe TristanWatanabe marked this pull request as ready for review October 21, 2022 19:03
@TristanWatanabe TristanWatanabe requested a review from a team as a code owner October 21, 2022 19:03
@TristanWatanabe TristanWatanabe merged commit bd5530e into microsoft:master Oct 26, 2022
@TristanWatanabe TristanWatanabe deleted the migrate-aria branch October 26, 2022 17:18
sunilsurana added a commit to sunilsurana/fluentuifork1 that referenced this pull request Oct 27, 2022
* Update Link.stories.tsx

* Update Link.stories.tsx

* update

* chore(babel-preset-global-context): migrate to new package structure (microsoft#25340)

* chore(react-aria): migrate to new package structure (microsoft#25199)

* feat: re-export react-table logic hooks (microsoft#25386)

* applying package updates

* Website: fix focus border on UHF footer links (microsoft#25389)

* use not uhf link to increase specificity instead of body tag

* improve comment

* fix(docsite): codesandbox exports now working properly for newly migrated v9 packages (microsoft#25388)

* chore(react-divider): migrate to new package structure (microsoft#25360)

* chore(react-select): migrate to new package structure (microsoft#25359)

* feat: Add support for the wbtx whiteboard file extension (microsoft#25346)

* revert some changes

* update storywright version

* rename

* rename

* updatE

* update

* update

* update

* update

* not needed

* update

* update

Co-authored-by: Tristan Watanabe <tristan.watanabe@gmail.com>
Co-authored-by: Bernardo Sunderhus <bernardo.sunderhus@gmail.com>
Co-authored-by: Fluent UI Build <fluentui-internal@service.microsoft.com>
Co-authored-by: Micah Godbolt <mgodbolt@microsoft.com>
Co-authored-by: jieleiwang <51342814+jieleiwang@users.noreply.github.com>
marcosmoura added a commit to marcosmoura/fluentui that referenced this pull request Oct 27, 2022
* master: (21 commits)
  fix(react-tabster): make acceptCondition optional as Tabster dont require it (microsoft#25416)
  chore: adds disableButtonEnhancement on triggers (microsoft#25211)
  applying package updates
  feat: Add support for the wbtx whiteboard file extension (microsoft#25346)
  chore(react-select): migrate to new package structure (microsoft#25359)
  chore(react-divider): migrate to new package structure (microsoft#25360)
  fix(docsite): codesandbox exports now working properly for newly migrated v9 packages (microsoft#25388)
  Website: fix focus border on UHF footer links (microsoft#25389)
  applying package updates
  feat: re-export react-table logic hooks (microsoft#25386)
  chore(react-aria): migrate to new package structure (microsoft#25199)
  chore(babel-preset-global-context): migrate to new package structure (microsoft#25340)
  applying package updates
  fix: Improve Stack's style recalculation performance by selectively applying children selectors (microsoft#25381)
  applying package updates
  fix(projects-test): explicitly install next version 12 to fix CI (microsoft#25374)
  allow details element to be toggled inside selection and focus zones (microsoft#25324)
  fix(react-persona): Changing persona's versions to pinned versions (microsoft#25367)
  update fast element and foundation package versions stable (microsoft#25364)
  chore(keyboard-keys, priority-overflow, react-context-selector, react-conformance-griffel): migrate to new package structure (microsoft#25362)
  ...
NotWoods pushed a commit to NotWoods/fluentui that referenced this pull request Nov 18, 2022
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.

4 participants