From 5c009f287c5ff2ae5c922c5760336c88a1edf66f Mon Sep 17 00:00:00 2001 From: Bill Thornton Date: Wed, 2 Dec 2020 13:59:49 -0500 Subject: [PATCH 1/2] Fix handling of /#!/ routes in appRouter --- src/components/appRouter.js | 64 ++++++++++++++++++++----------------- 1 file changed, 35 insertions(+), 29 deletions(-) diff --git a/src/components/appRouter.js b/src/components/appRouter.js index b7504c387e..333058e1c8 100644 --- a/src/components/appRouter.js +++ b/src/components/appRouter.js @@ -51,6 +51,12 @@ class AppRouter { } this.setBaseRoute(); + + // paths that start with a hashbang (i.e. /#!/page.html) get transformed to starting with // + // we need to strip one "/" for our routes to work + page('//*', (ctx) => { + page.redirect(ctx.path.substring(1)); + }); } /** @@ -682,27 +688,27 @@ class AppRouter { const serverId = item.ServerId || options.serverId; if (item === 'settings') { - return 'mypreferencesmenu.html'; + return '#!/mypreferencesmenu.html'; } if (item === 'wizard') { - return 'wizardstart.html'; + return '#!/wizardstart.html'; } if (item === 'manageserver') { - return 'dashboard.html'; + return '#!/dashboard.html'; } if (item === 'recordedtv') { - return 'livetv.html?tab=3&serverId=' + options.serverId; + return '#!/livetv.html?tab=3&serverId=' + options.serverId; } if (item === 'nextup') { - return 'list.html?type=nextup&serverId=' + options.serverId; + return '#!/list.html?type=nextup&serverId=' + options.serverId; } if (item === 'list') { - let url = 'list.html?serverId=' + options.serverId + '&type=' + options.itemTypes; + let url = '#!/list.html?serverId=' + options.serverId + '&type=' + options.itemTypes; if (options.isFavorite) { url += '&IsFavorite=true'; @@ -713,57 +719,57 @@ class AppRouter { if (item === 'livetv') { if (options.section === 'programs') { - return 'livetv.html?tab=0&serverId=' + options.serverId; + return '#!/livetv.html?tab=0&serverId=' + options.serverId; } if (options.section === 'guide') { - return 'livetv.html?tab=1&serverId=' + options.serverId; + return '#!/livetv.html?tab=1&serverId=' + options.serverId; } if (options.section === 'movies') { - return 'list.html?type=Programs&IsMovie=true&serverId=' + options.serverId; + return '#!/list.html?type=Programs&IsMovie=true&serverId=' + options.serverId; } if (options.section === 'shows') { - return 'list.html?type=Programs&IsSeries=true&IsMovie=false&IsNews=false&serverId=' + options.serverId; + return '#!/list.html?type=Programs&IsSeries=true&IsMovie=false&IsNews=false&serverId=' + options.serverId; } if (options.section === 'sports') { - return 'list.html?type=Programs&IsSports=true&serverId=' + options.serverId; + return '#!/list.html?type=Programs&IsSports=true&serverId=' + options.serverId; } if (options.section === 'kids') { - return 'list.html?type=Programs&IsKids=true&serverId=' + options.serverId; + return '#!/list.html?type=Programs&IsKids=true&serverId=' + options.serverId; } if (options.section === 'news') { - return 'list.html?type=Programs&IsNews=true&serverId=' + options.serverId; + return '#!/list.html?type=Programs&IsNews=true&serverId=' + options.serverId; } if (options.section === 'onnow') { - return 'list.html?type=Programs&IsAiring=true&serverId=' + options.serverId; + return '#!/list.html?type=Programs&IsAiring=true&serverId=' + options.serverId; } if (options.section === 'dvrschedule') { - return 'livetv.html?tab=4&serverId=' + options.serverId; + return '#!/livetv.html?tab=4&serverId=' + options.serverId; } if (options.section === 'seriesrecording') { - return 'livetv.html?tab=5&serverId=' + options.serverId; + return '#!/livetv.html?tab=5&serverId=' + options.serverId; } - return 'livetv.html?serverId=' + options.serverId; + return '#!/livetv.html?serverId=' + options.serverId; } if (itemType == 'SeriesTimer') { - return 'details?seriesTimerId=' + id + '&serverId=' + serverId; + return '#!/details?seriesTimerId=' + id + '&serverId=' + serverId; } if (item.CollectionType == 'livetv') { - return 'livetv.html'; + return '#!/livetv.html'; } if (item.Type === 'Genre') { - url = 'list.html?genreId=' + item.Id + '&serverId=' + serverId; + url = '#!/list.html?genreId=' + item.Id + '&serverId=' + serverId; if (context === 'livetv') { url += '&type=Programs'; @@ -777,7 +783,7 @@ class AppRouter { } if (item.Type === 'MusicGenre') { - url = 'list.html?musicGenreId=' + item.Id + '&serverId=' + serverId; + url = '#!/list.html?musicGenreId=' + item.Id + '&serverId=' + serverId; if (options.parentId) { url += '&parentId=' + options.parentId; @@ -787,7 +793,7 @@ class AppRouter { } if (item.Type === 'Studio') { - url = 'list.html?studioId=' + item.Id + '&serverId=' + serverId; + url = '#!/list.html?studioId=' + item.Id + '&serverId=' + serverId; if (options.parentId) { url += '&parentId=' + options.parentId; @@ -798,7 +804,7 @@ class AppRouter { if (context !== 'folders' && !itemHelper.isLocalItem(item)) { if (item.CollectionType == 'movies') { - url = 'movies.html?topParentId=' + item.Id; + url = '#!/movies.html?topParentId=' + item.Id; if (options && options.section === 'latest') { url += '&tab=1'; @@ -808,7 +814,7 @@ class AppRouter { } if (item.CollectionType == 'tvshows') { - url = 'tv.html?topParentId=' + item.Id; + url = '#!/tv.html?topParentId=' + item.Id; if (options && options.section === 'latest') { url += '&tab=2'; @@ -818,31 +824,31 @@ class AppRouter { } if (item.CollectionType == 'music') { - return 'music.html?topParentId=' + item.Id; + return '#!/music.html?topParentId=' + item.Id; } } const itemTypes = ['Playlist', 'TvChannel', 'Program', 'BoxSet', 'MusicAlbum', 'MusicGenre', 'Person', 'Recording', 'MusicArtist']; if (itemTypes.indexOf(itemType) >= 0) { - return 'details?id=' + id + '&serverId=' + serverId; + return '#!/details?id=' + id + '&serverId=' + serverId; } const contextSuffix = context ? '&context=' + context : ''; if (itemType == 'Series' || itemType == 'Season' || itemType == 'Episode') { - return 'details?id=' + id + contextSuffix + '&serverId=' + serverId; + return '#!/details?id=' + id + contextSuffix + '&serverId=' + serverId; } if (item.IsFolder) { if (id) { - return 'list.html?parentId=' + id + '&serverId=' + serverId; + return '#!/list.html?parentId=' + id + '&serverId=' + serverId; } return '#'; } - return 'details?id=' + id + '&serverId=' + serverId; + return '#!/details?id=' + id + '&serverId=' + serverId; } } From 0ba27ad4d908bac28388260a04e622ee09434777 Mon Sep 17 00:00:00 2001 From: Bill Thornton Date: Wed, 2 Dec 2020 14:01:07 -0500 Subject: [PATCH 2/2] Fix invalid hrefs --- src/components/favoriteitems.js | 2 +- src/components/remotecontrol/remotecontrol.js | 8 ++-- src/controllers/dashboard/dashboard.html | 10 ++--- src/controllers/dashboard/devices/devices.js | 2 +- src/controllers/dashboard/dlna/profiles.html | 2 +- src/controllers/dashboard/encodingsettings.js | 6 +-- src/controllers/dashboard/playback.js | 6 +-- .../dashboard/plugins/available/index.js | 2 +- .../dashboard/plugins/installed/index.js | 2 +- src/controllers/dashboard/streaming.js | 6 +-- .../dashboard/users/userprofilespage.js | 2 +- src/controllers/livetv.html | 12 ++--- src/controllers/livetvstatus.js | 4 +- .../session/selectServer/index.html | 2 +- src/controllers/user/menu/index.html | 4 +- src/controllers/user/menu/index.js | 12 ++--- src/scripts/clientUtils.js | 2 +- src/scripts/itembynamedetailpage.js | 12 ++--- src/scripts/libraryMenu.js | 44 +++++++++---------- 19 files changed, 70 insertions(+), 70 deletions(-) diff --git a/src/components/favoriteitems.js b/src/components/favoriteitems.js index cb1b61c43f..46a415b042 100644 --- a/src/components/favoriteitems.js +++ b/src/components/favoriteitems.js @@ -141,7 +141,7 @@ import '../elements/emby-itemscontainer/emby-itemscontainer'; if (result.Items.length) { if (html += '
', !layoutManager.tv && options.Limit && result.Items.length >= options.Limit) { - html += ''; + html += ''; html += '

