React Search Button Component API
Search Button API
Explore the API reference for the React Search Button component and discover how to effectively utilize its props for customization.
CSearchButton#
import { CSearchButton } from '@coreui/react'// orimport CSearchButton from '@coreui/react/src/components/search-button/CSearchButton'| Property | Default | Type |
|---|---|---|
| children# | - | ReactNode |
Content to customize the full button body. | ||
| className# | - | string |
A string of all className you want applied to the base component. | ||
| icon# | - | ReactNode |
Custom icon displayed before the placeholder text. | ||
| onTrigger# | - | () => void |
Callback fired when the component is activated by click or keyboard shortcut. | ||
| placeholder# | Search | ReactNode |
Placeholder content rendered inside | ||
| preventDefault# | true | boolean |
Prevent the browser's default behavior when the configured shortcut matches. | ||
| shortcut# | meta+/,ctrl+/ | string |
Comma-separated shortcut list. The component matches all configured shortcuts and renders the platform-preferred one. | ||