Skip to content

Commit 4afe5e1

Browse files
committed
Improve bookmark button
1 parent 1956677 commit 4afe5e1

File tree

2 files changed

+13
-3
lines changed

2 files changed

+13
-3
lines changed

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

Lines changed: 11 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -52,9 +52,19 @@
5252
&-icon {
5353
font-size: 22px;
5454
color: #aaa;
55+
transition: all 0.2s ease;
56+
width: 1em;
57+
height: 1em;
58+
display: flex;
59+
align-items: center;
60+
justify-content: center;
5561

5662
&--active {
57-
color: #4355b9;
63+
color: white;
64+
background-color: #4355b9;
65+
border-radius: 50%;
66+
padding: 8px;
67+
box-sizing: content-box;
5868
}
5969
}
6070
}

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

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@ import { IonIcon } from '@ionic/react';
22
import { format } from 'date-fns';
33
import { useTranslation } from 'react-i18next';
44
import { MedicalReport, ReportCategory } from 'common/models/medicalReport';
5-
import { bookmark, bookmarkOutline } from 'ionicons/icons';
5+
import { bookmarkOutline } from 'ionicons/icons';
66
import './ReportItem.scss';
77

88
// Import SVG icons
@@ -99,7 +99,7 @@ const ReportItem: React.FC<ReportItemProps> = ({
9999
{showBookmarkButton && (
100100
<div className="report-item__bookmark" onClick={handleBookmarkClick}>
101101
<IonIcon
102-
icon={bookmarked ? bookmark : bookmarkOutline}
102+
icon={bookmarkOutline}
103103
className={`report-item__bookmark-icon ${
104104
bookmarked ? 'report-item__bookmark-icon--active' : ''
105105
}`}

0 commit comments

Comments
 (0)