From 03cd2592df1ef6f047a289472a98bd83159eb798 Mon Sep 17 00:00:00 2001 From: jeanvier Date: Tue, 19 Nov 2024 15:47:54 +0100 Subject: [PATCH] feat: date labels --- package.json | 2 +- src/runtime/messages/validators/en.ts | 2 ++ src/runtime/messages/validators/fr.ts | 2 ++ 3 files changed, 5 insertions(+), 1 deletion(-) diff --git a/package.json b/package.json index 934057a..be955e6 100644 --- a/package.json +++ b/package.json @@ -1,7 +1,7 @@ { "name": "@wgr-sa/nuxt-form", "description": "Form builder for Nuxt", - "version": "0.9.2", + "version": "0.9.3", "repository": "https://github.com/WGR-SA/nuxt-form.git", "author": "jeanvier", "license": "MIT", diff --git a/src/runtime/messages/validators/en.ts b/src/runtime/messages/validators/en.ts index 69ca470..21b6720 100644 --- a/src/runtime/messages/validators/en.ts +++ b/src/runtime/messages/validators/en.ts @@ -105,6 +105,8 @@ export const en: {[key: string]: string} = { minLength: 'This field must contain at least {0} characters', maxLength: 'This field must not contain more than {0} characters', isNotEmpty: 'This field must not be empty', + minDate: 'This field must be later than {0}', + maxDate: 'This field must be earlier than {0}', } export default en diff --git a/src/runtime/messages/validators/fr.ts b/src/runtime/messages/validators/fr.ts index 8c37c60..bb4cbc8 100644 --- a/src/runtime/messages/validators/fr.ts +++ b/src/runtime/messages/validators/fr.ts @@ -105,6 +105,8 @@ export const fr: {[key: string]: string} = { minLength: 'Ce champ doit contenir au moins {0} caractères', maxLength: 'Ce champ ne doit pas contenir plus de {0} caractères', isNotEmpty: 'Ce champ ne doit pas être vide', + minDate: 'Ce champ doit être postérieur à {0}', + maxDate: 'Ce champ doit être antérieur à {0}', }; export default fr;