@descope/web-components-ui 1.0.376 → 1.0.377

Sign up to get free protection for your applications and to get access to all the features.
package/dist/index.esm.js CHANGED
@@ -6253,9 +6253,9 @@ let PhoneFieldInternal$1 = class PhoneFieldInternal extends BaseInputClass$6 {
6253
6253
  }
6254
6254
 
6255
6255
  set value(val) {
6256
- const parsed = parsePhone(val);
6257
- const countryCode = `+${parsed.countryCallingCode}`;
6258
- const phoneNumber = parsed.nationalNumber;
6256
+ const parsed = parsePhone(val || '');
6257
+ const countryCode = parsed?.countryCallingCode ? `+${parsed.countryCallingCode}` : '';
6258
+ const phoneNumber = parsed?.nationalNumber || '';
6259
6259
 
6260
6260
  if (countryCode) {
6261
6261
  const countryCodeItem = this.getCountryByDialCode(countryCode);