build: Use prettier for typescript
Stop ignoring .ts files in prettier and fix existing issues.
This commit is contained in:
@@ -8,11 +8,10 @@ import { Injectable } from '@angular/core';
|
||||
providedIn: 'root'
|
||||
})
|
||||
export class ThemeManagerService {
|
||||
|
||||
/** Stylesheet class for the theme of the application. */
|
||||
private themeManagerClass = 'theme-manager';
|
||||
|
||||
constructor() { }
|
||||
constructor() {}
|
||||
|
||||
/**
|
||||
* Sets a new theme for the application.
|
||||
@@ -56,5 +55,4 @@ export class ThemeManagerService {
|
||||
document.head.appendChild(linkElement);
|
||||
return linkElement;
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
@@ -8,9 +8,8 @@ describe('ThemePickerComponent', () => {
|
||||
|
||||
beforeEach(async(() => {
|
||||
TestBed.configureTestingModule({
|
||||
declarations: [ ThemePickerComponent ]
|
||||
})
|
||||
.compileComponents();
|
||||
declarations: [ThemePickerComponent]
|
||||
}).compileComponents();
|
||||
}));
|
||||
|
||||
beforeEach(() => {
|
||||
|
||||
@@ -19,7 +19,6 @@ import { ThemeStorageService } from './theme-storage.service';
|
||||
encapsulation: ViewEncapsulation.None
|
||||
})
|
||||
export class ThemePickerComponent implements OnInit {
|
||||
|
||||
/** Default theme for the application. */
|
||||
currentTheme: Theme = {
|
||||
href: 'denim-yellowgreen.css',
|
||||
@@ -41,7 +40,7 @@ export class ThemePickerComponent implements OnInit {
|
||||
href: 'indigo-pink.css',
|
||||
primary: '#3F51B5',
|
||||
accent: '#E91E63',
|
||||
isDark: false,
|
||||
isDark: false
|
||||
},
|
||||
{
|
||||
href: 'deeppurple-amber.css',
|
||||
@@ -66,7 +65,7 @@ export class ThemePickerComponent implements OnInit {
|
||||
/**
|
||||
* @param {ThemeStorageService} themeStorageService Theme Storage Service.
|
||||
*/
|
||||
constructor(public themeStorageService: ThemeStorageService) { }
|
||||
constructor(public themeStorageService: ThemeStorageService) {}
|
||||
|
||||
/**
|
||||
* Initializes the theme for the application.
|
||||
@@ -86,5 +85,4 @@ export class ThemePickerComponent implements OnInit {
|
||||
this.currentTheme = theme;
|
||||
this.themeStorageService.installTheme(theme);
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
/** Angular Imports */
|
||||
import {Injectable, EventEmitter} from '@angular/core';
|
||||
import { Injectable, EventEmitter } from '@angular/core';
|
||||
|
||||
/** Custom Model */
|
||||
import { Theme } from './theme.model';
|
||||
@@ -14,7 +14,6 @@ import { ThemeManagerService } from './theme-manager.service';
|
||||
providedIn: 'root'
|
||||
})
|
||||
export class ThemeStorageService {
|
||||
|
||||
/** Key to store current theme of application in local storage. */
|
||||
private themeStorageKey = 'mifosXTheme';
|
||||
/** Theme update event. */
|
||||
@@ -63,5 +62,4 @@ export class ThemeStorageService {
|
||||
}
|
||||
this.storeTheme(theme);
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user