mirror of
https://github.com/richard-loafle/fuse-angular.git
synced 2024-10-30 09:18:46 +00:00
(eslint) Fixed linting issues
This commit is contained in:
parent
3c0e326113
commit
6bcd04b799
|
@ -61,9 +61,9 @@ export class FuseDateRangeComponent implements ControlValueAccessor, OnInit, OnD
|
||||||
private _viewContainerRef: ViewContainerRef
|
private _viewContainerRef: ViewContainerRef
|
||||||
)
|
)
|
||||||
{
|
{
|
||||||
this._onChange = () => {
|
this._onChange = (): void => {
|
||||||
};
|
};
|
||||||
this._onTouched = () => {
|
this._onTouched = (): void => {
|
||||||
};
|
};
|
||||||
this.dateFormat = 'DD/MM/YYYY';
|
this.dateFormat = 'DD/MM/YYYY';
|
||||||
this.timeFormat = '12';
|
this.timeFormat = '12';
|
||||||
|
@ -361,7 +361,7 @@ export class FuseDateRangeComponent implements ControlValueAccessor, OnInit, OnD
|
||||||
this._unsubscribeAll.complete();
|
this._unsubscribeAll.complete();
|
||||||
|
|
||||||
// @ TODO: Workaround until "angular/issues/20007" resolved
|
// @ TODO: Workaround until "angular/issues/20007" resolved
|
||||||
this.writeValue = () => {
|
this.writeValue = (): void => {
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -389,7 +389,7 @@ export class FuseScrollbarDirective implements OnChanges, OnInit, OnDestroy
|
||||||
|
|
||||||
const cosParameter = (oldValue - value) / 2;
|
const cosParameter = (oldValue - value) / 2;
|
||||||
|
|
||||||
const step = (newTimestamp: number) => {
|
const step = (newTimestamp: number): void => {
|
||||||
scrollCount += Math.PI / (speed / (newTimestamp - oldTimestamp));
|
scrollCount += Math.PI / (speed / (newTimestamp - oldTimestamp));
|
||||||
newValue = Math.round(value + cosParameter + cosParameter * Math.cos(scrollCount));
|
newValue = Math.round(value + cosParameter + cosParameter * Math.cos(scrollCount));
|
||||||
|
|
||||||
|
|
|
@ -6,6 +6,7 @@ import { InitialDataResolver } from 'app/app.resolvers';
|
||||||
|
|
||||||
// @formatter:off
|
// @formatter:off
|
||||||
/* eslint-disable max-len */
|
/* eslint-disable max-len */
|
||||||
|
/* eslint-disable @typescript-eslint/explicit-function-return-type */
|
||||||
export const appRoutes: Route[] = [
|
export const appRoutes: Route[] = [
|
||||||
|
|
||||||
// Redirect empty path to '/dashboards/project'
|
// Redirect empty path to '/dashboards/project'
|
||||||
|
|
|
@ -1,6 +1,6 @@
|
||||||
import { NgModule } from '@angular/core';
|
import { NgModule } from '@angular/core';
|
||||||
import { RouterModule } from '@angular/router';
|
import { RouterModule } from '@angular/router';
|
||||||
import { Overlay } from '@angular/cdk/overlay';
|
import { BlockScrollStrategy, Overlay } from '@angular/cdk/overlay';
|
||||||
import { MAT_AUTOCOMPLETE_SCROLL_STRATEGY, MatAutocompleteModule } from '@angular/material/autocomplete';
|
import { MAT_AUTOCOMPLETE_SCROLL_STRATEGY, MatAutocompleteModule } from '@angular/material/autocomplete';
|
||||||
import { MatButtonModule } from '@angular/material/button';
|
import { MatButtonModule } from '@angular/material/button';
|
||||||
import { MatFormFieldModule } from '@angular/material/form-field';
|
import { MatFormFieldModule } from '@angular/material/form-field';
|
||||||
|
@ -28,7 +28,7 @@ import { SearchComponent } from 'app/layout/common/search/search.component';
|
||||||
providers : [
|
providers : [
|
||||||
{
|
{
|
||||||
provide : MAT_AUTOCOMPLETE_SCROLL_STRATEGY,
|
provide : MAT_AUTOCOMPLETE_SCROLL_STRATEGY,
|
||||||
useFactory: (overlay: Overlay) => () => overlay.scrollStrategies.block(),
|
useFactory: (overlay: Overlay) => (): BlockScrollStrategy => overlay.scrollStrategies.block(),
|
||||||
deps : [Overlay]
|
deps : [Overlay]
|
||||||
}
|
}
|
||||||
]
|
]
|
||||||
|
|
|
@ -295,12 +295,12 @@ export class ContactsMockApi
|
||||||
const reader = new FileReader();
|
const reader = new FileReader();
|
||||||
|
|
||||||
// Resolve the promise on success
|
// Resolve the promise on success
|
||||||
reader.onload = () => {
|
reader.onload = (): void => {
|
||||||
resolve(reader.result);
|
resolve(reader.result);
|
||||||
};
|
};
|
||||||
|
|
||||||
// Reject the promise on error
|
// Reject the promise on error
|
||||||
reader.onerror = (e) => {
|
reader.onerror = (e): void => {
|
||||||
reject(e);
|
reject(e);
|
||||||
};
|
};
|
||||||
|
|
||||||
|
|
|
@ -243,7 +243,7 @@ export class CalendarComponent implements OnInit, AfterViewInit, OnDestroy
|
||||||
day : 'numeric',
|
day : 'numeric',
|
||||||
omitCommas: true
|
omitCommas: true
|
||||||
},
|
},
|
||||||
columnHeaderHtml : date => `<span class="fc-weekday">${moment(date).format('ddd')}</span>
|
columnHeaderHtml : (date): string => `<span class="fc-weekday">${moment(date).format('ddd')}</span>
|
||||||
<span class="fc-date">${moment(date).format('D')}</span>`,
|
<span class="fc-date">${moment(date).format('D')}</span>`,
|
||||||
slotDuration : '01:00:00',
|
slotDuration : '01:00:00',
|
||||||
slotLabelFormat : this.eventTimeFormat
|
slotLabelFormat : this.eventTimeFormat
|
||||||
|
|
|
@ -330,12 +330,12 @@ export class NotesDetailsComponent implements OnInit, OnDestroy
|
||||||
const reader = new FileReader();
|
const reader = new FileReader();
|
||||||
|
|
||||||
// Resolve the promise on success
|
// Resolve the promise on success
|
||||||
reader.onload = () => {
|
reader.onload = (): void => {
|
||||||
resolve(reader.result);
|
resolve(reader.result);
|
||||||
};
|
};
|
||||||
|
|
||||||
// Reject the promise on error
|
// Reject the promise on error
|
||||||
reader.onerror = (e) => {
|
reader.onerror = (e): void => {
|
||||||
reject(e);
|
reject(e);
|
||||||
};
|
};
|
||||||
|
|
||||||
|
|
|
@ -70,10 +70,10 @@ export class AnalyticsComponent implements OnInit, OnDestroy
|
||||||
window['Apex'] = {
|
window['Apex'] = {
|
||||||
chart: {
|
chart: {
|
||||||
events: {
|
events: {
|
||||||
mounted: (chart: any, options?: any) => {
|
mounted: (chart: any, options?: any): void => {
|
||||||
this._fixSvgFill(chart.el);
|
this._fixSvgFill(chart.el);
|
||||||
},
|
},
|
||||||
updated: (chart: any, options?: any) => {
|
updated: (chart: any, options?: any): void => {
|
||||||
this._fixSvgFill(chart.el);
|
this._fixSvgFill(chart.el);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -234,8 +234,8 @@ export class AnalyticsComponent implements OnInit, OnDestroy
|
||||||
axisBorder: {
|
axisBorder: {
|
||||||
show: false
|
show: false
|
||||||
},
|
},
|
||||||
min : min => min - 750,
|
min : (min): number => min - 750,
|
||||||
max : max => max + 250,
|
max : (max): number => max + 250,
|
||||||
tickAmount: 5,
|
tickAmount: 5,
|
||||||
show : false
|
show : false
|
||||||
}
|
}
|
||||||
|
@ -274,7 +274,7 @@ export class AnalyticsComponent implements OnInit, OnDestroy
|
||||||
},
|
},
|
||||||
yaxis : {
|
yaxis : {
|
||||||
labels: {
|
labels: {
|
||||||
formatter: val => val.toString()
|
formatter: (val): string => val.toString()
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
};
|
};
|
||||||
|
@ -312,7 +312,7 @@ export class AnalyticsComponent implements OnInit, OnDestroy
|
||||||
},
|
},
|
||||||
yaxis : {
|
yaxis : {
|
||||||
labels: {
|
labels: {
|
||||||
formatter: val => val.toString()
|
formatter: (val): string => val.toString()
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
};
|
};
|
||||||
|
@ -350,7 +350,7 @@ export class AnalyticsComponent implements OnInit, OnDestroy
|
||||||
},
|
},
|
||||||
yaxis : {
|
yaxis : {
|
||||||
labels: {
|
labels: {
|
||||||
formatter: val => val.toString()
|
formatter: (val): string => val.toString()
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
};
|
};
|
||||||
|
@ -426,8 +426,8 @@ export class AnalyticsComponent implements OnInit, OnDestroy
|
||||||
colors: 'var(--fuse-text-secondary)'
|
colors: 'var(--fuse-text-secondary)'
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
max : max => max + 250,
|
max : (max): number => max + 250,
|
||||||
min : min => min - 250,
|
min : (min): number => min - 250,
|
||||||
show : false,
|
show : false,
|
||||||
tickAmount: 5
|
tickAmount: 5
|
||||||
}
|
}
|
||||||
|
@ -481,7 +481,7 @@ export class AnalyticsComponent implements OnInit, OnDestroy
|
||||||
custom : ({
|
custom : ({
|
||||||
seriesIndex,
|
seriesIndex,
|
||||||
w
|
w
|
||||||
}) => `<div class="flex items-center h-8 min-h-8 max-h-8 px-3">
|
}): string => `<div class="flex items-center h-8 min-h-8 max-h-8 px-3">
|
||||||
<div class="w-3 h-3 rounded-full" style="background-color: ${w.config.colors[seriesIndex]};"></div>
|
<div class="w-3 h-3 rounded-full" style="background-color: ${w.config.colors[seriesIndex]};"></div>
|
||||||
<div class="ml-2 text-md leading-none">${w.config.labels[seriesIndex]}:</div>
|
<div class="ml-2 text-md leading-none">${w.config.labels[seriesIndex]}:</div>
|
||||||
<div class="ml-2 text-md font-bold leading-none">${w.config.series[seriesIndex]}%</div>
|
<div class="ml-2 text-md font-bold leading-none">${w.config.series[seriesIndex]}%</div>
|
||||||
|
@ -537,7 +537,7 @@ export class AnalyticsComponent implements OnInit, OnDestroy
|
||||||
custom : ({
|
custom : ({
|
||||||
seriesIndex,
|
seriesIndex,
|
||||||
w
|
w
|
||||||
}) => `<div class="flex items-center h-8 min-h-8 max-h-8 px-3">
|
}): string => `<div class="flex items-center h-8 min-h-8 max-h-8 px-3">
|
||||||
<div class="w-3 h-3 rounded-full" style="background-color: ${w.config.colors[seriesIndex]};"></div>
|
<div class="w-3 h-3 rounded-full" style="background-color: ${w.config.colors[seriesIndex]};"></div>
|
||||||
<div class="ml-2 text-md leading-none">${w.config.labels[seriesIndex]}:</div>
|
<div class="ml-2 text-md leading-none">${w.config.labels[seriesIndex]}:</div>
|
||||||
<div class="ml-2 text-md font-bold leading-none">${w.config.series[seriesIndex]}%</div>
|
<div class="ml-2 text-md font-bold leading-none">${w.config.series[seriesIndex]}%</div>
|
||||||
|
@ -593,7 +593,7 @@ export class AnalyticsComponent implements OnInit, OnDestroy
|
||||||
custom : ({
|
custom : ({
|
||||||
seriesIndex,
|
seriesIndex,
|
||||||
w
|
w
|
||||||
}) => `<div class="flex items-center h-8 min-h-8 max-h-8 px-3">
|
}): string => `<div class="flex items-center h-8 min-h-8 max-h-8 px-3">
|
||||||
<div class="w-3 h-3 rounded-full" style="background-color: ${w.config.colors[seriesIndex]};"></div>
|
<div class="w-3 h-3 rounded-full" style="background-color: ${w.config.colors[seriesIndex]};"></div>
|
||||||
<div class="ml-2 text-md leading-none">${w.config.labels[seriesIndex]}:</div>
|
<div class="ml-2 text-md leading-none">${w.config.labels[seriesIndex]}:</div>
|
||||||
<div class="ml-2 text-md font-bold leading-none">${w.config.series[seriesIndex]}%</div>
|
<div class="ml-2 text-md font-bold leading-none">${w.config.series[seriesIndex]}%</div>
|
||||||
|
@ -649,7 +649,7 @@ export class AnalyticsComponent implements OnInit, OnDestroy
|
||||||
custom : ({
|
custom : ({
|
||||||
seriesIndex,
|
seriesIndex,
|
||||||
w
|
w
|
||||||
}) => `<div class="flex items-center h-8 min-h-8 max-h-8 px-3">
|
}): string => `<div class="flex items-center h-8 min-h-8 max-h-8 px-3">
|
||||||
<div class="w-3 h-3 rounded-full" style="background-color: ${w.config.colors[seriesIndex]};"></div>
|
<div class="w-3 h-3 rounded-full" style="background-color: ${w.config.colors[seriesIndex]};"></div>
|
||||||
<div class="ml-2 text-md leading-none">${w.config.labels[seriesIndex]}:</div>
|
<div class="ml-2 text-md leading-none">${w.config.labels[seriesIndex]}:</div>
|
||||||
<div class="ml-2 text-md font-bold leading-none">${w.config.series[seriesIndex]}%</div>
|
<div class="ml-2 text-md font-bold leading-none">${w.config.series[seriesIndex]}%</div>
|
||||||
|
|
|
@ -58,10 +58,10 @@ export class ProjectComponent implements OnInit, OnDestroy
|
||||||
window['Apex'] = {
|
window['Apex'] = {
|
||||||
chart: {
|
chart: {
|
||||||
events: {
|
events: {
|
||||||
mounted: (chart: any, options?: any) => {
|
mounted: (chart: any, options?: any): void => {
|
||||||
this._fixSvgFill(chart.el);
|
this._fixSvgFill(chart.el);
|
||||||
},
|
},
|
||||||
updated: (chart: any, options?: any) => {
|
updated: (chart: any, options?: any): void => {
|
||||||
this._fixSvgFill(chart.el);
|
this._fixSvgFill(chart.el);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -327,7 +327,7 @@ export class ProjectComponent implements OnInit, OnDestroy
|
||||||
categories: this.data.budgetDistribution.categories
|
categories: this.data.budgetDistribution.categories
|
||||||
},
|
},
|
||||||
yaxis : {
|
yaxis : {
|
||||||
max : (max: number) => parseInt((max + 10).toFixed(0), 10),
|
max : (max: number): number => parseInt((max + 10).toFixed(0), 10),
|
||||||
tickAmount: 7
|
tickAmount: 7
|
||||||
}
|
}
|
||||||
};
|
};
|
||||||
|
@ -360,7 +360,7 @@ export class ProjectComponent implements OnInit, OnDestroy
|
||||||
},
|
},
|
||||||
yaxis : {
|
yaxis : {
|
||||||
labels: {
|
labels: {
|
||||||
formatter: val => `$${val}`
|
formatter: (val): string => `$${val}`
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
};
|
};
|
||||||
|
@ -393,7 +393,7 @@ export class ProjectComponent implements OnInit, OnDestroy
|
||||||
},
|
},
|
||||||
yaxis : {
|
yaxis : {
|
||||||
labels: {
|
labels: {
|
||||||
formatter: val => `$${val}`
|
formatter: (val): string => `$${val}`
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
};
|
};
|
||||||
|
@ -426,7 +426,7 @@ export class ProjectComponent implements OnInit, OnDestroy
|
||||||
},
|
},
|
||||||
yaxis : {
|
yaxis : {
|
||||||
labels: {
|
labels: {
|
||||||
formatter: val => `$${val}`
|
formatter: (val): string => `$${val}`
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
};
|
};
|
||||||
|
|
Loading…
Reference in New Issue
Block a user