diff --git a/frontend/src/routes/guest/register/steps/register.tsx b/frontend/src/routes/guest/register/steps/register.tsx index 5463e4011b31c7e8e712074b9a42280ca4d21344..6688df1a3b3855ad57c30b592a4c22a7a9c1653c 100644 --- a/frontend/src/routes/guest/register/steps/register.tsx +++ b/frontend/src/routes/guest/register/steps/register.tsx @@ -63,7 +63,7 @@ const GuestRegisterStep = forwardRef( // components directly to the form-field using useForm const [countryCode, setCountryCode] = useState< CountryCallingCode | undefined - >(undefined) + >('NO') const [passportNationality, setPassportNationality] = useState< string | undefined >(undefined) @@ -124,11 +124,6 @@ const GuestRegisterStep = forwardRef( console.log('trigger result is', result) const tohandler = data - // Both mobilePhone and mobilePhoneCountry must be set - if (!data.mobilePhoneCountry || !data.mobilePhone) { - setPhoneErrorState(t('validation.phoneNumberAndCountryCode')) - return - } // Phone checks passed, clear error message setPhoneErrorState('') @@ -502,7 +497,7 @@ const GuestRegisterStep = forwardRef( > <Select sx={{ - maxHeight: '2.5rem', + maxHeight: '2.65rem', minWidth: '5rem', marginRight: '0.5rem', }} @@ -511,7 +506,7 @@ const GuestRegisterStep = forwardRef( displayEmpty onChange={handleCountryCodeChange} label={t('input.countryCallingCode')} - value={countryCode ? countryCode.toString() : ''} + value={countryCode ? countryCode.toString() : 'NO'} renderValue={(selected: any) => { if (!selected || selected.length === 0) { return t('input.countryCallingCode') @@ -526,9 +521,6 @@ const GuestRegisterStep = forwardRef( 'data-testid': 'phone-country-code-select-inner', }} > - <MenuItem disabled value=""> - {t('input.countryCallingCode')} - </MenuItem> {sortedPhoneCountries.map((country) => ( <MenuItem key={country[0]} value={country[0]}> {country[1]} ({country[2]}) @@ -605,7 +597,7 @@ const GuestRegisterStep = forwardRef( > <Select sx={{ - maxHeight: '2.5rem', + maxHeight: '2.65rem', minWidth: '5rem', marginRight: '0.5rem', }}