forked from microsoft/fluentui
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
chore: add "data-portal-node" attr in usePortalMountNode() (microsoft…
- Loading branch information
1 parent
81e34cd
commit 32372c0
Showing
5 changed files
with
15 additions
and
5 deletions.
There are no files selected for viewing
7 changes: 7 additions & 0 deletions
7
change/@fluentui-react-portal-7081febf-e493-416b-86c8-63477148649e.json
This file contains 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,7 @@ | ||
{ | ||
"type": "patch", | ||
"comment": "chore: add \"data-portal-node\" attr in usePortalMountNode()", | ||
"packageName": "@fluentui/react-portal", | ||
"email": "[email protected]", | ||
"dependentChangeType": "patch" | ||
} |
This file contains 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
This file contains 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
This file contains 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
7 changes: 2 additions & 5 deletions
7
packages/react-components/react-portal/stories/Portal/PortalDescription.md
This file contains 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 |
---|---|---|
@@ -1,6 +1,3 @@ | ||
A portal renders content outside of a DOM tree, at the end of the document. | ||
A portal renders content outside of a DOM tree, at the end of the document. This allows content to escape traditional boundaries caused by `"overflow: hidden"` CSS rules and keeps it on the top without using `z-index` rules. This is useful for example in `Menu` and `Tooltip` scenarios, where the content should always overlay everything else. | ||
|
||
This allows content to escape traditional boundaries caused by "overflow: hidden" CSS rules and keeps it on the top without using z-index rules. | ||
This is useful for example in Menu and Tooltip scenarios, where the content should always overlay everything else. | ||
|
||
`Portal` component is a thin wrapper around React's [`ReactDOM.createPortal()`](https://reactjs.org/docs/portals.html). | ||
`Portal` component is a thin wrapper around React's [`ReactDOM.createPortal()`](https://reactjs.org/docs/portals.html) that propagates Fluent styling (allows to use `tokens`) and text-direction handling to the content. You can identify DOM created by `Portal` by looking for the `data-portal-node` attribute. |