-
+
+
diff --git a/src/app/pages/pages.component.ts b/src/app/pages/pages.component.ts
index 95c2f20..b809fef 100644
--- a/src/app/pages/pages.component.ts
+++ b/src/app/pages/pages.component.ts
@@ -1,7 +1,7 @@
import { Component, AfterViewInit, ElementRef, Renderer, ViewChild, OnDestroy, OnInit, NgZone } from '@angular/core';
import { ScrollPanel } from 'primeng/primeng';
import { Router } from '@angular/router';
-
+import { fadeAnimation } from './pages-animation';
enum MenuOrientation {
STATIC,
OVERLAY,
@@ -12,7 +12,8 @@ enum MenuOrientation {
@Component({
selector: 'of-pages',
templateUrl: './pages.component.html',
- styleUrls: ['./pages.component.scss']
+ styleUrls: ['./pages.component.scss'],
+ animations: [ fadeAnimation ]
})
export class PagesComponent implements AfterViewInit, OnDestroy, OnInit {
layoutCompact = true;
@@ -59,7 +60,8 @@ export class PagesComponent implements AfterViewInit, OnDestroy, OnInit {
rippleMouseDownListener: any;
- constructor(public renderer: Renderer, public zone: NgZone, private router: Router) { }
+ constructor(public renderer: Renderer, public zone: NgZone, private router: Router) {
+ }
ngOnInit() {
if (this.isAuthRouteActivated()) {
@@ -323,6 +325,10 @@ export class PagesComponent implements AfterViewInit, OnDestroy, OnInit {
themeLink.href = 'assets/theme/theme-' + theme + '.css';
layoutLink.href = 'assets/layout/css/layout-' + theme + '.css';
-}
+ }
+
+ prepRouteState(outlet: any) {
+ return outlet.activatedRouteData['animation'] || 'firstPage';
+ }
}
diff --git a/src/packages/probe/component/detail/detail.component.ts b/src/packages/probe/component/detail/detail.component.ts
index 2fcb6af..fb1c165 100644
--- a/src/packages/probe/component/detail/detail.component.ts
+++ b/src/packages/probe/component/detail/detail.component.ts
@@ -30,7 +30,6 @@ export class DetailComponent implements OnInit, AfterContentInit, OnDestroy {
constructor(
private route: ActivatedRoute,
- private router: Router,
private detailStore: Store
,
private modifyStore: Store,
private confirmationService: ConfirmationService,
@@ -88,7 +87,7 @@ export class DetailComponent implements OnInit, AfterContentInit, OnDestroy {
icon: 'fa fa-trash',
message: 'Are you sure to remove this Probe?',
accept: () => {
- this.router.navigate(['probes/list']);
+ // this.router.navigate(['probes/list']);
},
reject: () => {
}
diff --git a/src/packages/probe/component/list/list.component.ts b/src/packages/probe/component/list/list.component.ts
index 7fcf0e7..6dbc58a 100644
--- a/src/packages/probe/component/list/list.component.ts
+++ b/src/packages/probe/component/list/list.component.ts
@@ -1,6 +1,4 @@
import { Component, OnInit, AfterViewInit, AfterContentInit, ViewChild, OnDestroy, Output, EventEmitter } from '@angular/core';
-import { Router } from '@angular/router';
-
import { Store, select } from '@ngrx/store';
import { RPCClientError } from '@loafer/ng-rpc/protocol';
@@ -24,7 +22,6 @@ export class ListComponent implements OnInit, AfterContentInit, OnDestroy {
@Output() select = new EventEmitter();
constructor(
- private router: Router,
private store: Store
) {
}