Merge pull request #2917 from jellyfin/dialog-history-2
Dialog history and actionSheet resolving
This commit is contained in:
commit
d14a106ecd
2 changed files with 3 additions and 5 deletions
|
@ -87,7 +87,7 @@ import '../../assets/css/scrollstyles.scss';
|
||||||
if (!self.closedByBack && isHistoryEnabled(dlg)) {
|
if (!self.closedByBack && isHistoryEnabled(dlg)) {
|
||||||
const state = window.history.state || {};
|
const state = window.history.state || {};
|
||||||
if (state.dialogId === hash) {
|
if (state.dialogId === hash) {
|
||||||
window.history.back();
|
appRouter.back();
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -142,7 +142,7 @@ import '../../assets/css/scrollstyles.scss';
|
||||||
animateDialogOpen(dlg);
|
animateDialogOpen(dlg);
|
||||||
|
|
||||||
if (isHistoryEnabled(dlg)) {
|
if (isHistoryEnabled(dlg)) {
|
||||||
appRouter.show('/dialog', { dialogId: hash });
|
appRouter.show(`/dialog?dlg=${hash}`, { dialogId: hash });
|
||||||
|
|
||||||
window.addEventListener('popstate', onHashChange);
|
window.addEventListener('popstate', onHashChange);
|
||||||
} else {
|
} else {
|
||||||
|
@ -213,7 +213,7 @@ import '../../assets/css/scrollstyles.scss';
|
||||||
export function close(dlg) {
|
export function close(dlg) {
|
||||||
if (isOpened(dlg)) {
|
if (isOpened(dlg)) {
|
||||||
if (isHistoryEnabled(dlg)) {
|
if (isHistoryEnabled(dlg)) {
|
||||||
window.history.back();
|
appRouter.back();
|
||||||
} else {
|
} else {
|
||||||
closeDialog(dlg);
|
closeDialog(dlg);
|
||||||
}
|
}
|
||||||
|
|
|
@ -63,7 +63,6 @@ class GroupSelectionMenu {
|
||||||
title: globalize.translate('HeaderSyncPlaySelectGroup'),
|
title: globalize.translate('HeaderSyncPlaySelectGroup'),
|
||||||
items: menuItems,
|
items: menuItems,
|
||||||
positionTo: button,
|
positionTo: button,
|
||||||
resolveOnClick: true,
|
|
||||||
border: true
|
border: true
|
||||||
};
|
};
|
||||||
|
|
||||||
|
@ -142,7 +141,6 @@ class GroupSelectionMenu {
|
||||||
title: groupInfo.GroupName,
|
title: groupInfo.GroupName,
|
||||||
items: menuItems,
|
items: menuItems,
|
||||||
positionTo: button,
|
positionTo: button,
|
||||||
resolveOnClick: true,
|
|
||||||
border: true
|
border: true
|
||||||
};
|
};
|
||||||
|
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue