feat: !new robot button

This commit is contained in:
karishmas6
2024-10-10 21:45:09 +05:30
parent 22f9ba2687
commit e670461799

View File

@@ -68,12 +68,14 @@ export const NavBar: React.FC<NavBarProps> = ({ newRecording, recordingName, isR
display: 'flex', display: 'flex',
justifyContent: 'flex-end', justifyContent: 'flex-end',
}}> }}>
{
!isRecording ? (
<IconButton <IconButton
aria-label="new" aria-label="new"
size={"small"} size={"small"}
onClick={handleNewRecording} onClick={handleNewRecording}
sx={{ sx={{
width: isRecording ? '130px' : '140px', width: '140px',
borderRadius: '5px', borderRadius: '5px',
padding: '8px', padding: '8px',
background: '#ff00c3', background: '#ff00c3',
@@ -88,8 +90,10 @@ export const NavBar: React.FC<NavBarProps> = ({ newRecording, recordingName, isR
} }
} }
> >
<Add sx={{ marginRight: '5px' }} /> {isRecording ? 'New Robot' : 'Create Robot'} <Add sx={{ marginRight: '5px' }} /> Create Robot
</IconButton> </IconButton>
) : ""
}
{ {
recordingLength > 0 recordingLength > 0
? <SaveRecording fileName={recordingName} /> ? <SaveRecording fileName={recordingName} />