Fix minimum length for 2 characters messages

This commit is contained in:
Alex
2024-09-01 00:17:59 +02:00
parent 4bb10c097d
commit cb3dacb32f
2 changed files with 3 additions and 2 deletions

View File

@@ -4,6 +4,7 @@
- Fix OIDC to allow only client_secret_basic and client_secret_post auth methods
- Improve poll results UI
- Fix minimum length for 2 characters messages
## v2.1.0

View File

@@ -226,7 +226,7 @@ Hooks.PostForm = {
e.preventDefault();
submitBtn.click();
} else {
if (TA.value.length > 1 && TA.value.length < 256) {
if (TA.value.length > 0 && TA.value.length < 256) {
submitBtn.classList.remove("opacity-50");
submitBtn.classList.add("opacity-100");
submitBtn.disabled = false;
@@ -261,7 +261,7 @@ Hooks.PostForm = {
updated() {
const submitBtn = document.getElementById("submitBtn");
const TA = document.getElementById("postFormTA");
if (TA.value.length > 1 && TA.value.length < 256) {
if (TA.value.length > 0 && TA.value.length < 256) {
submitBtn.classList.remove("opacity-50");
submitBtn.classList.add("opacity-100");
submitBtn.disabled = false;