cleanup: removed unused typescript typings import

This commit is contained in:
Torkel Ödegaard
2018-01-04 10:12:02 +01:00
parent c42a232644
commit 27835f373e
97 changed files with 7 additions and 205 deletions

View File

@@ -29,6 +29,8 @@ _.move = function(array, fromIndex, toIndex) {
import { coreModule, registerAngularDirectives } from './core/core'; import { coreModule, registerAngularDirectives } from './core/core';
import { setupAngularRoutes } from './routes/routes'; import { setupAngularRoutes } from './routes/routes';
declare var System: any;
export class GrafanaApp { export class GrafanaApp {
registerFunctions: any; registerFunctions: any;
ngModuleDependencies: any[]; ngModuleDependencies: any[];

View File

@@ -1,5 +1,3 @@
///<reference path="../../headers/common.d.ts" />
import coreModule from 'app/core/core_module'; import coreModule from 'app/core/core_module';
const template = ` const template = `

View File

@@ -1,5 +1,3 @@
///<reference path="../../../headers/common.d.ts" />
import coreModule from '../../core_module'; import coreModule from '../../core_module';
import appEvents from 'app/core/app_events'; import appEvents from 'app/core/app_events';

View File

@@ -1,5 +1,3 @@
///<reference path="../../headers/common.d.ts" />
import _ from 'lodash'; import _ from 'lodash';
import coreModule from 'app/core/core_module'; import coreModule from 'app/core/core_module';
import Drop from 'tether-drop'; import Drop from 'tether-drop';

View File

@@ -1,5 +1,3 @@
///<reference path="../../headers/common.d.ts" />
import coreModule from 'app/core/core_module'; import coreModule from 'app/core/core_module';
import { contextSrv } from 'app/core/services/context_srv'; import { contextSrv } from 'app/core/services/context_srv';

View File

@@ -1,5 +1,3 @@
///<reference path="../../../headers/common.d.ts" />
import _ from 'lodash'; import _ from 'lodash';
export class QueryPartDef { export class QueryPartDef {

View File

@@ -1,5 +1,3 @@
///<reference path="../../../headers/common.d.ts" />
import _ from 'lodash'; import _ from 'lodash';
import $ from 'jquery'; import $ from 'jquery';
import coreModule from 'app/core/core_module'; import coreModule from 'app/core/core_module';

View File

@@ -1,5 +1,3 @@
///<reference path="../../headers/common.d.ts" />
import coreModule from 'app/core/core_module'; import coreModule from 'app/core/core_module';
var template = ` var template = `

View File

@@ -1,5 +1,3 @@
///<reference path="../../headers/common.d.ts" />
import config from 'app/core/config'; import config from 'app/core/config';
import coreModule from '../core_module'; import coreModule from '../core_module';

View File

@@ -1,5 +1,3 @@
///<reference path="../../headers/common.d.ts" />
import _ from 'lodash'; import _ from 'lodash';
import coreModule from '../core_module'; import coreModule from '../core_module';

View File

@@ -1,5 +1,3 @@
///<reference path="../../headers/common.d.ts" />
import angular from 'angular'; import angular from 'angular';
import coreModule from '../core_module'; import coreModule from '../core_module';

View File

@@ -1,5 +1,3 @@
///<reference path="../../headers/common.d.ts" />
import coreModule from '../core_module'; import coreModule from '../core_module';
coreModule.directive('giveFocus', function() { coreModule.directive('giveFocus', function() {

View File

@@ -1,5 +1,3 @@
///<reference path="../../headers/common.d.ts" />
import _ from 'lodash'; import _ from 'lodash';
import angular from 'angular'; import angular from 'angular';
import moment from 'moment'; import moment from 'moment';

View File

@@ -1,5 +1,3 @@
///<reference path="../../headers/common.d.ts" />
import angular from 'angular'; import angular from 'angular';
import _ from 'lodash'; import _ from 'lodash';
import coreModule from 'app/core/core_module'; import coreModule from 'app/core/core_module';

View File

@@ -1,5 +1,3 @@
///<reference path="../../headers/common.d.ts" />
import _ from 'lodash'; import _ from 'lodash';
import coreModule from 'app/core/core_module'; import coreModule from 'app/core/core_module';
import appEvents from 'app/core/app_events'; import appEvents from 'app/core/app_events';

View File

@@ -1,5 +1,3 @@
///<reference path="../../headers/common.d.ts" />
import angular from 'angular'; import angular from 'angular';
import coreModule from '../core_module'; import coreModule from '../core_module';

View File

@@ -1,5 +1,3 @@
///<reference path="../../headers/common.d.ts" />
import _ from 'lodash'; import _ from 'lodash';
import coreModule from 'app/core/core_module'; import coreModule from 'app/core/core_module';
import Drop from 'tether-drop'; import Drop from 'tether-drop';

View File

@@ -1,5 +1,3 @@
///<reference path="../../headers/common.d.ts" />
import coreModule from 'app/core/core_module'; import coreModule from 'app/core/core_module';
import appEvents from 'app/core/app_events'; import appEvents from 'app/core/app_events';

View File

@@ -1,5 +1,3 @@
///<reference path="../../headers/common.d.ts" />
var waitSeconds = 100; var waitSeconds = 100;
var head = document.getElementsByTagName('head')[0]; var head = document.getElementsByTagName('head')[0];

View File

@@ -1,5 +1,3 @@
///<reference path="../../headers/common.d.ts" />
import _ from 'lodash'; import _ from 'lodash';
import moment from 'moment'; import moment from 'moment';

View File

@@ -1,4 +1,4 @@
import EventEmitter from 'eventemitter3'; import { EventEmitter } from 'eventemitter3';
export class Emitter { export class Emitter {
emitter: any; emitter: any;

View File

@@ -1,5 +1,3 @@
///<reference path="../../headers/common.d.ts" />
import _ from 'lodash'; import _ from 'lodash';
import moment from 'moment'; import moment from 'moment';
import * as dateMath from './datemath'; import * as dateMath from './datemath';

View File

@@ -1,5 +1,3 @@
///<reference path="../../headers/common.d.ts" />
import _ from 'lodash'; import _ from 'lodash';
import { ThresholdMapper } from './threshold_mapper'; import { ThresholdMapper } from './threshold_mapper';
import { QueryPart } from 'app/core/components/query_part/query_part'; import { QueryPart } from 'app/core/components/query_part/query_part';

View File

@@ -1,5 +1,3 @@
///<reference path="../../headers/common.d.ts" />
import _ from 'lodash'; import _ from 'lodash';
import { appEvents, coreModule } from 'app/core/core'; import { appEvents, coreModule } from 'app/core/core';

View File

@@ -1,5 +1,3 @@
///<reference path="../../headers/common.d.ts" />
import { coreModule } from 'app/core/core'; import { coreModule } from 'app/core/core';
export class AlertNotificationsListCtrl { export class AlertNotificationsListCtrl {

View File

@@ -1,5 +1,3 @@
///<reference path="../../../headers/common.d.ts" />
import coreModule from 'app/core/core_module'; import coreModule from 'app/core/core_module';
import _ from 'lodash'; import _ from 'lodash';

View File

@@ -1,5 +1,3 @@
///<reference path="../../headers/common.d.ts" />
import _ from 'lodash'; import _ from 'lodash';
import angular from 'angular'; import angular from 'angular';
import coreModule from 'app/core/core_module'; import coreModule from 'app/core/core_module';

View File

@@ -1,5 +1,3 @@
///<reference path="../../headers/common.d.ts" />
import coreModule from 'app/core/core_module'; import coreModule from 'app/core/core_module';
export class AlertingSrv { export class AlertingSrv {

View File

@@ -1,5 +1,3 @@
///<reference path="../../headers/common.d.ts" />
import coreModule from 'app/core/core_module'; import coreModule from 'app/core/core_module';
const template = ` const template = `

View File

@@ -1,5 +1,3 @@
///<reference path="../../../headers/common.d.ts" />
import angular from 'angular'; import angular from 'angular';
import _ from 'lodash'; import _ from 'lodash';

View File

@@ -1,5 +1,3 @@
///<reference path="../../headers/common.d.ts" />
import moment from 'moment'; import moment from 'moment';
import _ from 'lodash'; import _ from 'lodash';
import coreModule from 'app/core/core_module'; import coreModule from 'app/core/core_module';

View File

@@ -1,5 +1,3 @@
///<reference path="../../headers/common.d.ts" />
import coreModule from 'app/core/core_module'; import coreModule from 'app/core/core_module';
const template = ` const template = `

View File

@@ -1,5 +1,3 @@
///<reference path="../../headers/common.d.ts" />
import coreModule from 'app/core/core_module'; import coreModule from 'app/core/core_module';
var template = ` var template = `

View File

@@ -1,5 +1,3 @@
///<reference path="../../headers/common.d.ts" />
import config from 'app/core/config'; import config from 'app/core/config';
import coreModule from 'app/core/core_module'; import coreModule from 'app/core/core_module';

View File

@@ -1,5 +1,3 @@
///<reference path="../../headers/common.d.ts" />
import coreModule from 'app/core/core_module'; import coreModule from 'app/core/core_module';
import appEvents from 'app/core/app_events'; import appEvents from 'app/core/app_events';

View File

@@ -1,5 +1,3 @@
///<reference path="../../headers/common.d.ts" />
import angular from 'angular'; import angular from 'angular';
var directiveModule = angular.module('grafana.directives'); var directiveModule = angular.module('grafana.directives');

View File

@@ -1,5 +1,3 @@
///<reference path="../../headers/common.d.ts" />
import $ from 'jquery'; import $ from 'jquery';
import { coreModule } from 'app/core/core'; import { coreModule } from 'app/core/core';

View File

@@ -1,5 +1,3 @@
///<reference path="../../headers/common.d.ts" />
import _ from 'lodash'; import _ from 'lodash';
export class QueryCtrl { export class QueryCtrl {

View File

@@ -1,5 +1,3 @@
///<reference path="../../headers/common.d.ts" />
import angular from 'angular'; import angular from 'angular';
var module = angular.module('grafana.directives'); var module = angular.module('grafana.directives');

View File

@@ -1,5 +1,3 @@
///<reference path="../../headers/common.d.ts" />
import _ from 'lodash'; import _ from 'lodash';
import appEvents from 'app/core/app_events'; import appEvents from 'app/core/app_events';
import { coreModule, JsonExplorer } from 'app/core/core'; import { coreModule, JsonExplorer } from 'app/core/core';

View File

@@ -1,5 +1,3 @@
///<reference path="../../headers/common.d.ts" />
import coreModule from '../../core/core_module'; import coreModule from '../../core/core_module';
export class PlaylistSearchCtrl { export class PlaylistSearchCtrl {

View File

@@ -1,5 +1,3 @@
///<reference path="../../headers/common.d.ts" />
import coreModule from '../../core/core_module'; import coreModule from '../../core/core_module';
import kbn from 'app/core/utils/kbn'; import kbn from 'app/core/utils/kbn';
import appEvents from 'app/core/app_events'; import appEvents from 'app/core/app_events';

View File

@@ -1,5 +1,3 @@
///<reference path="../../headers/common.d.ts" />
import _ from 'lodash'; import _ from 'lodash';
import coreModule from '../../core/core_module'; import coreModule from '../../core/core_module';

View File

@@ -1,5 +1,3 @@
///<reference path="../../../headers/common.d.ts" />
import _ from 'lodash'; import _ from 'lodash';
import coreModule from 'app/core/core_module'; import coreModule from 'app/core/core_module';
import appEvents from 'app/core/app_events'; import appEvents from 'app/core/app_events';

View File

@@ -1,5 +1,3 @@
///<reference path="../../headers/common.d.ts" />
import angular from 'angular'; import angular from 'angular';
import _ from 'lodash'; import _ from 'lodash';
import Remarkable from 'remarkable'; import Remarkable from 'remarkable';

View File

@@ -1,5 +1,3 @@
///<reference path="../../headers/common.d.ts" />
import _ from 'lodash'; import _ from 'lodash';
export class DashboardRowCtrl { export class DashboardRowCtrl {

View File

@@ -1,5 +1,3 @@
///<reference path="../../headers/common.d.ts" />
import angular from 'angular'; import angular from 'angular';
import _ from 'lodash'; import _ from 'lodash';

View File

@@ -1,5 +1,3 @@
///<reference path="../../headers/common.d.ts" />
import { Variable, assignModelProperties, variableTypes } from './variable'; import { Variable, assignModelProperties, variableTypes } from './variable';
export class ConstantVariable implements Variable { export class ConstantVariable implements Variable {

View File

@@ -1,5 +1,3 @@
///<reference path="../../headers/common.d.ts" />
import _ from 'lodash'; import _ from 'lodash';
import { Variable, assignModelProperties, variableTypes } from './variable'; import { Variable, assignModelProperties, variableTypes } from './variable';

View File

@@ -1,5 +1,3 @@
///<reference path="../../headers/common.d.ts" />
import kbn from 'app/core/utils/kbn'; import kbn from 'app/core/utils/kbn';
import { Variable, containsVariable, assignModelProperties, variableTypes } from './variable'; import { Variable, containsVariable, assignModelProperties, variableTypes } from './variable';

View File

@@ -1,5 +1,3 @@
///<reference path="../../headers/common.d.ts" />
import _ from 'lodash'; import _ from 'lodash';
import kbn from 'app/core/utils/kbn'; import kbn from 'app/core/utils/kbn';
import { Variable, assignModelProperties, variableTypes } from './variable'; import { Variable, assignModelProperties, variableTypes } from './variable';

View File

@@ -1,5 +1,3 @@
///<reference path="../../headers/common.d.ts" />
import angular from 'angular'; import angular from 'angular';
import _ from 'lodash'; import _ from 'lodash';
import coreModule from 'app/core/core_module'; import coreModule from 'app/core/core_module';

View File

@@ -1,11 +0,0 @@
declare var System: any;
declare module 'eventemitter3' {
var config: any;
export default config;
}
declare module 'gemini-scrollbar' {
var d3: any;
export default d3;
}

View File

@@ -1,5 +1,3 @@
///<reference path="../../../headers/common.d.ts" />
export class ConfigCtrl { export class ConfigCtrl {
static template = ''; static template = '';

View File

@@ -1,5 +1,3 @@
///<reference path="../../../headers/common.d.ts" />
export class CloudWatchConfigCtrl { export class CloudWatchConfigCtrl {
static templateUrl = 'partials/config.html'; static templateUrl = 'partials/config.html';
current: any; current: any;

View File

@@ -1,5 +1,3 @@
///<reference path="../../../headers/common.d.ts" />
import './query_parameter_ctrl'; import './query_parameter_ctrl';
import { QueryCtrl } from 'app/plugins/sdk'; import { QueryCtrl } from 'app/plugins/sdk';

View File

@@ -1,5 +1,3 @@
///<reference path="../../../headers/common.d.ts" />
import angular from 'angular'; import angular from 'angular';
import _ from 'lodash'; import _ from 'lodash';
import moment from 'moment'; import moment from 'moment';

View File

@@ -1,5 +1,3 @@
///<reference path="../../../headers/common.d.ts" />
import _ from 'lodash'; import _ from 'lodash';
import * as queryDef from './query_def'; import * as queryDef from './query_def';
import TableModel from 'app/core/table_model'; import TableModel from 'app/core/table_model';

View File

@@ -1,5 +1,3 @@
///<reference path="../../../headers/common.d.ts" />
import './bucket_agg'; import './bucket_agg';
import './metric_agg'; import './metric_agg';

View File

@@ -1,5 +1,3 @@
///<reference path="../../../headers/common.d.ts" />
import _ from 'lodash'; import _ from 'lodash';
export const metricAggTypes = [ export const metricAggTypes = [

View File

@@ -1,5 +1,3 @@
///<reference path="../../../headers/common.d.ts" />
import { liveSrv } from 'app/core/core'; import { liveSrv } from 'app/core/core';
class DataObservable { class DataObservable {

View File

@@ -1,5 +1,3 @@
///<reference path="../../../headers/common.d.ts" />
import { GrafanaStreamDS } from './datasource'; import { GrafanaStreamDS } from './datasource';
import { QueryCtrl } from 'app/plugins/sdk'; import { QueryCtrl } from 'app/plugins/sdk';

View File

@@ -1,5 +1,3 @@
///<reference path="../../../headers/common.d.ts" />
export class GraphiteConfigCtrl { export class GraphiteConfigCtrl {
static templateUrl = 'public/app/plugins/datasource/graphite/partials/config.html'; static templateUrl = 'public/app/plugins/datasource/graphite/partials/config.html';
datasourceSrv: any; datasourceSrv: any;

View File

@@ -1,5 +1,3 @@
///<reference path="../../../headers/common.d.ts" />
import _ from 'lodash'; import _ from 'lodash';
import * as dateMath from 'app/core/utils/datemath'; import * as dateMath from 'app/core/utils/datemath';
import { isVersionGtOrEq, SemVersion } from 'app/core/utils/version'; import { isVersionGtOrEq, SemVersion } from 'app/core/utils/version';

View File

@@ -1,5 +1,3 @@
///<reference path="../../../headers/common.d.ts" />
import _ from 'lodash'; import _ from 'lodash';
// This is auto generated from the unicode tables. // This is auto generated from the unicode tables.

View File

@@ -1,5 +1,3 @@
///<reference path="../../../headers/common.d.ts" />
import _ from 'lodash'; import _ from 'lodash';
import queryPart from './query_part'; import queryPart from './query_part';
import kbn from 'app/core/utils/kbn'; import kbn from 'app/core/utils/kbn';

View File

@@ -1,5 +1,3 @@
///<reference path="../../../headers/common.d.ts" />
import _ from 'lodash'; import _ from 'lodash';
import { QueryPartDef, QueryPart, functionRenderer, suffixRenderer } from 'app/core/components/query_part/query_part'; import { QueryPartDef, QueryPart, functionRenderer, suffixRenderer } from 'app/core/components/query_part/query_part';

View File

@@ -1,5 +1,3 @@
///<reference path="../../../headers/common.d.ts" />
import angular from 'angular'; import angular from 'angular';
import _ from 'lodash'; import _ from 'lodash';

View File

@@ -1,4 +1,2 @@
///<reference path="../../../headers/common.d.ts" />
import { MixedDatasource } from './datasource'; import { MixedDatasource } from './datasource';
export { MixedDatasource, MixedDatasource as Datasource }; export { MixedDatasource, MixedDatasource as Datasource };

View File

@@ -1,5 +1,3 @@
///<reference path="../../../headers/common.d.ts" />
import _ from 'lodash'; import _ from 'lodash';
import ResponseParser from './response_parser'; import ResponseParser from './response_parser';

View File

@@ -1,5 +1,3 @@
///<reference path="../../../headers/common.d.ts" />
import { MysqlDatasource } from './datasource'; import { MysqlDatasource } from './datasource';
import { MysqlQueryCtrl } from './query_ctrl'; import { MysqlQueryCtrl } from './query_ctrl';

View File

@@ -1,5 +1,3 @@
///<reference path="../../../headers/common.d.ts" />
import _ from 'lodash'; import _ from 'lodash';
import { QueryCtrl } from 'app/plugins/sdk'; import { QueryCtrl } from 'app/plugins/sdk';

View File

@@ -1,5 +1,3 @@
///<reference path="../../../headers/common.d.ts" />
import _ from 'lodash'; import _ from 'lodash';
export default class ResponseParser { export default class ResponseParser {

View File

@@ -1,5 +1,3 @@
///<reference path="../../../headers/common.d.ts" />
export class OpenTsConfigCtrl { export class OpenTsConfigCtrl {
static templateUrl = 'public/app/plugins/datasource/opentsdb/partials/config.html'; static templateUrl = 'public/app/plugins/datasource/opentsdb/partials/config.html';
current: any; current: any;

View File

@@ -1,5 +1,3 @@
///<reference path="../../../headers/common.d.ts" />
import _ from 'lodash'; import _ from 'lodash';
import kbn from 'app/core/utils/kbn'; import kbn from 'app/core/utils/kbn';
import { QueryCtrl } from 'app/plugins/sdk'; import { QueryCtrl } from 'app/plugins/sdk';

View File

@@ -1,5 +1,3 @@
///<reference path="../../../headers/common.d.ts" />
import _ from 'lodash'; import _ from 'lodash';
import ResponseParser from './response_parser'; import ResponseParser from './response_parser';

View File

@@ -1,5 +1,3 @@
///<reference path="../../../headers/common.d.ts" />
import { PostgresDatasource } from './datasource'; import { PostgresDatasource } from './datasource';
import { PostgresQueryCtrl } from './query_ctrl'; import { PostgresQueryCtrl } from './query_ctrl';

View File

@@ -1,5 +1,3 @@
///<reference path="../../../headers/common.d.ts" />
import _ from 'lodash'; import _ from 'lodash';
import { QueryCtrl } from 'app/plugins/sdk'; import { QueryCtrl } from 'app/plugins/sdk';

View File

@@ -1,5 +1,3 @@
///<reference path="../../../headers/common.d.ts" />
import _ from 'lodash'; import _ from 'lodash';
export default class ResponseParser { export default class ResponseParser {

View File

@@ -1,5 +1,3 @@
///<reference path="../../../headers/common.d.ts" />
import { PrometheusDatasource } from './datasource'; import { PrometheusDatasource } from './datasource';
import _ from 'lodash'; import _ from 'lodash';

View File

@@ -1,5 +1,3 @@
///<reference path="../../../headers/common.d.ts" />
import _ from 'lodash'; import _ from 'lodash';
import moment from 'moment'; import moment from 'moment';
import alertDef from '../../../features/alerting/alert_def'; import alertDef from '../../../features/alerting/alert_def';

View File

@@ -1,5 +1,3 @@
///<reference path="../../../headers/common.d.ts" />
import { PanelCtrl } from 'app/plugins/sdk'; import { PanelCtrl } from 'app/plugins/sdk';
import { contextSrv } from 'app/core/core'; import { contextSrv } from 'app/core/core';

View File

@@ -1,5 +1,3 @@
///<reference path="../../../headers/common.d.ts" />
import kbn from 'app/core/utils/kbn'; import kbn from 'app/core/utils/kbn';
export class AxesEditorCtrl { export class AxesEditorCtrl {

View File

@@ -1,5 +1,3 @@
///<reference path="../../../headers/common.d.ts" />
import './graph'; import './graph';
import './legend'; import './legend';
import './series_overrides_ctrl'; import './series_overrides_ctrl';

View File

@@ -1,5 +1,3 @@
///<reference path="../../../../headers/common.d.ts" />
import { describe, beforeEach, it, expect, angularMocks } from '../../../../../test/lib/common'; import { describe, beforeEach, it, expect, angularMocks } from '../../../../../test/lib/common';
import moment from 'moment'; import moment from 'moment';

View File

@@ -1,5 +1,3 @@
///<reference path="../../../../headers/common.d.ts" />
import { describe, beforeEach, it, sinon, expect, angularMocks } from '../../../../../test/lib/common'; import { describe, beforeEach, it, sinon, expect, angularMocks } from '../../../../../test/lib/common';
import '../module'; import '../module';

View File

@@ -1,5 +1,3 @@
///<reference path="../../../../headers/common.d.ts" />
import { describe, it, expect } from '../../../../../test/lib/common'; import { describe, it, expect } from '../../../../../test/lib/common';
import { ThresholdManager } from '../threshold_manager'; import { ThresholdManager } from '../threshold_manager';

View File

@@ -1,5 +1,3 @@
///<reference path="../../../../headers/common.d.ts" />
import { describe, beforeEach, it, sinon, expect } from '../../../../../test/lib/common'; import { describe, beforeEach, it, sinon, expect } from '../../../../../test/lib/common';
import $ from 'jquery'; import $ from 'jquery';

View File

@@ -1,5 +1,3 @@
///<reference path="../../../headers/common.d.ts" />
import coreModule from 'app/core/core_module'; import coreModule from 'app/core/core_module';
export class ThresholdFormCtrl { export class ThresholdFormCtrl {

View File

@@ -1,5 +1,3 @@
///<reference path="../../../headers/common.d.ts" />
import kbn from 'app/core/utils/kbn'; import kbn from 'app/core/utils/kbn';
export class AxesEditorCtrl { export class AxesEditorCtrl {

View File

@@ -1,5 +1,3 @@
///<reference path="../../../headers/common.d.ts" />
export class HeatmapDisplayEditorCtrl { export class HeatmapDisplayEditorCtrl {
panel: any; panel: any;
panelCtrl: any; panelCtrl: any;

View File

@@ -1,5 +1,3 @@
///<reference path="../../../../headers/common.d.ts" />
import { describe, beforeEach, it, expect, angularMocks } from '../../../../../test/lib/common'; import { describe, beforeEach, it, expect, angularMocks } from '../../../../../test/lib/common';
import moment from 'moment'; import moment from 'moment';

View File

@@ -1,5 +1,3 @@
///<reference path="../../../../headers/common.d.ts" />
import { describe, beforeEach, it, sinon, expect, angularMocks } from '../../../../../test/lib/common'; import { describe, beforeEach, it, sinon, expect, angularMocks } from '../../../../../test/lib/common';
import '../module'; import '../module';

View File

@@ -1,5 +1,3 @@
///<reference path="../../../headers/common.d.ts" />
import _ from 'lodash'; import _ from 'lodash';
import kbn from 'app/core/utils/kbn'; import kbn from 'app/core/utils/kbn';

View File

@@ -1,5 +1,3 @@
///<reference path="../../../headers/common.d.ts" />
import _ from 'lodash'; import _ from 'lodash';
import { transformers } from './transformers'; import { transformers } from './transformers';

View File

@@ -1,5 +1,3 @@
///<reference path="../../../headers/common.d.ts" />
import _ from 'lodash'; import _ from 'lodash';
import $ from 'jquery'; import $ from 'jquery';
import { MetricsPanelCtrl } from 'app/plugins/sdk'; import { MetricsPanelCtrl } from 'app/plugins/sdk';

View File

@@ -1,7 +1,6 @@
///<reference path="../../../headers/common.d.ts" />
import _ from 'lodash'; import _ from 'lodash';
import { PanelCtrl } from 'app/plugins/sdk'; import { PanelCtrl } from 'app/plugins/sdk';
import Remarkable from 'remarkable';
export class TextPanelCtrl extends PanelCtrl { export class TextPanelCtrl extends PanelCtrl {
static templateUrl = `public/app/plugins/panel/text/module.html`; static templateUrl = `public/app/plugins/panel/text/module.html`;
@@ -66,12 +65,10 @@ export class TextPanelCtrl extends PanelCtrl {
renderMarkdown(content) { renderMarkdown(content) {
if (!this.remarkable) { if (!this.remarkable) {
return System.import('remarkable').then(Remarkable => {
this.remarkable = new Remarkable(); this.remarkable = new Remarkable();
this.$scope.$apply(() => { this.$scope.$apply(() => {
this.updateContent(this.remarkable.render(content)); this.updateContent(this.remarkable.render(content));
}); });
});
} }
this.$scope.$applyAsync(() => { this.$scope.$applyAsync(() => {