Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix: Display exact amount DQA fixes #3395

Merged
merged 10 commits into from
Jan 6, 2025
Merged
Show file tree
Hide file tree
Changes from 7 commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -3,37 +3,9 @@
.task {
background-color: $pure-white;
&--icon {
font-size: 24px;
font-size: 20px;
padding-top: 4px;
color: $blue-black;

&__warning {
font-size: 20px;
position: relative;
top: -2px;
left: -5px;
}

&__expense {
font-size: 20px;
position: relative;
top: -6px;
left: -8px;
}

&__advance {
position: relative;
top: -6px;
left: -8px;
font-size: 20px;
}

&__mobile {
position: relative;
bottom: 4px;
right: 6px;
font-size: 20px;
}
}

&--row {
Expand Down Expand Up @@ -97,7 +69,7 @@
line-height: 23px;
font-weight: 500;
color: $blue-black;
padding: 4px 0 0 0;
padding: 6px 0 0 0;
}

&--subheader {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@
<div class="advance-card--purpose-amount-date-block">
<!-- Icon -->
<div class="advance-card--icon-container">
<mat-icon class="advance-card--list-icon" svgIcon="list"></mat-icon>
<mat-icon class="advance-card--list-icon" svgIcon="list-new"></mat-icon>
</div>

<div class="advance-card--purpose-amount-date-container">
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -35,7 +35,9 @@ $advance_rejected_color: #d50000;

&--list-icon {
width: 16px;
height: 16px;
padding-top: 2px;
color: $black-light;
}

&--purpose {
Expand Down Expand Up @@ -66,7 +68,7 @@ $advance_rejected_color: #d50000;
&--currency {
color: $black-light;
font-weight: 500;
font-size: 16px;
font-size: 14px;
}

&--amount {
Expand Down
8 changes: 5 additions & 3 deletions src/app/fyle/my-create-report/my-create-report.page.html
Original file line number Diff line number Diff line change
Expand Up @@ -9,8 +9,10 @@
<div class="my-create-report--title-container text-center">
<div class="my-create-report--title">Create New Report</div>
<div class="my-create-report--sub-title">
{{ selectedElements?.length }} {{ selectedElements?.length > 1 ? 'Expenses' : 'Expense' }} - {{
selectedTotalAmount || 0 | humanizeCurrency: homeCurrency }}
{{ selectedElements?.length }} {{ selectedElements?.length > 1 ? 'Expenses' : 'Expense' }}
<span class="my-create-report--amount">
({{ { value: selectedTotalAmount || 0, currencyCode: homeCurrency } | exactCurrency }})
</span>
SahilK-027 marked this conversation as resolved.
Show resolved Hide resolved
</div>
</div>
</ion-toolbar>
Expand Down Expand Up @@ -47,7 +49,7 @@
</div>
</div>

<div *ngIf="readyToReportExpenses?.length > 0" class="my-create-report--heading">EXPENSES</div>
<div *ngIf="readyToReportExpenses?.length > 0" class="my-create-report--heading">Expenses</div>
<div *ngIf="readyToReportExpenses?.length > 0" class="my-create-report--select-all-checkbox">
<mat-checkbox
class="custom-mat-checkbox create-new-report--checkbox"
Expand Down
24 changes: 19 additions & 5 deletions src/app/fyle/my-create-report/my-create-report.page.scss
Original file line number Diff line number Diff line change
Expand Up @@ -14,17 +14,31 @@
color: $black;
font-weight: 500;
margin-left: -10%;
padding: 12px;
}

&--title {
font-size: 20px;
line-height: 1.28;
font-size: 18px;
font-weight: 500;
line-height: 28px;
}

&--sub-title {
font-size: 14px;
line-height: 1.28;
margin-top: 4px;
font-weight: 500;
color: $blue-black;
display: flex;
justify-content: center;
align-items: center;
flex-wrap: wrap;
gap: 4px;
}
SahilK-027 marked this conversation as resolved.
Show resolved Hide resolved

&--amount {
font-size: 12px;
margin-top: 2px;
font-weight: 400;
SahilK-027 marked this conversation as resolved.
Show resolved Hide resolved
color: $blue-black;
}

&--mandatory {
Expand Down Expand Up @@ -82,7 +96,7 @@
}

&--heading {
color: $grey-light;
color: $black-light;
font-size: 14px;
padding: 16px 16px;
background-color: $white;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -21,6 +21,7 @@ import { LoaderService } from 'src/app/core/services/loader.service';
import { TransactionService } from 'src/app/core/services/transaction.service';
import { FyCurrencyPipe } from 'src/app/shared/pipes/fy-currency.pipe';
import { HumanizeCurrencyPipe } from 'src/app/shared/pipes/humanize-currency.pipe';
import { ExactCurrencyPipe } from 'src/app/shared/pipes/exact-currency.pipe';
import { StorageService } from '../../core/services/storage.service';
import { TrackingService } from '../../core/services/tracking.service';
import { MyCreateReportPage } from './my-create-report.page';
Expand Down Expand Up @@ -63,7 +64,7 @@ describe('MyCreateReportPage', () => {
]);

TestBed.configureTestingModule({
declarations: [MyCreateReportPage, HumanizeCurrencyPipe],
declarations: [MyCreateReportPage, HumanizeCurrencyPipe, ExactCurrencyPipe],
imports: [IonicModule.forRoot(), RouterTestingModule, FormsModule, MatCheckboxModule],
providers: [
FyCurrencyPipe,
Expand Down
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
<ion-header>
<div class="report-list--header">
<mat-icon class="fy-modal-top-bar report-list--header--handle-bar-icon" svgIcon="notch"></mat-icon>
<ion-grid>
<ion-grid class="report-list--header--top-nav-container">
<ion-row>
<ion-col size="1" class="report-list--header--row-icon-container">
<ion-icon
Expand Down Expand Up @@ -31,7 +31,7 @@
<ion-grid class="ion-no-padding">
<ion-row class="report-list--report-card">
<ion-col size="0.75">
<mat-icon class="report-list--list-icon" svgIcon="list"></mat-icon>
<mat-icon class="report-list--list-icon" svgIcon="list-new"></mat-icon>
</ion-col>
<ion-col size="8.25" class="ion-no-padding">
<div class="report-list--purpose">{{ report.purpose }}</div>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -8,16 +8,24 @@ $reports_sent_back_color: #da1e28;
color: $black;
font-weight: 500;
border-bottom: 1px solid $grey;
display: flex;
flex-direction: column;

&--top-nav-container {
width: 100%;
}

&--row-icon-container {
display: flex;
align-items: center;
justify-content: center;
font-size: 20px;
width: 100%;
}

&--handle-bar-icon {
margin: 0 0 2px 0;
margin: 0 0 4px 0;
align-self: center;
}
}

Expand All @@ -28,6 +36,7 @@ $reports_sent_back_color: #da1e28;
&--list-icon {
width: 16px;
height: 16px;
color: $black-light;
}

&--currency-amount-container {
Expand All @@ -37,9 +46,8 @@ $reports_sent_back_color: #da1e28;
&--currency {
color: $black-light;
font-weight: 500;
font-size: 16px;
font-size: 14px;
line-height: 1.3;
margin-right: 2px;
}

&--amount {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -118,7 +118,7 @@
}

&--currency {
font-size: 16px;
font-size: 14px;
font-weight: 500;
color: $grey-light-2;
width: 40%;
Expand Down
2 changes: 1 addition & 1 deletion src/app/fyle/my-view-advance/my-view-advance.page.scss
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@
}

&--currency {
font-size: 16px;
font-size: 14px;
SahilK-027 marked this conversation as resolved.
Show resolved Hide resolved
font-weight: 500;
color: $grey-light-2;
width: 80px;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -6,9 +6,9 @@
<div *ngIf="selectedElements?.length > 0" class="add-expenses-to-report--title-container text-center">
<div class="add-expenses-to-report--title">
{{ selectedElements?.length }} {{ selectedElements?.length > 1 ? 'Expenses' : 'Expense' }}
</div>
<div class="add-expenses-to-report--total-amount">
{{ { value: selectedTotalAmount || 0, currencyCode: homeCurrency } | exactCurrency }}
<span class="add-expenses-to-report--total-amount">
({{ { value: selectedTotalAmount || 0, currencyCode: homeCurrency } | exactCurrency }})
</span>
</div>
</div>
</ion-title>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -14,6 +14,11 @@
&--title {
font-size: 14px;
margin-bottom: 4px;
display: flex;
justify-content: center;
align-items: center;
flex-wrap: wrap;
gap: 4px;
}

&--total-amount {
Expand Down
5 changes: 4 additions & 1 deletion src/app/fyle/my-view-report/my-view-report.page.html
Original file line number Diff line number Diff line change
Expand Up @@ -85,7 +85,10 @@
</ion-col>
<ion-col size="4">
<div class="view-reports--view-info" (click)="openViewReportInfoModal()">
<ion-icon class="view-reports--view-info__icon" src="../../../assets/svg/info-gradient.svg"></ion-icon>
<ion-icon
class="view-reports--view-info__icon"
src="../../../assets/svg/info-circle-gradient.svg"
></ion-icon>
<span class="view-reports--view-info__content">View Info</span>
</div>
</ion-col>
Expand Down
9 changes: 9 additions & 0 deletions src/app/fyle/my-view-report/my-view-report.page.scss
Original file line number Diff line number Diff line change
Expand Up @@ -101,6 +101,10 @@
&--amount {
color: $white;
font-size: 18px;
display: flex;
align-items: center;
justify-content: flex-start;
gap: 1px;
}

&--purpose-state {
Expand All @@ -125,6 +129,11 @@
font-size: 18px;
font-weight: 500;
}

&__currency {
font-size: 14px;
line-height: 1.5;
}
}

&--date-info-block {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -113,6 +113,7 @@
line-height: 1.25;
margin-right: -2px;
vertical-align: text-bottom;
font-size: 14px;
}

&--amount {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@
<div class="advance-card--purpose-amount-date-block">
<!-- Icon -->
<div class="advance-card--icon-container">
<mat-icon class="advance-card--list-icon" svgIcon="list"></mat-icon>
<mat-icon class="advance-card--list-icon" svgIcon="list-new"></mat-icon>
</div>

<!-- Purpose -->
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -37,6 +37,7 @@ $advance_rejected_color: #d50000;
width: 16px;
height: 16px;
padding-top: 2px;
color: $black-light;
}

&--purpose {
Expand Down Expand Up @@ -66,7 +67,7 @@ $advance_rejected_color: #d50000;
&--currency {
color: $black-light;
font-weight: 500;
font-size: 16px;
font-size: 14px;
SahilK-027 marked this conversation as resolved.
Show resolved Hide resolved
}

&--amount {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -140,7 +140,7 @@
}

&--currency {
font-size: 16px;
font-size: 14px;
font-weight: 500;
color: #4a4a4a;
width: 40%;
Expand Down
5 changes: 4 additions & 1 deletion src/app/fyle/view-team-report/view-team-report.page.html
Original file line number Diff line number Diff line change
Expand Up @@ -90,7 +90,10 @@
</ion-col>
<ion-col size="4" class="view-reports--view-info-container">
<div class="view-reports--view-info" (click)="openViewReportInfoModal()">
<ion-icon class="view-reports--view-info__icon" src="../../../assets/svg/info-gradient.svg"></ion-icon>
<ion-icon
class="view-reports--view-info__icon"
src="../../../assets/svg/info-circle-gradient.svg"
></ion-icon>
<span class="view-reports--view-info__content">View Info</span>
</div>
</ion-col>
Expand Down
8 changes: 8 additions & 0 deletions src/app/fyle/view-team-report/view-team-report.page.scss
Original file line number Diff line number Diff line change
Expand Up @@ -243,6 +243,10 @@ $sent-back-color: #da1e28;
&--amount {
color: $white;
font-size: 18px;
display: flex;
align-items: center;
justify-content: flex-start;
gap: 1px;
}

&--purpose-state {
Expand All @@ -267,6 +271,10 @@ $sent-back-color: #da1e28;
font-size: 18px;
font-weight: 500;
}

&__currency {
font-size: 14px;
}
}

&--submitted-date-container {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -6,9 +6,9 @@
<div class="create-new-report--title">Create new report</div>
<div class="create-new-report--sub-title">
{{ selectedElements.length }} {{ selectedElements.length > 1 ? 'expenses' : 'expense' }}
</div>
<div class="create-new-report--amount">
{{ { value: selectedTotalAmount || 0, currencyCode: homeCurrency } | exactCurrency }}
<span class="create-new-report--amount">
({{ { value: selectedTotalAmount || 0, currencyCode: homeCurrency } | exactCurrency }})
</span>
</div>
</div>
</ion-title>
Expand Down
Loading