Back to Component Browser

Chip

Quartz

lib/quartz/components/Chip/index.ts

Preview
DefaultTealPurpleSmall

Import

import { Chip } from '@/lib/quartz';

Props (10)

NameTypeRequiredDefaultDescription
idstringoptionalThe id of the text element
labelstringrequiredThe text to display inside the Chip
backgroundColorenumrequiredThe background color to apply to the Chip. While "white" and "lightGray" are similar, they look different against colored backgrounds...
startSlotReactNodeoptionalA slot to center align another piece of content before the Chip contents. Typically an SVG icon rendered as a react component.
endSlotReactNodeoptionalA slot to center align another piece of content after the Chip contents. Typically an SVG icon rendered as a react component.
sizeenumoptionalsmallThe size of the Chip.
slotSizeenumoptionalsmallThe size of the slot. Defaults to the size of the Chip.
startSlotGapenumoptionalsmallThe size of the gap between the start slot and the border of the Chip.
asenumoptionalspanTag name for the Chip.
onClick() => voidoptionalOptional click handler for when Chip is a button.

Usage

Not used in any projects yet.