Change cor-tabs to be a TypeScript and Angular "neu" component

We no longer use bootstrap tabs code in this version

This is in prep for changing the tab style
This commit is contained in:
Joseph Schorr 2017-04-28 17:03:38 -04:00
parent e5ec33511f
commit b11239f3bf
24 changed files with 832 additions and 588 deletions

View file

@ -214,61 +214,6 @@ angular.module("core-ui", [])
return directiveDefinitionObject;
})
.directive('corTabPanel', function() {
var directiveDefinitionObject = {
priority: 1,
templateUrl: '/static/directives/cor-tab-panel.html',
replace: true,
transclude: true,
restrict: 'C',
scope: {},
controller: function($rootScope, $scope, $element) {
}
};
return directiveDefinitionObject;
})
.directive('corTabContent', function() {
var directiveDefinitionObject = {
priority: 2,
replace: true,
transclude: false,
restrict: 'C',
scope: {},
controller: function($rootScope, $scope, $element) {
$element.addClass('co-tab-content tab-content col-md-11');
}
};
return directiveDefinitionObject;
})
.directive('corTabs', function() {
var directiveDefinitionObject = {
priority: 3,
templateUrl: '/static/directives/cor-tabs.html',
replace: true,
transclude: true,
restrict: 'C',
scope: {
'rememberCookie': '@rememberCookie'
},
controller: function($rootScope, $scope, $element, $timeout, $location, UIService) {
$scope.isClosed = true;
$scope.toggleClosed = function(e) {
$scope.isClosed = !$scope.isClosed;
e.stopPropagation();
e.preventDefault();
};
UIService.initializeTabs($scope, $element, function() {
$scope.isClosed = true;
}, $scope.rememberCookie);
}
};
return directiveDefinitionObject;
})
.directive('corFloatingBottomBar', function() {
var directiveDefinitionObject = {
priority: 3,
@ -338,34 +283,6 @@ angular.module("core-ui", [])
return directiveDefinitionObject;
})
.directive('corTab', function() {
var directiveDefinitionObject = {
priority: 4,
templateUrl: '/static/directives/cor-tab.html',
replace: true,
transclude: true,
restrict: 'C',
scope: {
'tabActive': '@tabActive',
'tabTitle': '@tabTitle',
'tabTarget': '@tabTarget',
'tabInit': '&tabInit',
'tabShown': '&tabShown',
'tabHidden': '&tabHidden'
},
controller: function($rootScope, $scope, $element) {
$element.find('a[data-toggle="tab"]').on('hidden.bs.tab', function (e) {
$scope.tabHidden({});
});
$element.find('a[data-toggle="tab"]').on('shown.bs.tab', function (e) {
$scope.tabShown({});
});
}
};
return directiveDefinitionObject;
})
.directive('corStep', function() {
var directiveDefinitionObject = {
priority: 4,