From 406444e17f177fedf0ce9af40bfa53224a0c2304 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Ferenc=20S=C3=A1rai?= Date: Mon, 13 Jan 2025 15:42:19 +0100 Subject: [PATCH 1/2] feat: update to bee-dashboard v0.31.0 --- ui/package-lock.json | 14 +++++++------- ui/package.json | 2 +- 2 files changed, 8 insertions(+), 8 deletions(-) diff --git a/ui/package-lock.json b/ui/package-lock.json index 1170e46..d7d0419 100644 --- a/ui/package-lock.json +++ b/ui/package-lock.json @@ -8,7 +8,7 @@ "name": "swarm-desktop-ui", "version": "0.1.0", "dependencies": { - "@ethersphere/bee-dashboard": "^0.30.0", + "@ethersphere/bee-dashboard": "^0.31.0", "@types/jest": "^28.1.3", "@types/node": "^18.0.0", "@types/react": "^18.0.14", @@ -2361,9 +2361,9 @@ } }, "node_modules/@ethersphere/bee-dashboard": { - "version": "0.30.0", - "resolved": "https://registry.npmjs.org/@ethersphere/bee-dashboard/-/bee-dashboard-0.30.0.tgz", - "integrity": "sha512-pBrH5nJ+Z0XqIEUFZBJWb/YUF/QlwinIHjxBxuwwdEZaHrTrV92psTONnBriKNWlKVdSImLwePT/rRuXTrcoKg==", + "version": "0.31.0", + "resolved": "https://registry.npmjs.org/@ethersphere/bee-dashboard/-/bee-dashboard-0.31.0.tgz", + "integrity": "sha512-vnzhUlRVxFODY1RcqCZLRHpbd3E/QzkQswVZHeH8+dQ0tAwLtWC8Hg0A419/+rLr5eRAtTAyzEHnySu6Wp0mHQ==", "license": "BSD-3-Clause", "dependencies": { "@ethersphere/bee-js": "^8.3.1", @@ -20795,9 +20795,9 @@ } }, "@ethersphere/bee-dashboard": { - "version": "0.30.0", - "resolved": "https://registry.npmjs.org/@ethersphere/bee-dashboard/-/bee-dashboard-0.30.0.tgz", - "integrity": "sha512-pBrH5nJ+Z0XqIEUFZBJWb/YUF/QlwinIHjxBxuwwdEZaHrTrV92psTONnBriKNWlKVdSImLwePT/rRuXTrcoKg==", + "version": "0.31.0", + "resolved": "https://registry.npmjs.org/@ethersphere/bee-dashboard/-/bee-dashboard-0.31.0.tgz", + "integrity": "sha512-vnzhUlRVxFODY1RcqCZLRHpbd3E/QzkQswVZHeH8+dQ0tAwLtWC8Hg0A419/+rLr5eRAtTAyzEHnySu6Wp0mHQ==", "requires": { "@ethersphere/bee-js": "^8.3.1", "@ethersphere/swarm-cid": "^0.1.0", diff --git a/ui/package.json b/ui/package.json index 942e6fd..7e8fe68 100644 --- a/ui/package.json +++ b/ui/package.json @@ -4,7 +4,7 @@ "private": true, "homepage": "http://localhost:5000/dashboard", "dependencies": { - "@ethersphere/bee-dashboard": "^0.30.0", + "@ethersphere/bee-dashboard": "^0.31.0", "@types/jest": "^28.1.3", "@types/node": "^18.0.0", "@types/react": "^18.0.14", From f764c5c003686ba1311633fd8b2cc85423c9e018 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Ferenc=20S=C3=A1rai?= Date: Tue, 14 Jan 2025 12:30:17 +0100 Subject: [PATCH 2/2] feat: add FDP link to Apps tray menu --- src/browser.ts | 4 ++++ src/electron.ts | 6 +++++- 2 files changed, 9 insertions(+), 1 deletion(-) diff --git a/src/browser.ts b/src/browser.ts index 979f203..9211ac0 100644 --- a/src/browser.ts +++ b/src/browser.ts @@ -9,3 +9,7 @@ export function openDashboardInBrowser() { export function openUrl(url: string) { shell.openExternal(url) } + +export function openPath(path: string) { + shell.openExternal(`http://localhost:${port.value}/dashboard/?#${path}`) +} diff --git a/src/electron.ts b/src/electron.ts index f6bd848..e07bd20 100644 --- a/src/electron.ts +++ b/src/electron.ts @@ -1,6 +1,6 @@ import { app, BrowserWindow, Menu, nativeTheme, Tray } from 'electron' import opener from 'opener' -import { openDashboardInBrowser, openUrl } from './browser' +import { openDashboardInBrowser, openUrl, openPath } from './browser' import { runLauncher } from './launcher' import { BeeManager } from './lifecycle' import { createNotification } from './notify' @@ -35,6 +35,10 @@ export function rebuildElectronTray() { type: 'submenu', label: 'Apps', submenu: [ + { + label: 'FDP', + click: () => openPath('/fdp'), + }, { label: 'Datafund App', click: () => openUrl('https://app.datafund.io'),