Popover
Popovers are small overlays that present additional content without cluttering the page.
Note that from accessibility perspective Popover
is treated as a tooltip (the element has role="tooltip"
) which means that it
shouldn't contain interactive elements (e.g, buttons, links, etc.), you can read more about tooltip specifications here.
Try using ModalPopup instead if you want Popover
's behaviour with interactive elements.
Basic Usage
Any Paragon component or export may be added to the code example.
State variants
Any Paragon component or export may be added to the code example.
Theme Variables#
CSS Variable | Computed Value |
---|---|
| |
| |
| |
| |
| |
Props API#
This is a pass through component from React-Bootstrap, see original props documentation here.
- id
string
RequiredAn html id attribute, necessary for accessibility.
- placement
enum
'auto' | 'top' | 'bottom' | 'left' | 'right'Default'right'Sets the direction the Popover is positioned towards.
This is generally provided by the
Overlay
component positioning the popover. - title
string
When this prop is set, it creates a
Popover
with aPopover.Title
inside passing the children directly to it. - arrowProps
shape
{ref:func
|shape
{current:},element
,style:}shape
{},An
Overlay
injected set of props for positioning the popover arrow.This is generally provided by the
Overlay
component positioning the popover. - content
bool
When this prop is set, it creates a
Popover
with aPopover.Content
inside passing the children directly to it. - popper
shape
{}A
Popper.js
config object passed to the the underlying popper instance. - show
bool
Whether the
Overlay
is shown. - children
node
Specifies the content of the
Overlay
- className
string
Specifies class name to append to the base element
- variant
string
The visual style of the
Overlay
- as
elementType
Default'div'Specifies the base element
- bsPrefix
string
Default'popover-header'Overrides underlying component base CSS class name
- as
elementType
Default'div'Specifies the base element
- bsPrefix
string
Default'popover-body'Overrides underlying component base CSS class name
Usage Insights#
Popover
Project Name | Paragon Version | Instance Count | |
---|---|---|---|
frontend-app-admin-portal | 21.13.1 | 6 | |
frontend-app-course-authoring | 22.8.1 | 3 | |
frontend-app-learner-portal-enterprise | 21.13.1 | 1 | |
frontend-app-learner-record | 22.10.0 | 1 | |
frontend-app-learning | 22.10.0 | 7 | |
frontend-app-ora-grading | 21.11.3 | 2 | |
frontend-app-support-tools | 21.13.1 | 2 | |
frontend-component-header-edx | 21.13.1 | 1 |
PopoverContent
Project Name | Paragon Version | Instance Count | |
---|---|---|---|
frontend-app-admin-portal | 21.13.1 | 6 | |
frontend-app-course-authoring | 22.8.1 | 2 | |
frontend-app-learner-portal-enterprise | 21.13.1 | 1 | |
frontend-app-learner-record | 22.10.0 | 2 | |
frontend-app-learning | 22.10.0 | 7 | |
frontend-app-ora-grading | 21.11.3 | 3 | |
frontend-app-support-tools | 21.13.1 | 2 | |
frontend-component-header-edx | 21.13.1 | 1 |
PopoverTitle
Project Name | Paragon Version | Instance Count | |
---|---|---|---|
frontend-app-admin-portal | 21.13.1 | 4 | |
frontend-app-course-authoring | 22.8.1 | 2 | |
frontend-app-learner-portal-enterprise | 21.13.1 | 1 | |
frontend-app-learner-record | 22.10.0 | 2 | |
frontend-app-support-tools | 21.13.1 | 2 | |
frontend-component-header-edx | 21.13.1 | 1 |