From 04ab9fca6f9473ef679633bcf9a9c0b6c14b0a5c Mon Sep 17 00:00:00 2001 From: Huzaifa Rasheed Date: Tue, 1 Aug 2023 03:06:26 +0500 Subject: [PATCH 1/9] Update frequently used emojis in state whenever its onyx key changes --- .../EmojiPicker/EmojiPickerMenu/index.js | 60 +++++++++++++------ .../EmojiPickerMenu/index.native.js | 48 +++++++++++---- 2 files changed, 80 insertions(+), 28 deletions(-) diff --git a/src/components/EmojiPicker/EmojiPickerMenu/index.js b/src/components/EmojiPicker/EmojiPickerMenu/index.js index 13c7e5516f37..602263e12ad3 100755 --- a/src/components/EmojiPicker/EmojiPickerMenu/index.js +++ b/src/components/EmojiPicker/EmojiPickerMenu/index.js @@ -54,23 +54,6 @@ class EmojiPickerMenu extends Component { // Ref for emoji FlatList this.emojiList = undefined; - // If we're on Windows, don't display the flag emojis (the last category), - // since Windows doesn't support them - const flagHeaderIndex = _.findIndex(emojis, (emoji) => emoji.header && emoji.code === 'flags'); - this.emojis = - getOperatingSystem() === CONST.OS.WINDOWS - ? EmojiUtils.mergeEmojisWithFrequentlyUsedEmojis(emojis.slice(0, flagHeaderIndex)) - : EmojiUtils.mergeEmojisWithFrequentlyUsedEmojis(emojis); - - // Get the header emojis along with the code, index and icon. - // index is the actual header index starting at the first emoji and counting each one - this.headerEmojis = EmojiUtils.getHeaderEmojis(this.emojis); - - // This is the indices of each header's Row - // The positions are static, and are calculated as index/numColumns (8 in our case) - // This is because each row of 8 emojis counts as one index to the flatlist - this.headerRowIndices = _.map(this.headerEmojis, (headerEmoji) => Math.floor(headerEmoji.index / CONST.EMOJI_NUM_PER_ROW)); - // We want consistent auto focus behavior on input between native and mWeb so we have some auto focus management code that will // prevent auto focus when open picker for mobile device this.shouldFocusInputOnScreenFocus = canFocusInputOnScreenFocus(); @@ -91,6 +74,10 @@ class EmojiPickerMenu extends Component { this.currentScrollOffset = 0; this.firstNonHeaderIndex = 0; + const {filteredEmojis, headerRowIndices} = this.getInitialFilteredEmojisAndHeaderRowIndices(); + this.emojis = filteredEmojis; + this.headerRowIndices = headerRowIndices; + this.state = { filteredEmojis: this.emojis, headerIndices: this.headerRowIndices, @@ -117,10 +104,46 @@ class EmojiPickerMenu extends Component { this.setFirstNonHeaderIndex(this.emojis); } + componentDidUpdate(prevProps) { + if (prevProps.frequentlyUsedEmojis !== this.props.frequentlyUsedEmojis) { + const {filteredEmojis, headerRowIndices} = this.getInitialFilteredEmojisAndHeaderRowIndices(); + this.emojis = filteredEmojis; + this.headerRowIndices = headerRowIndices; + this.setState({ + filteredEmojis: this.emojis, + headerIndices: this.headerRowIndices, + }); + } + } + componentWillUnmount() { this.cleanupEventHandlers(); } + /** + * Calculate the initial filtered emojis and header row indices + */ + getInitialFilteredEmojisAndHeaderRowIndices() { + // If we're on Windows, don't display the flag emojis (the last category), + // since Windows doesn't support them + const flagHeaderIndex = _.findIndex(emojis, (emoji) => emoji.header && emoji.code === 'flags'); + const filteredEmojis = + getOperatingSystem() === CONST.OS.WINDOWS + ? EmojiUtils.mergeEmojisWithFrequentlyUsedEmojis(emojis.slice(0, flagHeaderIndex)) + : EmojiUtils.mergeEmojisWithFrequentlyUsedEmojis(emojis); + + // Get the header emojis along with the code, index and icon. + // index is the actual header index starting at the first emoji and counting each one + const headerEmojis = EmojiUtils.getHeaderEmojis(filteredEmojis); + + // This is the indices of each header's Row + // The positions are static, and are calculated as index/numColumns (8 in our case) + // This is because each row of 8 emojis counts as one index to the flatlist + const headerRowIndices = _.map(headerEmojis, (headerEmoji) => Math.floor(headerEmoji.index / CONST.EMOJI_NUM_PER_ROW)); + + return {filteredEmojis, headerRowIndices}; + } + /** * On text input selection change * @@ -553,6 +576,9 @@ export default compose( preferredSkinTone: { key: ONYXKEYS.PREFERRED_EMOJI_SKIN_TONE, }, + frequentlyUsedEmojis: { + key: ONYXKEYS.FREQUENTLY_USED_EMOJIS, + }, }), )( React.forwardRef((props, ref) => ( diff --git a/src/components/EmojiPicker/EmojiPickerMenu/index.native.js b/src/components/EmojiPicker/EmojiPickerMenu/index.native.js index 88e1c7df6986..f78fa51bd6cd 100644 --- a/src/components/EmojiPicker/EmojiPickerMenu/index.native.js +++ b/src/components/EmojiPicker/EmojiPickerMenu/index.native.js @@ -45,17 +45,6 @@ class EmojiPickerMenu extends Component { // Ref for emoji FlatList this.emojiList = undefined; - this.emojis = EmojiUtils.mergeEmojisWithFrequentlyUsedEmojis(emojis); - - // Get the header emojis along with the code, index and icon. - // index is the actual header index starting at the first emoji and counting each one - this.headerEmojis = EmojiUtils.getHeaderEmojis(this.emojis); - - // This is the indices of each header's Row - // The positions are static, and are calculated as index/numColumns (8 in our case) - // This is because each row of 8 emojis counts as one index to the flatlist - this.headerRowIndices = _.map(this.headerEmojis, (headerEmoji) => Math.floor(headerEmoji.index / CONST.EMOJI_NUM_PER_ROW)); - this.renderItem = this.renderItem.bind(this); this.isMobileLandscape = this.isMobileLandscape.bind(this); this.updatePreferredSkinTone = this.updatePreferredSkinTone.bind(this); @@ -63,12 +52,46 @@ class EmojiPickerMenu extends Component { this.scrollToHeader = this.scrollToHeader.bind(this); this.getItemLayout = this.getItemLayout.bind(this); + const {filteredEmojis, headerRowIndices} = this.getInitialFilteredEmojisAndHeaderRowIndices(); + this.emojis = filteredEmojis; + this.headerRowIndices = headerRowIndices; + this.state = { filteredEmojis: this.emojis, headerIndices: this.headerRowIndices, }; } + componentDidUpdate(prevProps) { + if (prevProps.frequentlyUsedEmojis !== this.props.frequentlyUsedEmojis) { + const {filteredEmojis, headerRowIndices} = this.getInitialFilteredEmojisAndHeaderRowIndices(); + this.emojis = filteredEmojis; + this.headerRowIndices = headerRowIndices; + this.setState({ + filteredEmojis: this.emojis, + headerIndices: this.headerRowIndices, + }); + } + } + + /** + * Calculate the initial filtered emojis and header row indices + */ + getInitialFilteredEmojisAndHeaderRowIndices() { + const filteredEmojis = EmojiUtils.mergeEmojisWithFrequentlyUsedEmojis(emojis); + + // Get the header emojis along with the code, index and icon. + // index is the actual header index starting at the first emoji and counting each one + const headerEmojis = EmojiUtils.getHeaderEmojis(filteredEmojis); + + // This is the indices of each header's Row + // The positions are static, and are calculated as index/numColumns (8 in our case) + // This is because each row of 8 emojis counts as one index to the flatlist + const headerRowIndices = _.map(headerEmojis, (headerEmoji) => Math.floor(headerEmoji.index / CONST.EMOJI_NUM_PER_ROW)); + + return {filteredEmojis, headerRowIndices}; + } + getItemLayout(data, index) { return {length: CONST.EMOJI_PICKER_ITEM_HEIGHT, offset: CONST.EMOJI_PICKER_ITEM_HEIGHT * index, index}; } @@ -244,6 +267,9 @@ export default compose( preferredSkinTone: { key: ONYXKEYS.PREFERRED_EMOJI_SKIN_TONE, }, + frequentlyUsedEmojis: { + key: ONYXKEYS.FREQUENTLY_USED_EMOJIS, + }, }), )( React.forwardRef((props, ref) => ( From cac3ed3530a1c3573c84ab9e2f721880336276a2 Mon Sep 17 00:00:00 2001 From: Huzaifa Rasheed Date: Tue, 1 Aug 2023 03:31:39 +0500 Subject: [PATCH 2/9] Fix lint --- .../EmojiPicker/EmojiPickerMenu/index.js | 23 +++++++++++-------- .../EmojiPickerMenu/index.native.js | 5 ++++ 2 files changed, 19 insertions(+), 9 deletions(-) diff --git a/src/components/EmojiPicker/EmojiPickerMenu/index.js b/src/components/EmojiPicker/EmojiPickerMenu/index.js index 602263e12ad3..23db8e9e8512 100755 --- a/src/components/EmojiPicker/EmojiPickerMenu/index.js +++ b/src/components/EmojiPicker/EmojiPickerMenu/index.js @@ -33,6 +33,9 @@ const propTypes = { /** Stores user's preferred skin tone */ preferredSkinTone: PropTypes.oneOfType([PropTypes.number, PropTypes.string]), + /** Stores user's frequently used emojis */ + frequentlyUsedEmojis: PropTypes.arrayOf(PropTypes.object), + /** Props related to the dimensions of the window */ ...windowDimensionsPropTypes, @@ -42,6 +45,7 @@ const propTypes = { const defaultProps = { forwardedRef: () => {}, preferredSkinTone: CONST.EMOJI_DEFAULT_SKIN_TONE, + frequentlyUsedEmojis: [], }; class EmojiPickerMenu extends Component { @@ -120,8 +124,18 @@ class EmojiPickerMenu extends Component { this.cleanupEventHandlers(); } + /** + * On text input selection change + * + * @param {Event} event + */ + onSelectionChange(event) { + this.setState({selection: event.nativeEvent.selection}); + } + /** * Calculate the initial filtered emojis and header row indices + * @returns {Object} */ getInitialFilteredEmojisAndHeaderRowIndices() { // If we're on Windows, don't display the flag emojis (the last category), @@ -144,15 +158,6 @@ class EmojiPickerMenu extends Component { return {filteredEmojis, headerRowIndices}; } - /** - * On text input selection change - * - * @param {Event} event - */ - onSelectionChange(event) { - this.setState({selection: event.nativeEvent.selection}); - } - /** * Find and store index of the first emoji item * @param {Array} filteredEmojis diff --git a/src/components/EmojiPicker/EmojiPickerMenu/index.native.js b/src/components/EmojiPicker/EmojiPickerMenu/index.native.js index f78fa51bd6cd..f756623a5591 100644 --- a/src/components/EmojiPicker/EmojiPickerMenu/index.native.js +++ b/src/components/EmojiPicker/EmojiPickerMenu/index.native.js @@ -27,6 +27,9 @@ const propTypes = { /** Stores user's preferred skin tone */ preferredSkinTone: PropTypes.oneOfType([PropTypes.number, PropTypes.string]), + /** Stores user's frequently used emojis */ + frequentlyUsedEmojis: PropTypes.arrayOf(PropTypes.object), + /** Props related to the dimensions of the window */ ...windowDimensionsPropTypes, @@ -36,6 +39,7 @@ const propTypes = { const defaultProps = { preferredSkinTone: CONST.EMOJI_DEFAULT_SKIN_TONE, + frequentlyUsedEmojis: [], }; class EmojiPickerMenu extends Component { @@ -76,6 +80,7 @@ class EmojiPickerMenu extends Component { /** * Calculate the initial filtered emojis and header row indices + * @returns {Object} */ getInitialFilteredEmojisAndHeaderRowIndices() { const filteredEmojis = EmojiUtils.mergeEmojisWithFrequentlyUsedEmojis(emojis); From 4e61c7625338727f4800c716069f5287977f246b Mon Sep 17 00:00:00 2001 From: Huzaifa Rasheed Date: Tue, 1 Aug 2023 03:33:43 +0500 Subject: [PATCH 3/9] Fix lint --- src/components/EmojiPicker/EmojiPickerMenu/index.js | 1 + src/components/EmojiPicker/EmojiPickerMenu/index.native.js | 1 + 2 files changed, 2 insertions(+) diff --git a/src/components/EmojiPicker/EmojiPickerMenu/index.js b/src/components/EmojiPicker/EmojiPickerMenu/index.js index 23db8e9e8512..efdc0a8075f5 100755 --- a/src/components/EmojiPicker/EmojiPickerMenu/index.js +++ b/src/components/EmojiPicker/EmojiPickerMenu/index.js @@ -108,6 +108,7 @@ class EmojiPickerMenu extends Component { this.setFirstNonHeaderIndex(this.emojis); } + // eslint-disable-next-line rulesdir/prefer-early-return componentDidUpdate(prevProps) { if (prevProps.frequentlyUsedEmojis !== this.props.frequentlyUsedEmojis) { const {filteredEmojis, headerRowIndices} = this.getInitialFilteredEmojisAndHeaderRowIndices(); diff --git a/src/components/EmojiPicker/EmojiPickerMenu/index.native.js b/src/components/EmojiPicker/EmojiPickerMenu/index.native.js index f756623a5591..beda1cedcb54 100644 --- a/src/components/EmojiPicker/EmojiPickerMenu/index.native.js +++ b/src/components/EmojiPicker/EmojiPickerMenu/index.native.js @@ -66,6 +66,7 @@ class EmojiPickerMenu extends Component { }; } + // eslint-disable-next-line rulesdir/prefer-early-return componentDidUpdate(prevProps) { if (prevProps.frequentlyUsedEmojis !== this.props.frequentlyUsedEmojis) { const {filteredEmojis, headerRowIndices} = this.getInitialFilteredEmojisAndHeaderRowIndices(); From ac20ac9de4de82155785234bac62263f58d47064 Mon Sep 17 00:00:00 2001 From: Huzaifa Rasheed Date: Tue, 1 Aug 2023 03:38:37 +0500 Subject: [PATCH 4/9] Fix prop type --- src/components/EmojiPicker/EmojiPickerMenu/index.js | 1 + src/components/EmojiPicker/EmojiPickerMenu/index.native.js | 1 + 2 files changed, 2 insertions(+) diff --git a/src/components/EmojiPicker/EmojiPickerMenu/index.js b/src/components/EmojiPicker/EmojiPickerMenu/index.js index efdc0a8075f5..e4f92184e768 100755 --- a/src/components/EmojiPicker/EmojiPickerMenu/index.js +++ b/src/components/EmojiPicker/EmojiPickerMenu/index.js @@ -34,6 +34,7 @@ const propTypes = { preferredSkinTone: PropTypes.oneOfType([PropTypes.number, PropTypes.string]), /** Stores user's frequently used emojis */ + // eslint-disable-next-line react/forbid-prop-types frequentlyUsedEmojis: PropTypes.arrayOf(PropTypes.object), /** Props related to the dimensions of the window */ diff --git a/src/components/EmojiPicker/EmojiPickerMenu/index.native.js b/src/components/EmojiPicker/EmojiPickerMenu/index.native.js index beda1cedcb54..e3961a408eec 100644 --- a/src/components/EmojiPicker/EmojiPickerMenu/index.native.js +++ b/src/components/EmojiPicker/EmojiPickerMenu/index.native.js @@ -28,6 +28,7 @@ const propTypes = { preferredSkinTone: PropTypes.oneOfType([PropTypes.number, PropTypes.string]), /** Stores user's frequently used emojis */ + // eslint-disable-next-line react/forbid-prop-types frequentlyUsedEmojis: PropTypes.arrayOf(PropTypes.object), /** Props related to the dimensions of the window */ From 08017f7197bcdcef2ec1318de3e75cb308ed23c0 Mon Sep 17 00:00:00 2001 From: Huzaifa Rasheed Date: Tue, 1 Aug 2023 15:44:18 +0500 Subject: [PATCH 5/9] Fix lint --- src/components/EmojiPicker/EmojiPickerMenu/index.native.js | 1 + 1 file changed, 1 insertion(+) diff --git a/src/components/EmojiPicker/EmojiPickerMenu/index.native.js b/src/components/EmojiPicker/EmojiPickerMenu/index.native.js index 0ef4e472f44c..a794d4aa4bad 100644 --- a/src/components/EmojiPicker/EmojiPickerMenu/index.native.js +++ b/src/components/EmojiPicker/EmojiPickerMenu/index.native.js @@ -42,6 +42,7 @@ const defaultProps = { function EmojiPickerMenu({preferredLocale, onEmojiSelected, preferredSkinTone, translate, frequentlyUsedEmojis}) { const emojiList = useAnimatedRef(); + // eslint-disable-next-line react-hooks/exhaustive-deps const allEmojis = useMemo(() => EmojiUtils.mergeEmojisWithFrequentlyUsedEmojis(emojis), [frequentlyUsedEmojis]); const headerEmojis = useMemo(() => EmojiUtils.getHeaderEmojis(allEmojis), [allEmojis]); const headerRowIndices = useMemo(() => _.map(headerEmojis, (headerEmoji) => Math.floor(headerEmoji.index / CONST.EMOJI_NUM_PER_ROW)), [headerEmojis]); From d2f71e28ba3e9751de84fa206fd3469430254824 Mon Sep 17 00:00:00 2001 From: Huzaifa Rasheed <68777211+huzaifa-99@users.noreply.github.com> Date: Tue, 1 Aug 2023 19:21:18 +0500 Subject: [PATCH 6/9] Return early in componentDidUpdate() for --- .../EmojiPicker/EmojiPickerMenu/index.js | 19 +++++++++---------- 1 file changed, 9 insertions(+), 10 deletions(-) diff --git a/src/components/EmojiPicker/EmojiPickerMenu/index.js b/src/components/EmojiPicker/EmojiPickerMenu/index.js index e4f92184e768..9b64918f96f9 100755 --- a/src/components/EmojiPicker/EmojiPickerMenu/index.js +++ b/src/components/EmojiPicker/EmojiPickerMenu/index.js @@ -109,17 +109,16 @@ class EmojiPickerMenu extends Component { this.setFirstNonHeaderIndex(this.emojis); } - // eslint-disable-next-line rulesdir/prefer-early-return componentDidUpdate(prevProps) { - if (prevProps.frequentlyUsedEmojis !== this.props.frequentlyUsedEmojis) { - const {filteredEmojis, headerRowIndices} = this.getInitialFilteredEmojisAndHeaderRowIndices(); - this.emojis = filteredEmojis; - this.headerRowIndices = headerRowIndices; - this.setState({ - filteredEmojis: this.emojis, - headerIndices: this.headerRowIndices, - }); - } + if (prevProps.frequentlyUsedEmojis === this.props.frequentlyUsedEmojis) return; + + const {filteredEmojis, headerRowIndices} = this.getInitialFilteredEmojisAndHeaderRowIndices(); + this.emojis = filteredEmojis; + this.headerRowIndices = headerRowIndices; + this.setState({ + filteredEmojis: this.emojis, + headerIndices: this.headerRowIndices, + }); } componentWillUnmount() { From 079e5bf2517bd5051a28e24abc9e8cf6f660e7c1 Mon Sep 17 00:00:00 2001 From: Huzaifa Rasheed <68777211+huzaifa-99@users.noreply.github.com> Date: Tue, 1 Aug 2023 19:23:54 +0500 Subject: [PATCH 7/9] Renamed function --- src/components/EmojiPicker/EmojiPickerMenu/index.js | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/src/components/EmojiPicker/EmojiPickerMenu/index.js b/src/components/EmojiPicker/EmojiPickerMenu/index.js index 9b64918f96f9..4ed02bf7339d 100755 --- a/src/components/EmojiPicker/EmojiPickerMenu/index.js +++ b/src/components/EmojiPicker/EmojiPickerMenu/index.js @@ -79,7 +79,7 @@ class EmojiPickerMenu extends Component { this.currentScrollOffset = 0; this.firstNonHeaderIndex = 0; - const {filteredEmojis, headerRowIndices} = this.getInitialFilteredEmojisAndHeaderRowIndices(); + const {filteredEmojis, headerRowIndices} = this.getFilteredEmojisAndHeaderRowIndices(); this.emojis = filteredEmojis; this.headerRowIndices = headerRowIndices; @@ -112,7 +112,7 @@ class EmojiPickerMenu extends Component { componentDidUpdate(prevProps) { if (prevProps.frequentlyUsedEmojis === this.props.frequentlyUsedEmojis) return; - const {filteredEmojis, headerRowIndices} = this.getInitialFilteredEmojisAndHeaderRowIndices(); + const {filteredEmojis, headerRowIndices} = this.getFilteredEmojisAndHeaderRowIndices(); this.emojis = filteredEmojis; this.headerRowIndices = headerRowIndices; this.setState({ @@ -138,7 +138,7 @@ class EmojiPickerMenu extends Component { * Calculate the initial filtered emojis and header row indices * @returns {Object} */ - getInitialFilteredEmojisAndHeaderRowIndices() { + getFilteredEmojisAndHeaderRowIndices() { // If we're on Windows, don't display the flag emojis (the last category), // since Windows doesn't support them const flagHeaderIndex = _.findIndex(emojis, (emoji) => emoji.header && emoji.code === 'flags'); From 4d7800b0d8d56fe59d11b524098b857cbdfdbf7b Mon Sep 17 00:00:00 2001 From: Huzaifa Rasheed Date: Wed, 2 Aug 2023 15:51:26 +0500 Subject: [PATCH 8/9] Correctly set header emojis in emoji picker --- src/components/EmojiPicker/EmojiPickerMenu/index.js | 12 +++++++----- 1 file changed, 7 insertions(+), 5 deletions(-) diff --git a/src/components/EmojiPicker/EmojiPickerMenu/index.js b/src/components/EmojiPicker/EmojiPickerMenu/index.js index 4ed02bf7339d..87c0216ff8cf 100755 --- a/src/components/EmojiPicker/EmojiPickerMenu/index.js +++ b/src/components/EmojiPicker/EmojiPickerMenu/index.js @@ -79,8 +79,9 @@ class EmojiPickerMenu extends Component { this.currentScrollOffset = 0; this.firstNonHeaderIndex = 0; - const {filteredEmojis, headerRowIndices} = this.getFilteredEmojisAndHeaderRowIndices(); + const {filteredEmojis, headerEmojis, headerRowIndices} = this.getEmojisAndHeaderRowIndices(); this.emojis = filteredEmojis; + this.headerEmojis = headerEmojis; this.headerRowIndices = headerRowIndices; this.state = { @@ -112,8 +113,9 @@ class EmojiPickerMenu extends Component { componentDidUpdate(prevProps) { if (prevProps.frequentlyUsedEmojis === this.props.frequentlyUsedEmojis) return; - const {filteredEmojis, headerRowIndices} = this.getFilteredEmojisAndHeaderRowIndices(); + const {filteredEmojis, headerEmojis, headerRowIndices} = this.getEmojisAndHeaderRowIndices(); this.emojis = filteredEmojis; + this.headerEmojis = headerEmojis; this.headerRowIndices = headerRowIndices; this.setState({ filteredEmojis: this.emojis, @@ -135,10 +137,10 @@ class EmojiPickerMenu extends Component { } /** - * Calculate the initial filtered emojis and header row indices + * Calculate the initial filtered + header emojis and header row indices * @returns {Object} */ - getFilteredEmojisAndHeaderRowIndices() { + getEmojisAndHeaderRowIndices() { // If we're on Windows, don't display the flag emojis (the last category), // since Windows doesn't support them const flagHeaderIndex = _.findIndex(emojis, (emoji) => emoji.header && emoji.code === 'flags'); @@ -156,7 +158,7 @@ class EmojiPickerMenu extends Component { // This is because each row of 8 emojis counts as one index to the flatlist const headerRowIndices = _.map(headerEmojis, (headerEmoji) => Math.floor(headerEmoji.index / CONST.EMOJI_NUM_PER_ROW)); - return {filteredEmojis, headerRowIndices}; + return {filteredEmojis, headerEmojis, headerRowIndices}; } /** From 59498593d43827f3673fdd038ba01a0f2d052710 Mon Sep 17 00:00:00 2001 From: Huzaifa Rasheed <68777211+huzaifa-99@users.noreply.github.com> Date: Thu, 3 Aug 2023 03:03:57 +0500 Subject: [PATCH 9/9] Updated comment --- src/components/EmojiPicker/EmojiPickerMenu/index.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/components/EmojiPicker/EmojiPickerMenu/index.js b/src/components/EmojiPicker/EmojiPickerMenu/index.js index 87c0216ff8cf..dfa06e8daab2 100755 --- a/src/components/EmojiPicker/EmojiPickerMenu/index.js +++ b/src/components/EmojiPicker/EmojiPickerMenu/index.js @@ -137,7 +137,7 @@ class EmojiPickerMenu extends Component { } /** - * Calculate the initial filtered + header emojis and header row indices + * Calculate the filtered + header emojis and header row indices * @returns {Object} */ getEmojisAndHeaderRowIndices() {