mirror of
https://github.com/akveo/ngx-admin.git
synced 2025-12-17 16:00:14 +01:00
pageTop -> baPageTop
This commit is contained in:
parent
12a1056c12
commit
fd8f21aaff
8 changed files with 15 additions and 15 deletions
|
|
@ -1,7 +1,7 @@
|
||||||
import {Component, ViewEncapsulation} from '@angular/core';
|
import {Component, ViewEncapsulation} from '@angular/core';
|
||||||
import {RouteConfig} from '@angular/router-deprecated';
|
import {RouteConfig} from '@angular/router-deprecated';
|
||||||
|
|
||||||
import {PageTop, BaContentTop, Sidebar, BaBackTop} from '../theme/components';
|
import {BaPageTop, BaContentTop, Sidebar, BaBackTop} from '../theme/components';
|
||||||
|
|
||||||
import {Dashboard} from './dashboard';
|
import {Dashboard} from './dashboard';
|
||||||
import {Ui} from './ui';
|
import {Ui} from './ui';
|
||||||
|
|
@ -14,10 +14,10 @@ import {Tables} from './tables';
|
||||||
selector: 'pages',
|
selector: 'pages',
|
||||||
encapsulation: ViewEncapsulation.None,
|
encapsulation: ViewEncapsulation.None,
|
||||||
styles: [],
|
styles: [],
|
||||||
directives: [PageTop, Sidebar, BaContentTop, BaBackTop],
|
directives: [BaPageTop, Sidebar, BaContentTop, BaBackTop],
|
||||||
template: `
|
template: `
|
||||||
<sidebar></sidebar>
|
<sidebar></sidebar>
|
||||||
<page-top></page-top>
|
<ba-page-top></ba-page-top>
|
||||||
<div class="al-main">
|
<div class="al-main">
|
||||||
<div class="al-content">
|
<div class="al-content">
|
||||||
<ba-content-top></ba-content-top>
|
<ba-content-top></ba-content-top>
|
||||||
|
|
|
||||||
|
|
@ -4,7 +4,7 @@ import {BaMsgCenterService} from './baMsgCenter.service';
|
||||||
import {BaProfilePicturePipe} from '../../pipes';
|
import {BaProfilePicturePipe} from '../../pipes';
|
||||||
|
|
||||||
@Component({
|
@Component({
|
||||||
selector: 'msg-center',
|
selector: 'ba-msg-center',
|
||||||
providers: [BaMsgCenterService],
|
providers: [BaMsgCenterService],
|
||||||
styles: [require('./baMsgCenter.scss')],
|
styles: [require('./baMsgCenter.scss')],
|
||||||
template: require('./baMsgCenter.html'),
|
template: require('./baMsgCenter.html'),
|
||||||
|
|
|
||||||
|
|
@ -6,17 +6,17 @@ import {BaMsgCenter} from '../../components/baMsgCenter';
|
||||||
import {BaScrollPosition} from '../../directives';
|
import {BaScrollPosition} from '../../directives';
|
||||||
|
|
||||||
@Component({
|
@Component({
|
||||||
selector: 'page-top',
|
selector: 'ba-page-top',
|
||||||
styles: [require('./pageTop.scss')],
|
styles: [require('./baPageTop.scss')],
|
||||||
template: require('./pageTop.html'),
|
template: require('./baPageTop.html'),
|
||||||
directives: [BaMsgCenter, BaScrollPosition],
|
directives: [BaMsgCenter, BaScrollPosition],
|
||||||
pipes: [BaProfilePicturePipe],
|
pipes: [BaProfilePicturePipe],
|
||||||
encapsulation: ViewEncapsulation.None
|
encapsulation: ViewEncapsulation.None
|
||||||
})
|
})
|
||||||
export class PageTop {
|
export class BaPageTop {
|
||||||
|
|
||||||
isScrolled:Boolean = false;
|
public isScrolled:boolean = false;
|
||||||
isMenuCollapsed:boolean = false;
|
public isMenuCollapsed:boolean = false;
|
||||||
|
|
||||||
constructor(private _state:AppState) {
|
constructor(private _state:AppState) {
|
||||||
this._state.subscribe('menu.isCollapsed', (isCollapsed) => {
|
this._state.subscribe('menu.isCollapsed', (isCollapsed) => {
|
||||||
|
|
@ -24,12 +24,12 @@ export class PageTop {
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
|
|
||||||
toggleMenu() {
|
public toggleMenu() {
|
||||||
this.isMenuCollapsed = !this.isMenuCollapsed;
|
this.isMenuCollapsed = !this.isMenuCollapsed;
|
||||||
this._state.notifyDataChanged('menu.isCollapsed', this.isMenuCollapsed);
|
this._state.notifyDataChanged('menu.isCollapsed', this.isMenuCollapsed);
|
||||||
}
|
}
|
||||||
|
|
||||||
scrolledChanged(isScrolled) {
|
public scrolledChanged(isScrolled) {
|
||||||
this.isScrolled = isScrolled;
|
this.isScrolled = isScrolled;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
@ -20,6 +20,6 @@
|
||||||
<li class="dropdown-item"><a href class="signout"><i class="fa fa-power-off"></i>Sign out</a></li>
|
<li class="dropdown-item"><a href class="signout"><i class="fa fa-power-off"></i>Sign out</a></li>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
<msg-center></msg-center>
|
<ba-msg-center></ba-msg-center>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
1
src/app/theme/components/baPageTop/index.ts
Normal file
1
src/app/theme/components/baPageTop/index.ts
Normal file
|
|
@ -0,0 +1 @@
|
||||||
|
export * from './baPageTop.component.ts';
|
||||||
|
|
@ -1,4 +1,4 @@
|
||||||
export * from './pageTop';
|
export * from './baPageTop';
|
||||||
export * from './baMsgCenter';
|
export * from './baMsgCenter';
|
||||||
export * from './sidebar';
|
export * from './sidebar';
|
||||||
export * from './baContentTop';
|
export * from './baContentTop';
|
||||||
|
|
|
||||||
|
|
@ -1 +0,0 @@
|
||||||
export * from './pageTop.component.ts';
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue