feat: add custom themes (#74)

Add custom themes based on logo of Mifos

Fixes #73
This commit is contained in:
Abhay Chawla
2018-06-28 23:00:44 +05:30
committed by GitHub
parent b809d9d50f
commit 46a51073be
8 changed files with 150 additions and 4 deletions
@@ -9,6 +9,7 @@
<div class="mifosx-theme-picker-swatch">
<mat-icon class="mifosx-theme-chosen-icon" *ngIf="currentTheme.href === theme.href">check_circle</mat-icon>
<div class="mifosx-theme-picker-primary" [style.background]="theme.primary"></div>
<div class="mifosx-theme-picker-accent" [style.background]="theme.accent"></div>
</div>
</div>
</mat-grid-tile>
@@ -17,7 +17,7 @@ export class ThemePickerComponent implements OnInit {
primary: '#3F51B5',
accent: '#E91E63',
isDark: false,
isDefault: true,
isDefault: true
};
themes = [
this.currentTheme,
@@ -25,20 +25,32 @@ export class ThemePickerComponent implements OnInit {
href: 'deeppurple-amber.css',
primary: '#673AB7',
accent: '#FFC107',
isDark: false,
isDark: false
},
{
href: 'pink-bluegrey.css',
primary: '#E91E63',
accent: '#607D8B',
isDark: true,
isDark: true
},
{
href: 'purple-green.css',
primary: '#9C27B0',
accent: '#4CAF50',
isDark: true,
isDark: true
},
{
href: 'denim-yellowgreen.css',
primary: '#1074B9',
accent: '#B4D575',
isDark: false
},
{
href: 'pictonblue-yellowgreen.css',
primary: '#1DAEEC',
accent: '#B4D575',
isDark: false
}
];
constructor(public themeManagerService: ThemeManagerService,
+11
View File
@@ -5,4 +5,15 @@
</div>
</div> -->
<div class="button-row">
<button mat-raised-button>Basic</button>
<button mat-raised-button color="primary">Primary</button>
<button mat-raised-button color="accent">Accent</button>
<button mat-raised-button color="warn">Warn</button>
<button mat-raised-button disabled>Disabled</button>
<a mat-raised-button routerLink=".">Link</a>
</div>
<br>
<br>
<img class="logo" src="assets/images/mifos_lg-logo.jpg"/>
+6
View File
@@ -7,3 +7,9 @@
// font-size: 1.2rem;
// quotes: "« " " »";
// }
.button-row {
display: flex;
align-items: center;
justify-content: space-around;
}
+2
View File
@@ -4,6 +4,7 @@ import { CommonModule } from '@angular/common';
import { TranslateModule } from '@ngx-translate/core';
import { NgxChartsModule } from '@swimlane/ngx-charts';
import { CoreModule } from '../core/core.module';
import { SharedModule } from '../shared';
import { HomeRoutingModule } from './home-routing.module';
import { HomeComponent } from './home.component';
@@ -13,6 +14,7 @@ import { DashboardComponent } from './dashboard/dashboard.component';
@NgModule({
imports: [
CommonModule,
CoreModule,
TranslateModule,
NgxChartsModule,
SharedModule,