Skip to content

Commit 4491866

Browse files
committed
Merge branch 'main' of github.com:ModusCreateOrg/app-med-ai-gen into ADE-36
2 parents 5eeedea + bfdc653 commit 4491866

File tree

8 files changed

+14
-27
lines changed

8 files changed

+14
-27
lines changed
Lines changed: 1 addition & 1 deletion
Loading

frontend/src/common/api/__tests__/reportService.test.ts

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -98,7 +98,7 @@ const mockReports = [
9898
id: '2',
9999
title: 'brain-scan',
100100
status: ReportStatus.UNREAD,
101-
category: ReportCategory.NEUROLOGICAL,
101+
category: ReportCategory.BRAIN,
102102
date: '2024-03-24',
103103
}
104104
];
@@ -154,20 +154,20 @@ describe('reportService', () => {
154154
const heartReport = await uploadReport(heartFile);
155155
expect(heartReport.category).toBe(ReportCategory.HEART);
156156

157-
// Mock response for neurological file
157+
// Mock response for brain file
158158
(axios.post as ReturnType<typeof vi.fn>).mockResolvedValueOnce({
159159
data: {
160160
id: 'neuro-id',
161161
title: 'brain-scan',
162162
status: ReportStatus.UNREAD,
163-
category: ReportCategory.NEUROLOGICAL,
163+
category: ReportCategory.BRAIN,
164164
date: '2024-05-10',
165165
}
166166
});
167167

168168
const neuroFile = new File(['test'], 'brain-scan.pdf', { type: 'application/pdf' });
169169
const neuroReport = await uploadReport(neuroFile);
170-
expect(neuroReport.category).toBe(ReportCategory.NEUROLOGICAL);
170+
expect(neuroReport.category).toBe(ReportCategory.BRAIN);
171171
});
172172

173173
test('should handle upload without progress callback', async () => {

frontend/src/common/models/medicalReport.ts

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,6 @@ export enum ReportCategory {
55
GENERAL = 'general',
66
BRAIN = 'brain',
77
HEART = 'heart',
8-
OTHER = 'Other'
98
}
109

1110
/**

frontend/src/common/utils/i18n/resources/en/home.json

Lines changed: 1 addition & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -32,12 +32,8 @@
3232
},
3333
"categories": {
3434
"general": "General",
35-
"neurological": "Neurological",
36-
"oftalmological": "Oftalmological",
3735
"heart": "Heart",
38-
"gastro": "Gastroenterology",
39-
"orthopedic": "Orthopedic",
40-
"other": "Other"
36+
"brain": "Brain"
4137
},
4238
"status": {
4339
"read": "Read",

frontend/src/common/utils/i18n/resources/es/home.json

Lines changed: 2 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -32,12 +32,8 @@
3232
},
3333
"categories": {
3434
"general": "General",
35-
"neurological": "Neurológico",
36-
"oftalmological": "Oftalmológico",
37-
"heart": "Cardíaco",
38-
"gastro": "Gastroenterología",
39-
"orthopedic": "Ortopédico",
40-
"other": "Otro"
35+
"heart": "Corazón",
36+
"brain": "Cerebro"
4137
},
4238
"status": {
4339
"read": "Leído",

frontend/src/common/utils/i18n/resources/fr/home.json

Lines changed: 2 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -32,12 +32,8 @@
3232
},
3333
"categories": {
3434
"general": "Général",
35-
"neurological": "Neurologique",
36-
"oftalmological": "Ophtalmologique",
37-
"heart": "Cardiaque",
38-
"gastro": "Gastroentérologie",
39-
"orthopedic": "Orthopédique",
40-
"other": "Autre"
35+
"heart": "Cœur",
36+
"brain": "Cerveau"
4137
},
4238
"status": {
4339
"read": "Lu",

frontend/src/pages/Home/components/ReportItem/ReportItem.scss

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -19,7 +19,7 @@
1919
margin-bottom: 4px;
2020
font-weight: 700;
2121

22-
// Add a small bullet before neurological category
22+
// Add a small bullet before brain category
2323
&:before {
2424
content: "";
2525
display: inline-block;
@@ -72,7 +72,7 @@
7272
box-shadow: 0 1px 3px rgba(0, 0, 0, 0.08);
7373
border: 1px solid rgba(0, 0, 0, 0.03);
7474

75-
&--general, &--brain, &--neurological, &--heart {
75+
&--general, &--brain, &--heart {
7676
background-color: white;
7777
}
7878

frontend/src/pages/Home/components/ReportItem/ReportItem.tsx

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -40,7 +40,7 @@ const ReportItem: React.FC<ReportItemProps> = ({
4040
const getCategoryTranslationKey = () => {
4141
if (categoryStr === ReportCategory.GENERAL.toLowerCase()) {
4242
return 'list.categoryGeneral';
43-
} else if (categoryStr === ReportCategory.BRAIN.toLowerCase() || categoryStr === 'neurological') {
43+
} else if (categoryStr === ReportCategory.BRAIN.toLowerCase()) {
4444
return 'list.categoryBrain';
4545
} else if (categoryStr === ReportCategory.HEART.toLowerCase()) {
4646
return 'list.categoryHeart';
@@ -66,7 +66,7 @@ const ReportItem: React.FC<ReportItemProps> = ({
6666
const getCategoryIconSrc = (category: string) => {
6767
if (category === ReportCategory.GENERAL.toLowerCase()) {
6868
return healthIcon;
69-
} else if (category === ReportCategory.BRAIN.toLowerCase() || category === 'neurological') {
69+
} else if (category === ReportCategory.BRAIN.toLowerCase()) {
7070
return brainIcon;
7171
} else if (category === ReportCategory.HEART.toLowerCase()) {
7272
return heartIcon;

0 commit comments

Comments
 (0)