Przeglądaj źródła

Removed ghost panel

Torkel Ödegaard 10 lat temu
rodzic
commit
4e97df06a3

+ 0 - 18
src/app/features/dashboard/rowCtrl.js

@@ -169,22 +169,4 @@ function (angular, app, _, config) {
     };
   });
 
-  module.directive('panelGhost', function() {
-    return function(scope, element) {
-      function updateWidth() {
-        var spanLeft = 12 - scope.dashboard.rowSpan(scope.row);
-        if (spanLeft > 1) {
-          element.show();
-          element.find('.panel-container').css('height', scope.row.height);
-          element[0].style.width = ((spanLeft / 1.2) * 10) + '%';
-        } else {
-          element.hide();
-        }
-      }
-
-      updateWidth();
-      scope.$on('dashboard-panel-span-updated', updateWidth);
-    };
-  });
-
 });

+ 0 - 8
src/app/partials/dashboard.html

@@ -86,14 +86,6 @@
 						<panel-loader type="panel.type" class="panel-margin"></panel-loader>
 					</div>
 
-					<div class="panel panel-ghost" ng-if="!row.panels.length">
-						<div class="panel-container panel-margin">
-							<div class="panel-ghost-list" ng-repeat="(key, value) in panels">
-								<button class="btn btn-inverse" ng-click="add_panel_default(key)"><i class="fa fa-plus"></i> {{value.name}}</button>
-							</div>
-						</div>
-					</div>
-
 					<div panel-drop-zone class="panel panel-drop-zone" ui-on-drop="onDrop($data, row)" data-drop="true">
 						<div class="panel-container" style="background: transparent">
 							<div style="text-align: center">