Minor progress on fixing no-implicit any issues

This commit is contained in:
Torkel Ödegaard
2019-03-19 18:24:09 +01:00
parent a1a60ceae0
commit 42c87141a5
19 changed files with 75 additions and 92 deletions

View File

@@ -7,7 +7,7 @@ import { getNavModel } from 'app/core/selectors/navModel';
import { getApiKeys, getApiKeysCount } from './state/selectors';
import { loadApiKeys, deleteApiKey, setSearchQuery, addApiKey } from './state/actions';
import Page from 'app/core/components/Page/Page';
import SlideDown from 'app/core/components/Animations/SlideDown';
import { SlideDown } from 'app/core/components/Animations/SlideDown';
import ApiKeysAddedModal from './ApiKeysAddedModal';
import config from 'app/core/config';
import appEvents from 'app/core/app_events';

View File

@@ -1,6 +1,6 @@
import React, { PureComponent } from 'react';
import { Tooltip } from '@grafana/ui';
import SlideDown from 'app/core/components/Animations/SlideDown';
import { SlideDown } from 'app/core/components/Animations/SlideDown';
import { StoreState, FolderInfo } from 'app/types';
import { DashboardAcl, PermissionLevel, NewDashboardAclItem } from 'app/types/acl';
import {

View File

@@ -111,12 +111,12 @@ export class PanelModel {
cachedPluginOptions?: any;
legend?: { show: boolean };
constructor(model) {
constructor(model: any) {
this.events = new Emitter();
// copy properties from persisted model
for (const property in model) {
this[property] = model[property];
(this as any)[property] = model[property];
}
// defaults
@@ -150,7 +150,7 @@ export class PanelModel {
}
}
getOptions(panelDefaults) {
getOptions(panelDefaults: any) {
return _.defaultsDeep(this.options || {}, panelDefaults);
}
@@ -227,7 +227,7 @@ export class PanelModel {
}
return {
...acc,
[property]: this[property],
[property]: (this as any)[property],
};
}, {});
}
@@ -236,7 +236,7 @@ export class PanelModel {
const prevOptions = this.cachedPluginOptions[pluginId] || {};
Object.keys(prevOptions).map(property => {
this[property] = prevOptions[property];
(this as any)[property] = prevOptions[property];
});
}
@@ -252,7 +252,7 @@ export class PanelModel {
continue;
}
delete this[key];
delete (this as any)[key];
}
this.cachedPluginOptions[oldPluginId] = oldOptions;

View File

@@ -3,7 +3,7 @@ import { hot } from 'react-hot-loader';
import { connect } from 'react-redux';
import Page from 'app/core/components/Page/Page';
import { Tooltip } from '@grafana/ui';
import SlideDown from 'app/core/components/Animations/SlideDown';
import { SlideDown } from 'app/core/components/Animations/SlideDown';
import { getNavModel } from 'app/core/selectors/navModel';
import { NavModel, StoreState, FolderState } from 'app/types';
import { DashboardAcl, PermissionLevel, NewDashboardAclItem } from 'app/types/acl';

View File

@@ -1,6 +1,6 @@
import React, { PureComponent } from 'react';
import { connect } from 'react-redux';
import SlideDown from 'app/core/components/Animations/SlideDown';
import { SlideDown } from 'app/core/components/Animations/SlideDown';
import { Tooltip } from '@grafana/ui';
import { TeamGroup } from '../../types';
import { addTeamGroup, loadTeamGroups, removeTeamGroup } from './state/actions';

View File

@@ -1,6 +1,6 @@
import React, { PureComponent } from 'react';
import { connect } from 'react-redux';
import SlideDown from 'app/core/components/Animations/SlideDown';
import { SlideDown } from 'app/core/components/Animations/SlideDown';
import { UserPicker } from 'app/core/components/Select/UserPicker';
import { TagBadge } from 'app/core/components/TagFilter/TagBadge';
import { TeamMember, User } from 'app/types';