Browse Source

Allow Dialog to be cleared using the back button

pull/1474/head
Timothée Jaussoin 1 week ago
parent
commit
7c78941b38
  1. 5
      public/scripts/movim_tpl.js

5
public/scripts/movim_tpl.js

@ -182,6 +182,11 @@ MovimEvents.registerWindow('loaded', 'movimtpl', () => {
}); });
MovimEvents.registerWindow('popstate', 'movimtpl', (e) => { MovimEvents.registerWindow('popstate', 'movimtpl', (e) => {
if (Dialog.filled()) {
Dialog.clear();
return;
}
if (MovimTpl.popAnchorKey || e.target.location.hash != '') { if (MovimTpl.popAnchorKey || e.target.location.hash != '') {
MovimTpl.clearAnchorState(); MovimTpl.clearAnchorState();
return; return;

Loading…
Cancel
Save