summaryrefslogtreecommitdiffstats
path: root/js/directive/NewsArticleActions.js
diff options
context:
space:
mode:
Diffstat (limited to 'js/directive/NewsArticleActions.js')
-rw-r--r--js/directive/NewsArticleActions.js12
1 files changed, 8 insertions, 4 deletions
diff --git a/js/directive/NewsArticleActions.js b/js/directive/NewsArticleActions.js
index 0b8714e41..516fd3a00 100644
--- a/js/directive/NewsArticleActions.js
+++ b/js/directive/NewsArticleActions.js
@@ -10,16 +10,20 @@
app.directive('newsArticleActions', function () {
'use strict';
return {
- restrict: 'E',
+ restrict: 'A',
scope: {
- 'article': '='
+ newsArticleActions: '='
},
link: function (scope, elem) {
var plugins = News.getArticleActionPlugins();
for (var i=0; i<plugins.length; i+=1) {
- plugins[i](elem, scope.article);
+ plugins[i](elem, scope.newsArticleActions);
+ }
+
+ if (plugins.length === 0) {
+ $('#app-content .more').hide();
}
}
};
-}); \ No newline at end of file
+});