Chip
Chip generates a compact element that can represent an input, attribute, or action.
MUI Joy Chip
<Chip>
...
</Chip>
color
size
disabled
children
Decorators
Specify the startDecorator
prop or endDecorator
prop as a ReactNode
to the Chip
to display the decorators.
Today is sunny
Tomorrow is cloudy
<Chip variant="soft" startDecorator={<Sun />}>
Today is sunny
</Chip>
<Chip variant="soft" startDecorator={<Cloud />}>
Tomorrow is cloudy
</Chip>
Delete button
The Chip
has a complementary component called ChipDelete
. Use it for the purpose of deletable Chip
components.
The variant of the ChipDelete
changes based on the parent Chip
unless you specify a specific variant to it.
Remove
Delete
<Chip variant="outlined" endDecorator={<ChipDelete />}>
Remove
</Chip>
<Chip variant="soft" endDecorator={<ChipDelete variant="plain" />}>
Delete
</Chip>
Mark

<Chip
variant="outlined"
color="neutral"
size="lg"
startDecorator={<Avatar size="sm" src={`/static/images/avatar/1.jpg`} />}
endDecorator={<CheckIcon fontSize="md" sx={{ mr: 0.25 }} />}
onClick={() => alert('You clicked the Joy Chip!')}
>
Mark
</Chip>
Clear
<Chip
variant="outlined"
color="danger"
onClick={handleClick}
endDecorator={
<ChipDelete color="danger" variant="plain" onClick={handleClick}>
<DeleteForever />
</ChipDelete>
}
>
Clear
</Chip>
Favorite Movies
Best Movie
Unstyled
The component also comes with an unstyled version. It's ideal for doing heavy customizations and minimizing bundle size.