blur theme is now default

This commit is contained in:
nixa 2016-05-17 13:34:52 +03:00
parent 097257b5d7
commit e7595af72c
12 changed files with 44 additions and 9 deletions

View file

@ -43,8 +43,7 @@ export class BaCardBlurHelper {
private _genImageLoadSubject():void {
this.imageLoadSubject = new Subject<void>();
this.image.onerror = () => {
this.imageLoadSubject.error();
this.image.onerror = (err) => {
this.imageLoadSubject.complete();
};
this.image.onload = () => {

View file

@ -1,2 +1,3 @@
export * from './theme.constants'
export * from './theme.configProvider'
export * from './theme.config'

View file

@ -45,6 +45,10 @@ $card-header-font-size: 16px;
background: url($blurredBgUrl);
transition: none;
background-attachment: fixed;
.card-header, .card-footer {
background: transparent;
}
}
.card {

View file

@ -1,3 +1,3 @@
@import 'mixins';
@import 'colorSchemes/mint';
@import 'colorSchemes/blur';
@import 'variables';

View file

@ -0,0 +1,22 @@
import {Injectable} from '@angular/core';
import {BaThemeConfigProvider} from './theme.configProvider';
@Injectable()
export class BaThemeConfig {
constructor(private _baConfig:BaThemeConfigProvider) {
this._config();
}
private _config() {
this._baConfig.changeTheme({blur: true});
this._baConfig.changeColors({
default: 'rgba(#000000, 0.2)',
defaultText: '#ffffff',
dashboard: {
white: '#ffffff',
},
});
}
}

View file

@ -70,4 +70,12 @@ export class BaThemeConfigProvider {
get() {
return this.conf;
}
changeTheme (theme) {
_.merge(this.get().theme, theme);
}
changeColors (colors) {
_.merge(this.get().colors, colors);
}
}