Moving back to ng-bind-html

This commit is contained in:
Will Marshall
2014-05-28 14:58:53 +10:00
parent c26462db57
commit 0c8ee2488b
2 changed files with 3 additions and 11 deletions

View File

@@ -15,11 +15,3 @@ Darkswarm.directive "ofnModal", ($modal)->
elem.on "click", =>
scope.modalInstance = $modal.open(controller: ctrl, template: contents, scope: scope.$parent)
# TODO THIS IS TERRIBLE PLEASE FIX NG-BIND-HTML
Darkswarm.directive "injectHtml", ->
restrict: 'A'
scope:
injectHtml: "="
link: (scope, elem, attrs, ctrl)->
elem.html(scope.injectHtml)

View File

@@ -5,7 +5,7 @@
/ Will - scale large images down to 1200px wide, crop in to img aspect ratio 60W:13H
%h3.producer-name {{ producer.name }}
.row
.columns.small-12.large-6{"inject-html" => "producer.long_description"}
.columns.small-12.large-6{"ng-bind-html" => "producer.long_description"}
.columns.small-12.large-6
/ Will needs logic to add in following only if data is available for each type:
/ Will needs better formatting of URLs printed on-screen (minus http://www.)
@@ -26,12 +26,12 @@
%li{"ng-if" => "producer.facebook"}
%a{"ng-href" => "{{producer.facebook}}", target: "_blank"}
%i.fi-social-facebook
{{ producer.facebook }}
{{ producer.facebook | stripUrl }}
%li{"ng-if" => "producer.linkedin"}
%a{"ng-href" => "{{producer.linkedin}}", target: "_blank"}
%i.fi-social-linkedin
{{ producer.linkedin }}
{{ producer.linkedin | stripUrl }}
%li{"ng-if" => "producer.instagram"}
%a{"ng-href" => "http://instagram.com/{{producer.instagram}}", target: "_blank"}