update .gitignore, add example environment file, and modify consent handling in components
This commit is contained in:
@ -7,10 +7,8 @@ import {
|
||||
type InputBaseProps,
|
||||
type PolymorphicComponentProps,
|
||||
} from "@mantine/core";
|
||||
import CountrySelect from "@/components/ui/PhoneInput/components/CountrySelect";
|
||||
import { Country } from "@/components/ui/PhoneInput/types";
|
||||
import getInitialDataFromValue from "@/components/ui/PhoneInput/utils/getInitialDataFromValue";
|
||||
import getPhoneMask from "@/components/ui/PhoneInput/utils/getPhoneMask";
|
||||
|
||||
type AdditionalProps = {
|
||||
onChange: (value: string | null) => void;
|
||||
@ -68,20 +66,21 @@ const PhoneInput = ({
|
||||
component={IMaskInput}
|
||||
inputRef={inputRef}
|
||||
leftSection={
|
||||
<CountrySelect
|
||||
disabled={disabled || readOnly}
|
||||
country={country}
|
||||
setCountry={country => {
|
||||
setCountry(country);
|
||||
setPhoneMask(getPhoneMask(country.code), country);
|
||||
setValue("");
|
||||
if (inputRef.current) {
|
||||
inputRef.current.focus();
|
||||
}
|
||||
}}
|
||||
leftSectionWidth={leftSectionWidth}
|
||||
inputWidth={dropdownWidth}
|
||||
/>
|
||||
<></>
|
||||
// <CountrySelect
|
||||
// disabled={disabled || readOnly}
|
||||
// country={country}
|
||||
// setCountry={country => {
|
||||
// setCountry(country);
|
||||
// setPhoneMask(getPhoneMask(country.code), country);
|
||||
// setValue("");
|
||||
// if (inputRef.current) {
|
||||
// inputRef.current.focus();
|
||||
// }
|
||||
// }}
|
||||
// leftSectionWidth={leftSectionWidth}
|
||||
// inputWidth={dropdownWidth}
|
||||
// />
|
||||
}
|
||||
leftSectionWidth={leftSectionWidth}
|
||||
styles={{
|
||||
|
||||
Reference in New Issue
Block a user