Skip to content

Button

Displays a button or a component that looks like a button.

Installation

You have two options when using CopyPasteUi:

  1. Copy the Tailwind classes and use them in .html or .jsx components.
  2. Use React to copy the entire component. This allows you to access loading states and other dynamic features, making the component more reusable and fully customizable.

Example

Size

Radius

Variants

Colors

Solid

Outline

Ghost

Soft

Loading

API

This is only for the React version.

Button props

AttributeTypeDescriptionDefault
childrenchildrenThe content to display in the button-
variantsolid, outline, ghost, soft, linkButton appereance stylesolid
colordefault, blue, cerise, yellow, green, violetButton color styledefault
sizesmall, default, largeButton sizedefault
radionone, small, default, large fullButton border radius styledefault
loadingloadingLoading state-
onClickMouseEventHandlerNative button event handler-