aboutsummaryrefslogtreecommitdiffstats
path: root/view/js/mod_hq.js
blob: ad77e0af0ccda1ab2c5fe932fe9b221f837e0d7a (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
$(document).ready(function() {

	$(document).on('click', '.jot-toggle', function(e) {
		$(window).scrollTop(0);
		$(document).trigger('hz:hqControlsClickAction');
		$('#jot-popup').toggle();
		$('#profile-jot-text').focus();
	});

	$(document).on('click', '.notes-toggle', function(e) {
		$(window).scrollTop(0);
		$(document).trigger('hz:hqControlsClickAction');
		$('#personal-notes').toggleClass('d-none');
		$('#note-text').focus();
	});

	$(document).on('hz:handleNetworkNotificationsItems', function(e, obj) {
		push_notification(
			obj.name,
			$('<p>' + obj.message + '</p>').text(),
			baseurl + '/hq/' + obj.b64mid
		);
	});

});