Product Description - strip weird tags on paste

squashme
This commit is contained in:
Matt-Yorkley
2017-04-01 14:55:51 +01:00
committed by Rob Harrington
parent 05cf8c4351
commit cd55d2e2ff
2 changed files with 6 additions and 1 deletions

View File

@@ -0,0 +1,5 @@
angular.module("admin.utils").directive "textangularStrip", () ->
restrict: 'CA'
link: (scope, element, attrs) ->
scope.stripFormatting = ($html) ->
return String($html).replace(/<[^>]+>/gm, '')