fix: format plain french numbers with dot grouping

This commit is contained in:
Matthieu
2025-10-30 17:35:44 +01:00
parent 53dab13489
commit ef9a8b5b7b

View File

@@ -58,10 +58,6 @@ export const formatPhone = (rawValue: string | null | undefined): string => {
return ['+33', ...groups].join('.')
}
if (/^0\d{9}$/.test(normalized)) {
return normalized
}
const hasInternationalPrefix = normalized.startsWith('+')
const prefix = hasInternationalPrefix ? normalized.slice(0, 1) : ''
const digits = hasInternationalPrefix ? normalized.slice(1) : normalized