export class TabGroupController {
    constructor($scope) {
        'ngInject';

        this.$scope = $scope;
        this.activeTab = '';
        this.$onInit = this.init;
    }

    init() {
        // debugger
        // let self = this;
        // this.ngModel.$render = () => {
        //     self.count = self.ngModel.$viewValue;
        // };

        // this.$scope.$watch(function () {
        //     return self.count;
        // }, function (value) {
        //     self.ngModel.$setViewValue(value);
        // });
    }

}

export const tabGroupComponent = {
    bindings: {
        onClick: '&'
    },
    require: {
        ngModel: '^ngModel'
    },
    transclude: {
        'cil-tab-body': '?cilTabBody',
        'cil-tab-footer': '?cilTabFooter'
    },
    templateUrl: 'app/controls/components/tab-group/tab-group.html',
    controller: TabGroupController
};