import React, { type ReactElement, type ElementType } from 'react'; import { Box, Button, Dialog, DialogContent, DialogTitle, IconButton, TextField, Typography, } from '@mui/material'; import Slide from '@mui/material/Slide'; import type { TransitionProps } from '@mui/material/transitions'; import { CloseCircle } from 'iconsax-react'; import { Icon } from '@rkheftan/harmony-ui'; const MobileSlide = React.forwardRef(function MobileSlide( props: TransitionProps & { children: ReactElement }, ref: React.Ref, ) { return ; }); interface SocialMediaDialogProps { open: boolean; onClose: () => void; t: (key: string) => string; emailInput: string; setEmailInput: (val: string) => void; emailError: boolean; setEmailError: (val: boolean) => void; fullScreen: boolean; computedMaxWidth: 'xs' | 'sm' | 'md' | 'lg' | 'xl'; } export default function SocialMediaDialog({ open, onClose, t, emailInput, setEmailInput, emailError, setEmailError, fullScreen, computedMaxWidth, }: SocialMediaDialogProps) { const handleEmailChange = (e: React.ChangeEvent) => { const value = e.target.value; setEmailInput(value); setEmailError(!/^[^\s@]+@[^\s@]+\.[^\s@]+$/.test(value)); }; return ( {t('settingForm.addEmailButton')} {t('settingForm.newEmail')} {t('settingForm.dialogHeader')} ); }