Compare commits

...

20 commits

Author SHA1 Message Date
Mohit Nagaraj
5246683b8d
Merge e22b22ab49 into 778363a948 2024-11-11 10:08:57 +00:00
Dorence Deng
778363a948
fix(notification): #5323 fix EditMonitor.vue useToast error (#5333)
Some checks failed
Auto Test / e2e-test (push) Has been cancelled
Auto Test / armv7-simple-test (18, ARMv7) (push) Has been cancelled
Auto Test / armv7-simple-test (20, ARMv7) (push) Has been cancelled
Auto Test / check-linters (push) Has been cancelled
CodeQL / Analyze (push) Has been cancelled
Merge Conflict Labeler / Labeling (push) Has been cancelled
validate / json-yaml-validate (push) Has been cancelled
validate / validate (push) Has been cancelled
Auto Test / auto-test (18, ARM64) (push) Has been cancelled
Auto Test / auto-test (18, macos-latest) (push) Has been cancelled
Auto Test / auto-test (18, ubuntu-latest) (push) Has been cancelled
Auto Test / auto-test (18, windows-latest) (push) Has been cancelled
Auto Test / auto-test (20, ARM64) (push) Has been cancelled
Auto Test / auto-test (20, macos-latest) (push) Has been cancelled
Auto Test / auto-test (20, ubuntu-latest) (push) Has been cancelled
Auto Test / auto-test (20, windows-latest) (push) Has been cancelled
2024-11-11 11:08:43 +01:00
Mohit Nagaraj
e22b22ab49
Merge branch 'master' into master 2024-10-22 19:03:50 +05:30
Mohit Nagaraj
6e93ed1392
Merge branch 'master' into master 2024-10-20 21:55:06 +05:30
mohit-nagaraj
9684d34ad0
Revert "refactor: fix check for empty string"
This reverts commit 949198d09e.
2024-10-11 15:11:13 +05:30
mohit-nagaraj
dcb675a343
update 2024-10-11 14:23:35 +05:30
Mohit Nagaraj
e868ebb68e
Merge branch 'louislam:master' into master 2024-10-11 14:02:19 +05:30
Mohit Nagaraj
adb5cbe425
Merge pull request #1 from mohit-nagaraj/deepsource-autofix-1bba350f
refactor: fix check for empty string
2024-10-11 14:01:58 +05:30
deepsource-autofix[bot]
949198d09e
refactor: fix check for empty string
It is not recommended to use `len` for empty string test.
2024-10-11 08:31:13 +00:00
deepsource-io[bot]
87f3c2ef94
ci: update .deepsource.toml 2024-10-11 07:59:07 +00:00
deepsource-io[bot]
498786eb39
ci: add .deepsource.toml 2024-10-11 07:51:20 +00:00
mohit-nagaraj
95a9e0a096
remove duplicate code 2024-10-08 19:09:21 +05:30
mohit-nagaraj
0d2b380f44
Update NotificationDialog.vue
i hadnt saved this T_T
2024-10-08 09:31:05 +05:30
mohit-nagaraj
56b3cf412b
warnings fix :) 2024-10-08 09:10:36 +05:30
mohit-nagaraj
72849de1b4
fix lint 2024-10-08 08:43:30 +05:30
mohit-nagaraj
e2ce0e38a6
update 2024-10-08 08:23:07 +05:30
mohit-nagaraj
da831893de
fix scroll in notfication 2024-10-08 07:37:35 +05:30
mohit-nagaraj
45b6c8a91d
Fix scroll lock
when the modal is opened, its sets overflow hidden, remove this style so as to unfreeze it
2024-10-08 07:33:18 +05:30
mohit-nagaraj
1dceb96c7c
fix(app): notification modal fix 2024-10-08 07:17:31 +05:30
mohit-nagaraj
401710c3bd
fix(app): Fix proxy modal test 2024-10-08 07:01:49 +05:30
5 changed files with 67 additions and 3 deletions

View file

@ -42,6 +42,9 @@ export default {
mounted() { mounted() {
this.modal = new Modal(this.$refs.modal); this.modal = new Modal(this.$refs.modal);
}, },
beforeUnmount() {
this.cleanupModal();
},
methods: { methods: {
/** /**
* Show the confirm dialog * Show the confirm dialog
@ -58,6 +61,19 @@ export default {
this.$emit("added", this.groupName); this.$emit("added", this.groupName);
this.modal.hide(); this.modal.hide();
}, },
/**
* Clean up modal and restore scroll behavior
* @returns {void}
*/
cleanupModal() {
if (this.modal) {
try {
this.modal.hide();
} catch (e) {
console.warn("Modal hide failed:", e);
}
}
}
}, },
}; };
</script> </script>

View file

@ -232,6 +232,9 @@ export default {
mounted() { mounted() {
this.modal = new Modal(this.$refs.modal); this.modal = new Modal(this.$refs.modal);
}, },
beforeUnmount() {
this.cleanupModal();
},
methods: { methods: {
/** /**
@ -336,6 +339,20 @@ export default {
}); });
} while (this.$root.notificationList.find(it => it.name === name)); } while (this.$root.notificationList.find(it => it.name === name));
return name; return name;
},
/**
* Clean up modal and restore scroll behavior
* @returns {void}
*/
cleanupModal() {
if (this.modal) {
try {
this.modal.hide();
} catch (e) {
console.warn("Modal hide failed:", e);
}
}
} }
}, },
}; };

View file

@ -125,11 +125,12 @@ export default {
} }
}; };
}, },
mounted() { mounted() {
this.modal = new Modal(this.$refs.modal); this.modal = new Modal(this.$refs.modal);
}, },
beforeUnmount() {
this.cleanupModal();
},
methods: { methods: {
/** /**
* Show dialog to confirm deletion * Show dialog to confirm deletion
@ -209,6 +210,20 @@ export default {
} }
}); });
}, },
/**
* Clean up modal and restore scroll behavior
* @returns {void}
*/
cleanupModal() {
if (this.modal) {
try {
this.modal.hide();
} catch (e) {
console.warn("Modal hide failed:", e);
}
}
}
}, },
}; };
</script> </script>

View file

@ -248,6 +248,9 @@ export default {
this.modal = new Modal(this.$refs.modal); this.modal = new Modal(this.$refs.modal);
this.getExistingTags(); this.getExistingTags();
}, },
beforeUnmount() {
this.cleanupModal();
},
methods: { methods: {
/** /**
* Show the add tag dialog * Show the add tag dialog
@ -459,6 +462,19 @@ export default {
this.newTags = []; this.newTags = [];
this.deleteTags = []; this.deleteTags = [];
this.processing = false; this.processing = false;
},
/**
* Clean up modal and restore scroll behavior
* @returns {void}
*/
cleanupModal() {
if (this.modal) {
try {
this.modal.hide();
} catch (e) {
console.warn("Modal hide failed:", e);
}
}
} }
}, },
}; };

View file

@ -1065,7 +1065,7 @@ import { hostNameRegexPattern } from "../util-frontend";
import HiddenInput from "../components/HiddenInput.vue"; import HiddenInput from "../components/HiddenInput.vue";
import EditMonitorConditions from "../components/EditMonitorConditions.vue"; import EditMonitorConditions from "../components/EditMonitorConditions.vue";
const toast = useToast; const toast = useToast();
const pushTokenLength = 32; const pushTokenLength = 32;