-
Notifications
You must be signed in to change notification settings - Fork 2.9k
docs(react-persona): Adding migration guide #25022
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
Merged
Merged
Changes from 3 commits
Commits
Show all changes
9 commits
Select commit
Hold shift + click to select a range
45ad08c
adding migration guide
sopranopillow 667a963
reordering
sopranopillow c2fc851
removing NOT SUPPORTED from mapping table
sopranopillow 31a9035
Update packages/react-components/react-persona/MIGRATION.md
sopranopillow 0d89548
Update packages/react-components/react-persona/MIGRATION.md
sopranopillow 0f141e4
Update packages/react-components/react-persona/MIGRATION.md
sopranopillow 79ad3bd
Update packages/react-components/react-persona/MIGRATION.md
sopranopillow 3c63f2c
Merge branch 'master' of https://www.github.com/microsoft/fluentui in…
sopranopillow 80922fa
change file
sopranopillow File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
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
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,41 @@ | ||
| # Badge Migration | ||
|
|
||
| ## Migration from v8 | ||
|
|
||
| v8 offers a component equivalent to v9's `Persona`. However, the API is slightly different. The main difference is that v9's `Persona` does not handle the functionality of the `presence` and `avatar`. Instead, the `presence` and `avatar` are separate components that can be used in conjunction with `Persona`. | ||
|
|
||
| Here's how the API of v8's `Persona` compares to the one from v9's `Persona` component: | ||
|
|
||
| - `className` => `className` | ||
| - `coinProps` => Use `avatar`'s or `presence`'s slot props | ||
| - `componentRef` => NOT SUPPORTED - use `ref` instead | ||
| - `hidePersonaDetails` => NOT SUPPORTED | ||
| - `imageShouldFadeIn` => NOT SUPPORTED | ||
| - `isOutOfOffice` => Use `status` in `presence` slot props | ||
sopranopillow marked this conversation as resolved.
Outdated
Show resolved
Hide resolved
|
||
| - `presence` => `presence` | ||
sopranopillow marked this conversation as resolved.
Outdated
Show resolved
Hide resolved
|
||
| - `presenceTitle` => NOT SUPPORTED | ||
| - `showOverflowTooltip` => NOT SUPPORTED | ||
| - `showUnknownPersonaCoin` => NOT SUPPORTED | ||
| - `styles` => Use style customization through `className` instead | ||
|
|
||
| ## Property Mapping | ||
|
|
||
| | v8 `Persona` | v9 `Persona` | | ||
| | ------------------------ | -------------------------------------- | | ||
| | `coinProps` | `avatar` or `badge` slot props | | ||
| | `coinSize` | `size` in the `badge` or `avatar` slot | | ||
| | `className` | `className` | | ||
| | `componentRef` | `ref` | | ||
| | `hidePersonaDetails` | - | | ||
| | `imageShouldFadeIn` | - | | ||
| | `isOutOfOffice` | `status` in `presence` slot props | | ||
| | `optionalText` | `quaternaryText` | | ||
| | `presence` | `presence` | | ||
| | `presenceTitle` | | | ||
sopranopillow marked this conversation as resolved.
Outdated
Show resolved
Hide resolved
|
||
| | `primaryText` | `primaryText` | | ||
| | `secondaryText` | `secondaryText` | | ||
| | `showOverflowTooltip` | - | | ||
| | `showUnknownPersonaCoin` | - | | ||
| | `styles` | `className` | | ||
| | `tertiaryText` | `tertiaryText` | | ||
| | `text` | `name` | | ||
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.
Uh oh!
There was an error while loading. Please reload this page.