Skip to content

Commit

Permalink
🐛 fix: Fix ShareModal
Browse files Browse the repository at this point in the history
  • Loading branch information
canisminor1990 authored Dec 26, 2023
1 parent 1d0481b commit 4592515
Showing 1 changed file with 10 additions and 6 deletions.
16 changes: 10 additions & 6 deletions src/app/chat/features/ChatHeader/ShareButton/ShareModal.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -76,35 +76,39 @@ const ShareModal = memo<ModalProps>(({ onCancel, open }) => {
name: 'withSystemRole',
valuePropName: 'checked',
},
tab === Tab.Screenshot && {
{
children: <Switch />,
hidden: tab !== Tab.Screenshot,
label: t('shareModal.withBackground'),
minWidth: undefined,
name: 'withBackground',
valuePropName: 'checked',
},
tab === Tab.Screenshot && {
{
children: <Switch />,
hidden: tab !== Tab.Screenshot,
label: t('shareModal.withFooter'),
minWidth: undefined,
name: 'withFooter',
valuePropName: 'checked',
},
tab === Tab.Screenshot && {
{
children: <Segmented options={imageTypeOptions} />,
hidden: tab !== Tab.Screenshot,
label: t('shareModal.imageType'),
minWidth: undefined,
name: 'imageType',
},
tab === Tab.ShareGPT && {
{
children: <Switch />,
hidden: tab !== Tab.ShareGPT,
label: t('shareModal.withPluginInfo'),
minWidth: undefined,
name: 'withPluginInfo',
valuePropName: 'checked',
},
].filter(Boolean) as FormItemProps[],
[],
],
[tab],
);

return (
Expand Down

0 comments on commit 4592515

Please sign in to comment.