Skip to content

Commit 258e3d9

Browse files
committed
feat: Update cancel button styling to match upload button dimensions and improve layout
1 parent b50ea13 commit 258e3d9

File tree

2 files changed

+17
-5
lines changed

2 files changed

+17
-5
lines changed

frontend/src/common/components/Upload/UploadModal.scss

Lines changed: 12 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -279,19 +279,30 @@
279279
&__cancel-btn {
280280
margin-top: 1rem;
281281
width: 100%;
282-
max-width: 15rem;
282+
max-width: 12rem; // Match the upload button's max-width
283283
--color: white;
284284
--border-color: rgba(255, 255, 255, 0.6);
285285
--background: rgba(255, 255, 255, 0.1);
286286
--border-radius: 0.5rem;
287287
--border-width: 1px;
288288
--border-style: solid;
289+
height: 2.5rem; // Exactly match the upload button's height (40px)
290+
font-weight: 500;
291+
text-transform: none;
289292

290293
ion-icon {
291294
margin-right: 0.5rem;
292295
font-size: 1.25rem;
293296
}
294297
}
298+
299+
&__bottom-actions {
300+
margin-top: 20px;
301+
width: 100%;
302+
display: flex;
303+
justify-content: center; // Center the button
304+
padding: 0 1rem;
305+
}
295306

296307
&__file-item {
297308
display: flex;

frontend/src/common/components/Upload/UploadModal.tsx

Lines changed: 5 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@ import {
88
IonLabel,
99
IonItem
1010
} from '@ionic/react';
11-
import { closeOutline, cloudUploadOutline, documentOutline, checkmarkOutline, closeCircleOutline } from 'ionicons/icons';
11+
import { closeOutline, cloudUploadOutline, documentOutline, checkmarkOutline } from 'ionicons/icons';
1212
import { useTranslation } from 'react-i18next';
1313
import { UploadStatus, useFileUpload } from '../../hooks/useFileUpload';
1414
import { MedicalReport } from '../../models/medicalReport';
@@ -157,15 +157,16 @@ const UploadModal = ({ isOpen, onClose, onUploadComplete }: UploadModalProps): J
157157
</div>
158158
</div>
159159
)}
160-
161-
{/* Cancel button */}
160+
</div>
161+
162+
{/* Cancel button - updated to match the size of the upload button */}
163+
<div className="upload-modal__bottom-actions">
162164
<IonButton
163165
expand="block"
164166
fill="outline"
165167
className="upload-modal__cancel-btn"
166168
onClick={handleCancel}
167169
>
168-
<IonIcon icon={closeCircleOutline} slot="start" />
169170
{t('common.cancel')}
170171
</IonButton>
171172
</div>

0 commit comments

Comments
 (0)