diff --git a/src/ui/public/chrome/__tests__/kbn_loading_indicator.js b/src/ui/public/chrome/__tests__/kbn_loading_indicator.js
index f24f88d60a2c1..2ea104dfb8fae 100644
--- a/src/ui/public/chrome/__tests__/kbn_loading_indicator.js
+++ b/src/ui/public/chrome/__tests__/kbn_loading_indicator.js
@@ -16,7 +16,7 @@ describe('kbnLoadingIndicator', function () {
$rootScope.chrome = {
httpActive: (hasActiveConnections ? [1] : [])
};
- const $el = $('
');
+ const $el = $('');
$rootScope.$apply();
$compile($el)($rootScope);
return $el;
@@ -38,10 +38,4 @@ describe('kbnLoadingIndicator', function () {
const $el = compile(true);
expect($el.find('.spinner.ng-hide')).to.have.length(0);
});
-
- it('doesn\'t modify the contents of what the elment already has', function () {
- const $el = compile();
- expect($el.find('#other-content')).to.have.length(1);
- });
-
});
diff --git a/src/ui/public/chrome/chrome.html b/src/ui/public/chrome/chrome.html
index 75cbaaf9ee49f..a5fb0e84a8851 100644
--- a/src/ui/public/chrome/chrome.html
+++ b/src/ui/public/chrome/chrome.html
@@ -64,7 +64,8 @@
-
+
+
diff --git a/src/ui/public/chrome/directives/kbn_loading_indicator.js b/src/ui/public/chrome/directives/kbn_loading_indicator.js
index 63b32dfb788bf..1f5967c8b89ff 100644
--- a/src/ui/public/chrome/directives/kbn_loading_indicator.js
+++ b/src/ui/public/chrome/directives/kbn_loading_indicator.js
@@ -7,11 +7,7 @@ UiModules
.get('ui/kibana')
.directive('kbnLoadingIndicator', function ($compile) {
return {
- restrict: 'AC',
- link: function (scope, $el) {
- const $loadingEl = angular.element(spinnerTemplate);
- $el.append($loadingEl);
- $compile($loadingEl)(scope);
- }
+ restrict: 'E',
+ template: spinnerTemplate,
};
});