feat: hide '+' character in tel field

This commit is contained in:
Sebastian Pravda 2022-11-30 15:31:54 +01:00 committed by EETagent
parent fb1c83c6a8
commit bade5b98e7

View file

@ -10,7 +10,7 @@
$: {
let x = value.replace(/\D/g, '').match(/(\d{0,3})(\d{0,3})(\d{0,3})(\d{0,3})/)!;
value =
'+' + x[1] + (x[2] ? ' ' + x[2] : '') + (x[3] ? ' ' + x[3] : '') + (x[4] ? ' ' + x[4] : '');
(x[1] ? '+' + x[1] : '') + (x[2] ? ' ' + x[2] : '') + (x[3] ? ' ' + x[3] : '') + (x[4] ? ' ' + x[4] : '');
}
</script>