mirror of
https://gitlab.com/mbugroup/lti-web-client.git
synced 2026-05-25 07:45:47 +00:00
feat(FE-170): simplify action buttons in RecordingForm for detail view
This commit is contained in:
@@ -2414,7 +2414,6 @@ const RecordingForm = ({ type = 'add', initialValues }: RecordingFormProps) => {
|
|||||||
{/* Action buttons */}
|
{/* Action buttons */}
|
||||||
<div className='flex flex-row justify-between gap-2 flex-wrap'>
|
<div className='flex flex-row justify-between gap-2 flex-wrap'>
|
||||||
{/* Left side - Detail & Edit actions */}
|
{/* Left side - Detail & Edit actions */}
|
||||||
{type !== 'add' && !isRecordingApproved(initialValues) && (
|
|
||||||
<div className='flex flex-row justify-start gap-2'>
|
<div className='flex flex-row justify-start gap-2'>
|
||||||
{type === 'detail' && deleteRecordingClickHandler && (
|
{type === 'detail' && deleteRecordingClickHandler && (
|
||||||
<Button
|
<Button
|
||||||
@@ -2449,7 +2448,6 @@ const RecordingForm = ({ type = 'add', initialValues }: RecordingFormProps) => {
|
|||||||
</Button>
|
</Button>
|
||||||
)}
|
)}
|
||||||
</div>
|
</div>
|
||||||
)}
|
|
||||||
<div className='flex flex-row justify-end gap-2'>
|
<div className='flex flex-row justify-end gap-2'>
|
||||||
{type === 'detail' && isLayingCategory && (
|
{type === 'detail' && isLayingCategory && (
|
||||||
<Button
|
<Button
|
||||||
@@ -2494,7 +2492,7 @@ const RecordingForm = ({ type = 'add', initialValues }: RecordingFormProps) => {
|
|||||||
<>
|
<>
|
||||||
<Button
|
<Button
|
||||||
type='reset'
|
type='reset'
|
||||||
color='neutral'
|
color='warning'
|
||||||
className='px-4'
|
className='px-4'
|
||||||
onClick={(e) => {
|
onClick={(e) => {
|
||||||
formik.handleReset(e);
|
formik.handleReset(e);
|
||||||
@@ -2569,7 +2567,7 @@ const RecordingForm = ({ type = 'add', initialValues }: RecordingFormProps) => {
|
|||||||
</section>
|
</section>
|
||||||
|
|
||||||
{/* ===== MODALS ===== */}
|
{/* ===== MODALS ===== */}
|
||||||
{type !== 'add' && !isRecordingApproved(initialValues) && (
|
{type === 'detail' && (
|
||||||
<>
|
<>
|
||||||
<ConfirmationModal
|
<ConfirmationModal
|
||||||
ref={deleteModal.ref}
|
ref={deleteModal.ref}
|
||||||
|
|||||||
Reference in New Issue
Block a user