emoji-picker-react 4.4.7 → 4.4.8

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.
package/package.json CHANGED
@@ -1,5 +1,5 @@
1
1
  {
2
- "version": "4.4.7",
2
+ "version": "4.4.8",
3
3
  "license": "MIT",
4
4
  "main": "dist/index.js",
5
5
  "typings": "dist/index.d.ts",
@@ -23,7 +23,7 @@
23
23
  },
24
24
  "scripts": {
25
25
  "start": "tsdx watch",
26
- "build": "node ./scripts/prepare.js && tsdx build",
26
+ "build": "node ./scripts/prepare.js && tsdx build && node ./scripts/copyData.js",
27
27
  "test": "tsdx test --passWithNoTests",
28
28
  "lint": "eslint ./src --ext .ts,.tsx",
29
29
  "prepare": "tsdx build",
@@ -10,7 +10,8 @@ import {
10
10
  useCategoriesConfig,
11
11
  useEmojiStyleConfig,
12
12
  useGetEmojiUrlConfig,
13
- useLazyLoadEmojisConfig
13
+ useLazyLoadEmojisConfig,
14
+ useSkinTonesDisabledConfig
14
15
  } from '../../config/useConfig';
15
16
  import { emojisByCategory, emojiUnified } from '../../dataUtils/emojiSelectors';
16
17
  import { useIsEmojiDisallowed } from '../../hooks/useDisallowedEmojis';
@@ -67,6 +68,7 @@ function RenderCategory({
67
68
  const [activeSkinTone] = useActiveSkinToneState();
68
69
  const isEmojiDisallowed = useIsEmojiDisallowed();
69
70
  const getEmojiUrl = useGetEmojiUrlConfig();
71
+ const showVariations = !useSkinTonesDisabledConfig();
70
72
 
71
73
  // Small trick to defer the rendering of all emoji categories until the first category is visible
72
74
  // This way the user gets to actually see something and not wait for the whole picker to render.
@@ -91,6 +93,7 @@ function RenderCategory({
91
93
 
92
94
  return (
93
95
  <ClickableEmoji
96
+ showVariations={showVariations}
94
97
  key={unified}
95
98
  emoji={emoji}
96
99
  unified={unified}
@@ -4,7 +4,7 @@ import emojis from '../data/emojis';
4
4
  import skinToneVariations, {
5
5
  skinTonesMapped
6
6
  } from '../data/skinToneVariations';
7
- import { EmojiStyle, SkinTones } from '../types/exposedTypes';
7
+ import { EmojiStyle, SkinTones } from '../types/exposedTypes';
8
8
 
9
9
  import { DataEmoji, DataEmojis } from './DataTypes';
10
10