The Panel component is a container for grouping content in a subtly styled container.
The component can be imported via:
A Panel component can be composed with the following child components:
PanelHeader
PanelTitle
PanelHeaderPanelDescription
PanelHeader after the PanelTitlePanelFooter
PanelActions
PanelHeader or PanelFooterPanelSection
PanelHeader
and PanelFooter use this component, which sets the correct paddings and
is responsible for adding borders between sections.PanelInset
A complete example, using all the available child components, looks like:
This is a description for the panel that provides additional context.
The panel's content
The panel header can include both a title and an optional description. These components are arranged in a grid layout with the title and description stacked vertically on the left side and actions on the right side.
This is a description that provides additional context for the panel content. It appears below the title and helps users understand the purpose of this panel.
The panel's content
By default, the PanelHeader and PanelFooter components render without a border
to separate them from the panel's content.
A border can be enabled by setting withSectionBorders to true on the Panel:
The panel's content
It is also possible to control the borders individually by setting withBorder on a
PanelHeader or PanelFooter:
The panel's content
The panel's content
The panel's content
When using a bordered panel, a PanelSection component will automatically add additional
padding to separate the content from the borders.
By default, PanelSection components render with padding on all sides. You can disable this padding by setting withPadding={false}, which makes the section function like a PanelInset.
By default, the Panel renders with padding on all sides, and content will render accordingly. The PanelInset component can be used to stretch content to the edges of the panel, ignoring those paddings.
This can be useful in situations like rendering a full-width table, or section dividers within the Panel.
Additionally, if the PanelInset is the first or last child, the top or bottom paddings will also be ignored accordingly.
| Name | Genus | Species |
|---|---|---|
| Australian Magpie | Gymnorhina | tibicen |
| Galah | Eolophus | roseicapilla |
| Rainbow lorikeet | Trichoglossus | moluccanus |
PlumaPanel extends BoxDefault:false
Whether the panel should render with borders between the Header, content and Footer.
Whether this panel renders attached to a Tabs component. This will apply a negative top margin and remove the top-left border radius, to visually connect the panel to the tabs.
PlumaPanelSection extends BoxDefault:false
Whether the section should render a border to separate it from other sections.
Default:true
Whether the section should render with padding. If false, the section will function like PanelInset with no padding. When true (default), the section includes standard panel padding.
PlumaPanelHeader extends BoxDefault:false
Whether the section should render a border to separate it from other sections.
Default:true
Whether the section should render with padding. If false, the section will function like PanelInset with no padding. When true (default), the section includes standard panel padding.
PlumaPanelTitle extends BoxThe text color. (See text color tokens)
The font family. (See font family tokens)
The font style. (See MDN font-style)
Default:2
The level of the heading (which maps to h1-h6 tags)
The text size. (See font size tokens)
A predefined typography style. (See text tokens)
PlumaPanelDescription extends BoxThe text color. (See text color tokens)
The font family. (See font family tokens)
The font style. (See MDN font-style)
The text size. (See font size tokens)
Default:md
Size variant of paragraph style
A predefined typography style. (See text tokens)
Variant of paragraph style