UNPKG

angular-gantt

Version:

Gantt chart component for AngularJS

23 lines (18 loc) 861 B
(function(){ 'use strict'; angular.module('gantt.table').directive('ganttSideContentTable', ['GanttDirectiveBuilder', 'ganttLayout', function(Builder, layout) { var builder = new Builder('ganttSideContentTable', 'plugins/table/sideContentTable.tmpl.html'); builder.controller = function($scope) { var hScrollBarHeight = layout.getScrollBarHeight(); $scope.getMaxHeightCss = function() { var css = {}; if ($scope.maxHeight) { var bodyScrollBarHeight = $scope.gantt.scroll.isHScrollbarVisible() ? hScrollBarHeight : 0; css['max-height'] = $scope.maxHeight - bodyScrollBarHeight - $scope.gantt.header.getHeight() + 'px'; } return css; }; }; return builder.build(); }]); }());