emoji-picker-react 4.5.10 → 4.5.12

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -16841,9 +16841,13 @@ function emojiByUnified(unified) {
16841
16841
  }
16842
16842
  var allEmojis = /*#__PURE__*/Object.values(emojis).flat();
16843
16843
  function setCustomEmojis(customEmojis) {
16844
- emojis[exports.Categories.CUSTOM] = [];
16844
+ if (!customEmojis || customEmojis.length === 0) {
16845
+ emojis[exports.Categories.CUSTOM].length = 0;
16846
+ }
16847
+
16845
16848
  customEmojis.forEach(function (emoji) {
16846
16849
  var emojiData = customToRegularEmoji(emoji);
16850
+ emojis[exports.Categories.CUSTOM].push(emojiData);
16847
16851
 
16848
16852
  if (allEmojisByUnified[emojiData[EmojiProperties.unified]]) {
16849
16853
  return;
@@ -16851,7 +16855,6 @@ function setCustomEmojis(customEmojis) {
16851
16855
 
16852
16856
  allEmojis.push(emojiData);
16853
16857
  allEmojisByUnified[emojiData[EmojiProperties.unified]] = emojiData;
16854
- emojis[exports.Categories.CUSTOM].push(emojiData);
16855
16858
  indexEmoji(emojiData);
16856
16859
  });
16857
16860
  }