root page content to center

master
Boris Voropaev 2023-12-22 16:42:27 +03:00
parent ea5fac5fcb
commit e877aab062
5 changed files with 79 additions and 0 deletions

View File

@ -89,6 +89,10 @@
"replace": "src/environments/environment.ts",
"with": "src/environments/vniigaz-v2.env.dev.ts"
},
{
"replace": "src/app/_modules/layout/grid/grid.component.ts",
"with": "src/vniigaz-v2/component/layout/grid/grid.component.ts"
},
{
"replace": "src/app/_modules/layout/header/header.component.ts",
"with": "src/vniigaz-v2/component/layout/header/header.component.ts"
@ -143,6 +147,10 @@
"replace": "src/environments/environment.ts",
"with": "src/environments/vniigaz-v2.env.prod.ts"
},
{
"replace": "src/app/_modules/layout/grid/grid.component.ts",
"with": "src/vniigaz-v2/component/layout/grid/grid.component.ts"
},
{
"replace": "src/app/_modules/layout/header/header.component.ts",
"with": "src/vniigaz-v2/component/layout/header/header.component.ts"

View File

@ -0,0 +1,19 @@
<router-outlet name="auth"></router-outlet>
<router-outlet name="slider"></router-outlet>
<div class="wrapper" [class.this-root-page] = "isRootPage">
<header class="space"></header>
<jumbotron></jumbotron>
<div class="space content-sapce">
<div class="content-grid layout-corral">
<left-content></left-content>
<div class="main-content">
<router-outlet></router-outlet>
</div>
<right-content></right-content>
</div>
</div>
<footer class="space"></footer>
</div>
<fullscreen-gallery></fullscreen-gallery>
<cms-dialog></cms-dialog>

View File

@ -0,0 +1 @@

View File

@ -0,0 +1,39 @@
import {Component} from '@angular/core';
import {Subscription} from "rxjs";
import {ListsService} from "@app/_services";
import { PagesService } from '@app/_services/pages.service';
@Component({
selector: 'grid',
templateUrl: 'grid.component.html',
styleUrls: ['grid.component.scss']
})
export class GridComponent {
public classActive = '';
public bright: number = 150;
public contrast: number = 100;
subscription?: Subscription;
constructor(
private listsService: ListsService, private pagesService: PagesService
) {
}
ngOnInit() {
this.subscription = this.listsService.result('class').subscribe(val => {
this.classActive = val;
});
}
ngOnDestroy() {
this.subscription?.unsubscribe();
}
get isRootPage(){
return this.pagesService.currentPage && this.pagesService.currentPage.parents && this.pagesService.currentPage.parents.data.length == 0
}
}

View File

@ -135,6 +135,18 @@ jumbotron{
}
}
.this-root-page{
.content-sapce{
.content-grid{
justify-content: center;
right-content{
display: none;
}
};
}
}
footer{
background-color: var(--prime-act);
align-self: stretch;