@kingteza/crud-component 1.22.2 → 1.23.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/_virtual/_commonjsHelpers.cjs.js +1 -0
- package/dist/_virtual/_commonjsHelpers.es.js +6 -0
- package/dist/_virtual/index.cjs.js +1 -0
- package/dist/_virtual/index.cjs2.js +1 -0
- package/dist/_virtual/index.cjs3.js +1 -0
- package/dist/_virtual/index.cjs4.js +1 -0
- package/dist/_virtual/index.cjs5.js +1 -0
- package/dist/_virtual/index.es.js +7 -0
- package/dist/_virtual/index.es2.js +7 -0
- package/dist/_virtual/index.es3.js +4 -0
- package/dist/_virtual/index.es4.js +4 -0
- package/dist/_virtual/index.es5.js +4 -0
- package/dist/_virtual/react-is.development.cjs.js +1 -0
- package/dist/_virtual/react-is.development.es.js +4 -0
- package/dist/_virtual/react-is.production.min.cjs.js +1 -0
- package/dist/_virtual/react-is.production.min.es.js +4 -0
- package/dist/common/text-field/PhoneNumberField.cjs.js +1 -1
- package/dist/common/text-field/PhoneNumberField.d.ts +9 -1
- package/dist/common/text-field/PhoneNumberField.es.js +70 -15
- package/dist/common/text-field/index.d.ts +1 -0
- package/dist/crud/CrudComponent.d.ts +5 -0
- package/dist/crud/CrudField.cjs.js +1 -1
- package/dist/crud/CrudField.es.js +238 -213
- package/dist/crud/import/CrudImportComponent.cjs.js +2 -2
- package/dist/crud/import/CrudImportComponent.es.js +14 -15
- package/dist/node_modules/.pnpm/classnames@2.5.1/node_modules/classnames/index.cjs.js +5 -0
- package/dist/node_modules/.pnpm/classnames@2.5.1/node_modules/classnames/index.es.js +42 -0
- package/dist/node_modules/.pnpm/country-flag-icons@1.6.12/node_modules/country-flag-icons/modules/react/3x2/index.cjs.js +1 -0
- package/dist/node_modules/.pnpm/country-flag-icons@1.6.12/node_modules/country-flag-icons/modules/react/3x2/index.es.js +6214 -0
- package/dist/node_modules/.pnpm/country-flag-icons@1.6.12/node_modules/country-flag-icons/modules/unicode.cjs.js +1 -0
- package/dist/node_modules/.pnpm/country-flag-icons@1.6.12/node_modules/country-flag-icons/modules/unicode.es.js +9 -0
- package/dist/node_modules/.pnpm/input-format@0.3.14_react-dom@18.3.1_react@18.3.1__react@18.3.1/node_modules/input-format/modules/closeBraces.cjs.js +1 -0
- package/dist/node_modules/.pnpm/input-format@0.3.14_react-dom@18.3.1_react@18.3.1__react@18.3.1/node_modules/input-format/modules/closeBraces.es.js +9 -0
- package/dist/node_modules/.pnpm/input-format@0.3.14_react-dom@18.3.1_react@18.3.1__react@18.3.1/node_modules/input-format/modules/dom.cjs.js +1 -0
- package/dist/node_modules/.pnpm/input-format@0.3.14_react-dom@18.3.1_react@18.3.1__react@18.3.1/node_modules/input-format/modules/dom.es.js +43 -0
- package/dist/node_modules/.pnpm/input-format@0.3.14_react-dom@18.3.1_react@18.3.1__react@18.3.1/node_modules/input-format/modules/edit.cjs.js +1 -0
- package/dist/node_modules/.pnpm/input-format@0.3.14_react-dom@18.3.1_react@18.3.1__react@18.3.1/node_modules/input-format/modules/edit.es.js +17 -0
- package/dist/node_modules/.pnpm/input-format@0.3.14_react-dom@18.3.1_react@18.3.1__react@18.3.1/node_modules/input-format/modules/format.cjs.js +1 -0
- package/dist/node_modules/.pnpm/input-format@0.3.14_react-dom@18.3.1_react@18.3.1__react@18.3.1/node_modules/input-format/modules/format.es.js +28 -0
- package/dist/node_modules/.pnpm/input-format@0.3.14_react-dom@18.3.1_react@18.3.1__react@18.3.1/node_modules/input-format/modules/helpers.cjs.js +2 -0
- package/dist/node_modules/.pnpm/input-format@0.3.14_react-dom@18.3.1_react@18.3.1__react@18.3.1/node_modules/input-format/modules/helpers.es.js +37 -0
- package/dist/node_modules/.pnpm/input-format@0.3.14_react-dom@18.3.1_react@18.3.1__react@18.3.1/node_modules/input-format/modules/inputControl.cjs.js +1 -0
- package/dist/node_modules/.pnpm/input-format@0.3.14_react-dom@18.3.1_react@18.3.1__react@18.3.1/node_modules/input-format/modules/inputControl.es.js +36 -0
- package/dist/node_modules/.pnpm/input-format@0.3.14_react-dom@18.3.1_react@18.3.1__react@18.3.1/node_modules/input-format/modules/parse.cjs.js +1 -0
- package/dist/node_modules/.pnpm/input-format@0.3.14_react-dom@18.3.1_react@18.3.1__react@18.3.1/node_modules/input-format/modules/parse.es.js +15 -0
- package/dist/node_modules/.pnpm/input-format@0.3.14_react-dom@18.3.1_react@18.3.1__react@18.3.1/node_modules/input-format/modules/react/Input.cjs.js +1 -0
- package/dist/node_modules/.pnpm/input-format@0.3.14_react-dom@18.3.1_react@18.3.1__react@18.3.1/node_modules/input-format/modules/react/Input.es.js +86 -0
- package/dist/node_modules/.pnpm/input-format@0.3.14_react-dom@18.3.1_react@18.3.1__react@18.3.1/node_modules/input-format/modules/react/useInput.cjs.js +1 -0
- package/dist/node_modules/.pnpm/input-format@0.3.14_react-dom@18.3.1_react@18.3.1__react@18.3.1/node_modules/input-format/modules/react/useInput.es.js +69 -0
- package/dist/node_modules/.pnpm/input-format@0.3.14_react-dom@18.3.1_react@18.3.1__react@18.3.1/node_modules/input-format/modules/templateFormatter.cjs.js +2 -0
- package/dist/node_modules/.pnpm/input-format@0.3.14_react-dom@18.3.1_react@18.3.1__react@18.3.1/node_modules/input-format/modules/templateFormatter.es.js +62 -0
- package/dist/node_modules/.pnpm/libphonenumber-js@1.12.36/node_modules/libphonenumber-js/es6/AsYouType.cjs.js +2 -0
- package/dist/node_modules/.pnpm/libphonenumber-js@1.12.36/node_modules/libphonenumber-js/es6/AsYouType.es.js +366 -0
- package/dist/node_modules/.pnpm/libphonenumber-js@1.12.36/node_modules/libphonenumber-js/es6/AsYouTypeFormatter.PatternMatcher.cjs.js +4 -0
- package/dist/node_modules/.pnpm/libphonenumber-js@1.12.36/node_modules/libphonenumber-js/es6/AsYouTypeFormatter.PatternMatcher.es.js +172 -0
- package/dist/node_modules/.pnpm/libphonenumber-js@1.12.36/node_modules/libphonenumber-js/es6/AsYouTypeFormatter.PatternParser.cjs.js +1 -0
- package/dist/node_modules/.pnpm/libphonenumber-js@1.12.36/node_modules/libphonenumber-js/es6/AsYouTypeFormatter.PatternParser.es.js +157 -0
- package/dist/node_modules/.pnpm/libphonenumber-js@1.12.36/node_modules/libphonenumber-js/es6/AsYouTypeFormatter.cjs.js +2 -0
- package/dist/node_modules/.pnpm/libphonenumber-js@1.12.36/node_modules/libphonenumber-js/es6/AsYouTypeFormatter.complete.cjs.js +1 -0
- package/dist/node_modules/.pnpm/libphonenumber-js@1.12.36/node_modules/libphonenumber-js/es6/AsYouTypeFormatter.complete.es.js +49 -0
- package/dist/node_modules/.pnpm/libphonenumber-js@1.12.36/node_modules/libphonenumber-js/es6/AsYouTypeFormatter.es.js +264 -0
- package/dist/node_modules/.pnpm/libphonenumber-js@1.12.36/node_modules/libphonenumber-js/es6/AsYouTypeFormatter.util.cjs.js +2 -0
- package/dist/node_modules/.pnpm/libphonenumber-js@1.12.36/node_modules/libphonenumber-js/es6/AsYouTypeFormatter.util.es.js +63 -0
- package/dist/node_modules/.pnpm/libphonenumber-js@1.12.36/node_modules/libphonenumber-js/es6/AsYouTypeParser.cjs.js +2 -0
- package/dist/node_modules/.pnpm/libphonenumber-js@1.12.36/node_modules/libphonenumber-js/es6/AsYouTypeParser.es.js +265 -0
- package/dist/node_modules/.pnpm/libphonenumber-js@1.12.36/node_modules/libphonenumber-js/es6/AsYouTypeState.cjs.js +1 -0
- package/dist/node_modules/.pnpm/libphonenumber-js@1.12.36/node_modules/libphonenumber-js/es6/AsYouTypeState.es.js +110 -0
- package/dist/node_modules/.pnpm/libphonenumber-js@1.12.36/node_modules/libphonenumber-js/es6/ParseError.cjs.js +1 -0
- package/dist/node_modules/.pnpm/libphonenumber-js@1.12.36/node_modules/libphonenumber-js/es6/ParseError.es.js +89 -0
- package/dist/node_modules/.pnpm/libphonenumber-js@1.12.36/node_modules/libphonenumber-js/es6/PhoneNumber.cjs.js +1 -0
- package/dist/node_modules/.pnpm/libphonenumber-js@1.12.36/node_modules/libphonenumber-js/es6/PhoneNumber.es.js +188 -0
- package/dist/node_modules/.pnpm/libphonenumber-js@1.12.36/node_modules/libphonenumber-js/es6/constants.cjs.js +1 -0
- package/dist/node_modules/.pnpm/libphonenumber-js@1.12.36/node_modules/libphonenumber-js/es6/constants.es.js +10 -0
- package/dist/node_modules/.pnpm/libphonenumber-js@1.12.36/node_modules/libphonenumber-js/es6/format.cjs.js +1 -0
- package/dist/node_modules/.pnpm/libphonenumber-js@1.12.36/node_modules/libphonenumber-js/es6/format.es.js +98 -0
- package/dist/node_modules/.pnpm/libphonenumber-js@1.12.36/node_modules/libphonenumber-js/es6/formatIncompletePhoneNumber.cjs.js +1 -0
- package/dist/node_modules/.pnpm/libphonenumber-js@1.12.36/node_modules/libphonenumber-js/es6/formatIncompletePhoneNumber.es.js +7 -0
- package/dist/node_modules/.pnpm/libphonenumber-js@1.12.36/node_modules/libphonenumber-js/es6/getCountries.cjs.js +1 -0
- package/dist/node_modules/.pnpm/libphonenumber-js@1.12.36/node_modules/libphonenumber-js/es6/getCountries.es.js +7 -0
- package/dist/node_modules/.pnpm/libphonenumber-js@1.12.36/node_modules/libphonenumber-js/es6/helpers/RFC3966.cjs.js +1 -0
- package/dist/node_modules/.pnpm/libphonenumber-js@1.12.36/node_modules/libphonenumber-js/es6/helpers/RFC3966.es.js +11 -0
- package/dist/node_modules/.pnpm/libphonenumber-js@1.12.36/node_modules/libphonenumber-js/es6/helpers/applyInternationalSeparatorStyle.cjs.js +1 -0
- package/dist/node_modules/.pnpm/libphonenumber-js@1.12.36/node_modules/libphonenumber-js/es6/helpers/applyInternationalSeparatorStyle.es.js +7 -0
- package/dist/node_modules/.pnpm/libphonenumber-js@1.12.36/node_modules/libphonenumber-js/es6/helpers/checkNumberLength.cjs.js +1 -0
- package/dist/node_modules/.pnpm/libphonenumber-js@1.12.36/node_modules/libphonenumber-js/es6/helpers/checkNumberLength.es.js +16 -0
- package/dist/node_modules/.pnpm/libphonenumber-js@1.12.36/node_modules/libphonenumber-js/es6/helpers/extension/createExtensionPattern.cjs.js +1 -0
- package/dist/node_modules/.pnpm/libphonenumber-js@1.12.36/node_modules/libphonenumber-js/es6/helpers/extension/createExtensionPattern.es.js +11 -0
- package/dist/node_modules/.pnpm/libphonenumber-js@1.12.36/node_modules/libphonenumber-js/es6/helpers/extension/extractExtension.cjs.js +1 -0
- package/dist/node_modules/.pnpm/libphonenumber-js@1.12.36/node_modules/libphonenumber-js/es6/helpers/extension/extractExtension.es.js +18 -0
- package/dist/node_modules/.pnpm/libphonenumber-js@1.12.36/node_modules/libphonenumber-js/es6/helpers/extractCountryCallingCode.cjs.js +1 -0
- package/dist/node_modules/.pnpm/libphonenumber-js@1.12.36/node_modules/libphonenumber-js/es6/helpers/extractCountryCallingCode.es.js +47 -0
- package/dist/node_modules/.pnpm/libphonenumber-js@1.12.36/node_modules/libphonenumber-js/es6/helpers/extractCountryCallingCodeFromInternationalNumberWithoutPlusSign.cjs.js +1 -0
- package/dist/node_modules/.pnpm/libphonenumber-js@1.12.36/node_modules/libphonenumber-js/es6/helpers/extractCountryCallingCodeFromInternationalNumberWithoutPlusSign.es.js +22 -0
- package/dist/node_modules/.pnpm/libphonenumber-js@1.12.36/node_modules/libphonenumber-js/es6/helpers/extractFormattedPhoneNumberFromPossibleRfc3966NumberUri.cjs.js +1 -0
- package/dist/node_modules/.pnpm/libphonenumber-js@1.12.36/node_modules/libphonenumber-js/es6/helpers/extractFormattedPhoneNumberFromPossibleRfc3966NumberUri.es.js +23 -0
- package/dist/node_modules/.pnpm/libphonenumber-js@1.12.36/node_modules/libphonenumber-js/es6/helpers/extractNationalNumber.cjs.js +1 -0
- package/dist/node_modules/.pnpm/libphonenumber-js@1.12.36/node_modules/libphonenumber-js/es6/helpers/extractNationalNumber.es.js +39 -0
- package/dist/node_modules/.pnpm/libphonenumber-js@1.12.36/node_modules/libphonenumber-js/es6/helpers/extractNationalNumberFromPossiblyIncompleteNumber.cjs.js +1 -0
- package/dist/node_modules/.pnpm/libphonenumber-js@1.12.36/node_modules/libphonenumber-js/es6/helpers/extractNationalNumberFromPossiblyIncompleteNumber.es.js +31 -0
- package/dist/node_modules/.pnpm/libphonenumber-js@1.12.36/node_modules/libphonenumber-js/es6/helpers/extractPhoneContext.cjs.js +1 -0
- package/dist/node_modules/.pnpm/libphonenumber-js@1.12.36/node_modules/libphonenumber-js/es6/helpers/extractPhoneContext.es.js +23 -0
- package/dist/node_modules/.pnpm/libphonenumber-js@1.12.36/node_modules/libphonenumber-js/es6/helpers/formatNationalNumberUsingFormat.cjs.js +1 -0
- package/dist/node_modules/.pnpm/libphonenumber-js@1.12.36/node_modules/libphonenumber-js/es6/helpers/formatNationalNumberUsingFormat.es.js +27 -0
- package/dist/node_modules/.pnpm/libphonenumber-js@1.12.36/node_modules/libphonenumber-js/es6/helpers/getCountryByCallingCode.cjs.js +1 -0
- package/dist/node_modules/.pnpm/libphonenumber-js@1.12.36/node_modules/libphonenumber-js/es6/helpers/getCountryByCallingCode.es.js +12 -0
- package/dist/node_modules/.pnpm/libphonenumber-js@1.12.36/node_modules/libphonenumber-js/es6/helpers/getCountryByNationalNumber.cjs.js +2 -0
- package/dist/node_modules/.pnpm/libphonenumber-js@1.12.36/node_modules/libphonenumber-js/es6/helpers/getCountryByNationalNumber.es.js +45 -0
- package/dist/node_modules/.pnpm/libphonenumber-js@1.12.36/node_modules/libphonenumber-js/es6/helpers/getIddPrefix.cjs.js +1 -0
- package/dist/node_modules/.pnpm/libphonenumber-js@1.12.36/node_modules/libphonenumber-js/es6/helpers/getIddPrefix.es.js +12 -0
- package/dist/node_modules/.pnpm/libphonenumber-js@1.12.36/node_modules/libphonenumber-js/es6/helpers/getNumberType.cjs.js +2 -0
- package/dist/node_modules/.pnpm/libphonenumber-js@1.12.36/node_modules/libphonenumber-js/es6/helpers/getNumberType.es.js +50 -0
- package/dist/node_modules/.pnpm/libphonenumber-js@1.12.36/node_modules/libphonenumber-js/es6/helpers/getPossibleCountriesForNumber.cjs.js +1 -0
- package/dist/node_modules/.pnpm/libphonenumber-js@1.12.36/node_modules/libphonenumber-js/es6/helpers/getPossibleCountriesForNumber.es.js +14 -0
- package/dist/node_modules/.pnpm/libphonenumber-js@1.12.36/node_modules/libphonenumber-js/es6/helpers/isObject.cjs.js +1 -0
- package/dist/node_modules/.pnpm/libphonenumber-js@1.12.36/node_modules/libphonenumber-js/es6/helpers/isObject.es.js +7 -0
- package/dist/node_modules/.pnpm/libphonenumber-js@1.12.36/node_modules/libphonenumber-js/es6/helpers/isViablePhoneNumber.cjs.js +1 -0
- package/dist/node_modules/.pnpm/libphonenumber-js@1.12.36/node_modules/libphonenumber-js/es6/helpers/isViablePhoneNumber.es.js +20 -0
- package/dist/node_modules/.pnpm/libphonenumber-js@1.12.36/node_modules/libphonenumber-js/es6/helpers/matchesEntirely.cjs.js +1 -0
- package/dist/node_modules/.pnpm/libphonenumber-js@1.12.36/node_modules/libphonenumber-js/es6/helpers/matchesEntirely.es.js +6 -0
- package/dist/node_modules/.pnpm/libphonenumber-js@1.12.36/node_modules/libphonenumber-js/es6/helpers/parseDigits.cjs.js +2 -0
- package/dist/node_modules/.pnpm/libphonenumber-js@1.12.36/node_modules/libphonenumber-js/es6/helpers/parseDigits.es.js +112 -0
- package/dist/node_modules/.pnpm/libphonenumber-js@1.12.36/node_modules/libphonenumber-js/es6/helpers/stripIddPrefix.cjs.js +1 -0
- package/dist/node_modules/.pnpm/libphonenumber-js@1.12.36/node_modules/libphonenumber-js/es6/helpers/stripIddPrefix.es.js +19 -0
- package/dist/node_modules/.pnpm/libphonenumber-js@1.12.36/node_modules/libphonenumber-js/es6/isPossible.cjs.js +1 -0
- package/dist/node_modules/.pnpm/libphonenumber-js@1.12.36/node_modules/libphonenumber-js/es6/isPossible.es.js +42 -0
- package/dist/node_modules/.pnpm/libphonenumber-js@1.12.36/node_modules/libphonenumber-js/es6/isValid.cjs.js +1 -0
- package/dist/node_modules/.pnpm/libphonenumber-js@1.12.36/node_modules/libphonenumber-js/es6/isValid.es.js +12 -0
- package/dist/node_modules/.pnpm/libphonenumber-js@1.12.36/node_modules/libphonenumber-js/es6/isValidPhoneNumber.cjs.js +1 -0
- package/dist/node_modules/.pnpm/libphonenumber-js@1.12.36/node_modules/libphonenumber-js/es6/isValidPhoneNumber.es.js +59 -0
- package/dist/node_modules/.pnpm/libphonenumber-js@1.12.36/node_modules/libphonenumber-js/es6/metadata.cjs.js +1 -0
- package/dist/node_modules/.pnpm/libphonenumber-js@1.12.36/node_modules/libphonenumber-js/es6/metadata.es.js +473 -0
- package/dist/node_modules/.pnpm/libphonenumber-js@1.12.36/node_modules/libphonenumber-js/es6/normalizeArguments.cjs.js +2 -0
- package/dist/node_modules/.pnpm/libphonenumber-js@1.12.36/node_modules/libphonenumber-js/es6/normalizeArguments.es.js +108 -0
- package/dist/node_modules/.pnpm/libphonenumber-js@1.12.36/node_modules/libphonenumber-js/es6/parse.cjs.js +1 -0
- package/dist/node_modules/.pnpm/libphonenumber-js@1.12.36/node_modules/libphonenumber-js/es6/parse.es.js +119 -0
- package/dist/node_modules/.pnpm/libphonenumber-js@1.12.36/node_modules/libphonenumber-js/es6/parseIncompletePhoneNumber.cjs.js +2 -0
- package/dist/node_modules/.pnpm/libphonenumber-js@1.12.36/node_modules/libphonenumber-js/es6/parseIncompletePhoneNumber.es.js +47 -0
- package/dist/node_modules/.pnpm/libphonenumber-js@1.12.36/node_modules/libphonenumber-js/es6/parsePhoneNumber.cjs.js +1 -0
- package/dist/node_modules/.pnpm/libphonenumber-js@1.12.36/node_modules/libphonenumber-js/es6/parsePhoneNumber.es.js +9 -0
- package/dist/node_modules/.pnpm/libphonenumber-js@1.12.36/node_modules/libphonenumber-js/es6/parsePhoneNumberWithError_.cjs.js +1 -0
- package/dist/node_modules/.pnpm/libphonenumber-js@1.12.36/node_modules/libphonenumber-js/es6/parsePhoneNumberWithError_.es.js +55 -0
- package/dist/node_modules/.pnpm/libphonenumber-js@1.12.36/node_modules/libphonenumber-js/es6/parsePhoneNumber_.cjs.js +1 -0
- package/dist/node_modules/.pnpm/libphonenumber-js@1.12.36/node_modules/libphonenumber-js/es6/parsePhoneNumber_.es.js +62 -0
- package/dist/node_modules/.pnpm/libphonenumber-js@1.12.36/node_modules/libphonenumber-js/es6/tools/semver-compare.cjs.js +1 -0
- package/dist/node_modules/.pnpm/libphonenumber-js@1.12.36/node_modules/libphonenumber-js/es6/tools/semver-compare.es.js +14 -0
- package/dist/node_modules/.pnpm/libphonenumber-js@1.12.36/node_modules/libphonenumber-js/metadata.min.json.cjs.js +1 -0
- package/dist/node_modules/.pnpm/libphonenumber-js@1.12.36/node_modules/libphonenumber-js/metadata.min.json.es.js +4 -0
- package/dist/node_modules/.pnpm/object-assign@4.1.1/node_modules/object-assign/index.cjs.js +5 -0
- package/dist/node_modules/.pnpm/object-assign@4.1.1/node_modules/object-assign/index.es.js +54 -0
- package/dist/node_modules/.pnpm/prop-types@15.8.1/node_modules/prop-types/checkPropTypes.cjs.js +1 -0
- package/dist/node_modules/.pnpm/prop-types@15.8.1/node_modules/prop-types/checkPropTypes.es.js +54 -0
- package/dist/node_modules/.pnpm/prop-types@15.8.1/node_modules/prop-types/factoryWithThrowingShims.cjs.js +1 -0
- package/dist/node_modules/.pnpm/prop-types@15.8.1/node_modules/prop-types/factoryWithThrowingShims.es.js +52 -0
- package/dist/node_modules/.pnpm/prop-types@15.8.1/node_modules/prop-types/factoryWithTypeCheckers.cjs.js +2 -0
- package/dist/node_modules/.pnpm/prop-types@15.8.1/node_modules/prop-types/factoryWithTypeCheckers.es.js +329 -0
- package/dist/node_modules/.pnpm/prop-types@15.8.1/node_modules/prop-types/index.cjs.js +1 -0
- package/dist/node_modules/.pnpm/prop-types@15.8.1/node_modules/prop-types/index.es.js +17 -0
- package/dist/node_modules/.pnpm/prop-types@15.8.1/node_modules/prop-types/lib/ReactPropTypesSecret.cjs.js +1 -0
- package/dist/node_modules/.pnpm/prop-types@15.8.1/node_modules/prop-types/lib/ReactPropTypesSecret.es.js +10 -0
- package/dist/node_modules/.pnpm/prop-types@15.8.1/node_modules/prop-types/lib/has.cjs.js +1 -0
- package/dist/node_modules/.pnpm/prop-types@15.8.1/node_modules/prop-types/lib/has.es.js +7 -0
- package/dist/node_modules/.pnpm/react-is@16.13.1/node_modules/react-is/cjs/react-is.development.cjs.js +8 -0
- package/dist/node_modules/.pnpm/react-is@16.13.1/node_modules/react-is/cjs/react-is.development.es.js +95 -0
- package/dist/node_modules/.pnpm/react-is@16.13.1/node_modules/react-is/cjs/react-is.production.min.cjs.js +8 -0
- package/dist/node_modules/.pnpm/react-is@16.13.1/node_modules/react-is/cjs/react-is.production.min.es.js +78 -0
- package/dist/node_modules/.pnpm/react-is@16.13.1/node_modules/react-is/index.cjs.js +1 -0
- package/dist/node_modules/.pnpm/react-is@16.13.1/node_modules/react-is/index.es.js +10 -0
- package/dist/node_modules/.pnpm/react-phone-number-input@3.4.14_react-dom@18.3.1_react@18.3.1__react@18.3.1/node_modules/react-phone-number-input/locale/en.json.cjs.js +1 -0
- package/dist/node_modules/.pnpm/react-phone-number-input@3.4.14_react-dom@18.3.1_react@18.3.1__react@18.3.1/node_modules/react-phone-number-input/locale/en.json.es.js +263 -0
- package/dist/node_modules/.pnpm/react-phone-number-input@3.4.14_react-dom@18.3.1_react@18.3.1__react@18.3.1/node_modules/react-phone-number-input/min/index.cjs.js +1 -0
- package/dist/node_modules/.pnpm/react-phone-number-input@3.4.14_react-dom@18.3.1_react@18.3.1__react@18.3.1/node_modules/react-phone-number-input/min/index.es.js +20 -0
- package/dist/node_modules/.pnpm/react-phone-number-input@3.4.14_react-dom@18.3.1_react@18.3.1__react@18.3.1/node_modules/react-phone-number-input/modules/CountryIcon.cjs.js +1 -0
- package/dist/node_modules/.pnpm/react-phone-number-input@3.4.14_react-dom@18.3.1_react@18.3.1__react@18.3.1/node_modules/react-phone-number-input/modules/CountryIcon.es.js +69 -0
- package/dist/node_modules/.pnpm/react-phone-number-input@3.4.14_react-dom@18.3.1_react@18.3.1__react@18.3.1/node_modules/react-phone-number-input/modules/CountrySelect.cjs.js +2 -0
- package/dist/node_modules/.pnpm/react-phone-number-input@3.4.14_react-dom@18.3.1_react@18.3.1__react@18.3.1/node_modules/react-phone-number-input/modules/CountrySelect.es.js +158 -0
- package/dist/node_modules/.pnpm/react-phone-number-input@3.4.14_react-dom@18.3.1_react@18.3.1__react@18.3.1/node_modules/react-phone-number-input/modules/Flag.cjs.js +1 -0
- package/dist/node_modules/.pnpm/react-phone-number-input@3.4.14_react-dom@18.3.1_react@18.3.1__react@18.3.1/node_modules/react-phone-number-input/modules/Flag.es.js +62 -0
- package/dist/node_modules/.pnpm/react-phone-number-input@3.4.14_react-dom@18.3.1_react@18.3.1__react@18.3.1/node_modules/react-phone-number-input/modules/InputBasic.cjs.js +1 -0
- package/dist/node_modules/.pnpm/react-phone-number-input@3.4.14_react-dom@18.3.1_react@18.3.1__react@18.3.1/node_modules/react-phone-number-input/modules/InputBasic.es.js +113 -0
- package/dist/node_modules/.pnpm/react-phone-number-input@3.4.14_react-dom@18.3.1_react@18.3.1__react@18.3.1/node_modules/react-phone-number-input/modules/InputSmart.cjs.js +1 -0
- package/dist/node_modules/.pnpm/react-phone-number-input@3.4.14_react-dom@18.3.1_react@18.3.1__react@18.3.1/node_modules/react-phone-number-input/modules/InputSmart.es.js +106 -0
- package/dist/node_modules/.pnpm/react-phone-number-input@3.4.14_react-dom@18.3.1_react@18.3.1__react@18.3.1/node_modules/react-phone-number-input/modules/InternationalIcon.cjs.js +1 -0
- package/dist/node_modules/.pnpm/react-phone-number-input@3.4.14_react-dom@18.3.1_react@18.3.1__react@18.3.1/node_modules/react-phone-number-input/modules/InternationalIcon.es.js +122 -0
- package/dist/node_modules/.pnpm/react-phone-number-input@3.4.14_react-dom@18.3.1_react@18.3.1__react@18.3.1/node_modules/react-phone-number-input/modules/PhoneInputWithCountry.cjs.js +1 -0
- package/dist/node_modules/.pnpm/react-phone-number-input@3.4.14_react-dom@18.3.1_react@18.3.1__react@18.3.1/node_modules/react-phone-number-input/modules/PhoneInputWithCountry.es.js +830 -0
- package/dist/node_modules/.pnpm/react-phone-number-input@3.4.14_react-dom@18.3.1_react@18.3.1__react@18.3.1/node_modules/react-phone-number-input/modules/PhoneInputWithCountryDefault.cjs.js +1 -0
- package/dist/node_modules/.pnpm/react-phone-number-input@3.4.14_react-dom@18.3.1_react@18.3.1__react@18.3.1/node_modules/react-phone-number-input/modules/PhoneInputWithCountryDefault.es.js +50 -0
- package/dist/node_modules/.pnpm/react-phone-number-input@3.4.14_react-dom@18.3.1_react@18.3.1__react@18.3.1/node_modules/react-phone-number-input/modules/PropTypes.cjs.js +1 -0
- package/dist/node_modules/.pnpm/react-phone-number-input@3.4.14_react-dom@18.3.1_react@18.3.1__react@18.3.1/node_modules/react-phone-number-input/modules/PropTypes.es.js +9 -0
- package/dist/node_modules/.pnpm/react-phone-number-input@3.4.14_react-dom@18.3.1_react@18.3.1__react@18.3.1/node_modules/react-phone-number-input/modules/helpers/countries.cjs.js +2 -0
- package/dist/node_modules/.pnpm/react-phone-number-input@3.4.14_react-dom@18.3.1_react@18.3.1__react@18.3.1/node_modules/react-phone-number-input/modules/helpers/countries.es.js +78 -0
- package/dist/node_modules/.pnpm/react-phone-number-input@3.4.14_react-dom@18.3.1_react@18.3.1__react@18.3.1/node_modules/react-phone-number-input/modules/helpers/getInternationalPhoneNumberPrefix.cjs.js +1 -0
- package/dist/node_modules/.pnpm/react-phone-number-input@3.4.14_react-dom@18.3.1_react@18.3.1__react@18.3.1/node_modules/react-phone-number-input/modules/helpers/getInternationalPhoneNumberPrefix.es.js +8 -0
- package/dist/node_modules/.pnpm/react-phone-number-input@3.4.14_react-dom@18.3.1_react@18.3.1__react@18.3.1/node_modules/react-phone-number-input/modules/helpers/getPhoneInputWithCountryStateUpdateFromNewProps.cjs.js +1 -0
- package/dist/node_modules/.pnpm/react-phone-number-input@3.4.14_react-dom@18.3.1_react@18.3.1__react@18.3.1/node_modules/react-phone-number-input/modules/helpers/getPhoneInputWithCountryStateUpdateFromNewProps.es.js +141 -0
- package/dist/node_modules/.pnpm/react-phone-number-input@3.4.14_react-dom@18.3.1_react@18.3.1__react@18.3.1/node_modules/react-phone-number-input/modules/helpers/inputValuePrefix.cjs.js +1 -0
- package/dist/node_modules/.pnpm/react-phone-number-input@3.4.14_react-dom@18.3.1_react@18.3.1__react@18.3.1/node_modules/react-phone-number-input/modules/helpers/inputValuePrefix.es.js +12 -0
- package/dist/node_modules/.pnpm/react-phone-number-input@3.4.14_react-dom@18.3.1_react@18.3.1__react@18.3.1/node_modules/react-phone-number-input/modules/helpers/isE164Number.cjs.js +1 -0
- package/dist/node_modules/.pnpm/react-phone-number-input@3.4.14_react-dom@18.3.1_react@18.3.1__react@18.3.1/node_modules/react-phone-number-input/modules/helpers/isE164Number.es.js +17 -0
- package/dist/node_modules/.pnpm/react-phone-number-input@3.4.14_react-dom@18.3.1_react@18.3.1__react@18.3.1/node_modules/react-phone-number-input/modules/helpers/parsePhoneNumberCharacter.cjs.js +1 -0
- package/dist/node_modules/.pnpm/react-phone-number-input@3.4.14_react-dom@18.3.1_react@18.3.1__react@18.3.1/node_modules/react-phone-number-input/modules/helpers/parsePhoneNumberCharacter.es.js +17 -0
- package/dist/node_modules/.pnpm/react-phone-number-input@3.4.14_react-dom@18.3.1_react@18.3.1__react@18.3.1/node_modules/react-phone-number-input/modules/helpers/phoneInputHelpers.cjs.js +1 -0
- package/dist/node_modules/.pnpm/react-phone-number-input@3.4.14_react-dom@18.3.1_react@18.3.1__react@18.3.1/node_modules/react-phone-number-input/modules/helpers/phoneInputHelpers.es.js +203 -0
- package/dist/node_modules/.pnpm/react-phone-number-input@3.4.14_react-dom@18.3.1_react@18.3.1__react@18.3.1/node_modules/react-phone-number-input/modules/useExternalRef.cjs.js +2 -0
- package/dist/node_modules/.pnpm/react-phone-number-input@3.4.14_react-dom@18.3.1_react@18.3.1__react@18.3.1/node_modules/react-phone-number-input/modules/useExternalRef.es.js +39 -0
- package/dist/node_modules/.pnpm/react-phone-number-input@3.4.14_react-dom@18.3.1_react@18.3.1__react@18.3.1/node_modules/react-phone-number-input/modules/useInputKeyDownHandler.cjs.js +1 -0
- package/dist/node_modules/.pnpm/react-phone-number-input@3.4.14_react-dom@18.3.1_react@18.3.1__react@18.3.1/node_modules/react-phone-number-input/modules/useInputKeyDownHandler.es.js +18 -0
- package/dist/style.css +1 -1
- package/package.json +5 -4
|
@@ -0,0 +1,473 @@
|
|
|
1
|
+
import f from "./tools/semver-compare.es.js";
|
|
2
|
+
import l from "./helpers/isObject.es.js";
|
|
3
|
+
function a(n) {
|
|
4
|
+
"@babel/helpers - typeof";
|
|
5
|
+
return a = typeof Symbol == "function" && typeof Symbol.iterator == "symbol" ? function(t) {
|
|
6
|
+
return typeof t;
|
|
7
|
+
} : function(t) {
|
|
8
|
+
return t && typeof Symbol == "function" && t.constructor === Symbol && t !== Symbol.prototype ? "symbol" : typeof t;
|
|
9
|
+
}, a(n);
|
|
10
|
+
}
|
|
11
|
+
function o(n, t) {
|
|
12
|
+
if (!(n instanceof t)) throw new TypeError("Cannot call a class as a function");
|
|
13
|
+
}
|
|
14
|
+
function y(n, t) {
|
|
15
|
+
for (var e = 0; e < t.length; e++) {
|
|
16
|
+
var i = t[e];
|
|
17
|
+
i.enumerable = i.enumerable || !1, i.configurable = !0, "value" in i && (i.writable = !0), Object.defineProperty(n, v(i.key), i);
|
|
18
|
+
}
|
|
19
|
+
}
|
|
20
|
+
function u(n, t, e) {
|
|
21
|
+
return t && y(n.prototype, t), Object.defineProperty(n, "prototype", { writable: !1 }), n;
|
|
22
|
+
}
|
|
23
|
+
function v(n) {
|
|
24
|
+
var t = P(n, "string");
|
|
25
|
+
return a(t) == "symbol" ? t : t + "";
|
|
26
|
+
}
|
|
27
|
+
function P(n, t) {
|
|
28
|
+
if (a(n) != "object" || !n) return n;
|
|
29
|
+
var e = n[Symbol.toPrimitive];
|
|
30
|
+
if (e !== void 0) {
|
|
31
|
+
var i = e.call(n, t);
|
|
32
|
+
if (a(i) != "object") return i;
|
|
33
|
+
throw new TypeError("@@toPrimitive must return a primitive value.");
|
|
34
|
+
}
|
|
35
|
+
return String(n);
|
|
36
|
+
}
|
|
37
|
+
var d = "1.2.0", p = "1.7.35", h = " ext. ", C = /^\d+$/, b = /* @__PURE__ */ (function() {
|
|
38
|
+
function n(t) {
|
|
39
|
+
o(this, n), _(t), this.metadata = t, m.call(this, t);
|
|
40
|
+
}
|
|
41
|
+
return u(n, [{
|
|
42
|
+
key: "getCountries",
|
|
43
|
+
value: function() {
|
|
44
|
+
return Object.keys(this.metadata.countries).filter(function(e) {
|
|
45
|
+
return e !== "001";
|
|
46
|
+
});
|
|
47
|
+
}
|
|
48
|
+
}, {
|
|
49
|
+
key: "getCountryMetadata",
|
|
50
|
+
value: function(e) {
|
|
51
|
+
return this.metadata.countries[e];
|
|
52
|
+
}
|
|
53
|
+
}, {
|
|
54
|
+
key: "nonGeographic",
|
|
55
|
+
value: function() {
|
|
56
|
+
if (!(this.v1 || this.v2 || this.v3))
|
|
57
|
+
return this.metadata.nonGeographic || this.metadata.nonGeographical;
|
|
58
|
+
}
|
|
59
|
+
}, {
|
|
60
|
+
key: "hasCountry",
|
|
61
|
+
value: function(e) {
|
|
62
|
+
return this.getCountryMetadata(e) !== void 0;
|
|
63
|
+
}
|
|
64
|
+
}, {
|
|
65
|
+
key: "hasCallingCode",
|
|
66
|
+
value: function(e) {
|
|
67
|
+
if (this.getCountryCodesForCallingCode(e))
|
|
68
|
+
return !0;
|
|
69
|
+
if (this.nonGeographic()) {
|
|
70
|
+
if (this.nonGeographic()[e])
|
|
71
|
+
return !0;
|
|
72
|
+
} else {
|
|
73
|
+
var i = this.countryCallingCodes()[e];
|
|
74
|
+
if (i && i.length === 1 && i[0] === "001")
|
|
75
|
+
return !0;
|
|
76
|
+
}
|
|
77
|
+
}
|
|
78
|
+
}, {
|
|
79
|
+
key: "isNonGeographicCallingCode",
|
|
80
|
+
value: function(e) {
|
|
81
|
+
return this.nonGeographic() ? !!this.nonGeographic()[e] : !this.getCountryCodesForCallingCode(e);
|
|
82
|
+
}
|
|
83
|
+
// Deprecated.
|
|
84
|
+
}, {
|
|
85
|
+
key: "country",
|
|
86
|
+
value: function(e) {
|
|
87
|
+
return this.selectNumberingPlan(e);
|
|
88
|
+
}
|
|
89
|
+
}, {
|
|
90
|
+
key: "selectNumberingPlan",
|
|
91
|
+
value: function(e, i) {
|
|
92
|
+
if (e && C.test(e) && (i = e, e = null), e && e !== "001") {
|
|
93
|
+
if (!this.hasCountry(e))
|
|
94
|
+
throw new Error("Unknown country: ".concat(e));
|
|
95
|
+
this.numberingPlan = new g(this.getCountryMetadata(e), this);
|
|
96
|
+
} else if (i) {
|
|
97
|
+
if (!this.hasCallingCode(i))
|
|
98
|
+
throw new Error("Unknown calling code: ".concat(i));
|
|
99
|
+
this.numberingPlan = new g(this.getNumberingPlanMetadata(i), this);
|
|
100
|
+
} else
|
|
101
|
+
this.numberingPlan = void 0;
|
|
102
|
+
return this;
|
|
103
|
+
}
|
|
104
|
+
}, {
|
|
105
|
+
key: "getCountryCodesForCallingCode",
|
|
106
|
+
value: function(e) {
|
|
107
|
+
var i = this.countryCallingCodes()[e];
|
|
108
|
+
if (i)
|
|
109
|
+
return i.length === 1 && i[0].length === 3 ? void 0 : i;
|
|
110
|
+
}
|
|
111
|
+
}, {
|
|
112
|
+
key: "getCountryCodeForCallingCode",
|
|
113
|
+
value: function(e) {
|
|
114
|
+
var i = this.getCountryCodesForCallingCode(e);
|
|
115
|
+
if (i)
|
|
116
|
+
return i[0];
|
|
117
|
+
}
|
|
118
|
+
}, {
|
|
119
|
+
key: "getNumberingPlanMetadata",
|
|
120
|
+
value: function(e) {
|
|
121
|
+
var i = this.getCountryCodeForCallingCode(e);
|
|
122
|
+
if (i)
|
|
123
|
+
return this.getCountryMetadata(i);
|
|
124
|
+
if (this.nonGeographic()) {
|
|
125
|
+
var r = this.nonGeographic()[e];
|
|
126
|
+
if (r)
|
|
127
|
+
return r;
|
|
128
|
+
} else {
|
|
129
|
+
var s = this.countryCallingCodes()[e];
|
|
130
|
+
if (s && s.length === 1 && s[0] === "001")
|
|
131
|
+
return this.metadata.countries["001"];
|
|
132
|
+
}
|
|
133
|
+
}
|
|
134
|
+
// Deprecated.
|
|
135
|
+
}, {
|
|
136
|
+
key: "countryCallingCode",
|
|
137
|
+
value: function() {
|
|
138
|
+
return this.numberingPlan.callingCode();
|
|
139
|
+
}
|
|
140
|
+
// Deprecated.
|
|
141
|
+
}, {
|
|
142
|
+
key: "IDDPrefix",
|
|
143
|
+
value: function() {
|
|
144
|
+
return this.numberingPlan.IDDPrefix();
|
|
145
|
+
}
|
|
146
|
+
// Deprecated.
|
|
147
|
+
}, {
|
|
148
|
+
key: "defaultIDDPrefix",
|
|
149
|
+
value: function() {
|
|
150
|
+
return this.numberingPlan.defaultIDDPrefix();
|
|
151
|
+
}
|
|
152
|
+
// Deprecated.
|
|
153
|
+
}, {
|
|
154
|
+
key: "nationalNumberPattern",
|
|
155
|
+
value: function() {
|
|
156
|
+
return this.numberingPlan.nationalNumberPattern();
|
|
157
|
+
}
|
|
158
|
+
// Deprecated.
|
|
159
|
+
}, {
|
|
160
|
+
key: "possibleLengths",
|
|
161
|
+
value: function() {
|
|
162
|
+
return this.numberingPlan.possibleLengths();
|
|
163
|
+
}
|
|
164
|
+
// Deprecated.
|
|
165
|
+
}, {
|
|
166
|
+
key: "formats",
|
|
167
|
+
value: function() {
|
|
168
|
+
return this.numberingPlan.formats();
|
|
169
|
+
}
|
|
170
|
+
// Deprecated.
|
|
171
|
+
}, {
|
|
172
|
+
key: "nationalPrefixForParsing",
|
|
173
|
+
value: function() {
|
|
174
|
+
return this.numberingPlan.nationalPrefixForParsing();
|
|
175
|
+
}
|
|
176
|
+
// Deprecated.
|
|
177
|
+
}, {
|
|
178
|
+
key: "nationalPrefixTransformRule",
|
|
179
|
+
value: function() {
|
|
180
|
+
return this.numberingPlan.nationalPrefixTransformRule();
|
|
181
|
+
}
|
|
182
|
+
// Deprecated.
|
|
183
|
+
}, {
|
|
184
|
+
key: "leadingDigits",
|
|
185
|
+
value: function() {
|
|
186
|
+
return this.numberingPlan.leadingDigits();
|
|
187
|
+
}
|
|
188
|
+
// Deprecated.
|
|
189
|
+
}, {
|
|
190
|
+
key: "hasTypes",
|
|
191
|
+
value: function() {
|
|
192
|
+
return this.numberingPlan.hasTypes();
|
|
193
|
+
}
|
|
194
|
+
// Deprecated.
|
|
195
|
+
}, {
|
|
196
|
+
key: "type",
|
|
197
|
+
value: function(e) {
|
|
198
|
+
return this.numberingPlan.type(e);
|
|
199
|
+
}
|
|
200
|
+
// Deprecated.
|
|
201
|
+
}, {
|
|
202
|
+
key: "ext",
|
|
203
|
+
value: function() {
|
|
204
|
+
return this.numberingPlan.ext();
|
|
205
|
+
}
|
|
206
|
+
}, {
|
|
207
|
+
key: "countryCallingCodes",
|
|
208
|
+
value: function() {
|
|
209
|
+
return this.v1 ? this.metadata.country_phone_code_to_countries : this.metadata.country_calling_codes;
|
|
210
|
+
}
|
|
211
|
+
// Deprecated.
|
|
212
|
+
}, {
|
|
213
|
+
key: "chooseCountryByCountryCallingCode",
|
|
214
|
+
value: function(e) {
|
|
215
|
+
return this.selectNumberingPlan(e);
|
|
216
|
+
}
|
|
217
|
+
}, {
|
|
218
|
+
key: "hasSelectedNumberingPlan",
|
|
219
|
+
value: function() {
|
|
220
|
+
return this.numberingPlan !== void 0;
|
|
221
|
+
}
|
|
222
|
+
}]);
|
|
223
|
+
})(), g = /* @__PURE__ */ (function() {
|
|
224
|
+
function n(t, e) {
|
|
225
|
+
o(this, n), this.globalMetadataObject = e, this.metadata = t, m.call(this, e.metadata);
|
|
226
|
+
}
|
|
227
|
+
return u(n, [{
|
|
228
|
+
key: "callingCode",
|
|
229
|
+
value: function() {
|
|
230
|
+
return this.metadata[0];
|
|
231
|
+
}
|
|
232
|
+
// Formatting information for regions which share
|
|
233
|
+
// a country calling code is contained by only one region
|
|
234
|
+
// for performance reasons. For example, for NANPA region
|
|
235
|
+
// ("North American Numbering Plan Administration",
|
|
236
|
+
// which includes USA, Canada, Cayman Islands, Bahamas, etc)
|
|
237
|
+
// it will be contained in the metadata for `US`.
|
|
238
|
+
}, {
|
|
239
|
+
key: "getDefaultCountryMetadataForRegion",
|
|
240
|
+
value: function() {
|
|
241
|
+
return this.globalMetadataObject.getNumberingPlanMetadata(this.callingCode());
|
|
242
|
+
}
|
|
243
|
+
// Is always present.
|
|
244
|
+
}, {
|
|
245
|
+
key: "IDDPrefix",
|
|
246
|
+
value: function() {
|
|
247
|
+
if (!(this.v1 || this.v2))
|
|
248
|
+
return this.metadata[1];
|
|
249
|
+
}
|
|
250
|
+
// Is only present when a country supports multiple IDD prefixes.
|
|
251
|
+
}, {
|
|
252
|
+
key: "defaultIDDPrefix",
|
|
253
|
+
value: function() {
|
|
254
|
+
if (!(this.v1 || this.v2))
|
|
255
|
+
return this.metadata[12];
|
|
256
|
+
}
|
|
257
|
+
}, {
|
|
258
|
+
key: "nationalNumberPattern",
|
|
259
|
+
value: function() {
|
|
260
|
+
return this.v1 || this.v2 ? this.metadata[1] : this.metadata[2];
|
|
261
|
+
}
|
|
262
|
+
// "possible length" data is always present in Google's metadata.
|
|
263
|
+
}, {
|
|
264
|
+
key: "possibleLengths",
|
|
265
|
+
value: function() {
|
|
266
|
+
if (!this.v1)
|
|
267
|
+
return this.metadata[this.v2 ? 2 : 3];
|
|
268
|
+
}
|
|
269
|
+
}, {
|
|
270
|
+
key: "_getFormats",
|
|
271
|
+
value: function(e) {
|
|
272
|
+
return e[this.v1 ? 2 : this.v2 ? 3 : 4];
|
|
273
|
+
}
|
|
274
|
+
// For countries of the same region (e.g. NANPA)
|
|
275
|
+
// formats are all stored in the "main" country for that region.
|
|
276
|
+
// E.g. "RU" and "KZ", "US" and "CA".
|
|
277
|
+
}, {
|
|
278
|
+
key: "formats",
|
|
279
|
+
value: function() {
|
|
280
|
+
var e = this, i = this._getFormats(this.metadata) || this._getFormats(this.getDefaultCountryMetadataForRegion()) || [];
|
|
281
|
+
return i.map(function(r) {
|
|
282
|
+
return new F(r, e);
|
|
283
|
+
});
|
|
284
|
+
}
|
|
285
|
+
}, {
|
|
286
|
+
key: "nationalPrefix",
|
|
287
|
+
value: function() {
|
|
288
|
+
return this.metadata[this.v1 ? 3 : this.v2 ? 4 : 5];
|
|
289
|
+
}
|
|
290
|
+
}, {
|
|
291
|
+
key: "_getNationalPrefixFormattingRule",
|
|
292
|
+
value: function(e) {
|
|
293
|
+
return e[this.v1 ? 4 : this.v2 ? 5 : 6];
|
|
294
|
+
}
|
|
295
|
+
// For countries of the same region (e.g. NANPA)
|
|
296
|
+
// national prefix formatting rule is stored in the "main" country for that region.
|
|
297
|
+
// E.g. "RU" and "KZ", "US" and "CA".
|
|
298
|
+
}, {
|
|
299
|
+
key: "nationalPrefixFormattingRule",
|
|
300
|
+
value: function() {
|
|
301
|
+
return this._getNationalPrefixFormattingRule(this.metadata) || this._getNationalPrefixFormattingRule(this.getDefaultCountryMetadataForRegion());
|
|
302
|
+
}
|
|
303
|
+
}, {
|
|
304
|
+
key: "_nationalPrefixForParsing",
|
|
305
|
+
value: function() {
|
|
306
|
+
return this.metadata[this.v1 ? 5 : this.v2 ? 6 : 7];
|
|
307
|
+
}
|
|
308
|
+
}, {
|
|
309
|
+
key: "nationalPrefixForParsing",
|
|
310
|
+
value: function() {
|
|
311
|
+
return this._nationalPrefixForParsing() || this.nationalPrefix();
|
|
312
|
+
}
|
|
313
|
+
}, {
|
|
314
|
+
key: "nationalPrefixTransformRule",
|
|
315
|
+
value: function() {
|
|
316
|
+
return this.metadata[this.v1 ? 6 : this.v2 ? 7 : 8];
|
|
317
|
+
}
|
|
318
|
+
}, {
|
|
319
|
+
key: "_getNationalPrefixIsOptionalWhenFormatting",
|
|
320
|
+
value: function() {
|
|
321
|
+
return !!this.metadata[this.v1 ? 7 : this.v2 ? 8 : 9];
|
|
322
|
+
}
|
|
323
|
+
// For countries of the same region (e.g. NANPA)
|
|
324
|
+
// "national prefix is optional when formatting" flag is
|
|
325
|
+
// stored in the "main" country for that region.
|
|
326
|
+
// E.g. "RU" and "KZ", "US" and "CA".
|
|
327
|
+
}, {
|
|
328
|
+
key: "nationalPrefixIsOptionalWhenFormattingInNationalFormat",
|
|
329
|
+
value: function() {
|
|
330
|
+
return this._getNationalPrefixIsOptionalWhenFormatting(this.metadata) || this._getNationalPrefixIsOptionalWhenFormatting(this.getDefaultCountryMetadataForRegion());
|
|
331
|
+
}
|
|
332
|
+
}, {
|
|
333
|
+
key: "leadingDigits",
|
|
334
|
+
value: function() {
|
|
335
|
+
return this.metadata[this.v1 ? 8 : this.v2 ? 9 : 10];
|
|
336
|
+
}
|
|
337
|
+
}, {
|
|
338
|
+
key: "types",
|
|
339
|
+
value: function() {
|
|
340
|
+
return this.metadata[this.v1 ? 9 : this.v2 ? 10 : 11];
|
|
341
|
+
}
|
|
342
|
+
}, {
|
|
343
|
+
key: "hasTypes",
|
|
344
|
+
value: function() {
|
|
345
|
+
return this.types() && this.types().length === 0 ? !1 : !!this.types();
|
|
346
|
+
}
|
|
347
|
+
}, {
|
|
348
|
+
key: "type",
|
|
349
|
+
value: function(e) {
|
|
350
|
+
if (this.hasTypes() && c(this.types(), e))
|
|
351
|
+
return new x(c(this.types(), e), this);
|
|
352
|
+
}
|
|
353
|
+
}, {
|
|
354
|
+
key: "ext",
|
|
355
|
+
value: function() {
|
|
356
|
+
return this.v1 || this.v2 ? h : this.metadata[13] || h;
|
|
357
|
+
}
|
|
358
|
+
}]);
|
|
359
|
+
})(), F = /* @__PURE__ */ (function() {
|
|
360
|
+
function n(t, e) {
|
|
361
|
+
o(this, n), this._format = t, this.metadata = e;
|
|
362
|
+
}
|
|
363
|
+
return u(n, [{
|
|
364
|
+
key: "pattern",
|
|
365
|
+
value: function() {
|
|
366
|
+
return this._format[0];
|
|
367
|
+
}
|
|
368
|
+
}, {
|
|
369
|
+
key: "format",
|
|
370
|
+
value: function() {
|
|
371
|
+
return this._format[1];
|
|
372
|
+
}
|
|
373
|
+
}, {
|
|
374
|
+
key: "leadingDigitsPatterns",
|
|
375
|
+
value: function() {
|
|
376
|
+
return this._format[2] || [];
|
|
377
|
+
}
|
|
378
|
+
}, {
|
|
379
|
+
key: "nationalPrefixFormattingRule",
|
|
380
|
+
value: function() {
|
|
381
|
+
return this._format[3] || this.metadata.nationalPrefixFormattingRule();
|
|
382
|
+
}
|
|
383
|
+
}, {
|
|
384
|
+
key: "nationalPrefixIsOptionalWhenFormattingInNationalFormat",
|
|
385
|
+
value: function() {
|
|
386
|
+
return !!this._format[4] || this.metadata.nationalPrefixIsOptionalWhenFormattingInNationalFormat();
|
|
387
|
+
}
|
|
388
|
+
}, {
|
|
389
|
+
key: "nationalPrefixIsMandatoryWhenFormattingInNationalFormat",
|
|
390
|
+
value: function() {
|
|
391
|
+
return this.usesNationalPrefix() && !this.nationalPrefixIsOptionalWhenFormattingInNationalFormat();
|
|
392
|
+
}
|
|
393
|
+
// Checks whether national prefix formatting rule contains national prefix.
|
|
394
|
+
}, {
|
|
395
|
+
key: "usesNationalPrefix",
|
|
396
|
+
value: function() {
|
|
397
|
+
return !!(this.nationalPrefixFormattingRule() && // Check that national prefix formatting rule is not a "dummy" one.
|
|
398
|
+
!k.test(this.nationalPrefixFormattingRule()));
|
|
399
|
+
}
|
|
400
|
+
}, {
|
|
401
|
+
key: "internationalFormat",
|
|
402
|
+
value: function() {
|
|
403
|
+
return this._format[5] || this.format();
|
|
404
|
+
}
|
|
405
|
+
}]);
|
|
406
|
+
})(), k = /^\(?\$1\)?$/, x = /* @__PURE__ */ (function() {
|
|
407
|
+
function n(t, e) {
|
|
408
|
+
o(this, n), this.type = t, this.metadata = e;
|
|
409
|
+
}
|
|
410
|
+
return u(n, [{
|
|
411
|
+
key: "pattern",
|
|
412
|
+
value: function() {
|
|
413
|
+
return this.metadata.v1 ? this.type : this.type[0];
|
|
414
|
+
}
|
|
415
|
+
}, {
|
|
416
|
+
key: "possibleLengths",
|
|
417
|
+
value: function() {
|
|
418
|
+
if (!this.metadata.v1)
|
|
419
|
+
return this.type[1] || this.metadata.possibleLengths();
|
|
420
|
+
}
|
|
421
|
+
}]);
|
|
422
|
+
})();
|
|
423
|
+
function c(n, t) {
|
|
424
|
+
switch (t) {
|
|
425
|
+
case "FIXED_LINE":
|
|
426
|
+
return n[0];
|
|
427
|
+
case "MOBILE":
|
|
428
|
+
return n[1];
|
|
429
|
+
case "TOLL_FREE":
|
|
430
|
+
return n[2];
|
|
431
|
+
case "PREMIUM_RATE":
|
|
432
|
+
return n[3];
|
|
433
|
+
case "PERSONAL_NUMBER":
|
|
434
|
+
return n[4];
|
|
435
|
+
case "VOICEMAIL":
|
|
436
|
+
return n[5];
|
|
437
|
+
case "UAN":
|
|
438
|
+
return n[6];
|
|
439
|
+
case "PAGER":
|
|
440
|
+
return n[7];
|
|
441
|
+
case "VOIP":
|
|
442
|
+
return n[8];
|
|
443
|
+
case "SHARED_COST":
|
|
444
|
+
return n[9];
|
|
445
|
+
}
|
|
446
|
+
}
|
|
447
|
+
function _(n) {
|
|
448
|
+
if (!n)
|
|
449
|
+
throw new Error("[libphonenumber-js] `metadata` argument not passed. Check your arguments.");
|
|
450
|
+
if (!l(n) || !l(n.countries))
|
|
451
|
+
throw new Error("[libphonenumber-js] `metadata` argument was passed but it's not a valid metadata. Must be an object having `.countries` child object property. Got ".concat(l(n) ? "an object of shape: { " + Object.keys(n).join(", ") + " }" : "a " + N(n) + ": " + n, "."));
|
|
452
|
+
}
|
|
453
|
+
var N = function(t) {
|
|
454
|
+
return a(t);
|
|
455
|
+
};
|
|
456
|
+
function R(n, t) {
|
|
457
|
+
if (t = new b(t), t.hasCountry(n))
|
|
458
|
+
return t.selectNumberingPlan(n).countryCallingCode();
|
|
459
|
+
throw new Error("Unknown country: ".concat(n));
|
|
460
|
+
}
|
|
461
|
+
function O(n, t) {
|
|
462
|
+
return t.countries.hasOwnProperty(n);
|
|
463
|
+
}
|
|
464
|
+
function m(n) {
|
|
465
|
+
var t = n.version;
|
|
466
|
+
typeof t == "number" ? (this.v1 = t === 1, this.v2 = t === 2, this.v3 = t === 3, this.v4 = t === 4) : t ? f(t, d) === -1 ? this.v2 = !0 : f(t, p) === -1 ? this.v3 = !0 : this.v4 = !0 : this.v1 = !0;
|
|
467
|
+
}
|
|
468
|
+
export {
|
|
469
|
+
b as default,
|
|
470
|
+
R as getCountryCallingCode,
|
|
471
|
+
O as isSupportedCountry,
|
|
472
|
+
_ as validateMetadata
|
|
473
|
+
};
|
|
@@ -0,0 +1,2 @@
|
|
|
1
|
+
"use strict";const b=require("./helpers/isObject.cjs.js");function y(r){"@babel/helpers - typeof";return y=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(t){return typeof t}:function(t){return t&&typeof Symbol=="function"&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},y(r)}function f(r,t){var e=Object.keys(r);if(Object.getOwnPropertySymbols){var n=Object.getOwnPropertySymbols(r);t&&(n=n.filter(function(o){return Object.getOwnPropertyDescriptor(r,o).enumerable})),e.push.apply(e,n)}return e}function m(r){for(var t=1;t<arguments.length;t++){var e=arguments[t]!=null?arguments[t]:{};t%2?f(Object(e),!0).forEach(function(n){g(r,n,e[n])}):Object.getOwnPropertyDescriptors?Object.defineProperties(r,Object.getOwnPropertyDescriptors(e)):f(Object(e)).forEach(function(n){Object.defineProperty(r,n,Object.getOwnPropertyDescriptor(e,n))})}return r}function g(r,t,e){return(t=v(t))in r?Object.defineProperty(r,t,{value:e,enumerable:!0,configurable:!0,writable:!0}):r[t]=e,r}function v(r){var t=d(r,"string");return y(t)=="symbol"?t:t+""}function d(r,t){if(y(r)!="object"||!r)return r;var e=r[Symbol.toPrimitive];if(e!==void 0){var n=e.call(r,t);if(y(n)!="object")return n;throw new TypeError("@@toPrimitive must return a primitive value.")}return(t==="string"?String:Number)(r)}function O(r,t){return _(r)||w(r,t)||h(r,t)||j()}function j(){throw new TypeError(`Invalid attempt to destructure non-iterable instance.
|
|
2
|
+
In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function h(r,t){if(r){if(typeof r=="string")return s(r,t);var e={}.toString.call(r).slice(8,-1);return e==="Object"&&r.constructor&&(e=r.constructor.name),e==="Map"||e==="Set"?Array.from(r):e==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(e)?s(r,t):void 0}}function s(r,t){(t==null||t>r.length)&&(t=r.length);for(var e=0,n=Array(t);e<t;e++)n[e]=r[e];return n}function w(r,t){var e=r==null?null:typeof Symbol<"u"&&r[Symbol.iterator]||r["@@iterator"];if(e!=null){var n,o,u,l,c=[],i=!0,a=!1;try{if(u=(e=e.call(r)).next,t!==0)for(;!(i=(n=u.call(e)).done)&&(c.push(n.value),c.length!==t);i=!0);}catch(p){a=!0,o=p}finally{try{if(!i&&e.return!=null&&(l=e.return(),Object(l)!==l))return}finally{if(a)throw o}}return c}}function _(r){if(Array.isArray(r))return r}function A(r){var t=Array.prototype.slice.call(r),e=O(t,4),n=e[0],o=e[1],u=e[2],l=e[3],c,i,a;if(typeof n=="string")c=n;else throw new TypeError("A text for parsing must be a string.");if(!o||typeof o=="string")l?(i=u,a=l):(i=void 0,a=u),o&&(i=m({defaultCountry:o},i));else if(b(o))u?(i=o,a=u):a=o;else throw new Error("Invalid second argument: ".concat(o));return{text:c,options:i,metadata:a}}module.exports=A;
|
|
@@ -0,0 +1,108 @@
|
|
|
1
|
+
import b from "./helpers/isObject.es.js";
|
|
2
|
+
function f(r) {
|
|
3
|
+
"@babel/helpers - typeof";
|
|
4
|
+
return f = typeof Symbol == "function" && typeof Symbol.iterator == "symbol" ? function(t) {
|
|
5
|
+
return typeof t;
|
|
6
|
+
} : function(t) {
|
|
7
|
+
return t && typeof Symbol == "function" && t.constructor === Symbol && t !== Symbol.prototype ? "symbol" : typeof t;
|
|
8
|
+
}, f(r);
|
|
9
|
+
}
|
|
10
|
+
function y(r, t) {
|
|
11
|
+
var e = Object.keys(r);
|
|
12
|
+
if (Object.getOwnPropertySymbols) {
|
|
13
|
+
var n = Object.getOwnPropertySymbols(r);
|
|
14
|
+
t && (n = n.filter(function(o) {
|
|
15
|
+
return Object.getOwnPropertyDescriptor(r, o).enumerable;
|
|
16
|
+
})), e.push.apply(e, n);
|
|
17
|
+
}
|
|
18
|
+
return e;
|
|
19
|
+
}
|
|
20
|
+
function m(r) {
|
|
21
|
+
for (var t = 1; t < arguments.length; t++) {
|
|
22
|
+
var e = arguments[t] != null ? arguments[t] : {};
|
|
23
|
+
t % 2 ? y(Object(e), !0).forEach(function(n) {
|
|
24
|
+
g(r, n, e[n]);
|
|
25
|
+
}) : Object.getOwnPropertyDescriptors ? Object.defineProperties(r, Object.getOwnPropertyDescriptors(e)) : y(Object(e)).forEach(function(n) {
|
|
26
|
+
Object.defineProperty(r, n, Object.getOwnPropertyDescriptor(e, n));
|
|
27
|
+
});
|
|
28
|
+
}
|
|
29
|
+
return r;
|
|
30
|
+
}
|
|
31
|
+
function g(r, t, e) {
|
|
32
|
+
return (t = v(t)) in r ? Object.defineProperty(r, t, { value: e, enumerable: !0, configurable: !0, writable: !0 }) : r[t] = e, r;
|
|
33
|
+
}
|
|
34
|
+
function v(r) {
|
|
35
|
+
var t = d(r, "string");
|
|
36
|
+
return f(t) == "symbol" ? t : t + "";
|
|
37
|
+
}
|
|
38
|
+
function d(r, t) {
|
|
39
|
+
if (f(r) != "object" || !r) return r;
|
|
40
|
+
var e = r[Symbol.toPrimitive];
|
|
41
|
+
if (e !== void 0) {
|
|
42
|
+
var n = e.call(r, t);
|
|
43
|
+
if (f(n) != "object") return n;
|
|
44
|
+
throw new TypeError("@@toPrimitive must return a primitive value.");
|
|
45
|
+
}
|
|
46
|
+
return (t === "string" ? String : Number)(r);
|
|
47
|
+
}
|
|
48
|
+
function O(r, t) {
|
|
49
|
+
return _(r) || w(r, t) || h(r, t) || j();
|
|
50
|
+
}
|
|
51
|
+
function j() {
|
|
52
|
+
throw new TypeError(`Invalid attempt to destructure non-iterable instance.
|
|
53
|
+
In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`);
|
|
54
|
+
}
|
|
55
|
+
function h(r, t) {
|
|
56
|
+
if (r) {
|
|
57
|
+
if (typeof r == "string") return s(r, t);
|
|
58
|
+
var e = {}.toString.call(r).slice(8, -1);
|
|
59
|
+
return e === "Object" && r.constructor && (e = r.constructor.name), e === "Map" || e === "Set" ? Array.from(r) : e === "Arguments" || /^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(e) ? s(r, t) : void 0;
|
|
60
|
+
}
|
|
61
|
+
}
|
|
62
|
+
function s(r, t) {
|
|
63
|
+
(t == null || t > r.length) && (t = r.length);
|
|
64
|
+
for (var e = 0, n = Array(t); e < t; e++) n[e] = r[e];
|
|
65
|
+
return n;
|
|
66
|
+
}
|
|
67
|
+
function w(r, t) {
|
|
68
|
+
var e = r == null ? null : typeof Symbol < "u" && r[Symbol.iterator] || r["@@iterator"];
|
|
69
|
+
if (e != null) {
|
|
70
|
+
var n, o, u, l, c = [], i = !0, a = !1;
|
|
71
|
+
try {
|
|
72
|
+
if (u = (e = e.call(r)).next, t !== 0) for (; !(i = (n = u.call(e)).done) && (c.push(n.value), c.length !== t); i = !0) ;
|
|
73
|
+
} catch (p) {
|
|
74
|
+
a = !0, o = p;
|
|
75
|
+
} finally {
|
|
76
|
+
try {
|
|
77
|
+
if (!i && e.return != null && (l = e.return(), Object(l) !== l)) return;
|
|
78
|
+
} finally {
|
|
79
|
+
if (a) throw o;
|
|
80
|
+
}
|
|
81
|
+
}
|
|
82
|
+
return c;
|
|
83
|
+
}
|
|
84
|
+
}
|
|
85
|
+
function _(r) {
|
|
86
|
+
if (Array.isArray(r)) return r;
|
|
87
|
+
}
|
|
88
|
+
function S(r) {
|
|
89
|
+
var t = Array.prototype.slice.call(r), e = O(t, 4), n = e[0], o = e[1], u = e[2], l = e[3], c, i, a;
|
|
90
|
+
if (typeof n == "string")
|
|
91
|
+
c = n;
|
|
92
|
+
else throw new TypeError("A text for parsing must be a string.");
|
|
93
|
+
if (!o || typeof o == "string")
|
|
94
|
+
l ? (i = u, a = l) : (i = void 0, a = u), o && (i = m({
|
|
95
|
+
defaultCountry: o
|
|
96
|
+
}, i));
|
|
97
|
+
else if (b(o))
|
|
98
|
+
u ? (i = o, a = u) : a = o;
|
|
99
|
+
else throw new Error("Invalid second argument: ".concat(o));
|
|
100
|
+
return {
|
|
101
|
+
text: c,
|
|
102
|
+
options: i,
|
|
103
|
+
metadata: a
|
|
104
|
+
};
|
|
105
|
+
}
|
|
106
|
+
export {
|
|
107
|
+
S as default
|
|
108
|
+
};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
"use strict";const _=require("./constants.cjs.js"),C=require("./ParseError.cjs.js"),h=require("./metadata.cjs.js"),y=require("./helpers/isViablePhoneNumber.cjs.js"),P=require("./helpers/extension/extractExtension.cjs.js"),g=require("./parseIncompletePhoneNumber.cjs.js"),T=require("./isPossible.cjs.js"),m=require("./PhoneNumber.cjs.js"),O=require("./helpers/matchesEntirely.cjs.js"),v=require("./helpers/extractCountryCallingCode.cjs.js"),S=require("./helpers/extractNationalNumber.cjs.js"),w=require("./helpers/getCountryByCallingCode.cjs.js"),x=require("./helpers/extractFormattedPhoneNumberFromPossibleRfc3966NumberUri.cjs.js");var R=250,E=new RegExp("["+_.PLUS_CHARS+_.VALID_DIGITS+"]"),I=new RegExp("[^"+_.VALID_DIGITS+"#]+$");function q(t,r,n){if(r=r||{},n=new h.default(n),r.defaultCountry&&!n.hasCountry(r.defaultCountry))throw r.v2?new C("INVALID_COUNTRY"):new Error("Unknown country: ".concat(r.defaultCountry));var e=L(t,r.v2,r.extract),c=e.number,a=e.ext,o=e.error;if(!c){if(r.v2)throw o==="TOO_SHORT"?new C("TOO_SHORT"):new C("NOT_A_NUMBER");return{}}var l=U(c,r.defaultCountry,r.defaultCallingCode,n),u=l.country,i=l.nationalNumber,f=l.countryCallingCode,b=l.countryCallingCodeSource,N=l.carrierCode;if(!n.hasSelectedNumberingPlan()){if(r.v2)throw new C("INVALID_COUNTRY");return{}}if(!i||i.length<_.MIN_LENGTH_FOR_NSN){if(r.v2)throw new C("TOO_SHORT");return{}}if(i.length>_.MAX_LENGTH_FOR_NSN){if(r.v2)throw new C("TOO_LONG");return{}}if(r.v2){var s=new m(f,i,n.metadata);return u&&(s.country=u),N&&(s.carrierCode=N),a&&(s.ext=a),s.__countryCallingCodeSource=b,s}var d=(r.extended?n.hasSelectedNumberingPlan():u)?O(i,n.nationalNumberPattern()):!1;return r.extended?{country:u,countryCallingCode:f,carrierCode:N,valid:d,possible:d?!0:!!(r.extended===!0&&n.possibleLengths()&&T.isPossibleNumber(i,u,n)),phone:i,ext:a}:d?H(u,i,a):{}}function A(t,r,n){if(t){if(t.length>R){if(n)throw new C("TOO_LONG");return}if(r===!1)return t;var e=t.search(E);if(!(e<0))return t.slice(e).replace(I,"")}}function L(t,r,n){var e=x(t,{extractFormattedPhoneNumber:function(o){return A(o,n,r)}});if(!e)return{};if(!y.default(e))return y.isViablePhoneNumberStart(e)?{error:"TOO_SHORT"}:{};var c=P(e);return c.ext?c:{number:e}}function H(t,r,n){var e={country:t,phone:r};return n&&(e.ext=n),e}function U(t,r,n,e){var c=v(g.default(t),void 0,r,n,e.metadata),a=c.countryCallingCodeSource,o=c.countryCallingCode,l=c.number,u;if(o)e.selectNumberingPlan(o);else if(l&&(r||n))e.selectNumberingPlan(r,n),r&&(u=r),o=n||h.getCountryCallingCode(r,e.metadata);else return{};if(!l)return{countryCallingCodeSource:a,countryCallingCode:o};var i=S(g.default(l),u,e),f=i.nationalNumber,b=i.carrierCode,N=w(o,{nationalNumber:f,metadata:e});return N&&(u=N,N==="001"||e.selectNumberingPlan(u)),{country:u,countryCallingCode:o,countryCallingCodeSource:a,nationalNumber:f,carrierCode:b}}module.exports=q;
|