Skip to content

Commit

Permalink
feat: calculate remaining value in license details
Browse files Browse the repository at this point in the history
  • Loading branch information
sergivalero20 committed Aug 20, 2024
1 parent 80ad2cb commit c4abc54
Show file tree
Hide file tree
Showing 3 changed files with 6 additions and 6 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -46,9 +46,9 @@ const mockStore = {
data: [
{
licenseName: 'License Demo',
purchasedSeats: 10,
numberOfStudents: 20,
numberOfPendingStudents: 10,
purchasedSeats: 20,
numberOfStudents: 10,
numberOfPendingStudents: 5,
},
],
count: 1,
Expand Down
4 changes: 2 additions & 2 deletions src/features/Licenses/LicensesDetailPage/index.jsx
Original file line number Diff line number Diff line change
Expand Up @@ -110,8 +110,8 @@ const LicensesDetailPage = () => {
<div className="separator mx-4" />
<div className="d-flex flex-column align-items-center">
<p className="title">Remaining</p>
<span className="value number-of-pending">
{licenseInfo.numberOfPendingStudents}
<span className="value number-of-remaining">
{licenseInfo.purchasedSeats - licenseInfo.numberOfStudents - licenseInfo.numberOfPendingStudents}
</span>
</div>
</>
Expand Down
2 changes: 1 addition & 1 deletion src/features/Licenses/LicensesDetailPage/index.scss
Original file line number Diff line number Diff line change
Expand Up @@ -46,7 +46,7 @@
font-weight: bold;
}

.number-of-pending {
.number-of-remaining {
color: red;
}

Expand Down

0 comments on commit c4abc54

Please sign in to comment.