diff --git a/src/app/directives/ngBlur.js b/src/app/directives/ngBlur.js index 663d33f9eff..f8b2dd01b8a 100644 --- a/src/app/directives/ngBlur.js +++ b/src/app/directives/ngBlur.js @@ -17,4 +17,21 @@ function (angular) { }; }]); + angular + .module('kibana.directives') + .directive('dynamicWidth', function() { + return { + restrict: 'A', + link: function postLink(scope, elem, attrs) { + var startVal = scope.$eval(attrs.ngModel); + elem[0].style.width = ((startVal.length) * 11) + 'px'; + + elem.keyup(function() { + elem[0].style.width = ((elem.val().length * 11)) + 'px'; + }); + } + }; + }); + + }); \ No newline at end of file diff --git a/src/app/partials/graphite/editor.html b/src/app/partials/graphite/editor.html index 65cfe883181..92f513f8154 100644 --- a/src/app/partials/graphite/editor.html +++ b/src/app/partials/graphite/editor.html @@ -76,9 +76,19 @@
  • - - {{func.text}} - + + + {{func.def.name}}( + + ) +