mirror of
https://git.mirrors.martin98.com/https://github.com/langgenius/dify.git
synced 2025-08-14 11:45:57 +08:00
fix: modal disappear (#478)
This commit is contained in:
parent
9d98669e7d
commit
a87f6f2837
@ -83,17 +83,6 @@ const SettingsModal: FC<ISettingsModalProps> = ({
|
|||||||
|
|
||||||
return (
|
return (
|
||||||
<>
|
<>
|
||||||
{showEmojiPicker && <EmojiPicker
|
|
||||||
onSelect={(icon, icon_background) => {
|
|
||||||
console.log(icon, icon_background)
|
|
||||||
setEmoji({ icon, icon_background })
|
|
||||||
setShowEmojiPicker(false)
|
|
||||||
}}
|
|
||||||
onClose={() => {
|
|
||||||
setEmoji({ icon: '🤖', icon_background: '#FFEAD5' })
|
|
||||||
setShowEmojiPicker(false)
|
|
||||||
}}
|
|
||||||
/>}
|
|
||||||
<Modal
|
<Modal
|
||||||
title={t(`${prefixSettings}.title`)}
|
title={t(`${prefixSettings}.title`)}
|
||||||
isShow={isShow}
|
isShow={isShow}
|
||||||
@ -161,6 +150,17 @@ const SettingsModal: FC<ISettingsModalProps> = ({
|
|||||||
<Button className='mr-2 flex-shrink-0' onClick={onHide}>{t('common.operation.cancel')}</Button>
|
<Button className='mr-2 flex-shrink-0' onClick={onHide}>{t('common.operation.cancel')}</Button>
|
||||||
<Button type='primary' className='flex-shrink-0' onClick={onClickSave} loading={saveLoading}>{t('common.operation.save')}</Button>
|
<Button type='primary' className='flex-shrink-0' onClick={onClickSave} loading={saveLoading}>{t('common.operation.save')}</Button>
|
||||||
</div>
|
</div>
|
||||||
|
{showEmojiPicker && <EmojiPicker
|
||||||
|
onSelect={(icon, icon_background) => {
|
||||||
|
console.log(icon, icon_background)
|
||||||
|
setEmoji({ icon, icon_background })
|
||||||
|
setShowEmojiPicker(false)
|
||||||
|
}}
|
||||||
|
onClose={() => {
|
||||||
|
setEmoji({ icon: '🤖', icon_background: '#FFEAD5' })
|
||||||
|
setShowEmojiPicker(false)
|
||||||
|
}}
|
||||||
|
/>}
|
||||||
</Modal >
|
</Modal >
|
||||||
</>
|
</>
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user