Commit Graph

14 Commits

Author SHA1 Message Date
Johannes Meyer 7cea0d78e4 js: Only disable submit buttons on form submit
Previously all `input` elements (text, date, number, ...)
got also disabled. This is unecessary.
2023-01-12 09:39:31 +01:00
Yonas Habteab a1cd7441c5 modal.js: Don't try to hide a modal when there is none
Fixes a bug that when e.g. closing a color picker by clicking the escape key,
also the `modal.hide()` action is performed, even though there was no real modal
opened before, but it seems to react automatically on the escape key click.
2022-05-06 09:18:28 +02:00
Yonas Habteab 2be192679b modal.js: Set modal title from resp header on autosubmit 2022-04-11 13:26:08 +02:00
raviks789 703956c3da Fix unresponsive modal submit buttons in Safari 2021-11-10 09:33:21 +01:00
Johannes Meyer dcf394eaa6 modal.js: Don't disable inputs before the actual form submit is done
fixes Icinga/icingadb-web#376
2021-09-27 14:10:48 +02:00
Sukhwinder Dhillon 15b9bac755 modal.js: Do not open multiple modal windows by clicking more than once 2021-09-21 16:02:06 +02:00
Sukhwinder Dhillon 414a2ff7aa modal.js: Submit form only once 2021-09-21 12:38:07 +02:00
Johannes Meyer e704309c41 modal.js: Trigger `close-modal` when.. closing a modal 2021-05-17 13:20:43 +02:00
Johannes Meyer 07251e6d5e modal.js: Really only close the modal if the user clicks outside of it
The click event fires only after the mouse button is released, which
may happen on the outside, after the user tried to select something
and overrun accidentally. A close is then not desired as the user
may loose input. The mousedown event fires right when the button
is pressed and suffices on the outside of the modal.
2021-03-09 08:52:10 +01:00
Johannes Meyer 7790a72efa js: Only close a modal if an ESC press is not handled otherwise 2021-03-09 08:52:10 +01:00
Johannes Meyer 57b4a31bc3 js: Don't navigate right when opening a modal
Isn't the prettiest fix. I would have liked to completely
remove the target preparation from `getLinkTargetFor`.
But this is the easiest fix since it's only for modals
that preparation is not desired. It's also the most
compatible change.
2021-02-17 12:51:26 +01:00
Johannes Meyer 74a9a8edf0 modal.js: Request compact content with `showCompact` 2020-06-04 08:50:41 +02:00
Johannes Meyer db69f23c20 modal.js: Don't push form submits to the history 2020-01-15 08:41:34 +01:00
Johannes Meyer a13d2b1e48 js: Introduce behavior modal.js 2019-11-04 12:46:30 +01:00