mirror of
https://codeberg.org/catask-org/catask.git
synced 2025-04-18 12:53:42 -05:00
save settings on ctrl-s
This commit is contained in:
parent
b008488a4a
commit
b139d3a17b
1 changed files with 6 additions and 0 deletions
|
@ -107,6 +107,12 @@
|
|||
function saveConfig() {
|
||||
document.getElementById('saveConfig').click();
|
||||
};
|
||||
document.addEventListener('keydown', function(event) {
|
||||
if (event.ctrlKey && event.key === "s") {
|
||||
event.preventDefault();
|
||||
saveConfig();
|
||||
}
|
||||
});
|
||||
document.addEventListener('htmx:afterRequest', function(event) {
|
||||
const jsonResponse = event.detail.xhr.response;
|
||||
if (jsonResponse && event.detail.target.dataset.dontshowtoast != '') {
|
||||
|
|
Loading…
Add table
Reference in a new issue