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

docs(Tooltip): add floating menu reference #9140

Merged
Merged
Show file tree
Hide file tree
Changes from 2 commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@ options that are available to the user, but there is a space constraint.

`OverflowMenu` uses React Portals to render the overflow menu into the DOM. To
determine where in the DOM the menu will be placed, it looks for a parent
element with the `data-floating-menu-container` attribute. If none parent with
element with the `data-floating-menu-container` attribute. If no parent with
this attribute is found, the menu will be placed on `document.body`.

## Component API
Expand Down
7 changes: 7 additions & 0 deletions packages/react/src/components/Tooltip/Tooltip.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,13 @@ import { Props } from '@storybook/addon-docs/blocks';

## Overview

### `data-floating-menu-container`

`Tooltip` uses React Portals to render the tooltip into the DOM. To determine
where in the DOM the menu will be placed, it looks for a parent element with the
`data-floating-menu-container` attribute. If no parent with this attribute is
found, the menu will be placed on `document.body`.

## Component API

Please note that in addition to the props below, `Tooltip` also has two
Expand Down