summaryrefslogtreecommitdiffstats
path: root/client/components/modal/events.js
diff options
context:
space:
mode:
Diffstat (limited to 'client/components/modal/events.js')
-rw-r--r--client/components/modal/events.js14
1 files changed, 14 insertions, 0 deletions
diff --git a/client/components/modal/events.js b/client/components/modal/events.js
new file mode 100644
index 00000000..2943f841
--- /dev/null
+++ b/client/components/modal/events.js
@@ -0,0 +1,14 @@
+Template.modal.events({
+ 'click .window-overlay': function(event) {
+ // We only want to catch the event if the user click on the .window-overlay
+ // div itself, not a child (ie, not the overlay window)
+ if (event.target !== event.currentTarget)
+ return;
+ Utils.goBoardId(this.card.board()._id);
+ event.preventDefault();
+ },
+ 'click .js-close-window': function(event) {
+ Utils.goBoardId(this.card.board()._id);
+ event.preventDefault();
+ }
+});