diff options
-rw-r--r-- | js/components/propertyGroup/propertyGroup_controller.js | 11 | ||||
-rw-r--r-- | templates/propertyGroup.html | 1 |
2 files changed, 12 insertions, 0 deletions
diff --git a/js/components/propertyGroup/propertyGroup_controller.js b/js/components/propertyGroup/propertyGroup_controller.js index 5857e9cb..02106924 100644 --- a/js/components/propertyGroup/propertyGroup_controller.js +++ b/js/components/propertyGroup/propertyGroup_controller.js @@ -12,6 +12,17 @@ angular.module('contactsApp') return ctrl.meta.icon || 'icon-contacts-dark'; }; + this.getInfoClass = function() { + if (ctrl.meta.hasOwnProperty('info')) { + return 'icon-info'; + + } + }; + + this.getInfoText = function() { + return ctrl.meta.info; + }; + this.getReadableName = function() { return ctrl.meta.readableName; }; diff --git a/templates/propertyGroup.html b/templates/propertyGroup.html index e25ba091..2cce1a4f 100644 --- a/templates/propertyGroup.html +++ b/templates/propertyGroup.html @@ -1,6 +1,7 @@ <h3 class="propertyGroup__title"> <i ng-class="ctrl.getIconClass()"></i> {{ctrl.getReadableName()}} + <i ng-class="ctrl.getInfoClass()" title="{{ctrl.getInfoText()}}"></i> </h3> <detailsItem ng-repeat="property in ctrl.properties" name="ctrl.name" data="property" model="ctrl.contact" index="$index" class="details-item-{{ctrl.name}}" ng-class="{ 'failed': ctrl.contact.failedProps.indexOf(ctrl.name) !== -1 }"></detailsItem> |