diff --git a/containers/libreportal/frontend/html/topbar.html b/containers/libreportal/frontend/html/topbar.html index 396ad1a..a5ef5ae 100755 --- a/containers/libreportal/frontend/html/topbar.html +++ b/containers/libreportal/frontend/html/topbar.html @@ -9,7 +9,7 @@
diff --git a/containers/libreportal/frontend/js/components/app/apps-manager.js b/containers/libreportal/frontend/js/components/app/apps-manager.js index 8b9a688..6313f6d 100755 --- a/containers/libreportal/frontend/js/components/app/apps-manager.js +++ b/containers/libreportal/frontend/js/components/app/apps-manager.js @@ -652,7 +652,7 @@ class AppsManager { if (onHiddenTab) { window.appTabbedManager.switchTab('config'); } - let icon = app.icon || 'icons/apps/default.svg'; + let icon = app.icon || '/icons/apps/default.svg'; // Ensure absolute path from root if (!icon.startsWith('/')) { @@ -672,7 +672,7 @@ class AppsManager { const headerHTML = `
- ${shortName} + ${shortName}

${shortName}

@@ -1701,7 +1701,7 @@ class AppsManager { card.dataset.search = searchHaystack; const appName = app.command.split(' ').pop(); - let icon = app.icon || 'icons/apps/default.svg'; + let icon = app.icon || '/icons/apps/default.svg'; // Ensure absolute path from root if (!icon.startsWith('/')) { @@ -2476,7 +2476,7 @@ class AppsManager { async getFieldMappings() { try { // Load from apps folder (static file) - const response = await fetch('data/apps/apps-field-mappings.json'); + const response = await fetch('/data/apps/apps-field-mappings.json'); const data = await response.json(); //// // console.log('✅ Loaded field mappings from apps folder'); return data.fields || data; diff --git a/containers/libreportal/frontend/js/components/backup/backup-page.js b/containers/libreportal/frontend/js/components/backup/backup-page.js index b62eb33..6cb8fec 100644 --- a/containers/libreportal/frontend/js/components/backup/backup-page.js +++ b/containers/libreportal/frontend/js/components/backup/backup-page.js @@ -577,7 +577,7 @@ class BackupPage { const command = a.command || ''; return command.endsWith(` ${slug}`) || a.name?.toLowerCase() === slug.toLowerCase(); }); - let icon = match?.icon || 'icons/apps/default.svg'; + let icon = match?.icon || '/icons/apps/default.svg'; if (!icon.startsWith('/')) icon = '/' + icon; const displayName = (typeof window.getAppDisplayName === 'function') ? window.getAppDisplayName(slug) diff --git a/containers/libreportal/frontend/js/components/config/config-validator.js b/containers/libreportal/frontend/js/components/config/config-validator.js index 5f1510c..607c06b 100755 --- a/containers/libreportal/frontend/js/components/config/config-validator.js +++ b/containers/libreportal/frontend/js/components/config/config-validator.js @@ -23,7 +23,7 @@ window.ConfigValidator = function() { // Check if unified config file exists (file existence check only) const configFiles = [ - { name: 'Unified System Config', path: 'data/config/generated/configs.json' } + { name: 'Unified System Config', path: '/data/config/generated/configs.json' } ]; for (const config of configFiles) { diff --git a/containers/libreportal/frontend/js/components/dashboard.js b/containers/libreportal/frontend/js/components/dashboard.js index dcf3b4a..47e8b84 100755 --- a/containers/libreportal/frontend/js/components/dashboard.js +++ b/containers/libreportal/frontend/js/components/dashboard.js @@ -34,7 +34,7 @@ function renderInstalledApps() { function createInstalledAppCard(app) { const appName = app.command.split(' ').pop(); - let icon = app.icon || 'icons/apps/default.svg'; + let icon = app.icon || '/icons/apps/default.svg'; if (!icon.startsWith('/')) icon = '/' + icon; const shortName = app.name.split(' - ')[0].trim(); diff --git a/containers/libreportal/frontend/js/components/notifications.js b/containers/libreportal/frontend/js/components/notifications.js index 43bda97..92f8dc3 100755 --- a/containers/libreportal/frontend/js/components/notifications.js +++ b/containers/libreportal/frontend/js/components/notifications.js @@ -103,7 +103,7 @@ class NotificationSystem { if (appIcon) { content += `
- ${appName} + ${appName}
`; } diff --git a/containers/libreportal/frontend/js/components/task/task-actions.js b/containers/libreportal/frontend/js/components/task/task-actions.js index d2611b2..31ebe53 100755 --- a/containers/libreportal/frontend/js/components/task/task-actions.js +++ b/containers/libreportal/frontend/js/components/task/task-actions.js @@ -290,7 +290,7 @@ async configUpdate(changes) { } catch (error) { console.warn('Could not get app data:', error); } - const appIcon = appData?.icon || `icons/apps/${task.app}.svg`; + const appIcon = appData?.icon || `/icons/apps/${task.app}.svg`; let taskUrl; const currentUrl = window.location.href; @@ -356,7 +356,7 @@ async configUpdate(changes) { } catch (error) { console.warn('Could not get app data:', error); } - const appIcon = appData?.icon || `icons/apps/${task.app}.svg`; + const appIcon = appData?.icon || `/icons/apps/${task.app}.svg`; // Smart URL generation - always include app name let taskUrl; diff --git a/containers/libreportal/frontend/js/components/task/task-commands.js b/containers/libreportal/frontend/js/components/task/task-commands.js index e33fd0c..217132f 100755 --- a/containers/libreportal/frontend/js/components/task/task-commands.js +++ b/containers/libreportal/frontend/js/components/task/task-commands.js @@ -331,7 +331,7 @@ class TaskCommands { // Fallback: create minimal app data return { name: appName, - icon: `icons/apps/${appName}.svg`, + icon: `/icons/apps/${appName}.svg`, command: `libreportal app install ${appName}` }; } diff --git a/containers/libreportal/frontend/js/components/tasks/tasks-manager.js b/containers/libreportal/frontend/js/components/tasks/tasks-manager.js index 6a8d989..ce08c84 100755 --- a/containers/libreportal/frontend/js/components/tasks/tasks-manager.js +++ b/containers/libreportal/frontend/js/components/tasks/tasks-manager.js @@ -1035,7 +1035,7 @@ class TasksManager { } // Default icon path - return `icons/apps/${task.app}.svg`; + return `/icons/apps/${task.app}.svg`; } updateStats() { @@ -1343,7 +1343,7 @@ class TasksManager { 'info', appName, taskUrl, - `icons/apps/${appName}.svg`, + `/icons/apps/${appName}.svg`, customIcon ); } @@ -1458,7 +1458,7 @@ class TasksManager { const url = (onAppPage && appName) ? `/app/${appName}?tab=tasks&task=${taskId}` : `/tasks/all?task=${taskId}`; - const icon = appName ? `icons/apps/${appName}.svg` : null; + const icon = appName ? `/icons/apps/${appName}.svg` : null; // Match the per-action emoji used in the task list rows (see // `getTaskTypeIcon`). Passed as the 6th `customIcon` arg so the diff --git a/containers/libreportal/frontend/js/system/setup-wizard.js b/containers/libreportal/frontend/js/system/setup-wizard.js index ba59ad2..da6a8b7 100755 --- a/containers/libreportal/frontend/js/system/setup-wizard.js +++ b/containers/libreportal/frontend/js/system/setup-wizard.js @@ -327,7 +327,7 @@ class SetupWizard { const app = manifest.get(slug) || {}; const name = app.title || app.name || fallback.name; const desc = app.description || fallback.description; - const icon = app.icon || `icons/apps/${slug}.svg`; + const icon = app.icon || `/icons/apps/${slug}.svg`; // Sub-option lives OUTSIDE the parent label (nested