ComponentsDropdown Text

DropdownText

A dropdown text component that can be used to display hidden content



Dropdown Text


The DropdownText component is a dropdown text component that can be used to display hidden content. It is a great way to organize and display information in a structured and visually appealing way.

Tip!

The component can either manage its own state or be controlled by the parent component using the isOpen and onToggle props.




Props

The DropdownText component accepts the following props:

NameTypeDefaultDescription
titlestringThe title of the dropdown text component.
contentstringThe content of the dropdown text component.
isOpenbooleanfalseThe state of the dropdown text component.
onTogglefuncThe function to toggle the state of the dropdown text component.
borderbooleantrueWhether to show a border at the bottom of the dropdown text component.



Usage Examples

Basic DropdownText

Dropdown Text

Controlled DropdownText

Dropdown Text

This is the content of the dropdown text component.

DropdownText with No Border

Dropdown Text