diff --git a/CITATION.cff b/CITATION.cff index 1616ad3..d0d8af3 100644 --- a/CITATION.cff +++ b/CITATION.cff @@ -4,7 +4,7 @@ title: "TRIMSP-NL Workbench" type: software version: 1.5.0 date-released: 2026-08-28 -url: "http://musruser.psi.ch/TrimSP-NL/" +url: "http://musruser.psi.ch/TRIMSP-NL/" repository-code: "https://gitea.psi.ch/LMU/TRIMSP" license: GPL-3.0-or-later authors: diff --git a/README.md b/README.md index a4b50d6..7849bfb 100644 --- a/README.md +++ b/README.md @@ -53,7 +53,7 @@ Repository metadata is also provided in [CITATION.cff](CITATION.cff). ### Supported platforms ### * [Linux] -* Online at: http://musruser.psi.ch/TrimSP-NL/ +* Online at: http://musruser.psi.ch/TRIMSP-NL/ * Source repository: https://gitea.psi.ch/LMU/TRIMSP ### Installation ### diff --git a/TrimSPelec.js b/TrimSPelec.js index a27a7fa..a6dc358 100644 --- a/TrimSPelec.js +++ b/TrimSPelec.js @@ -18,7 +18,7 @@ window.openElectronAuxiliaryWindow = openElectronAuxiliaryWindow; // Electron links always point to the public web application rather than a // machine-local file:// URL, so they can be sent directly to another user. -var TRIMSP_CANONICAL_SHARE_URL = 'http://musruser.psi.ch/TrimSP-NL/'; +var TRIMSP_CANONICAL_SHARE_URL = 'http://musruser.psi.ch/TRIMSP-NL/'; function encodeElectronSharedConfiguration(config) { let json = JSON.stringify(config); diff --git a/TrimSPlib.js b/TrimSPlib.js index e90ff32..e92052c 100644 --- a/TrimSPlib.js +++ b/TrimSPlib.js @@ -3128,8 +3128,22 @@ function showTransientWarning(message, targetElement, duration = 4000) { warning.textContent = message; if (targetElement) { const rect = targetElement.getBoundingClientRect(); - warning.style.left = `${Math.max(12, rect.left + window.scrollX)}px`; - warning.style.top = `${rect.bottom + window.scrollY + 8}px`; + const viewportMargin = 12; + const targetGap = 8; + const maximumLeft = Math.max(viewportMargin, + window.innerWidth - warning.offsetWidth - viewportMargin); + const left = Math.min(Math.max(viewportMargin, rect.left), maximumLeft); + let top = rect.bottom + targetGap; + + // Keep notifications inside the viewport, including for controls near its + // right and bottom edges. Fixed-position elements use viewport coordinates. + if (top + warning.offsetHeight > window.innerHeight - viewportMargin) { + top = rect.top - warning.offsetHeight - targetGap; + } + top = Math.max(viewportMargin, + Math.min(top, window.innerHeight - warning.offsetHeight - viewportMargin)); + warning.style.left = `${left}px`; + warning.style.top = `${top}px`; } warning.classList.add('visible'); diff --git a/ZGUI.css b/ZGUI.css index ac563cf..a6a6bae 100644 --- a/ZGUI.css +++ b/ZGUI.css @@ -580,7 +580,8 @@ input[type="button"]:hover { box-shadow: 0 7px 20px rgba(29, 43, 50, 0.17); color: #523c08; line-height: 1.35; - max-width: 380px; + box-sizing: border-box; + max-width: min(380px, calc(100vw - 24px)); opacity: 0; padding: 9px 12px; pointer-events: none; diff --git a/main.js b/main.js index 8700046..6b3f5f8 100644 --- a/main.js +++ b/main.js @@ -156,7 +156,7 @@ function showAboutDialog(parentWindow) { '', 'Project repository:', 'Gitea: gitea.psi.ch/LMU/TRIMSP', - 'Web application: musruser.psi.ch/TrimSP-NL/' + 'Web application: musruser.psi.ch/TRIMSP-NL/' ].join('\n'); dialog.showMessageBox(parentWindow, { @@ -507,7 +507,7 @@ ipcMain.on('openQuickStartWindow', (event, options) => { ipcMain.handle('copyConfigurationLink', async (event, url) => { if (typeof url !== 'string' || url.length > 500000 - || !url.startsWith('http://musruser.psi.ch/TrimSP-NL/')) { + || !url.startsWith('http://musruser.psi.ch/TRIMSP-NL/')) { throw new Error('Invalid configuration link'); } clipboard.writeText(url); diff --git a/package.json b/package.json index 10c0428..2603194 100644 --- a/package.json +++ b/package.json @@ -41,7 +41,7 @@ "plotly.js-dist": "^1.58.4" }, "config": {}, - "homepage": "http://musruser.psi.ch/TrimSP-NL/", + "homepage": "http://musruser.psi.ch/TRIMSP-NL/", "repository": { "type": "git", "url": "https://gitea.psi.ch/LMU/TRIMSP.git"