diff options
author | fnuesse <felix.nuesse@t-online.de> | 2018-06-18 12:35:20 +0200 |
---|---|---|
committer | John Molakvoæ (skjnldsv) <skjnldsv@protonmail.com> | 2018-07-12 16:49:38 +0200 |
commit | 60e6ac3b6e8597a5cc63c9f60c943fa122b70698 (patch) | |
tree | 560b6c2306c96f7203249cb189cf2ffa39e14b47 /apps/files/js/navigation.js | |
parent | 9cd4b53a51c6b1ed4835df5976f7310b6fb3f75f (diff) | |
download | nextcloud-server-60e6ac3b6e8597a5cc63c9f60c943fa122b70698.tar.gz nextcloud-server-60e6ac3b6e8597a5cc63c9f60c943fa122b70698.zip |
Fixed css-flashing
Signed-off-by: fnuesse <felix.nuesse@t-online.de>
Fixed menu if initially empty
Signed-off-by: fnuesse <felix.nuesse@t-online.de>
Diffstat (limited to 'apps/files/js/navigation.js')
-rw-r--r-- | apps/files/js/navigation.js | 18 |
1 files changed, 14 insertions, 4 deletions
diff --git a/apps/files/js/navigation.js b/apps/files/js/navigation.js index 04c9143581c..f7757751b8f 100644 --- a/apps/files/js/navigation.js +++ b/apps/files/js/navigation.js @@ -146,11 +146,17 @@ var qaSelector= '#quickaccess-list'; if(itemId==='button-collapseQuickAccess'){ + + document.getElementById('enableQuickAccess').checked=!document.getElementById('enableQuickAccess').checked; $.get(OC.generateUrl("/apps/files/api/v1/showquickaccess"), {show: document.getElementById('enableQuickAccess').checked}, function(data, status){ }); - $("#quickaccess-list" ).toggle('open'); - var dotmenu = document.getElementById("quickaccess-list"); - dotmenu.style.display=''; + + if(!$("#favorites-toggle" ).hasClass('open')){ + $("#favorites-toggle" ).addClass('open'); + }else{ + $("#favorites-toggle" ).removeClass('open'); + } + } if(itemId==='button-favorites'){ @@ -173,7 +179,11 @@ if(itemId==='enableQuickAccess' ){ $.get(OC.generateUrl("/apps/files/api/v1/showquickaccess"), {show: document.getElementById('enableQuickAccess').checked}, function(data, status){ }); - $(qaSelector).toggle('open'); + if(!$("#favorites-toggle" ).hasClass('open')){ + $("#favorites-toggle" ).addClass('open'); + }else{ + $("#favorites-toggle" ).removeClass('open'); + } document.getElementById('menu-favorites').classList.toggle('open'); } |