diff --git a/dashboard/package-lock.json b/dashboard/package-lock.json index 0aec79dab..96bd8e335 100644 --- a/dashboard/package-lock.json +++ b/dashboard/package-lock.json @@ -6,7 +6,7 @@ "packages": { "": { "dependencies": { - "@cloudron/pankow": "^3.5.5", + "@cloudron/pankow": "^3.5.6", "@fontsource/inter": "^5.2.8", "@fortawesome/fontawesome-free": "^7.1.0", "@vitejs/plugin-vue": "^6.0.1", @@ -17,12 +17,12 @@ "async": "^3.2.6", "chart.js": "^4.5.1", "chartjs-plugin-annotation": "^3.1.0", - "eslint": "^9.38.0", + "eslint": "^9.39.0", "eslint-plugin-vue": "^10.5.1", "marked": "^16.4.1", "moment": "^2.30.1", "moment-timezone": "^0.6.0", - "vite": "^7.1.10", + "vite": "^7.1.12", "vite-plugin-singlefile": "^2.3.0", "vue": "^3.5.22", "vue-i18n": "^11.1.12", @@ -76,9 +76,9 @@ } }, "node_modules/@cloudron/pankow": { - "version": "3.5.5", - "resolved": "https://registry.npmjs.org/@cloudron/pankow/-/pankow-3.5.5.tgz", - "integrity": "sha512-jTS9yEft6wSr96kCplyy76CmO+2OrhktIcUWwopH75nj61mXwM2/QMmgq3bG7pYnKpefgit43QqZ/b+/wUhQ1Q==", + "version": "3.5.6", + "resolved": "https://registry.npmjs.org/@cloudron/pankow/-/pankow-3.5.6.tgz", + "integrity": "sha512-6N10wpe6iO13fmBrnZ7KMrqRvmyh5e6qCkdj7jaR7ojatp5ozTDCvI1IwY4Nxpj/UWUUgXiYMlNgluWFhN4IsA==", "license": "ISC", "dependencies": { "@fontsource/inter": "^5.2.8", @@ -540,21 +540,21 @@ } }, "node_modules/@eslint/config-helpers": { - "version": "0.4.1", - "resolved": "https://registry.npmjs.org/@eslint/config-helpers/-/config-helpers-0.4.1.tgz", - "integrity": "sha512-csZAzkNhsgwb0I/UAV6/RGFTbiakPCf0ZrGmrIxQpYvGZ00PhTkSnyKNolphgIvmnJeGw6rcGVEXfTzUnFuEvw==", + "version": "0.4.2", + "resolved": "https://registry.npmjs.org/@eslint/config-helpers/-/config-helpers-0.4.2.tgz", + "integrity": "sha512-gBrxN88gOIf3R7ja5K9slwNayVcZgK6SOUORm2uBzTeIEfeVaIhOpCtTox3P6R7o2jLFwLFTLnC7kU/RGcYEgw==", "license": "Apache-2.0", "dependencies": { - "@eslint/core": "^0.16.0" + "@eslint/core": "^0.17.0" }, "engines": { "node": "^18.18.0 || ^20.9.0 || >=21.1.0" } }, "node_modules/@eslint/core": { - "version": "0.16.0", - "resolved": "https://registry.npmjs.org/@eslint/core/-/core-0.16.0.tgz", - "integrity": "sha512-nmC8/totwobIiFcGkDza3GIKfAw1+hLiYVrh3I1nIomQ8PEr5cxg34jnkmGawul/ep52wGRAcyeDCNtWKSOj4Q==", + "version": "0.17.0", + "resolved": "https://registry.npmjs.org/@eslint/core/-/core-0.17.0.tgz", + "integrity": "sha512-yL/sLrpmtDaFEiUj1osRP4TI2MDz1AddJL+jZ7KSqvBuliN4xqYY54IfdN8qD8Toa6g1iloph1fxQNkjOxrrpQ==", "license": "Apache-2.0", "dependencies": { "@types/json-schema": "^7.0.15" @@ -587,9 +587,9 @@ } }, "node_modules/@eslint/js": { - "version": "9.38.0", - "resolved": "https://registry.npmjs.org/@eslint/js/-/js-9.38.0.tgz", - "integrity": "sha512-UZ1VpFvXf9J06YG9xQBdnzU+kthors6KjhMAl6f4gH4usHyh31rUf2DLGInT8RFYIReYXNSydgPY0V2LuWgl7A==", + "version": "9.39.0", + "resolved": "https://registry.npmjs.org/@eslint/js/-/js-9.39.0.tgz", + "integrity": "sha512-BIhe0sW91JGPiaF1mOuPy5v8NflqfjIcDNpC+LbW9f609WVRX1rArrhi6Z2ymvrAry9jw+5POTj4t2t62o8Bmw==", "license": "MIT", "engines": { "node": "^18.18.0 || ^20.9.0 || >=21.1.0" @@ -608,12 +608,12 @@ } }, "node_modules/@eslint/plugin-kit": { - "version": "0.4.0", - "resolved": "https://registry.npmjs.org/@eslint/plugin-kit/-/plugin-kit-0.4.0.tgz", - "integrity": "sha512-sB5uyeq+dwCWyPi31B2gQlVlo+j5brPlWx4yZBrEaRo/nhdDE8Xke1gsGgtiBdaBTxuTkceLVuVt/pclrasb0A==", + "version": "0.4.1", + "resolved": "https://registry.npmjs.org/@eslint/plugin-kit/-/plugin-kit-0.4.1.tgz", + "integrity": "sha512-43/qtrDUokr7LJqoF2c3+RInu/t4zfrpYdoSDfYyhg52rwLV6TnOvdG4fXm7IkSB3wErkcmJS9iEhjVtOSEjjA==", "license": "Apache-2.0", "dependencies": { - "@eslint/core": "^0.16.0", + "@eslint/core": "^0.17.0", "levn": "^0.4.1" }, "engines": { @@ -1457,19 +1457,19 @@ } }, "node_modules/eslint": { - "version": "9.38.0", - "resolved": "https://registry.npmjs.org/eslint/-/eslint-9.38.0.tgz", - "integrity": "sha512-t5aPOpmtJcZcz5UJyY2GbvpDlsK5E8JqRqoKtfiKE3cNh437KIqfJr3A3AKf5k64NPx6d0G3dno6XDY05PqPtw==", + "version": "9.39.0", + "resolved": "https://registry.npmjs.org/eslint/-/eslint-9.39.0.tgz", + "integrity": "sha512-iy2GE3MHrYTL5lrCtMZ0X1KLEKKUjmK0kzwcnefhR66txcEmXZD2YWgR5GNdcEwkNx3a0siYkSvl0vIC+Svjmg==", "license": "MIT", "dependencies": { "@eslint-community/eslint-utils": "^4.8.0", "@eslint-community/regexpp": "^4.12.1", "@eslint/config-array": "^0.21.1", - "@eslint/config-helpers": "^0.4.1", - "@eslint/core": "^0.16.0", + "@eslint/config-helpers": "^0.4.2", + "@eslint/core": "^0.17.0", "@eslint/eslintrc": "^3.3.1", - "@eslint/js": "9.38.0", - "@eslint/plugin-kit": "^0.4.0", + "@eslint/js": "9.39.0", + "@eslint/plugin-kit": "^0.4.1", "@humanfs/node": "^0.16.6", "@humanwhocodes/module-importer": "^1.0.1", "@humanwhocodes/retry": "^0.4.2", @@ -2383,9 +2383,9 @@ "integrity": "sha1-RQ1Nyfpw3nMnYvvS1KKJgUGaDM8=" }, "node_modules/vite": { - "version": "7.1.10", - "resolved": "https://registry.npmjs.org/vite/-/vite-7.1.10.tgz", - "integrity": "sha512-CmuvUBzVJ/e3HGxhg6cYk88NGgTnBoOo7ogtfJJ0fefUWAxN/WDSUa50o+oVBxuIhO8FoEZW0j2eW7sfjs5EtA==", + "version": "7.1.12", + "resolved": "https://registry.npmjs.org/vite/-/vite-7.1.12.tgz", + "integrity": "sha512-ZWyE8YXEXqJrrSLvYgrRP7p62OziLW7xI5HYGWFzOvupfAlrLvURSzv/FyGyy0eidogEM3ujU+kUG1zuHgb6Ug==", "license": "MIT", "dependencies": { "esbuild": "^0.25.0", @@ -2654,9 +2654,9 @@ } }, "@cloudron/pankow": { - "version": "3.5.5", - "resolved": "https://registry.npmjs.org/@cloudron/pankow/-/pankow-3.5.5.tgz", - "integrity": "sha512-jTS9yEft6wSr96kCplyy76CmO+2OrhktIcUWwopH75nj61mXwM2/QMmgq3bG7pYnKpefgit43QqZ/b+/wUhQ1Q==", + "version": "3.5.6", + "resolved": "https://registry.npmjs.org/@cloudron/pankow/-/pankow-3.5.6.tgz", + "integrity": "sha512-6N10wpe6iO13fmBrnZ7KMrqRvmyh5e6qCkdj7jaR7ojatp5ozTDCvI1IwY4Nxpj/UWUUgXiYMlNgluWFhN4IsA==", "requires": { "@fontsource/inter": "^5.2.8", "@fortawesome/fontawesome-free": "^7.1.0", @@ -2845,17 +2845,17 @@ } }, "@eslint/config-helpers": { - "version": "0.4.1", - "resolved": "https://registry.npmjs.org/@eslint/config-helpers/-/config-helpers-0.4.1.tgz", - "integrity": "sha512-csZAzkNhsgwb0I/UAV6/RGFTbiakPCf0ZrGmrIxQpYvGZ00PhTkSnyKNolphgIvmnJeGw6rcGVEXfTzUnFuEvw==", + "version": "0.4.2", + "resolved": "https://registry.npmjs.org/@eslint/config-helpers/-/config-helpers-0.4.2.tgz", + "integrity": "sha512-gBrxN88gOIf3R7ja5K9slwNayVcZgK6SOUORm2uBzTeIEfeVaIhOpCtTox3P6R7o2jLFwLFTLnC7kU/RGcYEgw==", "requires": { - "@eslint/core": "^0.16.0" + "@eslint/core": "^0.17.0" } }, "@eslint/core": { - "version": "0.16.0", - "resolved": "https://registry.npmjs.org/@eslint/core/-/core-0.16.0.tgz", - "integrity": "sha512-nmC8/totwobIiFcGkDza3GIKfAw1+hLiYVrh3I1nIomQ8PEr5cxg34jnkmGawul/ep52wGRAcyeDCNtWKSOj4Q==", + "version": "0.17.0", + "resolved": "https://registry.npmjs.org/@eslint/core/-/core-0.17.0.tgz", + "integrity": "sha512-yL/sLrpmtDaFEiUj1osRP4TI2MDz1AddJL+jZ7KSqvBuliN4xqYY54IfdN8qD8Toa6g1iloph1fxQNkjOxrrpQ==", "requires": { "@types/json-schema": "^7.0.15" } @@ -2877,9 +2877,9 @@ } }, "@eslint/js": { - "version": "9.38.0", - "resolved": "https://registry.npmjs.org/@eslint/js/-/js-9.38.0.tgz", - "integrity": "sha512-UZ1VpFvXf9J06YG9xQBdnzU+kthors6KjhMAl6f4gH4usHyh31rUf2DLGInT8RFYIReYXNSydgPY0V2LuWgl7A==" + "version": "9.39.0", + "resolved": "https://registry.npmjs.org/@eslint/js/-/js-9.39.0.tgz", + "integrity": "sha512-BIhe0sW91JGPiaF1mOuPy5v8NflqfjIcDNpC+LbW9f609WVRX1rArrhi6Z2ymvrAry9jw+5POTj4t2t62o8Bmw==" }, "@eslint/object-schema": { "version": "2.1.7", @@ -2887,11 +2887,11 @@ "integrity": "sha512-VtAOaymWVfZcmZbp6E2mympDIHvyjXs/12LqWYjVw6qjrfF+VK+fyG33kChz3nnK+SU5/NeHOqrTEHS8sXO3OA==" }, "@eslint/plugin-kit": { - "version": "0.4.0", - "resolved": "https://registry.npmjs.org/@eslint/plugin-kit/-/plugin-kit-0.4.0.tgz", - "integrity": "sha512-sB5uyeq+dwCWyPi31B2gQlVlo+j5brPlWx4yZBrEaRo/nhdDE8Xke1gsGgtiBdaBTxuTkceLVuVt/pclrasb0A==", + "version": "0.4.1", + "resolved": "https://registry.npmjs.org/@eslint/plugin-kit/-/plugin-kit-0.4.1.tgz", + "integrity": "sha512-43/qtrDUokr7LJqoF2c3+RInu/t4zfrpYdoSDfYyhg52rwLV6TnOvdG4fXm7IkSB3wErkcmJS9iEhjVtOSEjjA==", "requires": { - "@eslint/core": "^0.16.0", + "@eslint/core": "^0.17.0", "levn": "^0.4.1" } }, @@ -3416,18 +3416,18 @@ } }, "eslint": { - "version": "9.38.0", - "resolved": "https://registry.npmjs.org/eslint/-/eslint-9.38.0.tgz", - "integrity": "sha512-t5aPOpmtJcZcz5UJyY2GbvpDlsK5E8JqRqoKtfiKE3cNh437KIqfJr3A3AKf5k64NPx6d0G3dno6XDY05PqPtw==", + "version": "9.39.0", + "resolved": "https://registry.npmjs.org/eslint/-/eslint-9.39.0.tgz", + "integrity": "sha512-iy2GE3MHrYTL5lrCtMZ0X1KLEKKUjmK0kzwcnefhR66txcEmXZD2YWgR5GNdcEwkNx3a0siYkSvl0vIC+Svjmg==", "requires": { "@eslint-community/eslint-utils": "^4.8.0", "@eslint-community/regexpp": "^4.12.1", "@eslint/config-array": "^0.21.1", - "@eslint/config-helpers": "^0.4.1", - "@eslint/core": "^0.16.0", + "@eslint/config-helpers": "^0.4.2", + "@eslint/core": "^0.17.0", "@eslint/eslintrc": "^3.3.1", - "@eslint/js": "9.38.0", - "@eslint/plugin-kit": "^0.4.0", + "@eslint/js": "9.39.0", + "@eslint/plugin-kit": "^0.4.1", "@humanfs/node": "^0.16.6", "@humanwhocodes/module-importer": "^1.0.1", "@humanwhocodes/retry": "^0.4.2", @@ -4007,9 +4007,9 @@ "integrity": "sha1-RQ1Nyfpw3nMnYvvS1KKJgUGaDM8=" }, "vite": { - "version": "7.1.10", - "resolved": "https://registry.npmjs.org/vite/-/vite-7.1.10.tgz", - "integrity": "sha512-CmuvUBzVJ/e3HGxhg6cYk88NGgTnBoOo7ogtfJJ0fefUWAxN/WDSUa50o+oVBxuIhO8FoEZW0j2eW7sfjs5EtA==", + "version": "7.1.12", + "resolved": "https://registry.npmjs.org/vite/-/vite-7.1.12.tgz", + "integrity": "sha512-ZWyE8YXEXqJrrSLvYgrRP7p62OziLW7xI5HYGWFzOvupfAlrLvURSzv/FyGyy0eidogEM3ujU+kUG1zuHgb6Ug==", "requires": { "esbuild": "^0.25.0", "fdir": "^6.5.0", diff --git a/dashboard/package.json b/dashboard/package.json index 7ea56c813..6c2a3d530 100644 --- a/dashboard/package.json +++ b/dashboard/package.json @@ -7,7 +7,7 @@ }, "type": "module", "dependencies": { - "@cloudron/pankow": "^3.5.5", + "@cloudron/pankow": "^3.5.6", "@fontsource/inter": "^5.2.8", "@fortawesome/fontawesome-free": "^7.1.0", "@vitejs/plugin-vue": "^6.0.1", @@ -18,12 +18,12 @@ "async": "^3.2.6", "chart.js": "^4.5.1", "chartjs-plugin-annotation": "^3.1.0", - "eslint": "^9.38.0", + "eslint": "^9.39.0", "eslint-plugin-vue": "^10.5.1", "marked": "^16.4.1", "moment": "^2.30.1", "moment-timezone": "^0.6.0", - "vite": "^7.1.10", + "vite": "^7.1.12", "vite-plugin-singlefile": "^2.3.0", "vue": "^3.5.22", "vue-i18n": "^11.1.12", diff --git a/dashboard/src/components/Headerbar.vue b/dashboard/src/components/Headerbar.vue index e4b400232..f5d7c2bbe 100644 --- a/dashboard/src/components/Headerbar.vue +++ b/dashboard/src/components/Headerbar.vue @@ -33,6 +33,9 @@ const notificationsAllBusy = ref(false); function onOpenNotifications(popover, event, elem) { popover.open(event, elem); + + // close after 2 seconds if there is nothing to show + if (notifications.value.length === 0) setTimeout(popover.close, 2000); } async function onMarkNotificationRead(notification) { @@ -55,6 +58,8 @@ async function onMarkAllNotificationRead() { await refresh(); notificationsAllBusy.value = false; + + if (notifications.value.length === 0) setTimeout(helpPopover.value.close, 2000); } async function refresh() { diff --git a/dashboard/src/models/NotificationsModel.js b/dashboard/src/models/NotificationsModel.js index 80bee67b9..ad7e9a54d 100644 --- a/dashboard/src/models/NotificationsModel.js +++ b/dashboard/src/models/NotificationsModel.js @@ -9,7 +9,7 @@ function create() { async list(acknowledged = false) { let result; try { - result = await fetcher.get(`${API_ORIGIN}/api/v1/notifications`, { acknowledged, access_token: accessToken }); + result = await fetcher.get(`${API_ORIGIN}/api/v1/notifications`, { acknowledged, access_token: accessToken, per_page: 100 }); } catch (e) { return [e]; }