Tags help label and organise items using keywords that describe them. Use short labels for easy scanning. Tags can also be used as a method of filtering data. Top level label cannot be removed and remains at the top of the page to display key information. Removable tags are used when searching in the search bar or selecting an option in the dropdown. Users can remove tags by clicking the “X” icon.
Top level labels are placed on the top half of the page, under the title of page and display key information. Removable tags are at the bottom of the search bar, inside a table to display active filters. Please refer to Placement in page designs for examples.
Use the appropriate ARIA attributes for screen readers where applicable. Keyboard support The control to remove a tag is implemented as a button with standard keyboard support.
import { Tag } from '@shieldpay/bumblebee/tag'; <Tag variant="primary">Primary tag</Tag> // default just showing example <Tag variant="warning">Warning tag</Tag> <Tag variant="alert">Alert tag</Tag> <Tag variant="success">Success tag</Tag> <Tag size="small">Warning tag</Tag> // default just showing example <Tag size="medium">Alert tag</Tag> <Tag size="large">Success tag</Tag> <Tag onDismiss={() => noop} onDismissText="Remove"> Informative text here </Tag> <Tag expand> Tag this super long message that expands to full width </Tag>