'; html += globalize.translate(section.name); html += '

'; diff --git a/src/components/remotecontrol/remotecontrol.js b/src/components/remotecontrol/remotecontrol.js index 3ed0444651..dec95a470c 100644 --- a/src/components/remotecontrol/remotecontrol.js +++ b/src/components/remotecontrol/remotecontrol.js @@ -147,7 +147,7 @@ function updateNowPlayingInfo(context, state, serverId) { for (const artist of item.ArtistItems) { const artistName = artist.Name; const artistId = artist.Id; - artistsSeries += `
${artistName}`; + artistsSeries += `${artistName}`; if (artist !== item.ArtistItems.slice(-1)[0]) { artistsSeries += ', '; } @@ -165,7 +165,7 @@ function updateNowPlayingInfo(context, state, serverId) { } } if (item.Album != null) { - albumName = '` + item.Album + ''; + albumName = '` + item.Album + ''; } context.querySelector('.nowPlayingAlbum').innerHTML = albumName; context.querySelector('.nowPlayingArtist').innerHTML = artistsSeries; @@ -173,12 +173,12 @@ function updateNowPlayingInfo(context, state, serverId) { } else if (item.Type == 'Episode') { if (item.SeasonName != null) { const seasonName = item.SeasonName; - context.querySelector('.nowPlayingSeason').innerHTML = '${seasonName}`; + context.querySelector('.nowPlayingSeason').innerHTML = '${seasonName}`; } if (item.SeriesName != null) { const seriesName = item.SeriesName; if (item.SeriesId != null) { - context.querySelector('.nowPlayingSerie').innerHTML = '${seriesName}`; + context.querySelector('.nowPlayingSerie').innerHTML = '${seriesName}`; } else { context.querySelector('.nowPlayingSerie').innerHTML = seriesName; } diff --git a/src/controllers/dashboard/dashboard.html b/src/controllers/dashboard/dashboard.html index 83d30495e5..9b177e3f34 100644 --- a/src/controllers/dashboard/dashboard.html +++ b/src/controllers/dashboard/dashboard.html @@ -3,7 +3,7 @@
- +

${TabServer}

@@ -35,7 +35,7 @@
- +

${HeaderActiveDevices}

@@ -46,7 +46,7 @@
- +

${HeaderActivity}

@@ -63,7 +63,7 @@
- +

${Alerts}

@@ -72,7 +72,7 @@
- +

${HeaderPaths}

diff --git a/src/controllers/dashboard/devices/devices.js b/src/controllers/dashboard/devices/devices.js index e1eb99e677..63d2a7645e 100644 --- a/src/controllers/dashboard/devices/devices.js +++ b/src/controllers/dashboard/devices/devices.js @@ -96,7 +96,7 @@ import confirm from '../../../components/confirm/confirm'; deviceHtml += '
'; deviceHtml += '
'; deviceHtml += '
'; - deviceHtml += ''; + deviceHtml += ''; const iconUrl = imageHelper.getDeviceIcon(device); if (iconUrl) { diff --git a/src/controllers/dashboard/dlna/profiles.html b/src/controllers/dashboard/dlna/profiles.html index 615bb59ee8..acfbc0c2a4 100644 --- a/src/controllers/dashboard/dlna/profiles.html +++ b/src/controllers/dashboard/dlna/profiles.html @@ -8,7 +8,7 @@
diff --git a/src/controllers/dashboard/encodingsettings.js b/src/controllers/dashboard/encodingsettings.js index 7df1940bc7..c0ff10eeb7 100644 --- a/src/controllers/dashboard/encodingsettings.js +++ b/src/controllers/dashboard/encodingsettings.js @@ -145,13 +145,13 @@ import alert from '../../components/alert'; function getTabs() { return [{ - href: 'encodingsettings.html', + href: '#!/encodingsettings.html', name: globalize.translate('Transcoding') }, { - href: 'playbackconfiguration.html', + href: '#!/playbackconfiguration.html', name: globalize.translate('ButtonResume') }, { - href: 'streamingsettings.html', + href: '#!/streamingsettings.html', name: globalize.translate('TabStreaming') }]; } diff --git a/src/controllers/dashboard/playback.js b/src/controllers/dashboard/playback.js index b02090cd33..5ead6a5d2f 100644 --- a/src/controllers/dashboard/playback.js +++ b/src/controllers/dashboard/playback.js @@ -29,13 +29,13 @@ import Dashboard from '../../scripts/clientUtils'; function getTabs() { return [{ - href: 'encodingsettings.html', + href: '#!/encodingsettings.html', name: globalize.translate('Transcoding') }, { - href: 'playbackconfiguration.html', + href: '#!/playbackconfiguration.html', name: globalize.translate('ButtonResume') }, { - href: 'streamingsettings.html', + href: '#!/streamingsettings.html', name: globalize.translate('TabStreaming') }]; } diff --git a/src/controllers/dashboard/plugins/available/index.js b/src/controllers/dashboard/plugins/available/index.js index 7dc4a9e42d..e4e7e9dabc 100644 --- a/src/controllers/dashboard/plugins/available/index.js +++ b/src/controllers/dashboard/plugins/available/index.js @@ -91,7 +91,7 @@ function populateList(options) { function getPluginHtml(plugin, options, installedPlugins) { let html = ''; - let href = plugin.externalUrl ? plugin.externalUrl : 'addplugin.html?name=' + encodeURIComponent(plugin.name) + '&guid=' + plugin.guid; + let href = plugin.externalUrl ? plugin.externalUrl : '#!/addplugin.html?name=' + encodeURIComponent(plugin.name) + '&guid=' + plugin.guid; if (options.context) { href += '&context=' + options.context; diff --git a/src/controllers/dashboard/plugins/installed/index.js b/src/controllers/dashboard/plugins/installed/index.js index 226ae0defe..d38aa00862 100644 --- a/src/controllers/dashboard/plugins/installed/index.js +++ b/src/controllers/dashboard/plugins/installed/index.js @@ -98,7 +98,7 @@ function populateList(page, plugins, pluginConfigurationPages) { } else { html += '
'; html += '

' + globalize.translate('MessageNoPluginsInstalled') + '

'; - html += '

'; + html += '

'; html += globalize.translate('MessageBrowsePluginCatalog'); html += '

'; html += '
'; diff --git a/src/controllers/dashboard/streaming.js b/src/controllers/dashboard/streaming.js index 5f504d9535..2ce668ef37 100644 --- a/src/controllers/dashboard/streaming.js +++ b/src/controllers/dashboard/streaming.js @@ -24,13 +24,13 @@ import Dashboard from '../../scripts/clientUtils'; function getTabs() { return [{ - href: 'encodingsettings.html', + href: '#!/encodingsettings.html', name: globalize.translate('Transcoding') }, { - href: 'playbackconfiguration.html', + href: '#!/playbackconfiguration.html', name: globalize.translate('ButtonResume') }, { - href: 'streamingsettings.html', + href: '#!/streamingsettings.html', name: globalize.translate('TabStreaming') }]; } diff --git a/src/controllers/dashboard/users/userprofilespage.js b/src/controllers/dashboard/users/userprofilespage.js index a88393d731..33d445639f 100644 --- a/src/controllers/dashboard/users/userprofilespage.js +++ b/src/controllers/dashboard/users/userprofilespage.js @@ -93,7 +93,7 @@ import confirm from '../../../components/confirm/confirm'; html += '
'; html += '
'; html += '
'; - html += ''; + html += ''; let imgUrl; if (user.PrimaryImageTag) { diff --git a/src/controllers/livetv.html b/src/controllers/livetv.html index fa6c3125d5..348002b96e 100644 --- a/src/controllers/livetv.html +++ b/src/controllers/livetv.html @@ -5,7 +5,7 @@
- +

${HeaderOnNow}

@@ -14,7 +14,7 @@
- +

${Shows}

@@ -23,7 +23,7 @@
- +

${Movies}

@@ -32,7 +32,7 @@
- +

${Sports}

@@ -41,7 +41,7 @@
- +

${HeaderForKids}

@@ -50,7 +50,7 @@
- +

${News}

diff --git a/src/controllers/livetvstatus.js b/src/controllers/livetvstatus.js index c1ee98f205..9143d8b87c 100644 --- a/src/controllers/livetvstatus.js +++ b/src/controllers/livetvstatus.js @@ -218,9 +218,9 @@ function getProviderName(providerId) { function getProviderConfigurationUrl(providerId) { switch (providerId = providerId.toLowerCase()) { case 'xmltv': - return 'livetvguideprovider.html?type=xmltv'; + return '#!/livetvguideprovider.html?type=xmltv'; case 'schedulesdirect': - return 'livetvguideprovider.html?type=schedulesdirect'; + return '#!/livetvguideprovider.html?type=schedulesdirect'; } } diff --git a/src/controllers/session/selectServer/index.html b/src/controllers/session/selectServer/index.html index 2f7ceb5524..09c930aba4 100644 --- a/src/controllers/session/selectServer/index.html +++ b/src/controllers/session/selectServer/index.html @@ -9,7 +9,7 @@
diff --git a/src/controllers/user/menu/index.html b/src/controllers/user/menu/index.html index fc856e6219..376805d34b 100644 --- a/src/controllers/user/menu/index.html +++ b/src/controllers/user/menu/index.html @@ -69,7 +69,7 @@

${HeaderAdmin}

- +
@@ -77,7 +77,7 @@
- +
diff --git a/src/controllers/user/menu/index.js b/src/controllers/user/menu/index.js index cfc5b5f4a5..1b4afd70ea 100644 --- a/src/controllers/user/menu/index.js +++ b/src/controllers/user/menu/index.js @@ -22,12 +22,12 @@ export default function (view, params) { const userId = params.userId || Dashboard.getCurrentUserId(); const page = this; - page.querySelector('.lnkMyProfile').setAttribute('href', 'myprofile.html?userId=' + userId); - page.querySelector('.lnkDisplayPreferences').setAttribute('href', 'mypreferencesdisplay.html?userId=' + userId); - page.querySelector('.lnkHomePreferences').setAttribute('href', 'mypreferenceshome.html?userId=' + userId); - page.querySelector('.lnkPlaybackPreferences').setAttribute('href', 'mypreferencesplayback.html?userId=' + userId); - page.querySelector('.lnkSubtitlePreferences').setAttribute('href', 'mypreferencessubtitles.html?userId=' + userId); - page.querySelector('.lnkQuickConnectPreferences').setAttribute('href', 'mypreferencesquickconnect.html'); + page.querySelector('.lnkMyProfile').setAttribute('href', '#!/myprofile.html?userId=' + userId); + page.querySelector('.lnkDisplayPreferences').setAttribute('href', '#!/mypreferencesdisplay.html?userId=' + userId); + page.querySelector('.lnkHomePreferences').setAttribute('href', '#!/mypreferenceshome.html?userId=' + userId); + page.querySelector('.lnkPlaybackPreferences').setAttribute('href', '#!/mypreferencesplayback.html?userId=' + userId); + page.querySelector('.lnkSubtitlePreferences').setAttribute('href', '#!/mypreferencessubtitles.html?userId=' + userId); + page.querySelector('.lnkQuickConnectPreferences').setAttribute('href', '#!/mypreferencesquickconnect.html'); if (window.NativeShell && window.NativeShell.AppHost.supports('clientsettings')) { page.querySelector('.clientSettings').classList.remove('hide'); diff --git a/src/scripts/clientUtils.js b/src/scripts/clientUtils.js index 291202b2e0..a72584729a 100644 --- a/src/scripts/clientUtils.js +++ b/src/scripts/clientUtils.js @@ -95,7 +95,7 @@ export function logout() { } export function getPluginUrl(name) { - return 'configurationpage?name=' + encodeURIComponent(name); + return '#!/configurationpage?name=' + encodeURIComponent(name); } export function navigate(url, preserveQueryString) { diff --git a/src/scripts/itembynamedetailpage.js b/src/scripts/itembynamedetailpage.js index a2f88780df..1a30cde22f 100644 --- a/src/scripts/itembynamedetailpage.js +++ b/src/scripts/itembynamedetailpage.js @@ -295,26 +295,26 @@ function loadItems(element, item, type, query, listOptions) { function getMoreItemsHref(item, type) { if (item.Type === 'Genre') { - return 'list.html?type=' + type + '&genreId=' + item.Id + '&serverId=' + item.ServerId; + return '#!/list.html?type=' + type + '&genreId=' + item.Id + '&serverId=' + item.ServerId; } if (item.Type === 'MusicGenre') { - return 'list.html?type=' + type + '&musicGenreId=' + item.Id + '&serverId=' + item.ServerId; + return '#!/list.html?type=' + type + '&musicGenreId=' + item.Id + '&serverId=' + item.ServerId; } if (item.Type === 'Studio') { - return 'list.html?type=' + type + '&studioId=' + item.Id + '&serverId=' + item.ServerId; + return '#!/list.html?type=' + type + '&studioId=' + item.Id + '&serverId=' + item.ServerId; } if (item.Type === 'MusicArtist') { - return 'list.html?type=' + type + '&artistId=' + item.Id + '&serverId=' + item.ServerId; + return '#!/list.html?type=' + type + '&artistId=' + item.Id + '&serverId=' + item.ServerId; } if (item.Type === 'Person') { - return 'list.html?type=' + type + '&personId=' + item.Id + '&serverId=' + item.ServerId; + return '#!/list.html?type=' + type + '&personId=' + item.Id + '&serverId=' + item.ServerId; } - return 'list.html?type=' + type + '&parentId=' + item.Id + '&serverId=' + item.ServerId; + return '#!/list.html?type=' + type + '&parentId=' + item.Id + '&serverId=' + item.ServerId; } function addCurrentItemToQuery(query, item) { diff --git a/src/scripts/libraryMenu.js b/src/scripts/libraryMenu.js index 5c72685749..6472ccabbd 100644 --- a/src/scripts/libraryMenu.js +++ b/src/scripts/libraryMenu.js @@ -292,7 +292,7 @@ import Headroom from 'headroom.js'; function refreshLibraryInfoInDrawer(user, drawer) { let html = ''; html += '
'; - html += '
' + globalize.translate('Home') + ''; + html += '' + globalize.translate('Home') + ''; // libraries are added here html += '
'; @@ -303,8 +303,8 @@ import Headroom from 'headroom.js'; html += '

'; html += globalize.translate('HeaderAdmin'); html += '

'; - html += '' + globalize.translate('TabDashboard') + ''; - html += '' + globalize.translate('Metadata') + ''; + html += '' + globalize.translate('TabDashboard') + ''; + html += '' + globalize.translate('Metadata') + ''; html += '
'; } @@ -315,7 +315,7 @@ import Headroom from 'headroom.js'; html += ''; if (appHost.supports('multiserver')) { - html += '' + globalize.translate('SelectServer') + ''; + html += '' + globalize.translate('SelectServer') + ''; } html += '' + globalize.translate('Settings') + ''; @@ -390,28 +390,28 @@ import Headroom from 'headroom.js'; name: globalize.translate('TabServer') }, { name: globalize.translate('TabDashboard'), - href: 'dashboard.html', + href: '#!/dashboard.html', pageIds: ['dashboardPage'], icon: 'dashboard' }, { name: globalize.translate('General'), - href: 'dashboardgeneral.html', + href: '#!/dashboardgeneral.html', pageIds: ['dashboardGeneralPage'], icon: 'settings' }, { name: globalize.translate('HeaderUsers'), - href: 'userprofiles.html', + href: '#!/userprofiles.html', pageIds: ['userProfilesPage', 'newUserPage', 'editUserPage', 'userLibraryAccessPage', 'userParentalControlPage', 'userPasswordPage'], icon: 'people' }, { name: globalize.translate('HeaderLibraries'), - href: 'library.html', + href: '#!/library.html', pageIds: ['mediaLibraryPage', 'librarySettingsPage', 'libraryDisplayPage', 'metadataImagesConfigurationPage', 'metadataNfoPage'], icon: 'folder' }, { name: globalize.translate('TitlePlayback'), icon: 'play_arrow', - href: 'encodingsettings.html', + href: '#!/encodingsettings.html', pageIds: ['encodingSettingsPage', 'playbackConfigurationPage', 'streamingSettingsPage'] }]; addPluginPagesToMainMenu(links, pluginItems, 'server'); @@ -421,25 +421,25 @@ import Headroom from 'headroom.js'; }); links.push({ name: globalize.translate('HeaderDevices'), - href: 'devices.html', + href: '#!/devices.html', pageIds: ['devicesPage', 'devicePage'], icon: 'devices' }); links.push({ name: globalize.translate('QuickConnect'), - href: 'quickConnect.html', + href: '#!/quickConnect.html', pageIds: ['quickConnectPage'], icon: 'tap_and_play' }); links.push({ name: globalize.translate('HeaderActivity'), - href: 'serveractivity.html', + href: '#!/serveractivity.html', pageIds: ['serverActivityPage'], icon: 'assessment' }); links.push({ name: globalize.translate('DLNA'), - href: 'dlnasettings.html', + href: '#!/dlnasettings.html', pageIds: ['dlnaSettingsPage', 'dlnaProfilesPage', 'dlnaProfilePage'], icon: 'input' }); @@ -449,13 +449,13 @@ import Headroom from 'headroom.js'; }); links.push({ name: globalize.translate('LiveTV'), - href: 'livetvstatus.html', + href: '#!/livetvstatus.html', pageIds: ['liveTvStatusPage', 'liveTvTunerPage'], icon: 'live_tv' }); links.push({ name: globalize.translate('HeaderDVR'), - href: 'livetvsettings.html', + href: '#!/livetvsettings.html', pageIds: ['liveTvSettingsPage'], icon: 'dvr' }); @@ -466,36 +466,36 @@ import Headroom from 'headroom.js'; links.push({ name: globalize.translate('TabNetworking'), icon: 'cloud', - href: 'networking.html', + href: '#!/networking.html', pageIds: ['networkingPage'] }); links.push({ name: globalize.translate('HeaderApiKeys'), icon: 'vpn_key', - href: 'apikeys.html', + href: '#!/apikeys.html', pageIds: ['apiKeysPage'] }); links.push({ name: globalize.translate('TabLogs'), - href: 'log.html', + href: '#!/log.html', pageIds: ['logPage'], icon: 'bug_report' }); links.push({ name: globalize.translate('TabNotifications'), icon: 'notifications', - href: 'notificationsettings.html', + href: '#!/notificationsettings.html', pageIds: ['notificationSettingsPage', 'notificationSettingPage'] }); links.push({ name: globalize.translate('TabPlugins'), icon: 'shopping_cart', - href: 'installedplugins.html', + href: '#!/installedplugins.html', pageIds: ['pluginsPage', 'pluginCatalogPage'] }); links.push({ name: globalize.translate('TabScheduledTasks'), - href: 'scheduledtasks.html', + href: '#!/scheduledtasks.html', pageIds: ['scheduledTasksPage', 'scheduledTaskPage'], icon: 'schedule' }); @@ -567,7 +567,7 @@ import Headroom from 'headroom.js'; function createDashboardMenu(apiClient) { return getToolsMenuHtml(apiClient).then(function (toolsMenuHtml) { let html = ''; - html += ''; html += toolsMenuHtml;