From 2177eb52ac38d62ac6cee0623c9ec26f47fe83ac Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Radek=20=C5=A0er=C3=BD?= Date: Tue, 13 May 2025 10:17:23 +0200 Subject: [PATCH 1/2] =?UTF-8?q?Dokon=C4=8Den=C3=AD=20revertu=20z=20p=C5=99?= =?UTF-8?q?edchoz=C3=ADho=20release.=20P=C5=99i=20live=20validaci=20je=20p?= =?UTF-8?q?ot=C5=99eba=20mazat=20na=20za=C4=8D=C3=A1tku=20zpr=C3=A1vy.=20T?= =?UTF-8?q?oto=20bylo=20p=C5=AFvodn=C4=9B=20p=C5=99esunuto=20do=20`validat?= =?UTF-8?q?eControl`,=20ale=20pot=C3=A9=20odebr=C3=A1no=20a=20p=C5=99esunu?= =?UTF-8?q?to=20do=20`validateForm`.=20Nyn=C3=AD=20tedy=20vrac=C3=ADme=20j?= =?UTF-8?q?e=C5=A1t=C4=9B=20i=20do=20`liveValidation`,=20aby=20zpr=C3=A1vy?= =?UTF-8?q?=20byly=20odeb=C3=ADr=C3=A1ny=20p=C5=99i=20ka=C5=BEd=C3=A9=20op?= =?UTF-8?q?=C4=9Btovn=C3=A9=20validaci=20inputu.?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/assets/pdForms.js | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/src/assets/pdForms.js b/src/assets/pdForms.js index ab7d8b2..8d53694 100644 --- a/src/assets/pdForms.js +++ b/src/assets/pdForms.js @@ -160,6 +160,11 @@ validate.forEach(function(elem) { if (elem.getAttribute('data-pdforms-ever-focused')) { + // Assumes the input is valid, therefore removing all messages except those associated with ajax rules. + // This prevents flashing of messages when the ajax rule is evaluated - ajax rules remove their messages + // when the ajax rule is evaluated + pdForms.removeMessages(elem, false); + var rules = JSON.parse(elem.getAttribute('data-nette-rules') || '[]'); rules = pdForms.normalizeRules(rules); From aa7511f49aa03d9673bd9997f7ae4d5f69ecaf7b Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Radek=20=C5=A0er=C3=BD?= Date: Tue, 13 May 2025 10:17:39 +0200 Subject: [PATCH 2/2] Release 4.2.2 --- package.json | 2 +- src/assets/pdForms.js | 4 ++-- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/package.json b/package.json index b97d767..99fd104 100644 --- a/package.json +++ b/package.json @@ -2,7 +2,7 @@ "name": "pd-forms", "title": "pdForms", "description": "Customization of netteForms for use in PeckaDesign.", - "version": "4.2.1", + "version": "4.2.2", "author": "PeckaDesign, s.r.o ", "contributors": [ "Radek Šerý ", diff --git a/src/assets/pdForms.js b/src/assets/pdForms.js index 8d53694..d097f86 100644 --- a/src/assets/pdForms.js +++ b/src/assets/pdForms.js @@ -1,7 +1,7 @@ /** * @name pdForms * @author Radek Šerý - * @version 4.2.1 + * @version 4.2.2 * * Features: * - live validation @@ -45,7 +45,7 @@ var pdForms = window.pdForms || {}; - pdForms.version = '4.2.1'; + pdForms.version = '4.2.2'; /**