Updating VnInput
gitea/hedera-web/pipeline/pr-4922-vueMigration This commit looks good
Details
gitea/hedera-web/pipeline/pr-4922-vueMigration This commit looks good
Details
This commit is contained in:
parent
05d735702e
commit
73eb3dcbee
|
@ -56,10 +56,14 @@ defineExpose({
|
||||||
|
|
||||||
const inputRules = [
|
const inputRules = [
|
||||||
val => {
|
val => {
|
||||||
const { min } = vnInputRef.value.$attrs;
|
console.log('asd');
|
||||||
|
const { min, max } = vnInputRef.value.$attrs;
|
||||||
if (min >= 0) {
|
if (min >= 0) {
|
||||||
if (Math.floor(val) < min) return t('inputMin', { value: min });
|
if (Math.floor(val) < min) return t('inputMin', { value: min });
|
||||||
}
|
}
|
||||||
|
if (max > 0) {
|
||||||
|
if (Math.floor(val) > max) return t('inputMax', { value: max });
|
||||||
|
}
|
||||||
}
|
}
|
||||||
];
|
];
|
||||||
</script>
|
</script>
|
||||||
|
@ -111,12 +115,17 @@ const inputRules = [
|
||||||
<i18n lang="yaml">
|
<i18n lang="yaml">
|
||||||
en-US:
|
en-US:
|
||||||
inputMin: Must be more than {value}
|
inputMin: Must be more than {value}
|
||||||
|
inputMax: Must be less than {value}
|
||||||
es-ES:
|
es-ES:
|
||||||
inputMin: Must be more than {value}
|
inputMin: Debe ser mayor a {value}
|
||||||
|
inputMax: Debe ser menor a {value}
|
||||||
ca-ES:
|
ca-ES:
|
||||||
inputMin: Ha de ser més gran que {value}
|
inputMin: Ha de ser més gran que {value}
|
||||||
|
inputMax: Ha de ser menys que {value}
|
||||||
fr-FR:
|
fr-FR:
|
||||||
inputMin: Doit être supérieur à {value}
|
inputMin: Doit être supérieur à {value}
|
||||||
|
inputMax: Doit être supérieur à {value}
|
||||||
pt-PT:
|
pt-PT:
|
||||||
inputMin: Deve ser maior que {value}
|
inputMin: Deve ser maior que {value}
|
||||||
|
inputMax: Deve ser maior que {value}
|
||||||
</i18n>
|
</i18n>
|
||||||
|
|
Loading…
Reference in New Issue