phone format

This commit is contained in:
AntoXa PRO 2023-09-22 14:10:52 +03:00
parent 7c20f070f1
commit 33c32ce124
2 changed files with 6 additions and 2 deletions

View File

@ -1,7 +1,7 @@
{
"name": "axp-ui",
"descriiption": "My helper ui lib",
"version": "1.7.1",
"version": "1.7.2",
"homepage": "https://antoxahub.ru/antoxa/axp-ui",
"repository": {
"type": "git",

View File

@ -19,7 +19,11 @@ const emit = defineEmits<TUiFieldPhoneEmits>()
// Value string.
const valueStr = computed({
get: () => getPhoneNumberFormat(props.modelValue),
get: () => {
if (props.modelValue) {
return getPhoneNumberFormat(props.modelValue)
}
},
set: val => {
emit('update:error')
emit('update:model-value', getPhoneNumberValue(val))