EmojiPickerInput
Input with emoji picker dropdown
Source
LLM docs
Docs
Package
License
Usage
EmojiPickerInput component supports Input and Input.Wrapper component features and all button element props. The EmojiPickerInput documentation does not include all features supported by the component – see the Input documentation to learn about all available features.
Input description
Controlled
The value is an emoji ID (a key in data.emojis). Use value and onChange to control it.
When the value is not selected in the picker, the input displays the emoji without skin tone:
Clearable
Set clearable to display a clear button when an emoji is selected. The clear button
has aria-label="Clear emoji" by default, use clearButtonProps to change it or pass
other props to the button:
Close on select
By default, the dropdown closes when an emoji is selected.
Set closeOnSelect={false} to keep it open:
Disabled
Read only
EmojiPicker props
Use the pickerProps prop to pass props to the underlying EmojiPicker,
for example to change the number of columns or hide sections:
Controlled dropdown
Use opened and onOpenedChange props to control the dropdown state:
onEmojiSelect
onChange is called with the emoji ID. Use onEmojiSelect to get the full emoji object
with name, keywords and skin variants:
Popover props
Use the popoverProps prop to pass props to the underlying Popover component:
Styles API
EmojiPickerInput supports the Styles API; you can add styles to any inner element of the component with the classNames prop. Follow the Styles API documentation to learn more.
Get element ref
Accessibility
If EmojiPickerInput is used without the label prop, it will not be announced properly by screen readers:
Set aria-label to make the input accessible. In this case the label will not be visible, but screen readers will announce it:
If the label prop is set, the input will be accessible and it is not required to set aria-label: