Commit 2a50bc35 by Patrick O'Carroll

converted file to ts

parent 40332832
define(['angular', 'lodash', 'jquery', 'rst2html', 'tether-drop'], function(angular, _, $, rst2html, Drop) {
'use strict';
import angular from 'angular';
import _ from 'lodash';
import $ from 'jquery';
import rst2html from 'rst2html';
import Drop from 'tether-drop';
angular.module('grafana.directives').directive('graphiteAddFunc', function($compile) {
export function graphiteAddFunc($compile) {
var inputTemplate =
'<input type="text"' + ' class="gf-form-input"' + ' spellcheck="false" style="display:none"></input>';
......@@ -40,7 +43,7 @@ define(['angular', 'lodash', 'jquery', 'rst2html', 'tether-drop'], function(angu
});
if (!funcDef) {
return;
return '';
}
}
......@@ -124,9 +127,11 @@ define(['angular', 'lodash', 'jquery', 'rst2html', 'tether-drop'], function(angu
$scope.$on('$destroy', cleanUpDrop);
},
};
});
}
function createFunctionDropDownMenu(funcDefs) {
angular.module('grafana.directives').directive('graphiteAddFunc', graphiteAddFunc);
function createFunctionDropDownMenu(funcDefs) {
var categories = {};
_.forEach(funcDefs, function(funcDef) {
......@@ -151,5 +156,4 @@ define(['angular', 'lodash', 'jquery', 'rst2html', 'tether-drop'], function(angu
}),
'text'
);
}
});
}
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment