Skip to content

Commit

Permalink
c1: Zero state (#560)
Browse files Browse the repository at this point in the history
* C1: QA Fixes - 4 | Tooltip

* page alignment

* page alignment

* c1: Zero state

* fix content
  • Loading branch information
ashwin1111 authored Feb 21, 2024
1 parent 8da584f commit 60cee35
Show file tree
Hide file tree
Showing 7 changed files with 17 additions and 15 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -22,8 +22,8 @@

<app-zero-state *ngIf="!accountingExportSummary && !exportableAccountingExportIds.length"
[zeroStateImageURL]="'assets/illustrations/dashboard-illustration.svg'"
[headerText]="'Looks like you have'"
[subHeaderText]="'0 expenses to export right now'">
[headerText]="brandingConfig.brandId === 'fyle' ? 'Looks like you have': 'No records to show yet'"
[subHeaderText]="brandingConfig.brandId === 'fyle' ? '0 expenses to export right now': 'You\'ll be able to see export info here once you start exporting expenses'">
</app-zero-state>

<app-dashboard-export-summary-section *ngIf="exportableAccountingExportIds.length || accountingExportSummary"
Expand Down
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
import { Component, OnInit } from '@angular/core';
import { Observable, catchError, forkJoin, from, interval, of, switchMap, takeWhile } from 'rxjs';
import { brandingFeatureConfig } from 'src/app/branding/branding-config';
import { brandingConfig, brandingFeatureConfig } from 'src/app/branding/branding-config';
import { AccountingExportSummary, AccountingExportSummaryModel } from 'src/app/core/models/db/accounting-export-summary.model';
import { DashboardModel, DestinationFieldMap } from 'src/app/core/models/db/dashboard.model';
import { AccountingGroupedErrorStat, AccountingGroupedErrors, Error, ErrorResponse } from 'src/app/core/models/db/error.model';
Expand Down Expand Up @@ -65,6 +65,8 @@ export class QboDashboardComponent implements OnInit {

readonly isGradientAllowed: boolean = brandingFeatureConfig.isGradientAllowed;

readonly brandingConfig = brandingConfig;

constructor(
private accountingExportService: AccountingExportService,
private dashboardService: DashboardService,
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -28,13 +28,13 @@
</div>

<app-zero-state-with-illustration *ngIf="!filteredAccountingExports.length && !selectedDateFilter && totalCount > 0"
[mainText]="'Sorry, no results found!'"
[mainText]="brandingConfig.brandId === 'fyle' ? 'Sorry, no results found!': 'Sorry, no results found'"
[subText]="'We could not find what you were looking for. Kindly check the keywords again.'">
</app-zero-state-with-illustration>
</div>

<app-zero-state-with-illustration *ngIf="totalCount === 0"
[mainText]="'No records to show yet!'"
[subText]="'All your successful exports and their details will be stored here.'">
[mainText]="brandingConfig.brandId === 'fyle' ? 'No records to show yet!': 'No records to show yet'"
[subText]="brandingConfig.brandId === 'fyle' ? 'All your successful exports and their details will be stored here.': 'All your expenses that are successfully exported will be visible here'">
</app-zero-state-with-illustration>
</div>
Original file line number Diff line number Diff line change
Expand Up @@ -24,14 +24,14 @@
</div>

<app-zero-state-with-illustration *ngIf="!filteredExpenses.length && !selectedDateFilter && totalCount > 0"
[mainText]="'Sorry, no results found!'"
[mainText]="brandingConfig.brandId === 'fyle' ? 'Sorry, no results found!': 'Sorry, no results found'"
[subText]="'We could not find what you were looking for. Kindly check the keywords again.'">
</app-zero-state-with-illustration>

</div>

<app-zero-state-with-illustration *ngIf="totalCount === 0"
[mainText]="'No records to show yet!'"
[subText]="'All your expenses that were skipped from exporting will be stored here.'">
[mainText]="brandingConfig.brandId === 'fyle' ? 'No records to show yet!': 'No records to show yet'"
[subText]="brandingConfig.brandId === 'fyle' ? 'All your expenses that were skipped from exporting will be stored here.': 'All your expenses that are skipped from exporting will be visible here'">
</app-zero-state-with-illustration>
</div>
Original file line number Diff line number Diff line change
Expand Up @@ -20,13 +20,13 @@
<td>
<h4 class="tw-text-14-px tw-font-400 tw-text-text-secondary"
[ngClass]="{'truncate': rowData.employee[0]?.length > 16 && !isExportLogTable}"
[pTooltip]="rowData.employee[0]?.length > 16 ? rowData.employee[0] : null"
[pTooltip]="rowData.employee[0]?.length > 16 && !isExportLogTable ? rowData.employee[0] : null"
tooltipPosition="top">
{{rowData.employee[0]}}
</h4>
<h5 class="tw-font-400 !tw-text-12-px tw-text-text-muted"
[ngClass]="{'truncate': rowData.employee[1]?.length > 16 && !isExportLogTable}"
[pTooltip]="rowData.employee[1]?.length > 16 ? rowData.employee[1] : null"
[pTooltip]="rowData.employee[1]?.length > 16 && !isExportLogTable ? rowData.employee[1] : null"
tooltipPosition="top">
{{rowData.employee[1]}}
</h5>
Expand All @@ -35,7 +35,7 @@
<td class="tw-text-text-secondary tw-underline" (click)="openUrl(rowData.fyleUrl)">{{rowData.referenceNumber}}</td>
<td class="tw-text-text-secondary" *ngIf="!isDashboardFailed">
<span [ngClass]="{'truncate-export-type': rowData.exportedAs.length > 10 && !isExportLogTable}"
[pTooltip]="rowData.exportedAs.length > 10 ? rowData.exportedAs : null"
[pTooltip]="rowData.exportedAs.length > 10 && !isExportLogTable ? rowData.exportedAs : null"
tooltipPosition="top">
{{brandingConfig.brandId === 'co' ? (rowData.exportedAs | snakeCaseToSpaceCase) : (rowData.exportedAs | snakeCaseToSpaceCase | titlecase)}}
</span>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -17,8 +17,8 @@
</div>
<div *ngIf="!filteredMappingCount">
<app-zero-state-with-illustration
[mainText]="'No search result to show yet!'"
[subText]="'Looks like your search term does not match any of ' + (this.sourceField | snakeCaseToSpaceCase | titlecase) + ' mappings'">
[mainText]="brandingConfig.brandId === 'fyle' ? 'No search result to show yet!': 'No search result to show yet'"
[subText]="brandingConfig.brandId === 'fyle' ? 'Looks like your search term does not match any of ' + (this.sourceField | snakeCaseToSpaceCase | titlecase) + ' mappings': 'Looks like your search term does not match any of ' + (this.sourceField | snakeCaseToSpaceCase | lowercase) + ' mappings'">
</app-zero-state-with-illustration>
</div>
</div>
Expand Down
2 changes: 1 addition & 1 deletion src/assets/sprites/sprite.svg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.

0 comments on commit 60cee35

Please sign in to comment.