mirror of
https://dev.azure.com/hugendubel/ISA/_git/ISA-Frontend
synced 2025-12-31 09:37:15 +01:00
[HIMA-28] fixed breadcrumb margins
This commit is contained in:
@@ -1,4 +1,4 @@
|
||||
<div class="breadacrumb-grid" [ngClass]="{ 'grid-with-arrow': !backArrow }">
|
||||
<div class="breadacrumb-grid" [ngClass]="{'grid-with-arrow': !backArrow, 'breadcumb-mb-5': lowerMargin}">
|
||||
<!-- <app-back-arrow (back)="addOne()"></app-back-arrow> TESTING ANIMATION PURPOSES-->
|
||||
<app-back-arrow
|
||||
*ngIf="backArrow"
|
||||
|
||||
@@ -6,6 +6,10 @@
|
||||
margin-bottom: 16px;
|
||||
}
|
||||
|
||||
.breadcumb-mb-5 {
|
||||
margin-bottom: 5px;
|
||||
}
|
||||
|
||||
.grid-with-arrow {
|
||||
grid-template-columns: auto;
|
||||
}
|
||||
|
||||
@@ -22,6 +22,16 @@ export class BreadcrumbsComponent implements OnInit {
|
||||
return this.router.url.substring(0, 16) === '/product-details';
|
||||
}
|
||||
|
||||
get lowerMargin() {
|
||||
if (this.router.url === '/customer-search-result') {
|
||||
return true;
|
||||
}
|
||||
if (this.router.url.substring(0, 14) === '/customer-edit') {
|
||||
return true;
|
||||
}
|
||||
return false;
|
||||
}
|
||||
|
||||
constructor(private store: Store, private router: Router) {
|
||||
this.processes$.subscribe((data: Process[]) =>
|
||||
this.getBreadcrumbsFromCurentProcess(data)
|
||||
|
||||
@@ -687,7 +687,7 @@ export class ProcessState {
|
||||
|
||||
const process = state.processes.find(t => t.selected === true);
|
||||
const breadcrumbs = [...process.breadcrumbs].map((b, i) => {
|
||||
if (i == process.breadcrumbs.length - 1) {
|
||||
if (i === process.breadcrumbs.length - 1) {
|
||||
return { name: payload, path: b.path };
|
||||
}
|
||||
return b;
|
||||
|
||||
Reference in New Issue
Block a user