From 679cbde646a688d7d298d40d8746e1e9588af809 Mon Sep 17 00:00:00 2001 From: axolotle Date: Wed, 5 Jan 2022 15:55:21 +0100 Subject: [PATCH 1/6] clean CardForm old disable mecanism --- app/src/components/globals/CardForm.vue | 8 +------- 1 file changed, 1 insertion(+), 7 deletions(-) diff --git a/app/src/components/globals/CardForm.vue b/app/src/components/globals/CardForm.vue index 5bf3b128..784851c0 100644 --- a/app/src/components/globals/CardForm.vue +++ b/app/src/components/globals/CardForm.vue @@ -19,10 +19,7 @@ - + {{ submitText ? submitText : $t('save') }} @@ -45,9 +42,6 @@ export default { }, computed: { - disabled () { - return false // this.validation ? this.validation.$invalid : false - }, errorFeedback () { if (this.serverError) return this.serverError else if (this.validation && this.validation.$anyError) { From fd21c9f406fafc064585afcafb014309c9392c4f Mon Sep 17 00:00:00 2001 From: axolotle Date: Wed, 5 Jan 2022 15:56:14 +0100 Subject: [PATCH 2/6] allow i18n error messages with pattern validation --- app/src/helpers/yunohostArguments.js | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/app/src/helpers/yunohostArguments.js b/app/src/helpers/yunohostArguments.js index 06eb385e..0fc02bbd 100644 --- a/app/src/helpers/yunohostArguments.js +++ b/app/src/helpers/yunohostArguments.js @@ -218,8 +218,7 @@ export function formatYunoHostArgument (arg) { validation.required = validators.required } if (arg.pattern && arg.type !== 'tags') { - // validation.pattern = validators.helpers.withMessage(arg.pattern.error, - validation.pattern = validators.helpers.regex(arg.pattern.error, new RegExp(arg.pattern.regexp)) + validation.pattern = validators.helpers.regex(formatI18nField(arg.pattern.error), new RegExp(arg.pattern.regexp)) } validation.remote = validators.helpers.withParams(error, (v) => { const result = !error.message From 4547427ac3782db2c85e3a94f9325fc0e46ddbc5 Mon Sep 17 00:00:00 2001 From: axolotle Date: Wed, 5 Jan 2022 15:56:39 +0100 Subject: [PATCH 3/6] improve TopBar buttons responsiveness --- app/src/components/globals/TopBar.vue | 15 ++++++++------- 1 file changed, 8 insertions(+), 7 deletions(-) diff --git a/app/src/components/globals/TopBar.vue b/app/src/components/globals/TopBar.vue index a02ecab4..18fb7db2 100644 --- a/app/src/components/globals/TopBar.vue +++ b/app/src/components/globals/TopBar.vue @@ -47,28 +47,29 @@ export default { diff --git a/app/src/views/app/AppConfigPanel.vue b/app/src/views/app/AppConfigPanel.vue index 4df0021e..274a6e2d 100644 --- a/app/src/views/app/AppConfigPanel.vue +++ b/app/src/views/app/AppConfigPanel.vue @@ -182,12 +182,9 @@ export default { } } - From a19f57c6d6f1fdaf3334ad9affcf04ef1507ee9c Mon Sep 17 00:00:00 2001 From: axolotle Date: Wed, 5 Jan 2022 18:32:01 +0100 Subject: [PATCH 5/6] add TabForm component that act like CardForm --- app/src/components/globals/TabForm.vue | 82 ++++++++++++++++++++++++++ 1 file changed, 82 insertions(+) create mode 100644 app/src/components/globals/TabForm.vue diff --git a/app/src/components/globals/TabForm.vue b/app/src/components/globals/TabForm.vue new file mode 100644 index 00000000..2d8c3d7a --- /dev/null +++ b/app/src/components/globals/TabForm.vue @@ -0,0 +1,82 @@ + + + + + From 71f1e672897362beee6f9e49e34af89315d723bd Mon Sep 17 00:00:00 2001 From: axolotle Date: Wed, 5 Jan 2022 18:34:24 +0100 Subject: [PATCH 6/6] update AppConfigPanel with TabForm --- app/src/views/app/AppConfigPanel.vue | 57 ++++++++++++---------------- 1 file changed, 25 insertions(+), 32 deletions(-) diff --git a/app/src/views/app/AppConfigPanel.vue b/app/src/views/app/AppConfigPanel.vue index 274a6e2d..4983d40f 100644 --- a/app/src/views/app/AppConfigPanel.vue +++ b/app/src/views/app/AppConfigPanel.vue @@ -1,41 +1,32 @@