popper

v4.9.10arrow_drop_down
v4.9.10
v4.5.2
v3.9.2
STATUS
Passing
DOWNLOADS
213,339
LICENSE
MIT
VISIBILITY
Public
PUBLISHED
5 years ago
SIZE
25 KB
This is the reference element, or a function that returns the reference element, that may be used to set the position of the popover.
2 contributors
Install popper as a package?
Copied
npm i @bit/mui-org.material-ui.popper
Set Bit as a scoped registryLearn more
npm config set '@bit:registry' https://node.bit.cloud
Component Example
React
React
Vue
Angular
React Native
Add dependency... help_outline
Just
import
any of the 1 million components
and packages in Bit or NPM to the example.
import Button from '@bit/grommet.grommet.button';
import Lodash from 'lodash';
toggle layout
modifieddraft
chevron_left
chevron_right

This is the reference element, or a function that returns the reference element, that may be used to set the position of the popover. The return value will passed as the reference object of the Popper instance.

The reference element should be an HTML Element instance or a referenceObject.

Popper render function or node.

A node, component instance, or function that returns either. The container will passed to the Modal component. By default, it uses the body of the anchorEl’s top-level document object, so it’s simply document.body most of the time.

Disable the portal behavior. The children stay within it’s parent DOM hierarchy.

Always keep the children in the DOM. This prop can be useful in SEO situation or when you want to maximize the responsiveness of the Popper.

Popper.js is based on a “plugin-like” architecture, most of its features are fully encapsulated "modifiers".

A modifier is a function that is called each time Popper.js needs to compute the position of the popper. For this reason, modifiers should be very performant to avoid bottlenecks. To learn how to create a modifier, read the modifiers documentation.

If true, the popper is visible.

Popper placement.

Options provided to the popper.js instance.

A ref that points to the used popper instance.

Help supporting a react-transition-group/Transition component.

Poppers rely on the 3rd party library Popper.js for positioning. Demos:

API:

Poppers rely on the 3rd party library Popper.js for positioning.

Properties
NameTypeDescription
anchorEl
custom

This is the reference element, or a function that returns the reference element, that may be used to set the position of the popover. The return value will passed as the reference object of the Popper instance.

The reference element should be an HTML Element instance or a referenceObject.

children
(required)
node | function

Popper render function or node.

container
function | React.Component | typeof Element === 'undefined' ? Object : Element

A node, component instance, or function that returns either. The container will passed to the Modal component. By default, it uses the body of the anchorEl’s top-level document object, so it’s simply document.body most of the time.

disablePortal
bool

Disable the portal behavior. The children stay within it’s parent DOM hierarchy.

keepMounted
bool

Always keep the children in the DOM. This prop can be useful in SEO situation or when you want to maximize the responsiveness of the Popper.

modifiers
object

Popper.js is based on a “plugin-like” architecture, most of its features are fully encapsulated "modifiers".

A modifier is a function that is called each time Popper.js needs to compute the position of the popper. For this reason, modifiers should be very performant to avoid bottlenecks. To learn how to create a modifier, read the modifiers documentation.

open
(required)
bool

If true, the popper is visible.

placement
'bottom-end' | 'bottom-start' | 'bottom' | 'left-end' | 'left-start' | 'left' | 'right-end' | 'right-start' | 'right' | 'top-end' | 'top-start' | 'top'

Popper placement.

popperOptions
object

Options provided to the popper.js instance.

popperRef
custom

A ref that points to the used popper instance.

style
object
transition
bool

Help supporting a react-transition-group/Transition component.

Help and resources