highlight.js 293 B

12345678910111213
  1. 'use strict';
  2. angular.module('etcdControlPanel')
  3. .directive('highlight', function() {
  4. return {
  5. restrict: 'A',
  6. link: function(scope, element, attrs) {
  7. if('#' + scope.etcdPath === attrs.href) {
  8. element.parent().parent().addClass('etcd-selected');
  9. }
  10. }
  11. };
  12. });