Adding a learn more modal, restructuring partials

This commit is contained in:
Will Marshall
2014-04-23 16:48:53 +10:00
parent 0479a0a55d
commit c060019873
5 changed files with 57 additions and 36 deletions

View File

@@ -0,0 +1,13 @@
Darkswarm.directive "ofnModal", ($modal)->
restrict: 'E'
replace: true
transclude: true
template: "<a>{{title}}</a>"
link: (scope, elem, attrs, ctrl, transclude)->
scope.title = attrs.title
scope.cancel = ->
scope.modalInstance.dismiss("cancel")
elem.on "click", ->
scope.modalInstance = $modal.open(template: transclude())