feat: ship creator journey v2 and profile updates
This commit is contained in:
@@ -1,5 +1,7 @@
|
||||
import React, { useCallback, useEffect, useRef, useState } from 'react'
|
||||
import EmojiMartPicker from '../common/EmojiMartPicker'
|
||||
import extractNativeEmoji from '../common/extractNativeEmoji'
|
||||
import isEventWithinNode from '../common/isEventWithinNode'
|
||||
import loadEmojiMartData from '../common/loadEmojiMartData'
|
||||
|
||||
/**
|
||||
@@ -38,7 +40,7 @@ export default function EmojiPickerButton({ onEmojiSelect, disabled = false, cla
|
||||
if (!open) return
|
||||
|
||||
function handleClick(e) {
|
||||
if (wrapRef.current && !wrapRef.current.contains(e.target)) {
|
||||
if (!isEventWithinNode(e, wrapRef.current)) {
|
||||
setOpen(false)
|
||||
}
|
||||
}
|
||||
@@ -61,7 +63,10 @@ export default function EmojiPickerButton({ onEmojiSelect, disabled = false, cla
|
||||
|
||||
const handleSelect = useCallback(
|
||||
(emoji) => {
|
||||
onEmojiSelect?.(emoji.native)
|
||||
const nativeEmoji = extractNativeEmoji(emoji)
|
||||
if (nativeEmoji) {
|
||||
onEmojiSelect?.(nativeEmoji)
|
||||
}
|
||||
setOpen(false)
|
||||
},
|
||||
[onEmojiSelect],
|
||||
|
||||
Reference in New Issue
Block a user