diff options
Diffstat (limited to 'client/components/main/header.js')
-rw-r--r-- | client/components/main/header.js | 14 |
1 files changed, 14 insertions, 0 deletions
diff --git a/client/components/main/header.js b/client/components/main/header.js index 49acbfef..3b724651 100644 --- a/client/components/main/header.js +++ b/client/components/main/header.js @@ -10,8 +10,22 @@ Template.header.helpers({ appIsOffline() { return !Meteor.status().connected; }, + + hasAnnouncement() { + const notice = Notices.findOne(); + return notice && notice.enabled; + }, + + announcement() { + $('.announcement').show(); + const notice = Notices.findOne(); + return notice && notice.body; + }, }); Template.header.events({ 'click .js-create-board': Popup.open('headerBarCreateBoard'), + 'click .js-close-announcement'() { + $('.announcement').hide(); + }, }); |