mirror of
https://github.com/friendica/friendica
synced 2024-11-19 17:03:41 +00:00
make profiles-menu disappear when clicked outside it
Signed-off-by: Simon L'nu <simon.lnu@gmail.com>
This commit is contained in:
parent
01f8710832
commit
91fee866b7
2 changed files with 18 additions and 0 deletions
|
@ -73,6 +73,15 @@ $(document).ready(function() {
|
||||||
$('#nav-notifications-linkmenu').click(function(event) {
|
$('#nav-notifications-linkmenu').click(function(event) {
|
||||||
event.stopPropagation();
|
event.stopPropagation();
|
||||||
});
|
});
|
||||||
|
// click outside profiles menu closes it
|
||||||
|
$('html').click(function() {
|
||||||
|
$('#profiles-menu-trigger').removeClass('selected');
|
||||||
|
document.getElementById("profiles-menu").style.display = "none";
|
||||||
|
});
|
||||||
|
|
||||||
|
$('#profiles-menu').click(function(event) {
|
||||||
|
event.stopPropagation();
|
||||||
|
});
|
||||||
|
|
||||||
// main function in toolbar functioning
|
// main function in toolbar functioning
|
||||||
function toggleToolbar() {
|
function toggleToolbar() {
|
||||||
|
|
|
@ -73,6 +73,15 @@ $(document).ready(function() {
|
||||||
$('#nav-notifications-linkmenu').click(function(event) {
|
$('#nav-notifications-linkmenu').click(function(event) {
|
||||||
event.stopPropagation();
|
event.stopPropagation();
|
||||||
});
|
});
|
||||||
|
// click outside profiles menu closes it
|
||||||
|
$('html').click(function() {
|
||||||
|
$('#profiles-menu-trigger').removeClass('selected');
|
||||||
|
document.getElementById("profiles-menu").style.display = "none";
|
||||||
|
});
|
||||||
|
|
||||||
|
$('#profiles-menu').click(function(event) {
|
||||||
|
event.stopPropagation();
|
||||||
|
});
|
||||||
|
|
||||||
// main function in toolbar functioning
|
// main function in toolbar functioning
|
||||||
function toggleToolbar() {
|
function toggleToolbar() {
|
||||||
|
|
Loading…
Reference in a new issue