Foundations
Components
- Accordion
- Alert Dialog
- Avatar
- Badge
- Banner
- BreadcrumbSOON
- Button
- Button Group
- Calendar
- Callout
- Card
- Checkbox
- CodeblockSOON
- Color PickerNEW
- Container
- Control Group
- Dialog
- Divider
- Dropdown
- File UploaderNEW
- Flex
- FormSOON
- Grid
- IconSOON
- ImageSOON
- Input
- LinkNEW
- List
- MenuSOON
- PaginationSOON
- Popover
- Progress
- Radio
- Section
- Select
- Skeleton
- SliderSOON
- SpinnerSOON
- Switch
- Table
- Tabs
- Tag
- Textarea
- ToastSOON
- Tooltip
Tag
Tag, you're it! With our Tags, categorizing and navigating items is a playful breeze
Example
Default
1 import { Tag, Flex } from '@haktos/sugarcoat-ui';23 <Flex justify='center'>4 <Tag>Default</Tag>5 </Flex>6
API Reference
Component | Description |
---|---|
Tag | The Tag component is an interface element used for items that need to be labeled, categorized, or organized using keywords. Tags can also be used as navigational aids. In the Sugarcoat UI library, the Tag component is a small, interactive element that can provide quick information in a compact form |
Component Properties
Badge
Prop | Type | Default | Explanation |
---|---|---|---|
size | string | md | Adjusts the size of the tag. It can take values like "xs", "sm", "md", "lg", which correspond to different dimensions. |
color | string | default | Modifies the color of the tag. It shares the same values as Badge |
block | boolean | false | Make the Badge a block element, filling the width of its parent. |
removable | boolean | true | When set to true, includes a small 'x' button on the tag for removal purposes. |
onRemove | function | A function which gets triggered when the 'x' button is clicked. |