A tag component.

Parameters:
NameTypeDescription
propsobject

Component props.

Properties
NameTypeDescription
childrenJSX.Element

React element children.

contentstring

Tag text.

customAttributesobject

Custom attributes for the component.

customClassesstring | Array | object

Custom classes for the component.

sizestring

The font size for the label.

spacingstring | number | Array | object

The spacing for the component, as a string, number, array, or object.

triangleTagboolean

Whether to show a triangle arrow for the tag.

triangleTagDirectionstring

The direction of the triangle arrow.

typestring

The tag type.

weightstring

The font weight for the label.

refobject | null

Ref to the component.

Since
  • 1.1.18
Returns:

The Tag component.

Type: 
JSX.Element
Example
import Tag from '@gravityforms/components/react/admin/elements/Tag';

return <Tag triangleTag>{ 'Elite' }</Tag>;