Merge pull request #2917 from jellyfin/dialog-history-2

Dialog history and actionSheet resolving
This commit is contained in:
dkanada 2021-09-07 01:36:30 +09:00 committed by GitHub
commit d14a106ecd
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
2 changed files with 3 additions and 5 deletions

View File

@ -87,7 +87,7 @@ import '../../assets/css/scrollstyles.scss';
if (!self.closedByBack && isHistoryEnabled(dlg)) {
const state = window.history.state || {};
if (state.dialogId === hash) {
window.history.back();
appRouter.back();
}
}
@ -142,7 +142,7 @@ import '../../assets/css/scrollstyles.scss';
animateDialogOpen(dlg);
if (isHistoryEnabled(dlg)) {
appRouter.show('/dialog', { dialogId: hash });
appRouter.show(`/dialog?dlg=${hash}`, { dialogId: hash });
window.addEventListener('popstate', onHashChange);
} else {
@ -213,7 +213,7 @@ import '../../assets/css/scrollstyles.scss';
export function close(dlg) {
if (isOpened(dlg)) {
if (isHistoryEnabled(dlg)) {
window.history.back();
appRouter.back();
} else {
closeDialog(dlg);
}

View File

@ -63,7 +63,6 @@ class GroupSelectionMenu {
title: globalize.translate('HeaderSyncPlaySelectGroup'),
items: menuItems,
positionTo: button,
resolveOnClick: true,
border: true
};
@ -142,7 +141,6 @@ class GroupSelectionMenu {
title: groupInfo.GroupName,
items: menuItems,
positionTo: button,
resolveOnClick: true,
border: true
};