Panel

Toggle content visibility using Panel.

installyarn add @clayui/panel
versionNPM Version
useimport Panel from '@clayui/panel';

Basic Usage

Title
Header!
Body!

Snippet

Secondary

Title
Body!

Snippet

Unstyled

Title
Body!

Snippet

Collapsible

Collapsable panels provide you with the ability to expand and collapse content as needed. They can simplify the interface by hiding content until it is needed.

This page uses Bootstrap’s collapse plugin which requires JQuery. Liferay 7.4 no longer includes JQuery by default. We have included a standalone collapse plugin in 7.4, just replace the attribute data-toggle=“collapse” with data-toggle=“liferay-collapse” on the trigger.
Header!
Body!

Snippet

Groups

Grouped panels provide you with the ability of making accordion-like elements with multiple collapsable panels.

Here is some content inside for number One
Here is some content inside for number Two
Here is some content inside for number Three

Snippet

With Sheets

Sometimes you might want to place a panel inside of a card or a sheet, in that case, wrap the Panel component in a sheet wrapper like below.

Sheet Title

Here is some content inside for number One
Here is some content inside for number Two
Here is some content inside for number Three

Snippet

With a Custom Title

Sometimes you want to have some custom content that’s not a string or a number in your title, that’s where ClayPanel.Title comes in handy. It allows you to add custom content to the title of the panel as seen in this example using ClayLabels.

Body!

Snippet

Edit this page on GitHub

Contributors

Matuzalém Teles

Last edited May 12, 2025 at 7:56:02 PM