Skip to content

Report a problem:

Problems can be reported via Microsoft Teams in your team channel within the "IT - Codey" team.

Please include the following information:

Report type:
Docs problem report a bug instead β†’
Path:
/vnext/docs/components/general/button.html
Message:

DESCRIBE THE PROBLEM BEFORE SUBMITTING TO CODEY

Button ​

javascript
import { XerButton } from "@xerius/codey-components";

Showcases ​

CTA Button ​

For indicating the primary path of the application.

Small CTA Button ​

Only to be used in combination with a textfield The small CTA button never be of another type of button, it should always be a CTA.

Small Variants Button ​

Small variants with a full and stroke look.

Buttons with the link prop provided will be a tag element.

Buttons with the link prop provided will be a tag element.

Disabling CTA Buttons ​

Disabling Small Variants Buttons ​

Props ​

NameTypeDefaultRequiredDescription
variantString"stroke"falseIndicates what the variant of the button is. ("cta", "cta-outline", "full", "stroke")
variantColorStringfalseIndicates what the variant color of the button is. ("cta", "brand", "base")
iconIcon ComponentfalseProvide an icon.
leftBooleanfalsefalseIcon + text: icon will be placed on the left side of the button. Icon only: button will point to the left.
loadingBooleanfalsefalseShows loading icon with animation.
linkStringfalseURL of the link, which it will navigate to after click. When link is relative, Vue Router will be used for navigation.
typeString"button"falseThe button type (for buttons) or link type (for links). See Vue Router documentation for link types.
htmlStringfalseHTML to show in the button. To be used instead of the v-html directive.
disabledBooleanfalsefalseIndicates if the button is disabled or not.
dataAutomationIdString"button"falseSets the data automation id for the button component.

Events ​

All standard HTML button events are supported (click, focus, blur, etc.) when rendered as a button. When rendered as a link, all standard HTML anchor events are supported.

Slots ​

NamePurpose
defaultButton content (text, HTML elements). Cannot be used with html prop.

Report a problem:

Problems can be reported via Microsoft Teams in your team channel within the "IT - Codey" team.

Please include the following information:

Report type:
Docs problem report a bug instead β†’
Path:
/vnext/docs/components/general/button.html
Message:

DESCRIBE THE PROBLEM BEFORE SUBMITTING TO CODEY

Last updated: