Skip to content

Commit c2120ef

Browse files
paul-grant-hsealush
authored andcommitted
Update README and compareConfig to include new option
1 parent 2128ae7 commit c2120ef

File tree

3 files changed

+5
-1
lines changed

3 files changed

+5
-1
lines changed

README.md

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -73,6 +73,7 @@ The following props are accepted by the picker:
7373
| lazyLoadEmojis | boolean | `false` | Controls whether the emojis are loaded lazily or not. |
7474
| previewConfig | object | `{}` | Controls the preview of the emoji. See below for more information. |
7575
| searchPlaceholder | string | `Search` | Controls the placeholder of the search input. |
76+
| searchClearButtonLabel | string | 'Clear' | Controls the `aria-label` and `title` of the Clear button of the search input. |
7677
| suggestedEmojisMode | string | `frequent` | Controls the suggested emojis mode. Possible values are `frequent` and `recent`. |
7778
| skinTonesDisabled | boolean | `false` | Controls whether the skin tones are disabled or not. |
7879
| searchDisabled | boolean | `false` | Controls whether the search is disabled or not. When disabled, the skin tone picker will be shown in the preview component. |
@@ -166,6 +167,8 @@ import { SkinTones } from 'emoji-picker-react';
166167

167168
- `searchPlaceholder`: `string` - The placeholder text for the search input. Defaults to `Search`.
168169

170+
- `searchClearButtonLabel`: `string` - The `aria-label` and `title` text for the search input clear button. Defaults to `Clear`.
171+
169172
- categories: Allows full config over ordering, naming and display of categories.
170173
To only sort/omit categories, you can simply pass an array of category names to display:
171174

package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
{
2-
"version": "4.15.2",
2+
"version": "4.16.0",
33
"license": "MIT",
44
"main": "dist/index.js",
55
"typings": "dist/index.d.ts",

src/config/compareConfig.ts

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -10,6 +10,7 @@ export function compareConfig(prev: PickerConfig, next: PickerConfig) {
1010
prev.reactionsDefaultOpen === next.reactionsDefaultOpen &&
1111
prev.searchPlaceHolder === next.searchPlaceHolder &&
1212
prev.searchPlaceholder === next.searchPlaceholder &&
13+
prev.searchClearButtonLabel === next.searchClearButtonLabel &&
1314
prev.defaultSkinTone === next.defaultSkinTone &&
1415
prev.skinTonesDisabled === next.skinTonesDisabled &&
1516
prev.autoFocusSearch === next.autoFocusSearch &&

0 commit comments

Comments
 (0)