summaryrefslogtreecommitdiffstats
path: root/core/src/components/UserMenu.js
diff options
context:
space:
mode:
authorChristopher Ng <chrng8@gmail.com>2021-10-14 08:28:54 +0000
committerChristopher Ng <chrng8@gmail.com>2021-10-19 04:59:36 +0000
commit3be9d3ca8fca4fb743a4d2f2ffe44a45fa9ffa6e (patch)
tree5519fb218db5daa3d0e16198f600d5646f7d0b1a /core/src/components/UserMenu.js
parent309354852f12ae88d5eef05d311d6ebcba8ee762 (diff)
downloadnextcloud-server-3be9d3ca8fca4fb743a4d2f2ffe44a45fa9ffa6e.tar.gz
nextcloud-server-3be9d3ca8fca4fb743a4d2f2ffe44a45fa9ffa6e.zip
Profile frontend
Signed-off-by: Christopher Ng <chrng8@gmail.com> Signed-off-by: nextcloud-command <nextcloud-command@users.noreply.github.com>
Diffstat (limited to 'core/src/components/UserMenu.js')
-rw-r--r--core/src/components/UserMenu.js12
1 files changed, 9 insertions, 3 deletions
diff --git a/core/src/components/UserMenu.js b/core/src/components/UserMenu.js
index c4cb6527da3..aaecec546b9 100644
--- a/core/src/components/UserMenu.js
+++ b/core/src/components/UserMenu.js
@@ -26,6 +26,10 @@ import $ from 'jquery'
export const setUp = () => {
const $menu = $('#header #settings')
+ // Using page terminoogy as below
+ const $excludedPageClasses = [
+ 'user-status-menu-item__header',
+ ]
// show loading feedback
$menu.delegate('a', 'click', event => {
@@ -34,9 +38,11 @@ export const setUp = () => {
$page = $page.closest('a')
}
if (event.which === 1 && !event.ctrlKey && !event.metaKey) {
- $page.find('img').remove()
- $page.find('div').remove() // prevent odd double-clicks
- $page.prepend($('<div/>').addClass('icon-loading-small'))
+ if (!$excludedPageClasses.includes($page.attr('class'))) {
+ $page.find('img').remove()
+ $page.find('div').remove() // prevent odd double-clicks
+ $page.prepend($('<div/>').addClass('icon-loading-small'))
+ }
} else {
// Close navigation when opening menu entry in
// a new tab