Fixed phone # formatting issues. BOD-308
This commit is contained in:
@@ -1,13 +1,8 @@
|
||||
import React from "react";
|
||||
import NumberFormat from "react-number-format";
|
||||
|
||||
//import NumberFormat from "react-number-format";
|
||||
import phone from "phone";
|
||||
export default function PhoneNumberFormatter(props) {
|
||||
return (
|
||||
<NumberFormat
|
||||
value={props.children}
|
||||
type="tel"
|
||||
format="+# (###)-###-####"
|
||||
displayType={"text"}
|
||||
/>
|
||||
);
|
||||
const p = phone(props.children);
|
||||
|
||||
return <span>{p[0]}</span>;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user