mirror of
https://github.com/jellyfin/jellyfin-web
synced 2025-03-30 19:56:21 +00:00
update shared components
This commit is contained in:
parent
8bada4146e
commit
57d96ea95d
6 changed files with 41 additions and 15 deletions
|
@ -16,12 +16,12 @@
|
|||
},
|
||||
"devDependencies": {},
|
||||
"ignore": [],
|
||||
"version": "1.0.44",
|
||||
"_release": "1.0.44",
|
||||
"version": "1.0.45",
|
||||
"_release": "1.0.45",
|
||||
"_resolution": {
|
||||
"type": "version",
|
||||
"tag": "1.0.44",
|
||||
"commit": "31d79dade27d28bad1c45ad30da03550493c17ca"
|
||||
"tag": "1.0.45",
|
||||
"commit": "b49575b7ace02784d060db167c17e92deec3512e"
|
||||
},
|
||||
"_source": "git://github.com/MediaBrowser/Emby.ApiClient.Javascript.git",
|
||||
"_target": "~1.0.3",
|
||||
|
|
|
@ -80,6 +80,18 @@
|
|||
});
|
||||
};
|
||||
|
||||
self.isLoggedIn = function() {
|
||||
|
||||
var info = self.serverInfo();
|
||||
if (info) {
|
||||
if (info.UserId && info.AccessToken) {
|
||||
return true;
|
||||
}
|
||||
}
|
||||
|
||||
return false;
|
||||
};
|
||||
|
||||
/**
|
||||
* Gets or sets the current user id.
|
||||
*/
|
||||
|
|
|
@ -16,12 +16,12 @@
|
|||
},
|
||||
"devDependencies": {},
|
||||
"ignore": [],
|
||||
"version": "1.1.50",
|
||||
"_release": "1.1.50",
|
||||
"version": "1.1.54",
|
||||
"_release": "1.1.54",
|
||||
"_resolution": {
|
||||
"type": "version",
|
||||
"tag": "1.1.50",
|
||||
"commit": "d9bc0ad32357f2302171b6d592a792c1361ddc55"
|
||||
"tag": "1.1.54",
|
||||
"commit": "29eafd218a8ea6f0b6bb28c67abf78cc772dd6d9"
|
||||
},
|
||||
"_source": "git://github.com/MediaBrowser/emby-webcomponents.git",
|
||||
"_target": "~1.1.5",
|
||||
|
|
|
@ -259,12 +259,12 @@ define(['loading', 'viewManager', 'skinManager', 'pluginManager', 'backdrop', 'b
|
|||
}
|
||||
}
|
||||
|
||||
var server = connectionManager.currentLoggedInServer();
|
||||
var apiClient = connectionManager.currentApiClient();
|
||||
var pathname = ctx.pathname.toLowerCase();
|
||||
|
||||
console.log('Emby.Page - processing path request ' + pathname);
|
||||
|
||||
if (server) {
|
||||
if (apiClient && apiClient.isLoggedIn()) {
|
||||
|
||||
console.log('Emby.Page - user is authenticated');
|
||||
|
||||
|
@ -495,6 +495,19 @@ define(['loading', 'viewManager', 'skinManager', 'pluginManager', 'backdrop', 'b
|
|||
page.pushState(state, title, url);
|
||||
}
|
||||
|
||||
function setBaseRoute() {
|
||||
var baseRoute = window.location.pathname.replace('/index.html', '');
|
||||
if (baseRoute.lastIndexOf('/') == baseRoute.length - 1) {
|
||||
baseRoute = baseRoute.substring(0, baseRoute.length - 1);
|
||||
}
|
||||
|
||||
console.log('Setting page base to ' + baseRoute);
|
||||
|
||||
page.base(baseRoute);
|
||||
}
|
||||
|
||||
setBaseRoute();
|
||||
|
||||
return {
|
||||
addRoute: addRoute,
|
||||
param: param,
|
||||
|
|
|
@ -1,4 +1,4 @@
|
|||
define(['viewcontainer', 'focusManager', 'queryString'], function (viewcontainer, focusManager, queryString) {
|
||||
define(['viewcontainer', 'focusManager', 'queryString', 'connectionManager', 'events'], function (viewcontainer, focusManager, queryString, connectionManager, events) {
|
||||
|
||||
var currentView;
|
||||
|
||||
|
@ -88,8 +88,9 @@ define(['viewcontainer', 'focusManager', 'queryString'], function (viewcontainer
|
|||
}
|
||||
|
||||
document.addEventListener('skinunload', resetCachedViews);
|
||||
document.addEventListener('usersignedin', resetCachedViews);
|
||||
document.addEventListener('usersignedout', resetCachedViews);
|
||||
|
||||
events.on(connectionManager, 'localusersignedin', resetCachedViews);
|
||||
events.on(connectionManager, 'localusersignedout', resetCachedViews);
|
||||
|
||||
function tryRestoreInternal(viewcontainer, options, resolve, reject) {
|
||||
|
||||
|
|
|
@ -36,7 +36,7 @@
|
|||
"tag": "v1.3.0",
|
||||
"commit": "1662093611cda3fd29125cdab94a61d3d88093da"
|
||||
},
|
||||
"_source": "git://github.com/polymerelements/iron-selector.git",
|
||||
"_source": "git://github.com/PolymerElements/iron-selector.git",
|
||||
"_target": "^1.0.0",
|
||||
"_originalSource": "polymerelements/iron-selector"
|
||||
"_originalSource": "PolymerElements/iron-selector"
|
||||
}
|
Loading…
Add table
Add a link
Reference in a new issue