From 5ceb9c4d7adbeddf4ce2685d4f12dac468930a6f Mon Sep 17 00:00:00 2001 From: tkrym Date: Mon, 23 Feb 2015 01:51:20 +0100 Subject: e templateUrl instead of template in directives declaration #197 --- isteven-multi-select.js | 153 ++++++++++++++++++++++++------------------------ 1 file changed, 78 insertions(+), 75 deletions(-) diff --git a/isteven-multi-select.js b/isteven-multi-select.js index 1cacbc2..b477609 100644 --- a/isteven-multi-select.js +++ b/isteven-multi-select.js @@ -47,7 +47,7 @@ angular.module( 'isteven-multi-select', ['ng'] ).directive( 'istevenMultiSelect' // settings based on attribute buttonLabel : '@', directiveId : '@', - helperElements : '@', + helperElements : '@', isDisabled : '=', itemLabel : '@', maxLabels : '@', @@ -75,80 +75,8 @@ angular.module( 'isteven-multi-select', ['ng'] ).directive( 'istevenMultiSelect' // i18n translation : '=' // 3.0.0 - OK }, - - template: - '' + - '' + - '
' + - - '
' + - '
' + - - ''+ - - ''+ - - '' + - '
' + - - '
'+ - - ''+ - - ' '+ - '
'+ - '
'+ - - '
'+ - '
'+ - - '
'+ + templateUrl: 'isteven-multi-select.html', - '
'+ - - '
'+ - - ''+ - '
'+ - - ''+ - '
'+ - '
'+ - '
'+ - '
', link: function ( $scope, element, attrs ) { @@ -1042,5 +970,80 @@ angular.module( 'isteven-multi-select', ['ng'] ).directive( 'istevenMultiSelect' }); } } -}]); +}]).run(['$templateCache', function($templateCache){ + var template = + '' + + '' + + '
' + + + '
' + + '
' + + + ''+ + + ''+ + + '' + + '
' + + + '
'+ + + ''+ + + ' '+ + '
'+ + '
'+ + + '
'+ + '
'+ + + '
'+ + + '
'+ + + '
'+ + + ''+ + '
'+ + + ''+ + '
'+ + '
'+ + '
'+ + '
'; + $templateCache.put('isteven-multi-select.html', template); + }]); ; -- cgit v1.1