@smooai/chat-widget 0.11.0 → 0.13.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/README.md +1 -0
- package/dist/chat-widget.global.js +473 -21
- package/dist/chat-widget.global.js.map +1 -1
- package/dist/index.d.ts +333 -236
- package/dist/index.d.ts.map +1 -1
- package/dist/index.js +454 -18
- package/dist/index.js.map +1 -1
- package/package.json +2 -2
- package/src/config.ts +11 -0
- package/src/conversation.ts +205 -3
- package/src/element.ts +315 -18
- package/src/index.ts +2 -0
- package/src/styles.ts +53 -2
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"chat-widget.global.js","names":["metadata","_typeof","_defineProperties","_toPropertyKey","_createClass","_toPrimitive","_classCallCheck","_typeof","_classCallCheck","_defineProperties","_toPropertyKey","_createClass","_toPrimitive","compare","_createForOfIteratorHelperLoose","_unsupportedIterableToArray","_arrayLikeToArray","_createForOfIteratorHelperLoose","_unsupportedIterableToArray","_arrayLikeToArray","_createForOfIteratorHelperLoose","_unsupportedIterableToArray","_arrayLikeToArray","_createForOfIteratorHelperLoose","_unsupportedIterableToArray","_arrayLikeToArray","USE_NON_GEOGRAPHIC_COUNTRY_CODE","_createForOfIteratorHelperLoose","_unsupportedIterableToArray","_arrayLikeToArray","USE_NON_GEOGRAPHIC_COUNTRY_CODE","formatNationalNumber","_typeof","ownKeys","_objectSpread","_defineProperty","_toPropertyKey","_classCallCheck","_defineProperties","_createClass","_toPrimitive","isPossibleNumber","USE_NON_GEOGRAPHIC_COUNTRY_CODE","parsePhoneNumber","_typeof","ownKeys","_objectSpread","_defineProperty","_toPropertyKey","_toPrimitive","parsePhoneNumberWithError","_typeof","ownKeys","_objectSpread","_defineProperty","_toPropertyKey","_toPrimitive","_slicedToArray","_arrayWithHoles","_iterableToArrayLimit","_unsupportedIterableToArray","_nonIterableRest","_arrayLikeToArray","parsePhoneNumberWithError","parsePhoneNumberWithError_","_typeof","ownKeys","_objectSpread","_defineProperty","_toPropertyKey","_toPrimitive","parsePhoneNumberWithError","_typeof","_defineProperty","_toPropertyKey","_toPrimitive","isValidPhoneNumber","_typeof","_classCallCheck","_defineProperties","_toPropertyKey","_createClass","_toPrimitive","_createForOfIteratorHelperLoose","_unsupportedIterableToArray","_arrayLikeToArray","_typeof","_classCallCheck","_defineProperties","_toPropertyKey","_createClass","_toPrimitive","_createForOfIteratorHelperLoose","_unsupportedIterableToArray","_arrayLikeToArray","_typeof","_classCallCheck","_defineProperties","_toPropertyKey","_createClass","_toPrimitive","_typeof","_unsupportedIterableToArray","_arrayLikeToArray","_classCallCheck","_defineProperties","_toPropertyKey","_createClass","_toPrimitive","_typeof","_slicedToArray","_arrayWithHoles","_iterableToArrayLimit","_unsupportedIterableToArray","_nonIterableRest","_arrayLikeToArray","_classCallCheck","_defineProperties","_toPropertyKey","_createClass","_toPrimitive","extractCountryCallingCode","_extractCountryCallingCode","_typeof","AsYouType","_parsePhoneNumberWithError","_isValidPhoneNumber","_AsYouType","metadata","parsePhoneNumber"],"sources":["../node_modules/.pnpm/libphonenumber-js@1.13.7/node_modules/libphonenumber-js/metadata.min.json.js","../node_modules/.pnpm/libphonenumber-js@1.13.7/node_modules/libphonenumber-js/min/exports/withMetadataArgument.js","../node_modules/.pnpm/libphonenumber-js@1.13.7/node_modules/libphonenumber-js/es6/constants.js","../node_modules/.pnpm/libphonenumber-js@1.13.7/node_modules/libphonenumber-js/es6/ParseError.js","../node_modules/.pnpm/libphonenumber-js@1.13.7/node_modules/libphonenumber-js/es6/tools/semver-compare.js","../node_modules/.pnpm/libphonenumber-js@1.13.7/node_modules/libphonenumber-js/es6/helpers/isObject.js","../node_modules/.pnpm/libphonenumber-js@1.13.7/node_modules/libphonenumber-js/es6/helpers/isCallingCode.js","../node_modules/.pnpm/libphonenumber-js@1.13.7/node_modules/libphonenumber-js/es6/metadata.js","../node_modules/.pnpm/libphonenumber-js@1.13.7/node_modules/libphonenumber-js/es6/helpers/extension/createExtensionPattern.js","../node_modules/.pnpm/libphonenumber-js@1.13.7/node_modules/libphonenumber-js/es6/helpers/isViablePhoneNumber.js","../node_modules/.pnpm/libphonenumber-js@1.13.7/node_modules/libphonenumber-js/es6/helpers/extension/extractExtension.js","../node_modules/.pnpm/libphonenumber-js@1.13.7/node_modules/libphonenumber-js/es6/helpers/parseDigits.js","../node_modules/.pnpm/libphonenumber-js@1.13.7/node_modules/libphonenumber-js/es6/parseIncompletePhoneNumber.js","../node_modules/.pnpm/libphonenumber-js@1.13.7/node_modules/libphonenumber-js/es6/helpers/mergeArrays.js","../node_modules/.pnpm/libphonenumber-js@1.13.7/node_modules/libphonenumber-js/es6/helpers/checkNumberLength.js","../node_modules/.pnpm/libphonenumber-js@1.13.7/node_modules/libphonenumber-js/es6/isPossible.js","../node_modules/.pnpm/libphonenumber-js@1.13.7/node_modules/libphonenumber-js/es6/helpers/matchesEntirely.js","../node_modules/.pnpm/libphonenumber-js@1.13.7/node_modules/libphonenumber-js/es6/helpers/getNumberType.js","../node_modules/.pnpm/libphonenumber-js@1.13.7/node_modules/libphonenumber-js/es6/isValid.js","../node_modules/.pnpm/libphonenumber-js@1.13.7/node_modules/libphonenumber-js/es6/helpers/isCountryCode.js","../node_modules/.pnpm/libphonenumber-js@1.13.7/node_modules/libphonenumber-js/es6/helpers/getCountryAndCallingCodeFromOneOfThem.js","../node_modules/.pnpm/libphonenumber-js@1.13.7/node_modules/libphonenumber-js/es6/helpers/getPossibleCountriesForNumber.js","../node_modules/.pnpm/libphonenumber-js@1.13.7/node_modules/libphonenumber-js/es6/helpers/stripIddPrefix.js","../node_modules/.pnpm/libphonenumber-js@1.13.7/node_modules/libphonenumber-js/es6/helpers/extractNationalNumberFromPossiblyIncompleteNumber.js","../node_modules/.pnpm/libphonenumber-js@1.13.7/node_modules/libphonenumber-js/es6/helpers/getCountryByNationalNumber.js","../node_modules/.pnpm/libphonenumber-js@1.13.7/node_modules/libphonenumber-js/es6/helpers/getCountryByCallingCode.js","../node_modules/.pnpm/libphonenumber-js@1.13.7/node_modules/libphonenumber-js/es6/helpers/extractNationalNumber.js","../node_modules/.pnpm/libphonenumber-js@1.13.7/node_modules/libphonenumber-js/es6/helpers/extractCountryCallingCodeFromInternationalNumberWithoutPlusSign.js","../node_modules/.pnpm/libphonenumber-js@1.13.7/node_modules/libphonenumber-js/es6/helpers/extractCountryCallingCode.js","../node_modules/.pnpm/libphonenumber-js@1.13.7/node_modules/libphonenumber-js/es6/helpers/applyInternationalSeparatorStyle.js","../node_modules/.pnpm/libphonenumber-js@1.13.7/node_modules/libphonenumber-js/es6/helpers/formatNationalNumberUsingFormat.js","../node_modules/.pnpm/libphonenumber-js@1.13.7/node_modules/libphonenumber-js/es6/helpers/getIddPrefix.js","../node_modules/.pnpm/libphonenumber-js@1.13.7/node_modules/libphonenumber-js/es6/helpers/RFC3966.js","../node_modules/.pnpm/libphonenumber-js@1.13.7/node_modules/libphonenumber-js/es6/format.js","../node_modules/.pnpm/libphonenumber-js@1.13.7/node_modules/libphonenumber-js/es6/PhoneNumber.js","../node_modules/.pnpm/libphonenumber-js@1.13.7/node_modules/libphonenumber-js/es6/helpers/extractPhoneContext.js","../node_modules/.pnpm/libphonenumber-js@1.13.7/node_modules/libphonenumber-js/es6/helpers/extractFormattedPhoneNumberFromPossibleRfc3966NumberUri.js","../node_modules/.pnpm/libphonenumber-js@1.13.7/node_modules/libphonenumber-js/es6/parse.js","../node_modules/.pnpm/libphonenumber-js@1.13.7/node_modules/libphonenumber-js/es6/parsePhoneNumberWithError_.js","../node_modules/.pnpm/libphonenumber-js@1.13.7/node_modules/libphonenumber-js/es6/normalizeArguments.js","../node_modules/.pnpm/libphonenumber-js@1.13.7/node_modules/libphonenumber-js/es6/parsePhoneNumberWithError.js","../node_modules/.pnpm/libphonenumber-js@1.13.7/node_modules/libphonenumber-js/es6/parsePhoneNumber_.js","../node_modules/.pnpm/libphonenumber-js@1.13.7/node_modules/libphonenumber-js/es6/isValidPhoneNumber.js","../node_modules/.pnpm/libphonenumber-js@1.13.7/node_modules/libphonenumber-js/es6/AsYouTypeState.js","../node_modules/.pnpm/libphonenumber-js@1.13.7/node_modules/libphonenumber-js/es6/AsYouTypeFormatter.util.js","../node_modules/.pnpm/libphonenumber-js@1.13.7/node_modules/libphonenumber-js/es6/AsYouTypeFormatter.complete.js","../node_modules/.pnpm/libphonenumber-js@1.13.7/node_modules/libphonenumber-js/es6/AsYouTypeFormatter.PatternParser.js","../node_modules/.pnpm/libphonenumber-js@1.13.7/node_modules/libphonenumber-js/es6/AsYouTypeFormatter.PatternMatcher.js","../node_modules/.pnpm/libphonenumber-js@1.13.7/node_modules/libphonenumber-js/es6/AsYouTypeFormatter.js","../node_modules/.pnpm/libphonenumber-js@1.13.7/node_modules/libphonenumber-js/es6/AsYouTypeParser.js","../node_modules/.pnpm/libphonenumber-js@1.13.7/node_modules/libphonenumber-js/es6/AsYouType.js","../node_modules/.pnpm/libphonenumber-js@1.13.7/node_modules/libphonenumber-js/min/exports/parsePhoneNumberWithError.js","../node_modules/.pnpm/libphonenumber-js@1.13.7/node_modules/libphonenumber-js/min/exports/isValidPhoneNumber.js","../node_modules/.pnpm/libphonenumber-js@1.13.7/node_modules/libphonenumber-js/min/exports/AsYouType.js","../src/markdown.ts","../src/config.ts","../node_modules/.pnpm/@smooai+smooth-operator@1.8.0/node_modules/@smooai/smooth-operator/dist/transport.js","../node_modules/.pnpm/@smooai+smooth-operator@1.8.0/node_modules/@smooai/smooth-operator/dist/types.js","../node_modules/.pnpm/@smooai+smooth-operator@1.8.0/node_modules/@smooai/smooth-operator/dist/client.js","../src/fingerprint.ts","../node_modules/.pnpm/zustand@5.0.14/node_modules/zustand/esm/vanilla.mjs","../node_modules/.pnpm/zustand@5.0.14/node_modules/zustand/esm/middleware.mjs","../src/persistence.ts","../src/conversation.ts","../src/logo.ts","../src/styles.ts","../src/element.ts","../src/standalone.ts"],"sourcesContent":["// This file is a workaround for a bug in web browsers' \"native\"\n// ES6 importing system which is uncapable of importing \"*.json\" files.\n// https://github.com/catamphetamine/libphonenumber-js/issues/239\nexport default {\"version\":4,\"country_calling_codes\":{\"1\":[\"US\",\"AG\",\"AI\",\"AS\",\"BB\",\"BM\",\"BS\",\"CA\",\"DM\",\"DO\",\"GD\",\"GU\",\"JM\",\"KN\",\"KY\",\"LC\",\"MP\",\"MS\",\"PR\",\"SX\",\"TC\",\"TT\",\"VC\",\"VG\",\"VI\"],\"7\":[\"RU\",\"KZ\"],\"20\":[\"EG\"],\"27\":[\"ZA\"],\"30\":[\"GR\"],\"31\":[\"NL\"],\"32\":[\"BE\"],\"33\":[\"FR\"],\"34\":[\"ES\"],\"36\":[\"HU\"],\"39\":[\"IT\",\"VA\"],\"40\":[\"RO\"],\"41\":[\"CH\"],\"43\":[\"AT\"],\"44\":[\"GB\",\"GG\",\"IM\",\"JE\"],\"45\":[\"DK\"],\"46\":[\"SE\"],\"47\":[\"NO\",\"SJ\"],\"48\":[\"PL\"],\"49\":[\"DE\"],\"51\":[\"PE\"],\"52\":[\"MX\"],\"53\":[\"CU\"],\"54\":[\"AR\"],\"55\":[\"BR\"],\"56\":[\"CL\"],\"57\":[\"CO\"],\"58\":[\"VE\"],\"60\":[\"MY\"],\"61\":[\"AU\",\"CC\",\"CX\"],\"62\":[\"ID\"],\"63\":[\"PH\"],\"64\":[\"NZ\"],\"65\":[\"SG\"],\"66\":[\"TH\"],\"81\":[\"JP\"],\"82\":[\"KR\"],\"84\":[\"VN\"],\"86\":[\"CN\"],\"90\":[\"TR\"],\"91\":[\"IN\"],\"92\":[\"PK\"],\"93\":[\"AF\"],\"94\":[\"LK\"],\"95\":[\"MM\"],\"98\":[\"IR\"],\"211\":[\"SS\"],\"212\":[\"MA\",\"EH\"],\"213\":[\"DZ\"],\"216\":[\"TN\"],\"218\":[\"LY\"],\"220\":[\"GM\"],\"221\":[\"SN\"],\"222\":[\"MR\"],\"223\":[\"ML\"],\"224\":[\"GN\"],\"225\":[\"CI\"],\"226\":[\"BF\"],\"227\":[\"NE\"],\"228\":[\"TG\"],\"229\":[\"BJ\"],\"230\":[\"MU\"],\"231\":[\"LR\"],\"232\":[\"SL\"],\"233\":[\"GH\"],\"234\":[\"NG\"],\"235\":[\"TD\"],\"236\":[\"CF\"],\"237\":[\"CM\"],\"238\":[\"CV\"],\"239\":[\"ST\"],\"240\":[\"GQ\"],\"241\":[\"GA\"],\"242\":[\"CG\"],\"243\":[\"CD\"],\"244\":[\"AO\"],\"245\":[\"GW\"],\"246\":[\"IO\"],\"247\":[\"AC\"],\"248\":[\"SC\"],\"249\":[\"SD\"],\"250\":[\"RW\"],\"251\":[\"ET\"],\"252\":[\"SO\"],\"253\":[\"DJ\"],\"254\":[\"KE\"],\"255\":[\"TZ\"],\"256\":[\"UG\"],\"257\":[\"BI\"],\"258\":[\"MZ\"],\"260\":[\"ZM\"],\"261\":[\"MG\"],\"262\":[\"RE\",\"YT\"],\"263\":[\"ZW\"],\"264\":[\"NA\"],\"265\":[\"MW\"],\"266\":[\"LS\"],\"267\":[\"BW\"],\"268\":[\"SZ\"],\"269\":[\"KM\"],\"290\":[\"SH\",\"TA\"],\"291\":[\"ER\"],\"297\":[\"AW\"],\"298\":[\"FO\"],\"299\":[\"GL\"],\"350\":[\"GI\"],\"351\":[\"PT\"],\"352\":[\"LU\"],\"353\":[\"IE\"],\"354\":[\"IS\"],\"355\":[\"AL\"],\"356\":[\"MT\"],\"357\":[\"CY\"],\"358\":[\"FI\",\"AX\"],\"359\":[\"BG\"],\"370\":[\"LT\"],\"371\":[\"LV\"],\"372\":[\"EE\"],\"373\":[\"MD\"],\"374\":[\"AM\"],\"375\":[\"BY\"],\"376\":[\"AD\"],\"377\":[\"MC\"],\"378\":[\"SM\"],\"380\":[\"UA\"],\"381\":[\"RS\"],\"382\":[\"ME\"],\"383\":[\"XK\"],\"385\":[\"HR\"],\"386\":[\"SI\"],\"387\":[\"BA\"],\"389\":[\"MK\"],\"420\":[\"CZ\"],\"421\":[\"SK\"],\"423\":[\"LI\"],\"500\":[\"FK\"],\"501\":[\"BZ\"],\"502\":[\"GT\"],\"503\":[\"SV\"],\"504\":[\"HN\"],\"505\":[\"NI\"],\"506\":[\"CR\"],\"507\":[\"PA\"],\"508\":[\"PM\"],\"509\":[\"HT\"],\"590\":[\"GP\",\"BL\",\"MF\"],\"591\":[\"BO\"],\"592\":[\"GY\"],\"593\":[\"EC\"],\"594\":[\"GF\"],\"595\":[\"PY\"],\"596\":[\"MQ\"],\"597\":[\"SR\"],\"598\":[\"UY\"],\"599\":[\"CW\",\"BQ\"],\"670\":[\"TL\"],\"672\":[\"NF\"],\"673\":[\"BN\"],\"674\":[\"NR\"],\"675\":[\"PG\"],\"676\":[\"TO\"],\"677\":[\"SB\"],\"678\":[\"VU\"],\"679\":[\"FJ\"],\"680\":[\"PW\"],\"681\":[\"WF\"],\"682\":[\"CK\"],\"683\":[\"NU\"],\"685\":[\"WS\"],\"686\":[\"KI\"],\"687\":[\"NC\"],\"688\":[\"TV\"],\"689\":[\"PF\"],\"690\":[\"TK\"],\"691\":[\"FM\"],\"692\":[\"MH\"],\"850\":[\"KP\"],\"852\":[\"HK\"],\"853\":[\"MO\"],\"855\":[\"KH\"],\"856\":[\"LA\"],\"880\":[\"BD\"],\"886\":[\"TW\"],\"960\":[\"MV\"],\"961\":[\"LB\"],\"962\":[\"JO\"],\"963\":[\"SY\"],\"964\":[\"IQ\"],\"965\":[\"KW\"],\"966\":[\"SA\"],\"967\":[\"YE\"],\"968\":[\"OM\"],\"970\":[\"PS\"],\"971\":[\"AE\"],\"972\":[\"IL\"],\"973\":[\"BH\"],\"974\":[\"QA\"],\"975\":[\"BT\"],\"976\":[\"MN\"],\"977\":[\"NP\"],\"992\":[\"TJ\"],\"993\":[\"TM\"],\"994\":[\"AZ\"],\"995\":[\"GE\"],\"996\":[\"KG\"],\"998\":[\"UZ\"]},\"countries\":{\"AC\":[\"247\",\"00\",\"(?:[01589]\\\\d|[46])\\\\d{4}\",[5,6]],\"AD\":[\"376\",\"00\",\"(?:1|6\\\\d)\\\\d{7}|[135-9]\\\\d{5}\",[6,8,9],[[\"(\\\\d{3})(\\\\d{3})\",\"$1 $2\",[\"[135-9]\"]],[\"(\\\\d{4})(\\\\d{4})\",\"$1 $2\",[\"1\"]],[\"(\\\\d{3})(\\\\d{3})(\\\\d{3})\",\"$1 $2 $3\",[\"6\"]]]],\"AE\":[\"971\",\"00\",\"(?:[4-7]\\\\d|9[0-689])\\\\d{7}|800\\\\d{2,9}|[2-4679]\\\\d{7}\",[5,6,7,8,9,10,11,12],[[\"(\\\\d{3})(\\\\d{2,9})\",\"$1 $2\",[\"60|8\"]],[\"(\\\\d)(\\\\d{3})(\\\\d{4})\",\"$1 $2 $3\",[\"[236]|[479][2-8]\"],\"0$1\"],[\"(\\\\d{3})(\\\\d)(\\\\d{5})\",\"$1 $2 $3\",[\"[479]\"]],[\"(\\\\d{2})(\\\\d{3})(\\\\d{4})\",\"$1 $2 $3\",[\"5\"],\"0$1\"]],\"0\"],\"AF\":[\"93\",\"00\",\"[2-7]\\\\d{8}\",[9],[[\"(\\\\d{2})(\\\\d{3})(\\\\d{4})\",\"$1 $2 $3\",[\"[2-7]\"],\"0$1\"]],\"0\"],\"AG\":[\"1\",\"011\",\"(?:268|[58]\\\\d\\\\d|900)\\\\d{7}\",[10],0,\"1\",0,\"([457]\\\\d{6})$|1\",\"268$1\",0,\"268\"],\"AI\":[\"1\",\"011\",\"(?:264|[58]\\\\d\\\\d|900)\\\\d{7}\",[10],0,\"1\",0,\"([2457]\\\\d{6})$|1\",\"264$1\",0,\"264\"],\"AL\":[\"355\",\"00\",\"(?:700\\\\d\\\\d|900)\\\\d{3}|8\\\\d{5,7}|(?:[2-5]|6\\\\d)\\\\d{7}\",[6,7,8,9],[[\"(\\\\d{3})(\\\\d{3,4})\",\"$1 $2\",[\"80|9\"],\"0$1\"],[\"(\\\\d)(\\\\d{3})(\\\\d{4})\",\"$1 $2 $3\",[\"4[2-6]\"],\"0$1\"],[\"(\\\\d{2})(\\\\d{3})(\\\\d{3})\",\"$1 $2 $3\",[\"[2358][2-5]|4\"],\"0$1\"],[\"(\\\\d{3})(\\\\d{5})\",\"$1 $2\",[\"[23578]\"],\"0$1\"],[\"(\\\\d{2})(\\\\d{3})(\\\\d{4})\",\"$1 $2 $3\",[\"6\"],\"0$1\"]],\"0\"],\"AM\":[\"374\",\"00\",\"(?:[1-489]\\\\d|55|60|77)\\\\d{6}\",[8],[[\"(\\\\d{3})(\\\\d{2})(\\\\d{3})\",\"$1 $2 $3\",[\"[89]0\"],\"0 $1\"],[\"(\\\\d{3})(\\\\d{5})\",\"$1 $2\",[\"2|3[12]\"],\"(0$1)\"],[\"(\\\\d{2})(\\\\d{6})\",\"$1 $2\",[\"1|47\"],\"(0$1)\"],[\"(\\\\d{2})(\\\\d{6})\",\"$1 $2\",[\"[3-9]\"],\"0$1\"]],\"0\"],\"AO\":[\"244\",\"00\",\"[29]\\\\d{8}\",[9],[[\"(\\\\d{3})(\\\\d{3})(\\\\d{3})\",\"$1 $2 $3\",[\"[29]\"]]]],\"AR\":[\"54\",\"00\",\"(?:11|[89]\\\\d\\\\d)\\\\d{8}|[2368]\\\\d{9}\",[10,11],[[\"(\\\\d{4})(\\\\d{2})(\\\\d{4})\",\"$1 $2-$3\",[\"2(?:2[024-9]|3[0-59]|47|6[245]|9[02-8])|3(?:3[28]|4[03-9]|5[2-46-8]|7[1-578]|8[2-9])\",\"2(?:[23]02|6(?:[25]|4[6-8])|9(?:[02356]|4[02568]|72|8[23]))|3(?:3[28]|4(?:[04679]|3[5-8]|5[4-68]|8[2379])|5(?:[2467]|3[237]|8[2-5])|7[1-578]|8(?:[2469]|3[2578]|5[4-8]|7[36-8]|8[5-8]))|2(?:2[24-9]|3[1-59]|47)\",\"2(?:[23]02|6(?:[25]|4(?:64|[78]))|9(?:[02356]|4(?:[0268]|5[2-6])|72|8[23]))|3(?:3[28]|4(?:[04679]|3[78]|5(?:4[46]|8)|8[2379])|5(?:[2467]|3[237]|8[23])|7[1-578]|8(?:[2469]|3[278]|5[56][46]|86[3-6]))|2(?:2[24-9]|3[1-59]|47)|38(?:[58][78]|7[378])|3(?:4[35][56]|58[45]|8(?:[38]5|54|76))[4-6]\",\"2(?:[23]02|6(?:[25]|4(?:64|[78]))|9(?:[02356]|4(?:[0268]|5[2-6])|72|8[23]))|3(?:3[28]|4(?:[04679]|3(?:5(?:4[0-25689]|[56])|[78])|58|8[2379])|5(?:[2467]|3[237]|8(?:[23]|4(?:[45]|60)|5(?:4[0-39]|5|64)))|7[1-578]|8(?:[2469]|3[278]|54(?:4|5[13-7]|6[89])|86[3-6]))|2(?:2[24-9]|3[1-59]|47)|38(?:[58][78]|7[378])|3(?:454|85[56])[46]|3(?:4(?:36|5[56])|8(?:[38]5|76))[4-6]\"],\"0$1\",1],[\"(\\\\d{2})(\\\\d{4})(\\\\d{4})\",\"$1 $2-$3\",[\"1\"],\"0$1\",1],[\"(\\\\d{3})(\\\\d{3})(\\\\d{4})\",\"$1-$2-$3\",[\"[68]\"],\"0$1\"],[\"(\\\\d{3})(\\\\d{3})(\\\\d{4})\",\"$1 $2-$3\",[\"[23]\"],\"0$1\",1],[\"(\\\\d)(\\\\d{4})(\\\\d{2})(\\\\d{4})\",\"$2 15-$3-$4\",[\"9(?:2[2-469]|3[3-578])\",\"9(?:2(?:2[024-9]|3[0-59]|47|6[245]|9[02-8])|3(?:3[28]|4[03-9]|5[2-46-8]|7[1-578]|8[2-9]))\",\"9(?:2(?:[23]02|6(?:[25]|4[6-8])|9(?:[02356]|4[02568]|72|8[23]))|3(?:3[28]|4(?:[04679]|3[5-8]|5[4-68]|8[2379])|5(?:[2467]|3[237]|8[2-5])|7[1-578]|8(?:[2469]|3[2578]|5[4-8]|7[36-8]|8[5-8])))|92(?:2[24-9]|3[1-59]|47)\",\"9(?:2(?:[23]02|6(?:[25]|4(?:64|[78]))|9(?:[02356]|4(?:[0268]|5[2-6])|72|8[23]))|3(?:3[28]|4(?:[04679]|3[78]|5(?:4[46]|8)|8[2379])|5(?:[2467]|3[237]|8[23])|7[1-578]|8(?:[2469]|3[278]|5(?:[56][46]|[78])|7[378]|8(?:6[3-6]|[78]))))|92(?:2[24-9]|3[1-59]|47)|93(?:4[35][56]|58[45]|8(?:[38]5|54|76))[4-6]\",\"9(?:2(?:[23]02|6(?:[25]|4(?:64|[78]))|9(?:[02356]|4(?:[0268]|5[2-6])|72|8[23]))|3(?:3[28]|4(?:[04679]|3(?:5(?:4[0-25689]|[56])|[78])|5(?:4[46]|8)|8[2379])|5(?:[2467]|3[237]|8(?:[23]|4(?:[45]|60)|5(?:4[0-39]|5|64)))|7[1-578]|8(?:[2469]|3[278]|5(?:4(?:4|5[13-7]|6[89])|[56][46]|[78])|7[378]|8(?:6[3-6]|[78]))))|92(?:2[24-9]|3[1-59]|47)|93(?:4(?:36|5[56])|8(?:[38]5|76))[4-6]\"],\"0$1\",0,\"$1 $2 $3-$4\"],[\"(\\\\d)(\\\\d{2})(\\\\d{4})(\\\\d{4})\",\"$2 15-$3-$4\",[\"91\"],\"0$1\",0,\"$1 $2 $3-$4\"],[\"(\\\\d{3})(\\\\d{3})(\\\\d{5})\",\"$1-$2-$3\",[\"8\"],\"0$1\"],[\"(\\\\d)(\\\\d{3})(\\\\d{3})(\\\\d{4})\",\"$2 15-$3-$4\",[\"9\"],\"0$1\",0,\"$1 $2 $3-$4\"]],\"0\",0,\"0?(?:(11|2(?:2(?:02?|[13]|2[13-79]|4[1-6]|5[2457]|6[124-8]|7[1-4]|8[13-6]|9[1267])|3(?:02?|1[467]|2[03-6]|3[13-8]|[49][2-6]|5[2-8]|[67])|4(?:7[3-578]|9)|6(?:[0136]|2[24-6]|4[6-8]?|5[15-8])|80|9(?:0[1-3]|[19]|2\\\\d|3[1-6]|4[02568]?|5[2-4]|6[2-46]|72?|8[23]?))|3(?:3(?:2[79]|6|8[2578])|4(?:0[0-24-9]|[12]|3[5-8]?|4[24-7]|5[4-68]?|6[02-9]|7[126]|8[2379]?|9[1-36-8])|5(?:1|2[1245]|3[237]?|4[1-46-9]|6[2-4]|7[1-6]|8[2-5]?)|6[24]|7(?:[069]|1[1568]|2[15]|3[145]|4[13]|5[14-8]|7[2-57]|8[126])|8(?:[01]|2[15-7]|3[2578]?|4[13-6]|5[4-8]?|6[1-357-9]|7[36-8]?|8[5-8]?|9[124])))15)?\",\"9$1\"],\"AS\":[\"1\",\"011\",\"(?:[58]\\\\d\\\\d|684|900)\\\\d{7}\",[10],0,\"1\",0,\"([267]\\\\d{6})$|1\",\"684$1\",0,\"684\"],\"AT\":[\"43\",\"00\",\"1\\\\d{3,12}|2\\\\d{6,12}|43(?:(?:0\\\\d|5[02-9])\\\\d{3,9}|2\\\\d{4,5}|[3467]\\\\d{4}|8\\\\d{4,6}|9\\\\d{4,7})|5\\\\d{4,12}|8\\\\d{7,12}|9\\\\d{8,12}|(?:[367]\\\\d|4[0-24-9])\\\\d{4,11}\",[4,5,6,7,8,9,10,11,12,13],[[\"(\\\\d)(\\\\d{3,12})\",\"$1 $2\",[\"1(?:11|[2-9])\"],\"0$1\"],[\"(\\\\d{3})(\\\\d{2})\",\"$1 $2\",[\"517\"],\"0$1\"],[\"(\\\\d{2})(\\\\d{3,5})\",\"$1 $2\",[\"5[079]\"],\"0$1\"],[\"(\\\\d{3})(\\\\d{3,10})\",\"$1 $2\",[\"(?:31|4)6|51|6(?:48|5[0-3579]|[6-9])|7(?:20|32|8)|[89]\",\"(?:31|4)6|51|6(?:485|5[0-3579]|[6-9])|7(?:20|32|8)|[89]\"],\"0$1\"],[\"(\\\\d{4})(\\\\d{3,9})\",\"$1 $2\",[\"[2-467]|5[2-6]\"],\"0$1\"],[\"(\\\\d{2})(\\\\d{3})(\\\\d{3,4})\",\"$1 $2 $3\",[\"5\"],\"0$1\"],[\"(\\\\d{2})(\\\\d{4})(\\\\d{4,7})\",\"$1 $2 $3\",[\"5\"],\"0$1\"]],\"0\"],\"AU\":[\"61\",\"001[14-689]|14(?:1[14]|34|4[17]|[56]6|7[47]|88)0011\",\"1(?:[0-79]\\\\d{7}(?:\\\\d(?:\\\\d{2})?)?|8[0-24-9]\\\\d{7})|[2-478]\\\\d{8}|1\\\\d{4,7}\",[5,6,7,8,9,10,12],[[\"(\\\\d{2})(\\\\d{3,4})\",\"$1 $2\",[\"16\"],\"0$1\"],[\"(\\\\d{2})(\\\\d{3})(\\\\d{2,4})\",\"$1 $2 $3\",[\"16\"],\"0$1\"],[\"(\\\\d{3})(\\\\d{3})(\\\\d{3})\",\"$1 $2 $3\",[\"14|4\"],\"0$1\"],[\"(\\\\d)(\\\\d{4})(\\\\d{4})\",\"$1 $2 $3\",[\"[2378]\"],\"(0$1)\"],[\"(\\\\d{4})(\\\\d{3})(\\\\d{3})\",\"$1 $2 $3\",[\"1(?:30|[89])\"]]],\"0\",0,\"(183[12])|0\",0,0,0,[[\"(?:(?:241|349)0\\\\d\\\\d|8(?:51(?:0(?:0[03-9]|[12479]\\\\d|3[2-9]|5[0-8]|6[1-9]|8[0-7])|1(?:[0235689]\\\\d|1[0-69]|4[0-589]|7[0-47-9])|2(?:0[0-79]|[18][13579]|2[14-9]|3[0-46-9]|[4-6]\\\\d|7[89]|9[0-4])|[34]\\\\d\\\\d)|91(?:(?:[0-58]\\\\d|6[0135-9])\\\\d|7(?:0[0-24-9]|[1-9]\\\\d)|9(?:[0-46-9]\\\\d|5[0-79]))))\\\\d{3}|(?:2(?:[0-26-9]\\\\d|3[0-8]|4[02-9]|5[0135-9])|3(?:[0-3589]\\\\d|4[0-578]|6[1-9]|7[0-35-9])|7(?:[013-57-9]\\\\d|2[0-8])|8(?:55|6[0-8]|[78]\\\\d|9[02-9]))\\\\d{6}\",[9]],[\"4(?:79[01]|83[0-36-9]|95[0-3])\\\\d{5}|4(?:[0-36]\\\\d|4[047-9]|[58][0-24-9]|7[02-8]|9[0-47-9])\\\\d{6}\",[9]],[\"180(?:0\\\\d{3}|2)\\\\d{3}\",[7,10]],[\"190[0-26]\\\\d{6}\",[10]],0,0,0,[\"163\\\\d{2,6}\",[5,6,7,8,9]],[\"14(?:5(?:1[0458]|[23][458])|71\\\\d)\\\\d{4}\",[9]],[\"13(?:00\\\\d{6}(?:\\\\d{2})?|45[0-4]\\\\d{3})|13\\\\d{4}\",[6,8,10,12]]],\"0011\"],\"AW\":[\"297\",\"00\",\"(?:[25-79]\\\\d\\\\d|800)\\\\d{4}\",[7],[[\"(\\\\d{3})(\\\\d{4})\",\"$1 $2\",[\"[25-9]\"]]]],\"AX\":[\"358\",\"00|99(?:[01469]|5(?:[14]1|3[23]|5[59]|77|88|9[09]))\",\"2\\\\d{4,9}|35\\\\d{4,5}|(?:60\\\\d\\\\d|800)\\\\d{4,6}|7\\\\d{5,11}|(?:[14]\\\\d|3[0-46-9]|50)\\\\d{4,8}\",[5,6,7,8,9,10,11,12],0,\"0\",0,0,0,0,\"18\",0,\"00\"],\"AZ\":[\"994\",\"00\",\"365\\\\d{6}|(?:[124579]\\\\d|60|88)\\\\d{7}\",[9],[[\"(\\\\d{3})(\\\\d{2})(\\\\d{2})(\\\\d{2})\",\"$1 $2 $3 $4\",[\"90\"],\"0$1\"],[\"(\\\\d{2})(\\\\d{3})(\\\\d{2})(\\\\d{2})\",\"$1 $2 $3 $4\",[\"1[28]|2|365|46\",\"1[28]|2|365[45]|46\",\"1[28]|2|365(?:4|5[02])|46\"],\"(0$1)\"],[\"(\\\\d{2})(\\\\d{3})(\\\\d{2})(\\\\d{2})\",\"$1 $2 $3 $4\",[\"[13-9]\"],\"0$1\"]],\"0\"],\"BA\":[\"387\",\"00\",\"6\\\\d{8}|(?:[35689]\\\\d|49|70)\\\\d{6}\",[8,9],[[\"(\\\\d{2})(\\\\d{3})(\\\\d{3})\",\"$1 $2 $3\",[\"6[1-3]|[7-9]\"],\"0$1\"],[\"(\\\\d{2})(\\\\d{3})(\\\\d{3})\",\"$1 $2-$3\",[\"[3-5]|6[56]\"],\"0$1\"],[\"(\\\\d{2})(\\\\d{2})(\\\\d{2})(\\\\d{3})\",\"$1 $2 $3 $4\",[\"6\"],\"0$1\"]],\"0\"],\"BB\":[\"1\",\"011\",\"(?:246|[58]\\\\d\\\\d|900)\\\\d{7}\",[10],0,\"1\",0,\"([2-9]\\\\d{6})$|1\",\"246$1\",0,\"246\"],\"BD\":[\"880\",\"00\",\"[1-469]\\\\d{9}|8[0-79]\\\\d{7,8}|[2-79]\\\\d{8}|[2-9]\\\\d{7}|[3-9]\\\\d{6}|[57-9]\\\\d{5}\",[6,7,8,9,10],[[\"(\\\\d{2})(\\\\d{4,6})\",\"$1-$2\",[\"31[5-8]|[459]1\"],\"0$1\"],[\"(\\\\d{3})(\\\\d{3,7})\",\"$1-$2\",[\"3(?:[67]|8[013-9])|4(?:6[168]|7|[89][18])|5(?:6[128]|9)|6(?:[15]|28|4[14])|7[2-589]|8(?:0[014-9]|[12])|9[358]|(?:3[2-5]|4[235]|5[2-578]|6[0389]|76|8[3-7]|9[24])1|(?:44|66)[01346-9]\"],\"0$1\"],[\"(\\\\d{4})(\\\\d{3,6})\",\"$1-$2\",[\"[13-9]|2[23]\"],\"0$1\"],[\"(\\\\d)(\\\\d{7,8})\",\"$1-$2\",[\"2\"],\"0$1\"]],\"0\"],\"BE\":[\"32\",\"00\",\"4\\\\d{8}|[1-9]\\\\d{7}\",[8,9],[[\"(\\\\d{3})(\\\\d{2})(\\\\d{3})\",\"$1 $2 $3\",[\"(?:80|9)0\"],\"0$1\"],[\"(\\\\d)(\\\\d{3})(\\\\d{2})(\\\\d{2})\",\"$1 $2 $3 $4\",[\"[239]|4[23]\"],\"0$1\"],[\"(\\\\d{2})(\\\\d{2})(\\\\d{2})(\\\\d{2})\",\"$1 $2 $3 $4\",[\"[15-8]\"],\"0$1\"],[\"(\\\\d{3})(\\\\d{2})(\\\\d{2})(\\\\d{2})\",\"$1 $2 $3 $4\",[\"4\"],\"0$1\"]],\"0\"],\"BF\":[\"226\",\"00\",\"[024-7]\\\\d{7}\",[8],[[\"(\\\\d{2})(\\\\d{2})(\\\\d{2})(\\\\d{2})\",\"$1 $2 $3 $4\",[\"[024-7]\"]]]],\"BG\":[\"359\",\"00\",\"00800\\\\d{7}|[2-7]\\\\d{6,7}|[89]\\\\d{6,8}|2\\\\d{5}\",[6,7,8,9,12],[[\"(\\\\d)(\\\\d)(\\\\d{2})(\\\\d{2})\",\"$1 $2 $3 $4\",[\"2\"],\"0$1\"],[\"(\\\\d{3})(\\\\d{4})\",\"$1 $2\",[\"43[1-6]|70[1-9]\"],\"0$1\"],[\"(\\\\d)(\\\\d{3})(\\\\d{3,4})\",\"$1 $2 $3\",[\"2\"],\"0$1\"],[\"(\\\\d{2})(\\\\d{3})(\\\\d{2,3})\",\"$1 $2 $3\",[\"[356]|4[124-7]|7[1-9]|8[1-6]|9[1-7]\"],\"0$1\"],[\"(\\\\d{3})(\\\\d{2})(\\\\d{3})\",\"$1 $2 $3\",[\"(?:70|8)0\"],\"0$1\"],[\"(\\\\d{3})(\\\\d{3})(\\\\d{2})\",\"$1 $2 $3\",[\"43[1-7]|7\"],\"0$1\"],[\"(\\\\d{2})(\\\\d{3})(\\\\d{3,4})\",\"$1 $2 $3\",[\"[48]|9[08]\"],\"0$1\"],[\"(\\\\d{3})(\\\\d{3})(\\\\d{3})\",\"$1 $2 $3\",[\"9\"],\"0$1\"]],\"0\"],\"BH\":[\"973\",\"00\",\"[136-9]\\\\d{7}\",[8],[[\"(\\\\d{4})(\\\\d{4})\",\"$1 $2\",[\"[13679]|8[02-4679]\"]]]],\"BI\":[\"257\",\"00\",\"(?:[267]\\\\d|31)\\\\d{6}\",[8],[[\"(\\\\d{2})(\\\\d{2})(\\\\d{2})(\\\\d{2})\",\"$1 $2 $3 $4\",[\"[2367]\"]]]],\"BJ\":[\"229\",\"00\",\"(?:01\\\\d|8)\\\\d{7}\",[8,10],[[\"(\\\\d{2})(\\\\d{2})(\\\\d{2})(\\\\d{2})\",\"$1 $2 $3 $4\",[\"8\"]],[\"(\\\\d{2})(\\\\d{2})(\\\\d{2})(\\\\d{2})(\\\\d{2})\",\"$1 $2 $3 $4 $5\",[\"0\"]]]],\"BL\":[\"590\",\"00\",\"7090\\\\d{5}|(?:[56]9|[89]\\\\d)\\\\d{7}\",[9],0,\"0\",0,0,0,0,0,[[\"(?:59(?:0(?:2[7-9]|3[3-7]|5[12]|87)|87\\\\d)|80[6-9]\\\\d\\\\d)\\\\d{4}\"],[\"(?:69(?:0\\\\d\\\\d|1(?:2[2-9]|3[0-5]))|7090[0-4])\\\\d{4}\"],[\"80[0-5]\\\\d{6}\"],[\"8[129]\\\\d{7}\"],0,0,0,0,[\"9(?:(?:39[5-7]|76[018])\\\\d|475[0-6])\\\\d{4}\"]]],\"BM\":[\"1\",\"011\",\"(?:441|[58]\\\\d\\\\d|900)\\\\d{7}\",[10],0,\"1\",0,\"([2-9]\\\\d{6})$|1\",\"441$1\",0,\"441\"],\"BN\":[\"673\",\"00\",\"[2-578]\\\\d{6}\",[7],[[\"(\\\\d{3})(\\\\d{4})\",\"$1 $2\",[\"[2-578]\"]]]],\"BO\":[\"591\",\"00(?:1\\\\d)?\",\"(?:[2-7]\\\\d\\\\d|8001)\\\\d{5}\",[8,9],[[\"(\\\\d)(\\\\d{7})\",\"$1 $2\",[\"[23]|4[46]|50\"]],[\"(\\\\d{8})\",\"$1\",[\"[5-7]\"]],[\"(\\\\d{3})(\\\\d{2})(\\\\d{4})\",\"$1 $2 $3\",[\"8\"]]],\"0\",0,\"0(1\\\\d)?\"],\"BQ\":[\"599\",\"00\",\"(?:[34]1|7\\\\d)\\\\d{5}\",[7],0,0,0,0,0,0,\"[347]\"],\"BR\":[\"55\",\"00(?:1[245]|2[1-35]|31|4[13]|[56]5|99)\",\"[1-467]\\\\d{9,10}|55[0-46-9]\\\\d{8}|[34]\\\\d{7}|55\\\\d{7,8}|(?:5[0-46-9]|[89]\\\\d)\\\\d{7,9}\",[8,9,10,11],[[\"(\\\\d{4})(\\\\d{4})\",\"$1-$2\",[\"300|4(?:0[02]|37|86)\",\"300|4(?:0(?:0|20)|370|864)\"]],[\"(\\\\d{3})(\\\\d{2,3})(\\\\d{4})\",\"$1 $2 $3\",[\"(?:[358]|90)0\"],\"0$1\"],[\"(\\\\d{2})(\\\\d{4})(\\\\d{4})\",\"$1 $2-$3\",[\"(?:[14689][1-9]|2[12478]|3[1-578]|5[13-5]|7[13-579])[2-57]\"],\"($1)\"],[\"(\\\\d{2})(\\\\d{5})(\\\\d{4})\",\"$1 $2-$3\",[\"[16][1-9]|[2-57-9]\"],\"($1)\"]],\"0\",0,\"(?:0|90)(?:(1[245]|2[1-35]|31|4[13]|[56]5|99)(\\\\d{10,11}))?\",\"$2\"],\"BS\":[\"1\",\"011\",\"(?:242|[58]\\\\d\\\\d|900)\\\\d{7}\",[10],0,\"1\",0,\"([3-8]\\\\d{6})$|1\",\"242$1\",0,\"242\"],\"BT\":[\"975\",\"00\",\"[178]\\\\d{7}|[2-8]\\\\d{6}\",[7,8],[[\"(\\\\d)(\\\\d{3})(\\\\d{3})\",\"$1 $2 $3\",[\"[2-6]|7[246]|8[2-4]\"]],[\"(\\\\d{2})(\\\\d{2})(\\\\d{2})(\\\\d{2})\",\"$1 $2 $3 $4\",[\"1[67]|[78]\"]]]],\"BW\":[\"267\",\"00\",\"(?:0800|(?:[37]|800)\\\\d)\\\\d{6}|(?:[2-6]\\\\d|90)\\\\d{5}\",[7,8,10],[[\"(\\\\d{2})(\\\\d{5})\",\"$1 $2\",[\"90\"]],[\"(\\\\d{3})(\\\\d{4})\",\"$1 $2\",[\"[24-6]|3[15-9]\"]],[\"(\\\\d{2})(\\\\d{3})(\\\\d{3})\",\"$1 $2 $3\",[\"[37]\"]],[\"(\\\\d{4})(\\\\d{3})(\\\\d{3})\",\"$1 $2 $3\",[\"0\"]],[\"(\\\\d{3})(\\\\d{4})(\\\\d{3})\",\"$1 $2 $3\",[\"8\"]]]],\"BY\":[\"375\",\"810\",\"(?:[12]\\\\d|33|44|902)\\\\d{7}|8(?:0[0-79]\\\\d{5,7}|[1-7]\\\\d{9})|8(?:1[0-489]|[5-79]\\\\d)\\\\d{7}|8[1-79]\\\\d{6,7}|8[0-79]\\\\d{5}|8\\\\d{5}\",[6,7,8,9,10,11],[[\"(\\\\d{3})(\\\\d{3})\",\"$1 $2\",[\"800\"],\"8 $1\"],[\"(\\\\d{3})(\\\\d{2})(\\\\d{2,4})\",\"$1 $2 $3\",[\"800\"],\"8 $1\"],[\"(\\\\d{4})(\\\\d{2})(\\\\d{3})\",\"$1 $2-$3\",[\"1(?:5[169]|6[3-5]|7[179])|2(?:1[35]|2[34]|3[3-5])\",\"1(?:5[169]|6(?:3[1-3]|4|5[125])|7(?:1[3-9]|7[0-24-6]|9[2-7]))|2(?:1[35]|2[34]|3[3-5])\"],\"8 0$1\"],[\"(\\\\d{3})(\\\\d{2})(\\\\d{2})(\\\\d{2})\",\"$1 $2-$3-$4\",[\"1(?:[56]|7[467])|2[1-3]\"],\"8 0$1\"],[\"(\\\\d{2})(\\\\d{3})(\\\\d{2})(\\\\d{2})\",\"$1 $2-$3-$4\",[\"[1-4]\"],\"8 0$1\"],[\"(\\\\d{3})(\\\\d{3,4})(\\\\d{4})\",\"$1 $2 $3\",[\"[89]\"],\"8 $1\"]],\"8\",0,\"0|80?\",0,0,0,0,\"8~10\"],\"BZ\":[\"501\",\"00\",\"(?:0800\\\\d|[2-8])\\\\d{6}\",[7,11],[[\"(\\\\d{3})(\\\\d{4})\",\"$1-$2\",[\"[2-8]\"]],[\"(\\\\d)(\\\\d{3})(\\\\d{4})(\\\\d{3})\",\"$1-$2-$3-$4\",[\"0\"]]]],\"CA\":[\"1\",\"011\",\"[2-9]\\\\d{9}|3\\\\d{6}\",[7,10],0,\"1\",0,0,0,0,0,[[\"(?:2(?:04|[23]6|[48]9|5[07]|63)|3(?:06|43|54|6[578]|82)|4(?:03|1[68]|[26]8|3[178]|50|74)|5(?:06|1[49]|48|79|8[147])|6(?:04|[18]3|39|47|72)|7(?:0[59]|42|53|78|8[02])|8(?:[06]7|19|25|7[39])|9(?:0[25]|42))[2-9]\\\\d{6}\",[10]],[\"\",[10]],[\"8(?:00|33|44|55|66|77|88)[2-9]\\\\d{6}\",[10]],[\"900[2-9]\\\\d{6}\",[10]],[\"52(?:3(?:[2-46-9][02-9]\\\\d|5(?:[02-46-9]\\\\d|5[0-46-9]))|4(?:[2-478][02-9]\\\\d|5(?:[034]\\\\d|2[024-9]|5[0-46-9])|6(?:0[1-9]|[2-9]\\\\d)|9(?:[05-9]\\\\d|2[0-5]|49)))\\\\d{4}|52[34][2-9]1[02-9]\\\\d{4}|(?:5(?:2[125-9]|3[23]|44|66|77|88)|6(?:22|33))[2-9]\\\\d{6}\",[10]],0,[\"310\\\\d{4}\",[7]],0,[\"600[2-9]\\\\d{6}\",[10]]]],\"CC\":[\"61\",\"001[14-689]|14(?:1[14]|34|4[17]|[56]6|7[47]|88)0011\",\"1(?:[0-79]\\\\d{8}(?:\\\\d{2})?|8[0-24-9]\\\\d{7})|[148]\\\\d{8}|1\\\\d{5,7}\",[6,7,8,9,10,12],0,\"0\",0,\"([59]\\\\d{7})$|0\",\"8$1\",0,0,[[\"8(?:51(?:0(?:02|31|60|89)|1(?:18|76)|223)|91(?:0(?:1[0-2]|29)|1(?:[28]2|50|79)|2(?:10|64)|3(?:[06]8|22)|4[29]8|62\\\\d|70[23]|959))\\\\d{3}\",[9]],[\"4(?:79[01]|83[0-36-9]|95[0-3])\\\\d{5}|4(?:[0-36]\\\\d|4[047-9]|[58][0-24-9]|7[02-8]|9[0-47-9])\\\\d{6}\",[9]],[\"180(?:0\\\\d{3}|2)\\\\d{3}\",[7,10]],[\"190[0-26]\\\\d{6}\",[10]],0,0,0,0,[\"14(?:5(?:1[0458]|[23][458])|71\\\\d)\\\\d{4}\",[9]],[\"13(?:00\\\\d{6}(?:\\\\d{2})?|45[0-4]\\\\d{3})|13\\\\d{4}\",[6,8,10,12]]],\"0011\"],\"CD\":[\"243\",\"00\",\"(?:(?:[189]|5\\\\d)\\\\d|2)\\\\d{7}|[1-68]\\\\d{6}\",[7,8,9,10],[[\"(\\\\d{2})(\\\\d{2})(\\\\d{3})\",\"$1 $2 $3\",[\"88\"],\"0$1\"],[\"(\\\\d{2})(\\\\d{5})\",\"$1 $2\",[\"[1-6]\"],\"0$1\"],[\"(\\\\d{2})(\\\\d{2})(\\\\d{4})\",\"$1 $2 $3\",[\"2\"],\"0$1\"],[\"(\\\\d{2})(\\\\d{3})(\\\\d{4})\",\"$1 $2 $3\",[\"1\"],\"0$1\"],[\"(\\\\d{3})(\\\\d{3})(\\\\d{3})\",\"$1 $2 $3\",[\"[89]\"],\"0$1\"],[\"(\\\\d{2})(\\\\d{2})(\\\\d{3})(\\\\d{3})\",\"$1 $2 $3 $4\",[\"5\"],\"0$1\"]],\"0\"],\"CF\":[\"236\",\"00\",\"8776\\\\d{4}|(?:[27]\\\\d|61)\\\\d{6}\",[8],[[\"(\\\\d{2})(\\\\d{2})(\\\\d{2})(\\\\d{2})\",\"$1 $2 $3 $4\",[\"[26-8]\"]]]],\"CG\":[\"242\",\"00\",\"222\\\\d{6}|(?:0\\\\d|80)\\\\d{7}\",[9],[[\"(\\\\d)(\\\\d{4})(\\\\d{4})\",\"$1 $2 $3\",[\"8\"]],[\"(\\\\d{2})(\\\\d{3})(\\\\d{4})\",\"$1 $2 $3\",[\"[02]\"]]]],\"CH\":[\"41\",\"00\",\"8\\\\d{11}|[2-9]\\\\d{8}\",[9,12],[[\"(\\\\d{3})(\\\\d{3})(\\\\d{3})\",\"$1 $2 $3\",[\"8[047]|90\"],\"0$1\"],[\"(\\\\d{2})(\\\\d{3})(\\\\d{2})(\\\\d{2})\",\"$1 $2 $3 $4\",[\"[2-79]|81\"],\"0$1\"],[\"(\\\\d{3})(\\\\d{2})(\\\\d{3})(\\\\d{2})(\\\\d{2})\",\"$1 $2 $3 $4 $5\",[\"8\"],\"0$1\"]],\"0\"],\"CI\":[\"225\",\"00\",\"[02]\\\\d{9}\",[10],[[\"(\\\\d{2})(\\\\d{2})(\\\\d)(\\\\d{5})\",\"$1 $2 $3 $4\",[\"2\"]],[\"(\\\\d{2})(\\\\d{2})(\\\\d{2})(\\\\d{4})\",\"$1 $2 $3 $4\",[\"0\"]]]],\"CK\":[\"682\",\"00\",\"[2-578]\\\\d{4}\",[5],[[\"(\\\\d{2})(\\\\d{3})\",\"$1 $2\",[\"[2-578]\"]]]],\"CL\":[\"56\",\"(?:0|1(?:1[0-69]|2[02-5]|5[13-58]|69|7[0167]|8[018]))0\",\"12300\\\\d{6}|6\\\\d{9,10}|[2-9]\\\\d{8}\",[9,10,11],[[\"(\\\\d{5})(\\\\d{4})\",\"$1 $2\",[\"219\",\"2196\"],\"($1)\"],[\"(\\\\d{3})(\\\\d{3})(\\\\d{3})\",\"$1 $2 $3\",[\"60|809\"]],[\"(\\\\d{2})(\\\\d{3})(\\\\d{4})\",\"$1 $2 $3\",[\"44\"]],[\"(\\\\d)(\\\\d{4})(\\\\d{4})\",\"$1 $2 $3\",[\"2[1-36]\"],\"($1)\"],[\"(\\\\d)(\\\\d{4})(\\\\d{4})\",\"$1 $2 $3\",[\"9(?:10|[2-9])\"]],[\"(\\\\d{2})(\\\\d{3})(\\\\d{4})\",\"$1 $2 $3\",[\"3[2-5]|[47]|5[1-3578]|6[13-57]|8(?:0[1-8]|[1-9])\"],\"($1)\"],[\"(\\\\d{3})(\\\\d{3})(\\\\d{3,4})\",\"$1 $2 $3\",[\"60|8\"]],[\"(\\\\d{4})(\\\\d{3})(\\\\d{4})\",\"$1 $2 $3\",[\"1\"]],[\"(\\\\d{3})(\\\\d{3})(\\\\d{2})(\\\\d{3})\",\"$1 $2 $3 $4\",[\"60\"]]]],\"CM\":[\"237\",\"00\",\"[26]\\\\d{8}|88\\\\d{6,7}\",[8,9],[[\"(\\\\d{2})(\\\\d{2})(\\\\d{2})(\\\\d{2})\",\"$1 $2 $3 $4\",[\"88\"]],[\"(\\\\d)(\\\\d{2})(\\\\d{2})(\\\\d{2})(\\\\d{2})\",\"$1 $2 $3 $4 $5\",[\"[26]|88\"]]]],\"CN\":[\"86\",\"00|1(?:[12]\\\\d|79)\\\\d\\\\d00\",\"(?:(?:1[03-689]|2\\\\d)\\\\d\\\\d|6)\\\\d{8}|1\\\\d{10}|[126]\\\\d{6}(?:\\\\d(?:\\\\d{2})?)?|86\\\\d{5,6}|(?:[3-579]\\\\d|8[0-57-9])\\\\d{5,9}\",[7,8,9,10,11,12],[[\"(\\\\d{2})(\\\\d{5,6})\",\"$1 $2\",[\"(?:10|2[0-57-9])[19]|3(?:[157]|35|49|9[1-68])|4(?:1[124-9]|2[179]|6[47-9]|7|8[23])|5(?:[1357]|2[37]|4[36]|6[1-46]|80)|6(?:3[1-5]|6[0238]|9[12])|7(?:01|[1579]|2[248]|3[014-9]|4[3-6]|6[023689])|8(?:07|1[236-8]|2[5-7]|[37]|8[36-8]|9[1-8])|9(?:0[1-3689]|1[1-79]|3|4[13]|5[1-5]|7[0-79]|9[0-35-9])|(?:4[35]|59|85)[1-9]\",\"(?:10|2[0-57-9])(?:1[02]|9[56])|8078|(?:3(?:[157]\\\\d|35|49|9[1-68])|4(?:1[124-9]|2[179]|[35][1-9]|6[47-9]|7\\\\d|8[23])|5(?:[1357]\\\\d|2[37]|4[36]|6[1-46]|80|9[1-9])|6(?:3[1-5]|6[0238]|9[12])|7(?:01|[1579]\\\\d|2[248]|3[014-9]|4[3-6]|6[023689])|8(?:1[236-8]|2[5-7]|[37]\\\\d|5[1-9]|8[36-8]|9[1-8])|9(?:0[1-3689]|1[1-79]|3\\\\d|4[13]|5[1-5]|7[0-79]|9[0-35-9]))1\",\"10(?:1(?:0|23)|9[56])|2[0-57-9](?:1(?:00|23)|9[56])|80781|(?:3(?:[157]\\\\d|35|49|9[1-68])|4(?:1[124-9]|2[179]|[35][1-9]|6[47-9]|7\\\\d|8[23])|5(?:[1357]\\\\d|2[37]|4[36]|6[1-46]|80|9[1-9])|6(?:3[1-5]|6[0238]|9[12])|7(?:01|[1579]\\\\d|2[248]|3[014-9]|4[3-6]|6[023689])|8(?:1[236-8]|2[5-7]|[37]\\\\d|5[1-9]|8[36-8]|9[1-8])|9(?:0[1-3689]|1[1-79]|3\\\\d|4[13]|5[1-5]|7[0-79]|9[0-35-9]))12\",\"10(?:1(?:0|23)|9[56])|2[0-57-9](?:1(?:00|23)|9[56])|807812|(?:3(?:[157]\\\\d|35|49|9[1-68])|4(?:1[124-9]|2[179]|[35][1-9]|6[47-9]|7\\\\d|8[23])|5(?:[1357]\\\\d|2[37]|4[36]|6[1-46]|80|9[1-9])|6(?:3[1-5]|6[0238]|9[12])|7(?:01|[1579]\\\\d|2[248]|3[014-9]|4[3-6]|6[023689])|8(?:1[236-8]|2[5-7]|[37]\\\\d|5[1-9]|8[36-8]|9[1-8])|9(?:0[1-3689]|1[1-79]|3\\\\d|4[13]|5[1-5]|7[0-79]|9[0-35-9]))123\",\"10(?:1(?:0|23)|9[56])|2[0-57-9](?:1(?:00|23)|9[56])|(?:3(?:[157]\\\\d|35|49|9[1-68])|4(?:1[124-9]|2[179]|[35][1-9]|6[47-9]|7\\\\d|8[23])|5(?:[1357]\\\\d|2[37]|4[36]|6[1-46]|80|9[1-9])|6(?:3[1-5]|6[0238]|9[12])|7(?:01|[1579]\\\\d|2[248]|3[014-9]|4[3-6]|6[023689])|8(?:078|1[236-8]|2[5-7]|[37]\\\\d|5[1-9]|8[36-8]|9[1-8])|9(?:0[1-3689]|1[1-79]|3\\\\d|4[13]|5[1-5]|7[0-79]|9[0-35-9]))123\"],\"0$1\"],[\"(\\\\d{3})(\\\\d{5,6})\",\"$1 $2\",[\"3(?:[157]|35|49|9[1-68])|4(?:[17]|2[179]|6[47-9]|8[23])|5(?:[1357]|2[37]|4[36]|6[1-46]|80)|6(?:3[1-5]|6[0238]|9[12])|7(?:01|[1579]|2[248]|3[014-9]|4[3-6]|6[023689])|8(?:1[236-8]|2[5-7]|[37]|8[36-8]|9[1-8])|9(?:0[1-3689]|1[1-79]|[379]|4[13]|5[1-5])|(?:4[35]|59|85)[1-9]\",\"(?:3(?:[157]\\\\d|35|49|9[1-68])|4(?:[17]\\\\d|2[179]|[35][1-9]|6[47-9]|8[23])|5(?:[1357]\\\\d|2[37]|4[36]|6[1-46]|80|9[1-9])|6(?:3[1-5]|6[0238]|9[12])|7(?:01|[1579]\\\\d|2[248]|3[014-9]|4[3-6]|6[023689])|8(?:1[236-8]|2[5-7]|[37]\\\\d|5[1-9]|8[36-8]|9[1-8])|9(?:0[1-3689]|1[1-79]|[379]\\\\d|4[13]|5[1-5]))[19]\",\"85[23](?:10|95)|(?:3(?:[157]\\\\d|35|49|9[1-68])|4(?:[17]\\\\d|2[179]|[35][1-9]|6[47-9]|8[23])|5(?:[1357]\\\\d|2[37]|4[36]|6[1-46]|80|9[1-9])|6(?:3[1-5]|6[0238]|9[12])|7(?:01|[1579]\\\\d|2[248]|3[014-9]|4[3-6]|6[023689])|8(?:1[236-8]|2[5-7]|[37]\\\\d|5[14-9]|8[36-8]|9[1-8])|9(?:0[1-3689]|1[1-79]|[379]\\\\d|4[13]|5[1-5]))(?:10|9[56])\",\"85[23](?:100|95)|(?:3(?:[157]\\\\d|35|49|9[1-68])|4(?:[17]\\\\d|2[179]|[35][1-9]|6[47-9]|8[23])|5(?:[1357]\\\\d|2[37]|4[36]|6[1-46]|80|9[1-9])|6(?:3[1-5]|6[0238]|9[12])|7(?:01|[1579]\\\\d|2[248]|3[014-9]|4[3-6]|6[023689])|8(?:1[236-8]|2[5-7]|[37]\\\\d|5[14-9]|8[36-8]|9[1-8])|9(?:0[1-3689]|1[1-79]|[379]\\\\d|4[13]|5[1-5]))(?:100|9[56])\"],\"0$1\"],[\"(\\\\d{3})(\\\\d{3})(\\\\d{4})\",\"$1 $2 $3\",[\"(?:4|80)0\"]],[\"(\\\\d{2})(\\\\d{4})(\\\\d{4})\",\"$1 $2 $3\",[\"10|2(?:[02-57-9]|1[1-9])\",\"10|2(?:[02-57-9]|1[1-9])\",\"10[0-79]|2(?:[02-57-9]|1[1-79])|(?:10|21)8(?:0[1-9]|[1-9])\"],\"0$1\",1],[\"(\\\\d{3})(\\\\d{3})(\\\\d{4})\",\"$1 $2 $3\",[\"3(?:[3-59]|7[02-68])|4(?:[26-8]|3[3-9]|5[2-9])|5(?:3[03-9]|[468]|7[028]|9[2-46-9])|6|7(?:[0-247]|3[04-9]|5[0-4689]|6[2368])|8(?:[1-358]|9[1-7])|9(?:[013479]|5[1-5])|(?:[34]1|55|79|87)[02-9]\"],\"0$1\",1],[\"(\\\\d{3})(\\\\d{7,8})\",\"$1 $2\",[\"9\"]],[\"(\\\\d{4})(\\\\d{3})(\\\\d{4})\",\"$1 $2 $3\",[\"80\"],\"0$1\",1],[\"(\\\\d{3})(\\\\d{4})(\\\\d{4})\",\"$1 $2 $3\",[\"[3-578]\"],\"0$1\",1],[\"(\\\\d{3})(\\\\d{4})(\\\\d{4})\",\"$1 $2 $3\",[\"1[3-9]\"]],[\"(\\\\d{2})(\\\\d{3})(\\\\d{3})(\\\\d{4})\",\"$1 $2 $3 $4\",[\"[12]\"],\"0$1\",1]],\"0\",0,\"(1(?:[12]\\\\d|79)\\\\d\\\\d)|0\",0,0,0,0,\"00\"],\"CO\":[\"57\",\"00(?:4(?:[14]4|56)|[579])\",\"(?:46|60\\\\d\\\\d)\\\\d{6}|(?:1\\\\d|[39])\\\\d{9}\",[8,10,11],[[\"(\\\\d{4})(\\\\d{4})\",\"$1 $2\",[\"46\"]],[\"(\\\\d{3})(\\\\d{7})\",\"$1 $2\",[\"6|90\"],\"($1)\"],[\"(\\\\d{3})(\\\\d{7})\",\"$1 $2\",[\"3[0-357]|9[14]\"]],[\"(\\\\d)(\\\\d{3})(\\\\d{7})\",\"$1-$2-$3\",[\"1\"],\"0$1\",0,\"$1 $2 $3\"]],\"0\",0,\"0([3579]|4(?:[14]4|56))?\"],\"CR\":[\"506\",\"00\",\"(?:8\\\\d|90)\\\\d{8}|(?:[24-8]\\\\d{3}|3005)\\\\d{4}\",[8,10],[[\"(\\\\d{4})(\\\\d{4})\",\"$1 $2\",[\"[2-7]|8[3-9]\"]],[\"(\\\\d{3})(\\\\d{3})(\\\\d{4})\",\"$1-$2-$3\",[\"[89]\"]]],0,0,\"(19(?:0[0-2468]|1[09]|20|66|77|99))\"],\"CU\":[\"53\",\"119\",\"(?:[2-7]|8\\\\d\\\\d)\\\\d{7}|[2-47]\\\\d{6}|[34]\\\\d{5}\",[6,7,8,10],[[\"(\\\\d{2})(\\\\d{4,6})\",\"$1 $2\",[\"2[1-4]|[34]\"],\"(0$1)\"],[\"(\\\\d)(\\\\d{6,7})\",\"$1 $2\",[\"7\"],\"(0$1)\"],[\"(\\\\d)(\\\\d{7})\",\"$1 $2\",[\"[56]\"],\"0$1\"],[\"(\\\\d{3})(\\\\d{7})\",\"$1 $2\",[\"8\"],\"0$1\"]],\"0\"],\"CV\":[\"238\",\"0\",\"(?:[2-59]\\\\d\\\\d|800)\\\\d{4}\",[7],[[\"(\\\\d{3})(\\\\d{2})(\\\\d{2})\",\"$1 $2 $3\",[\"[2-589]\"]]]],\"CW\":[\"599\",\"00\",\"(?:[34]1|60|(?:7|9\\\\d)\\\\d)\\\\d{5}\",[7,8],[[\"(\\\\d{3})(\\\\d{4})\",\"$1 $2\",[\"[3467]\"]],[\"(\\\\d)(\\\\d{3})(\\\\d{4})\",\"$1 $2 $3\",[\"9[4-8]\"]]],0,0,0,0,0,\"[69]\"],\"CX\":[\"61\",\"001[14-689]|14(?:1[14]|34|4[17]|[56]6|7[47]|88)0011\",\"1(?:[0-79]\\\\d{8}(?:\\\\d{2})?|8[0-24-9]\\\\d{7})|[148]\\\\d{8}|1\\\\d{5,7}\",[6,7,8,9,10,12],0,\"0\",0,\"([59]\\\\d{7})$|0\",\"8$1\",0,0,[[\"8(?:51(?:0(?:01|30|59|88)|1(?:17|46|75)|2(?:22|35))|91(?:00[6-9]|1(?:[28]1|49|78)|2(?:09|63)|3(?:12|26|75)|4(?:56|97)|64\\\\d|7(?:0[01]|1[0-2])|958))\\\\d{3}\",[9]],[\"4(?:79[01]|83[0-36-9]|95[0-3])\\\\d{5}|4(?:[0-36]\\\\d|4[047-9]|[58][0-24-9]|7[02-8]|9[0-47-9])\\\\d{6}\",[9]],[\"180(?:0\\\\d{3}|2)\\\\d{3}\",[7,10]],[\"190[0-26]\\\\d{6}\",[10]],0,0,0,0,[\"14(?:5(?:1[0458]|[23][458])|71\\\\d)\\\\d{4}\",[9]],[\"13(?:00\\\\d{6}(?:\\\\d{2})?|45[0-4]\\\\d{3})|13\\\\d{4}\",[6,8,10,12]]],\"0011\"],\"CY\":[\"357\",\"00\",\"(?:[279]\\\\d|[58]0)\\\\d{6}\",[8],[[\"(\\\\d{2})(\\\\d{6})\",\"$1 $2\",[\"[257-9]\"]]]],\"CZ\":[\"420\",\"00\",\"(?:[2-578]\\\\d|60)\\\\d{7}|9\\\\d{8,11}\",[9,10,11,12],[[\"(\\\\d{3})(\\\\d{3})(\\\\d{3})\",\"$1 $2 $3\",[\"[2-8]|9[015-7]\"]],[\"(\\\\d{2})(\\\\d{3})(\\\\d{3})(\\\\d{2})\",\"$1 $2 $3 $4\",[\"96\"]],[\"(\\\\d{2})(\\\\d{3})(\\\\d{3})(\\\\d{3})\",\"$1 $2 $3 $4\",[\"9\"]],[\"(\\\\d{3})(\\\\d{3})(\\\\d{3})(\\\\d{3})\",\"$1 $2 $3 $4\",[\"9\"]]]],\"DE\":[\"49\",\"00\",\"[2579]\\\\d{5,14}|49(?:[34]0|69|8\\\\d)\\\\d\\\\d?|49(?:37|49|60|7[089]|9\\\\d)\\\\d{1,3}|49(?:2[024-9]|3[2-689]|7[1-7])\\\\d{1,8}|(?:1|[368]\\\\d|4[0-8])\\\\d{3,13}|49(?:[015]\\\\d|2[13]|31|[46][1-8])\\\\d{1,9}\",[4,5,6,7,8,9,10,11,12,13,14,15],[[\"(\\\\d{2})(\\\\d{3,13})\",\"$1 $2\",[\"3[02]|40|[68]9\"],\"0$1\"],[\"(\\\\d{3})(\\\\d{3,12})\",\"$1 $2\",[\"2(?:0[1-389]|1[124]|2[18]|3[14])|3(?:[35-9][15]|4[015])|906|(?:2[4-9]|4[2-9]|[579][1-9]|[68][1-8])1\",\"2(?:0[1-389]|12[0-8])|3(?:[35-9][15]|4[015])|906|2(?:[13][14]|2[18])|(?:2[4-9]|4[2-9]|[579][1-9]|[68][1-8])1\"],\"0$1\"],[\"(\\\\d{4})(\\\\d{2,11})\",\"$1 $2\",[\"[24-6]|3(?:[3569][02-46-9]|4[2-4679]|7[2-467]|8[2-46-8])|70[2-8]|8(?:0[2-9]|[1-8])|90[7-9]|[79][1-9]\",\"[24-6]|3(?:3(?:0[1-467]|2[127-9]|3[124578]|7[1257-9]|8[1256]|9[145])|4(?:2[135]|4[13578]|9[1346])|5(?:0[14]|2[1-3589]|6[1-4]|7[13468]|8[13568])|6(?:2[1-489]|3[124-6]|6[13]|7[12579]|8[1-356]|9[135])|7(?:2[1-7]|4[145]|6[1-5]|7[1-4])|8(?:21|3[1468]|6|7[1467]|8[136])|9(?:0[12479]|2[1358]|4[134679]|6[1-9]|7[136]|8[147]|9[1468]))|70[2-8]|8(?:0[2-9]|[1-8])|90[7-9]|[79][1-9]|3[68]4[1347]|3(?:47|60)[1356]|3(?:3[46]|46|5[49])[1246]|3[4579]3[1357]\"],\"0$1\"],[\"(\\\\d{3})(\\\\d{4})\",\"$1 $2\",[\"138\"],\"0$1\"],[\"(\\\\d{5})(\\\\d{2,10})\",\"$1 $2\",[\"3\"],\"0$1\"],[\"(\\\\d{3})(\\\\d{5,11})\",\"$1 $2\",[\"181\"],\"0$1\"],[\"(\\\\d{3})(\\\\d)(\\\\d{4,10})\",\"$1 $2 $3\",[\"1(?:3|80)|9\"],\"0$1\"],[\"(\\\\d{3})(\\\\d{7,8})\",\"$1 $2\",[\"1[67]\"],\"0$1\"],[\"(\\\\d{3})(\\\\d{7,12})\",\"$1 $2\",[\"8\"],\"0$1\"],[\"(\\\\d{5})(\\\\d{6})\",\"$1 $2\",[\"185\",\"1850\",\"18500\"],\"0$1\"],[\"(\\\\d{3})(\\\\d{4})(\\\\d{4})\",\"$1 $2 $3\",[\"7\"],\"0$1\"],[\"(\\\\d{4})(\\\\d{7})\",\"$1 $2\",[\"18[68]\"],\"0$1\"],[\"(\\\\d{4})(\\\\d{7})\",\"$1 $2\",[\"15[1279]\"],\"0$1\"],[\"(\\\\d{5})(\\\\d{6})\",\"$1 $2\",[\"15[03568]\",\"15(?:[0568]|3[13])\"],\"0$1\"],[\"(\\\\d{3})(\\\\d{8})\",\"$1 $2\",[\"18\"],\"0$1\"],[\"(\\\\d{3})(\\\\d{2})(\\\\d{7,8})\",\"$1 $2 $3\",[\"1(?:6[023]|7)\"],\"0$1\"],[\"(\\\\d{4})(\\\\d{2})(\\\\d{7})\",\"$1 $2 $3\",[\"15[279]\"],\"0$1\"],[\"(\\\\d{3})(\\\\d{2})(\\\\d{8})\",\"$1 $2 $3\",[\"15\"],\"0$1\"]],\"0\"],\"DJ\":[\"253\",\"00\",\"(?:2\\\\d|77)\\\\d{6}\",[8],[[\"(\\\\d{2})(\\\\d{2})(\\\\d{2})(\\\\d{2})\",\"$1 $2 $3 $4\",[\"[27]\"]]]],\"DK\":[\"45\",\"00\",\"[2-9]\\\\d{7}\",[8],[[\"(\\\\d{2})(\\\\d{2})(\\\\d{2})(\\\\d{2})\",\"$1 $2 $3 $4\",[\"[2-9]\"]]]],\"DM\":[\"1\",\"011\",\"(?:[58]\\\\d\\\\d|767|900)\\\\d{7}\",[10],0,\"1\",0,\"([2-7]\\\\d{6})$|1\",\"767$1\",0,\"767\"],\"DO\":[\"1\",\"011\",\"(?:[58]\\\\d\\\\d|900)\\\\d{7}\",[10],0,\"1\",0,0,0,0,\"8001|8[024]9\"],\"DZ\":[\"213\",\"00\",\"(?:[1-4]|[5-79]\\\\d|80)\\\\d{7}\",[8,9],[[\"(\\\\d{2})(\\\\d{2})(\\\\d{2})(\\\\d{2})\",\"$1 $2 $3 $4\",[\"[1-4]\"],\"0$1\"],[\"(\\\\d{2})(\\\\d{3})(\\\\d{2})(\\\\d{2})\",\"$1 $2 $3 $4\",[\"9\"],\"0$1\"],[\"(\\\\d{3})(\\\\d{2})(\\\\d{2})(\\\\d{2})\",\"$1 $2 $3 $4\",[\"[5-8]\"],\"0$1\"]],\"0\"],\"EC\":[\"593\",\"00\",\"1\\\\d{9,10}|(?:[2-7]|9\\\\d)\\\\d{7}\",[8,9,10,11],[[\"(\\\\d)(\\\\d{3})(\\\\d{4})\",\"$1 $2-$3\",[\"[2-7]\"],\"(0$1)\",0,\"$1-$2-$3\"],[\"(\\\\d{2})(\\\\d{3})(\\\\d{4})\",\"$1 $2 $3\",[\"9\"],\"0$1\"],[\"(\\\\d{4})(\\\\d{3})(\\\\d{3,4})\",\"$1 $2 $3\",[\"1\"]]],\"0\"],\"EE\":[\"372\",\"00\",\"8\\\\d{9}|[4578]\\\\d{7}|(?:[3-8]\\\\d|90)\\\\d{5}\",[7,8,10],[[\"(\\\\d{3})(\\\\d{4})\",\"$1 $2\",[\"[369]|4[3-8]|5(?:[0-2]|5[0-478]|6[45])|7[1-9]|88\",\"[369]|4[3-8]|5(?:[02]|1(?:[0-8]|95)|5[0-478]|6(?:4[0-4]|5[1-589]))|7[1-9]|88\"]],[\"(\\\\d{4})(\\\\d{3,4})\",\"$1 $2\",[\"[45]|8(?:00|[1-49])\",\"[45]|8(?:00[1-9]|[1-49])\"]],[\"(\\\\d{2})(\\\\d{2})(\\\\d{4})\",\"$1 $2 $3\",[\"7\"]],[\"(\\\\d{4})(\\\\d{3})(\\\\d{3})\",\"$1 $2 $3\",[\"8\"]]]],\"EG\":[\"20\",\"00\",\"[189]\\\\d{8,9}|[24-6]\\\\d{8}|[135]\\\\d{7}\",[8,9,10],[[\"(\\\\d)(\\\\d{7,8})\",\"$1 $2\",[\"[23]\"],\"0$1\"],[\"(\\\\d{2})(\\\\d{6,7})\",\"$1 $2\",[\"1[35]|[4-6]|8[2468]|9[235-7]\"],\"0$1\"],[\"(\\\\d{3})(\\\\d{3})(\\\\d{4})\",\"$1 $2 $3\",[\"[89]\"],\"0$1\"],[\"(\\\\d{2})(\\\\d{8})\",\"$1 $2\",[\"1\"],\"0$1\"]],\"0\"],\"EH\":[\"212\",\"00\",\"[5-8]\\\\d{8}\",[9],0,\"0\",0,0,0,0,0,[[\"528[89]\\\\d{5}\"],[\"(?:6(?:[0-79]\\\\d|8[0-247-9])|7(?:[016-8]\\\\d|2[0-8]|5[0-5]))\\\\d{6}\"],[\"80[0-7]\\\\d{6}\"],[\"89\\\\d{7}\"],0,0,0,0,[\"(?:592(?:4[0-2]|93)|80[89]\\\\d\\\\d)\\\\d{4}\"]]],\"ER\":[\"291\",\"00\",\"[178]\\\\d{6}\",[7],[[\"(\\\\d)(\\\\d{3})(\\\\d{3})\",\"$1 $2 $3\",[\"[178]\"],\"0$1\"]],\"0\"],\"ES\":[\"34\",\"00\",\"[5-9]\\\\d{8}\",[9],[[\"(\\\\d{3})(\\\\d{3})(\\\\d{3})\",\"$1 $2 $3\",[\"[89]00\"]],[\"(\\\\d{3})(\\\\d{2})(\\\\d{2})(\\\\d{2})\",\"$1 $2 $3 $4\",[\"[5-9]\"]]]],\"ET\":[\"251\",\"00\",\"(?:11|[2-57-9]\\\\d)\\\\d{7}\",[9],[[\"(\\\\d{2})(\\\\d{3})(\\\\d{4})\",\"$1 $2 $3\",[\"[1-57-9]\"],\"0$1\"]],\"0\"],\"FI\":[\"358\",\"00|99(?:[01469]|5(?:[14]1|3[23]|5[59]|77|88|9[09]))\",\"[1-35689]\\\\d{4}|7\\\\d{10,11}|(?:[124-7]\\\\d|3[0-46-9])\\\\d{8}|[1-9]\\\\d{5,8}\",[5,6,7,8,9,10,11,12],[[\"(\\\\d{5})\",\"$1\",[\"20[2-59]\"],\"0$1\"],[\"(\\\\d{3})(\\\\d{3,7})\",\"$1 $2\",[\"(?:[1-3]0|[68])0|70[07-9]\"],\"0$1\"],[\"(\\\\d{2})(\\\\d{4,8})\",\"$1 $2\",[\"[14]|2[09]|50|7[135]\"],\"0$1\"],[\"(\\\\d{2})(\\\\d{6,10})\",\"$1 $2\",[\"7\"],\"0$1\"],[\"(\\\\d)(\\\\d{4,9})\",\"$1 $2\",[\"(?:19|[2568])[1-8]|3(?:0[1-9]|[1-9])|9\"],\"0$1\"]],\"0\",0,0,0,0,\"1[03-79]|[2-9]\",0,\"00\"],\"FJ\":[\"679\",\"0(?:0|52)\",\"45\\\\d{5}|(?:0800\\\\d|[235-9])\\\\d{6}\",[7,11],[[\"(\\\\d{3})(\\\\d{4})\",\"$1 $2\",[\"[235-9]|45\"]],[\"(\\\\d{4})(\\\\d{3})(\\\\d{4})\",\"$1 $2 $3\",[\"0\"]]],0,0,0,0,0,0,0,\"00\"],\"FK\":[\"500\",\"00\",\"[2-7]\\\\d{4}\",[5]],\"FM\":[\"691\",\"00\",\"(?:[39]\\\\d\\\\d|820)\\\\d{4}\",[7],[[\"(\\\\d{3})(\\\\d{4})\",\"$1 $2\",[\"[389]\"]]]],\"FO\":[\"298\",\"00\",\"[2-9]\\\\d{5}\",[6],[[\"(\\\\d{6})\",\"$1\",[\"[2-9]\"]]],0,0,\"(10(?:01|[12]0|88))\"],\"FR\":[\"33\",\"00\",\"[1-9]\\\\d{8}\",[9],[[\"(\\\\d{3})(\\\\d{2})(\\\\d{2})(\\\\d{2})\",\"$1 $2 $3 $4\",[\"8\"],\"0 $1\"],[\"(\\\\d)(\\\\d{2})(\\\\d{2})(\\\\d{2})(\\\\d{2})\",\"$1 $2 $3 $4 $5\",[\"[1-79]\"],\"0$1\"]],\"0\"],\"GA\":[\"241\",\"00\",\"(?:[067]\\\\d|11)\\\\d{6}|[2-7]\\\\d{6}\",[7,8],[[\"(\\\\d)(\\\\d{2})(\\\\d{2})(\\\\d{2})\",\"$1 $2 $3 $4\",[\"[2-7]\"],\"0$1\"],[\"(\\\\d{2})(\\\\d{2})(\\\\d{2})(\\\\d{2})\",\"$1 $2 $3 $4\",[\"0\"]],[\"(\\\\d{2})(\\\\d{2})(\\\\d{2})(\\\\d{2})\",\"$1 $2 $3 $4\",[\"11|[67]\"],\"0$1\"]],0,0,\"0(11\\\\d{6}|60\\\\d{6}|61\\\\d{6}|6[256]\\\\d{6}|7[467]\\\\d{6})\",\"$1\"],\"GB\":[\"44\",\"00\",\"[1-357-9]\\\\d{9}|[18]\\\\d{8}|8\\\\d{6}\",[7,9,10],[[\"(\\\\d{3})(\\\\d{4})\",\"$1 $2\",[\"800\",\"8001\",\"80011\",\"800111\",\"8001111\"],\"0$1\"],[\"(\\\\d{3})(\\\\d{2})(\\\\d{2})\",\"$1 $2 $3\",[\"845\",\"8454\",\"84546\",\"845464\"],\"0$1\"],[\"(\\\\d{3})(\\\\d{6})\",\"$1 $2\",[\"800\"],\"0$1\"],[\"(\\\\d{5})(\\\\d{4,5})\",\"$1 $2\",[\"1(?:38|5[23]|69|76|94)\",\"1(?:(?:38|69)7|5(?:24|39)|768|946)\",\"1(?:3873|5(?:242|39[4-6])|(?:697|768)[347]|9467)\"],\"0$1\"],[\"(\\\\d{4})(\\\\d{5,6})\",\"$1 $2\",[\"1(?:[2-69][02-9]|[78])\"],\"0$1\"],[\"(\\\\d{2})(\\\\d{4})(\\\\d{4})\",\"$1 $2 $3\",[\"[25]|7(?:0|6[02-9])\",\"[25]|7(?:0|6(?:[03-9]|2[356]))\"],\"0$1\"],[\"(\\\\d{4})(\\\\d{6})\",\"$1 $2\",[\"7\"],\"0$1\"],[\"(\\\\d{3})(\\\\d{3})(\\\\d{4})\",\"$1 $2 $3\",[\"[1389]\"],\"0$1\"]],\"0\",0,\"0|180020\",0,0,0,[[\"(?:1(?:1(?:3(?:[0-58]\\\\d\\\\d|73[0-5])|4(?:(?:[0-5]\\\\d|70)\\\\d|69[7-9])|(?:(?:5[0-26-9]|[78][0-49])\\\\d|6(?:[0-4]\\\\d|5[01]))\\\\d)|(?:2(?:(?:0[024-9]|2[3-9]|3[3-79]|4[1-689]|[58][02-9]|6[0-47-9]|7[013-9]|9\\\\d)\\\\d|1(?:[0-7]\\\\d|8[0-3]))|(?:3(?:0\\\\d|1[0-8]|[25][02-9]|3[02-579]|[468][0-46-9]|7[1-35-79]|9[2-578])|4(?:0[03-9]|[137]\\\\d|[28][02-57-9]|4[02-69]|5[0-8]|[69][0-79])|5(?:0[1-35-9]|[16]\\\\d|2[024-9]|3[015689]|4[02-9]|5[03-9]|7[0-35-9]|8[0-468]|9[0-57-9])|6(?:0[034689]|1\\\\d|2[0-35689]|[38][013-9]|4[1-467]|5[0-69]|6[13-9]|7[0-8]|9[0-24578])|7(?:0[0246-9]|2\\\\d|3[0236-8]|4[03-9]|5[0-46-9]|6[013-9]|7[0-35-9]|8[024-9]|9[02-9])|8(?:0[35-9]|2[1-57-9]|3[02-578]|4[0-578]|5[124-9]|6[2-69]|7\\\\d|8[02-9]|9[02569])|9(?:0[02-589]|[18]\\\\d|2[02-689]|3[1-57-9]|4[2-9]|5[0-579]|6[2-47-9]|7[0-24578]|9[2-57]))\\\\d)\\\\d)|2(?:0[013478]|3[0189]|4[017]|8[0-46-9]|9[0-2])\\\\d{3})\\\\d{4}|1(?:2(?:0(?:46[1-4]|87[2-9])|545[1-79]|76(?:2\\\\d|3[1-8]|6[1-6])|9(?:7(?:2[0-4]|3[2-5])|8(?:2[2-8]|7[0-47-9]|8[3-5])))|3(?:6(?:38[2-5]|47[23])|8(?:47[04-9]|64[0157-9]))|4(?:044[1-7]|20(?:2[23]|8\\\\d)|6(?:0(?:30|5[2-57]|6[1-8]|7[2-8])|140)|8(?:052|87[1-3]))|5(?:2(?:4(?:3[2-79]|6\\\\d)|76\\\\d)|6(?:26[06-9]|686))|6(?:06(?:4\\\\d|7[4-79])|295[5-7]|35[34]\\\\d|47(?:24|61)|59(?:5[08]|6[67]|74)|9(?:55[0-4]|77[23]))|7(?:26(?:6[13-9]|7[0-7])|(?:442|688)\\\\d|50(?:2[0-3]|[3-68]2|76))|8(?:27[56]\\\\d|37(?:5[2-5]|8[239])|843[2-58])|9(?:0(?:0(?:6[1-8]|85)|52\\\\d)|3583|4(?:66[1-8]|9(?:2[01]|81))|63(?:23|3[1-4])|9561))\\\\d{3}\",[9,10]],[\"7(?:457[0-57-9]|700[01]|911[028])\\\\d{5}|7(?:[1-3]\\\\d\\\\d|4(?:[0-46-9]\\\\d|5[0-689])|5(?:0[0-8]|[13-9]\\\\d|2[0-35-9])|7(?:0[1-9]|[1-7]\\\\d|8[02-9]|9[0-689])|8(?:[014-9]\\\\d|[23][0-8])|9(?:[024-9]\\\\d|1[02-9]|3[0-689]))\\\\d{6}\",[10]],[\"80[08]\\\\d{7}|800\\\\d{6}|8001111\"],[\"(?:8(?:4[2-5]|7[0-3])|9(?:[01]\\\\d|8[2-49]))\\\\d{7}|845464\\\\d\",[7,10]],[\"70\\\\d{8}\",[10]],0,[\"(?:3[0347]|55)\\\\d{8}\",[10]],[\"76(?:464|652)\\\\d{5}|76(?:0[0-28]|2[356]|34|4[01347]|5[49]|6[0-369]|77|8[14]|9[139])\\\\d{6}\",[10]],[\"56\\\\d{8}\",[10]]],0,\" x\"],\"GD\":[\"1\",\"011\",\"(?:473|[58]\\\\d\\\\d|900)\\\\d{7}\",[10],0,\"1\",0,\"([2-9]\\\\d{6})$|1\",\"473$1\",0,\"473\"],\"GE\":[\"995\",\"00\",\"(?:[3-57]\\\\d\\\\d|800)\\\\d{6}\",[9],[[\"(\\\\d{3})(\\\\d{3})(\\\\d{3})\",\"$1 $2 $3\",[\"70\"],\"0$1\"],[\"(\\\\d{2})(\\\\d{3})(\\\\d{2})(\\\\d{2})\",\"$1 $2 $3 $4\",[\"32\"],\"0$1\"],[\"(\\\\d{3})(\\\\d{2})(\\\\d{2})(\\\\d{2})\",\"$1 $2 $3 $4\",[\"[57]\"]],[\"(\\\\d{3})(\\\\d{2})(\\\\d{2})(\\\\d{2})\",\"$1 $2 $3 $4\",[\"[348]\"],\"0$1\"]],\"0\"],\"GF\":[\"594\",\"00\",\"(?:694\\\\d|7093)\\\\d{5}|(?:59|[89]\\\\d)\\\\d{7}\",[9],[[\"(\\\\d{3})(\\\\d{2})(\\\\d{2})(\\\\d{2})\",\"$1 $2 $3 $4\",[\"[5-7]|80[6-9]|9[47]\"],\"0$1\"],[\"(\\\\d{3})(\\\\d{2})(\\\\d{2})(\\\\d{2})\",\"$1 $2 $3 $4\",[\"[89]\"],\"0$1\"]],\"0\"],\"GG\":[\"44\",\"00\",\"(?:1481|[357-9]\\\\d{3})\\\\d{6}|8\\\\d{6}(?:\\\\d{2})?\",[7,9,10],0,\"0\",0,\"([25-9]\\\\d{5})$|0|180020\",\"1481$1\",0,0,[[\"1481[25-9]\\\\d{5}\",[10]],[\"7(?:(?:781|839)\\\\d|911[17])\\\\d{5}\",[10]],[\"80[08]\\\\d{7}|800\\\\d{6}|8001111\"],[\"(?:8(?:4[2-5]|7[0-3])|9(?:[01]\\\\d|8[0-3]))\\\\d{7}|845464\\\\d\",[7,10]],[\"70\\\\d{8}\",[10]],0,[\"(?:3[0347]|55)\\\\d{8}\",[10]],[\"76(?:464|652)\\\\d{5}|76(?:0[0-28]|2[356]|34|4[01347]|5[49]|6[0-369]|77|8[14]|9[139])\\\\d{6}\",[10]],[\"56\\\\d{8}\",[10]]]],\"GH\":[\"233\",\"00\",\"[235]\\\\d{8}|800\\\\d{5,6}\",[8,9],[[\"(\\\\d{3})(\\\\d{5})\",\"$1 $2\",[\"8\"],\"0$1\"],[\"(\\\\d{2})(\\\\d{3})(\\\\d{4})\",\"$1 $2 $3\",[\"[2358]\"],\"0$1\"]],\"0\"],\"GI\":[\"350\",\"00\",\"(?:[25]\\\\d|60)\\\\d{6}\",[8],[[\"(\\\\d{3})(\\\\d{5})\",\"$1 $2\",[\"2\"]]]],\"GL\":[\"299\",\"00\",\"(?:19|[2-689]\\\\d|70)\\\\d{4}\",[6],[[\"(\\\\d{2})(\\\\d{2})(\\\\d{2})\",\"$1 $2 $3\",[\"19|[2-9]\"]]]],\"GM\":[\"220\",\"00\",\"[2-9]\\\\d{6}\",[7],[[\"(\\\\d{3})(\\\\d{4})\",\"$1 $2\",[\"[2-9]\"]]]],\"GN\":[\"224\",\"00\",\"722\\\\d{6}|(?:3|6\\\\d)\\\\d{7}\",[8,9],[[\"(\\\\d{2})(\\\\d{2})(\\\\d{2})(\\\\d{2})\",\"$1 $2 $3 $4\",[\"3\"]],[\"(\\\\d{3})(\\\\d{2})(\\\\d{2})(\\\\d{2})\",\"$1 $2 $3 $4\",[\"[67]\"]]]],\"GP\":[\"590\",\"00\",\"7090\\\\d{5}|(?:[56]9|[89]\\\\d)\\\\d{7}\",[9],[[\"(\\\\d{3})(\\\\d{2})(\\\\d{2})(\\\\d{2})\",\"$1 $2 $3 $4\",[\"[5-79]|80[6-9]\"],\"0$1\"],[\"(\\\\d{3})(\\\\d{2})(\\\\d{2})(\\\\d{2})\",\"$1 $2 $3 $4\",[\"8\"],\"0$1\"]],\"0\",0,0,0,0,0,[[\"(?:59(?:0(?:0[1-68]|[14][0-24-9]|2[0-68]|3[1-9]|5[3-579]|[68][0-689]|7[08]|9\\\\d)|87\\\\d)|80[6-9]\\\\d\\\\d)\\\\d{4}\"],[\"(?:69(?:0\\\\d\\\\d|1(?:2[2-9]|3[0-5]))|7090[0-4])\\\\d{4}\"],[\"80[0-5]\\\\d{6}\"],[\"8[129]\\\\d{7}\"],0,0,0,0,[\"9(?:(?:39[5-7]|76[018])\\\\d|475[0-6])\\\\d{4}\"]]],\"GQ\":[\"240\",\"00\",\"222\\\\d{6}|(?:3\\\\d|55|[89]0)\\\\d{7}\",[9],[[\"(\\\\d{3})(\\\\d{3})(\\\\d{3})\",\"$1 $2 $3\",[\"[235]\"]],[\"(\\\\d{3})(\\\\d{6})\",\"$1 $2\",[\"[89]\"]]]],\"GR\":[\"30\",\"00\",\"5005000\\\\d{3}|8\\\\d{9,11}|(?:[269]\\\\d|70)\\\\d{8}\",[10,11,12],[[\"(\\\\d{2})(\\\\d{4})(\\\\d{4})\",\"$1 $2 $3\",[\"21|7\"]],[\"(\\\\d{4})(\\\\d{6})\",\"$1 $2\",[\"2(?:2|3[2-57-9]|4[2-469]|5[2-59]|6[2-9]|7[2-69]|8[2-49])|5\"]],[\"(\\\\d{3})(\\\\d{3})(\\\\d{4})\",\"$1 $2 $3\",[\"[2689]\"]],[\"(\\\\d{3})(\\\\d{3,4})(\\\\d{5})\",\"$1 $2 $3\",[\"8\"]]]],\"GT\":[\"502\",\"00\",\"80\\\\d{6}|(?:1\\\\d{3}|[2-7])\\\\d{7}\",[8,11],[[\"(\\\\d{4})(\\\\d{4})\",\"$1 $2\",[\"[2-8]\"]],[\"(\\\\d{4})(\\\\d{3})(\\\\d{4})\",\"$1 $2 $3\",[\"1\"]]]],\"GU\":[\"1\",\"011\",\"(?:[58]\\\\d\\\\d|671|900)\\\\d{7}\",[10],0,\"1\",0,\"([2-9]\\\\d{6})$|1\",\"671$1\",0,\"671\"],\"GW\":[\"245\",\"00\",\"[49]\\\\d{8}|4\\\\d{6}\",[7,9],[[\"(\\\\d{3})(\\\\d{4})\",\"$1 $2\",[\"40\"]],[\"(\\\\d{3})(\\\\d{3})(\\\\d{3})\",\"$1 $2 $3\",[\"[49]\"]]]],\"GY\":[\"592\",\"001\",\"(?:[2-8]\\\\d{3}|9008)\\\\d{3}\",[7],[[\"(\\\\d{3})(\\\\d{4})\",\"$1 $2\",[\"[2-9]\"]]]],\"HK\":[\"852\",\"00(?:30|5[09]|[126-9]?)\",\"8[0-46-9]\\\\d{6,7}|9\\\\d{4,7}|(?:[2-7]|9\\\\d{3})\\\\d{7}\",[5,6,7,8,9,11],[[\"(\\\\d{3})(\\\\d{2,5})\",\"$1 $2\",[\"900\",\"9003\"]],[\"(\\\\d{4})(\\\\d{4})\",\"$1 $2\",[\"[2-7]|8[1-4]|9(?:0[1-9]|[1-8])\"]],[\"(\\\\d{3})(\\\\d{3})(\\\\d{3})\",\"$1 $2 $3\",[\"8\"]],[\"(\\\\d{3})(\\\\d{2})(\\\\d{3})(\\\\d{3})\",\"$1 $2 $3 $4\",[\"9\"]]],0,0,0,0,0,0,0,\"00\"],\"HN\":[\"504\",\"00\",\"8\\\\d{10}|[237-9]\\\\d{7}\",[8,11],[[\"(\\\\d{4})(\\\\d{4})\",\"$1-$2\",[\"[237-9]\"]]]],\"HR\":[\"385\",\"00\",\"[2-69]\\\\d{8}|80\\\\d{5,7}|[1-79]\\\\d{7}|6\\\\d{6}\",[7,8,9],[[\"(\\\\d{2})(\\\\d{2})(\\\\d{3})\",\"$1 $2 $3\",[\"6[01]\"],\"0$1\"],[\"(\\\\d{3})(\\\\d{2})(\\\\d{2,3})\",\"$1 $2 $3\",[\"8\"],\"0$1\"],[\"(\\\\d)(\\\\d{4})(\\\\d{3})\",\"$1 $2 $3\",[\"1\"],\"0$1\"],[\"(\\\\d{2})(\\\\d{3})(\\\\d{3,4})\",\"$1 $2 $3\",[\"6|7[245]\"],\"0$1\"],[\"(\\\\d{2})(\\\\d{3})(\\\\d{3,4})\",\"$1 $2 $3\",[\"9\"],\"0$1\"],[\"(\\\\d{2})(\\\\d{3})(\\\\d{3,4})\",\"$1 $2 $3\",[\"[2-57]\"],\"0$1\"],[\"(\\\\d{3})(\\\\d{3})(\\\\d{3})\",\"$1 $2 $3\",[\"8\"],\"0$1\"]],\"0\"],\"HT\":[\"509\",\"00\",\"[2-589]\\\\d{7}\",[8],[[\"(\\\\d{2})(\\\\d{2})(\\\\d{4})\",\"$1 $2 $3\",[\"[2-589]\"]]]],\"HU\":[\"36\",\"00\",\"[235-7]\\\\d{8}|[1-9]\\\\d{7}\",[8,9],[[\"(\\\\d)(\\\\d{3})(\\\\d{4})\",\"$1 $2 $3\",[\"1\"],\"(06 $1)\"],[\"(\\\\d{2})(\\\\d{3})(\\\\d{3})\",\"$1 $2 $3\",[\"[27][2-9]|3[2-7]|4[24-9]|5[2-79]|6|8[2-57-9]|9[2-69]\"],\"(06 $1)\"],[\"(\\\\d{2})(\\\\d{3})(\\\\d{3,4})\",\"$1 $2 $3\",[\"[2-9]\"],\"06 $1\"]],\"06\"],\"ID\":[\"62\",\"00[89]\",\"00[1-9]\\\\d{9,14}|(?:[1-36]|8\\\\d{5})\\\\d{6}|00\\\\d{9}|[1-9]\\\\d{8,10}|[2-9]\\\\d{7}\",[7,8,9,10,11,12,13,14,15,16,17],[[\"(\\\\d)(\\\\d{3})(\\\\d{3})\",\"$1 $2 $3\",[\"15\"]],[\"(\\\\d{2})(\\\\d{5,9})\",\"$1 $2\",[\"2[124]|[36]1\"],\"(0$1)\"],[\"(\\\\d{3})(\\\\d{5,7})\",\"$1 $2\",[\"800\"],\"0$1\"],[\"(\\\\d{3})(\\\\d{5,8})\",\"$1 $2\",[\"[2-79]\"],\"(0$1)\"],[\"(\\\\d{3})(\\\\d{3,4})(\\\\d{3})\",\"$1-$2-$3\",[\"8[1-35-9]\"],\"0$1\"],[\"(\\\\d{3})(\\\\d{6,8})\",\"$1 $2\",[\"1\"],\"0$1\"],[\"(\\\\d{3})(\\\\d{3})(\\\\d{4})\",\"$1 $2 $3\",[\"804\"],\"0$1\"],[\"(\\\\d{3})(\\\\d)(\\\\d{3})(\\\\d{3})\",\"$1 $2 $3 $4\",[\"80\"],\"0$1\"],[\"(\\\\d{3})(\\\\d{4})(\\\\d{4,5})\",\"$1-$2-$3\",[\"8\"],\"0$1\"]],\"0\"],\"IE\":[\"353\",\"00\",\"(?:1\\\\d|[2569])\\\\d{6,8}|4\\\\d{6,9}|7\\\\d{8}|8\\\\d{8,9}\",[7,8,9,10],[[\"(\\\\d{2})(\\\\d{5})\",\"$1 $2\",[\"2[24-9]|47|58|6[237-9]|9[35-9]\"],\"(0$1)\"],[\"(\\\\d{3})(\\\\d{5})\",\"$1 $2\",[\"[45]0\"],\"(0$1)\"],[\"(\\\\d)(\\\\d{3,4})(\\\\d{4})\",\"$1 $2 $3\",[\"1\"],\"(0$1)\"],[\"(\\\\d{2})(\\\\d{3})(\\\\d{3,4})\",\"$1 $2 $3\",[\"[2569]|4[1-69]|7[14]\"],\"(0$1)\"],[\"(\\\\d{3})(\\\\d{3})(\\\\d{3})\",\"$1 $2 $3\",[\"70\"],\"0$1\"],[\"(\\\\d{3})(\\\\d{3})(\\\\d{3})\",\"$1 $2 $3\",[\"81\"],\"(0$1)\"],[\"(\\\\d{2})(\\\\d{3})(\\\\d{4})\",\"$1 $2 $3\",[\"[78]\"],\"0$1\"],[\"(\\\\d{4})(\\\\d{3})(\\\\d{3})\",\"$1 $2 $3\",[\"1\"]],[\"(\\\\d{2})(\\\\d{4})(\\\\d{4})\",\"$1 $2 $3\",[\"4\"],\"(0$1)\"],[\"(\\\\d{2})(\\\\d)(\\\\d{3})(\\\\d{4})\",\"$1 $2 $3 $4\",[\"8\"],\"0$1\"]],\"0\"],\"IL\":[\"972\",\"0(?:0|1[2-9])\",\"1\\\\d{6}(?:\\\\d{3,5})?|[57]\\\\d{8}|[1-489]\\\\d{7}\",[7,8,9,10,11,12],[[\"(\\\\d{4})(\\\\d{3})\",\"$1-$2\",[\"125\"]],[\"(\\\\d{4})(\\\\d{2})(\\\\d{2})\",\"$1-$2-$3\",[\"121\"]],[\"(\\\\d)(\\\\d{3})(\\\\d{4})\",\"$1-$2-$3\",[\"[2-489]\"],\"0$1\"],[\"(\\\\d{2})(\\\\d{3})(\\\\d{4})\",\"$1-$2-$3\",[\"[57]\"],\"0$1\"],[\"(\\\\d{4})(\\\\d{3})(\\\\d{3})\",\"$1-$2-$3\",[\"12\"]],[\"(\\\\d{4})(\\\\d{6})\",\"$1-$2\",[\"159\"]],[\"(\\\\d)(\\\\d{3})(\\\\d{3})(\\\\d{3})\",\"$1-$2-$3-$4\",[\"1[7-9]\"]],[\"(\\\\d{3})(\\\\d{1,2})(\\\\d{3})(\\\\d{4})\",\"$1-$2 $3-$4\",[\"15\"]]],\"0\"],\"IM\":[\"44\",\"00\",\"1624\\\\d{6}|(?:[3578]\\\\d|90)\\\\d{8}\",[10],0,\"0\",0,\"([25-8]\\\\d{5})$|0|180020\",\"1624$1\",0,\"74576|(?:16|7[56])24\"],\"IN\":[\"91\",\"00\",\"(?:000800|[2-9]\\\\d\\\\d)\\\\d{7}|1\\\\d{7,12}\",[8,9,10,11,12,13],[[\"(\\\\d{8})\",\"$1\",[\"5(?:0|2[23]|3[03]|[67]1|88)\",\"5(?:0|2(?:21|3)|3(?:0|3[23])|616|717|888)\",\"5(?:0|2(?:21|3)|3(?:0|3[23])|616|717|8888)\"],0,1],[\"(\\\\d{4})(\\\\d{4,5})\",\"$1 $2\",[\"180\",\"1800\"],0,1],[\"(\\\\d{3})(\\\\d{3})(\\\\d{4})\",\"$1 $2 $3\",[\"140\"],0,1],[\"(\\\\d{2})(\\\\d{4})(\\\\d{4})\",\"$1 $2 $3\",[\"11|2[02]|33|4[04]|79[1-7]|80[2-46]\",\"11|2[02]|33|4[04]|79(?:[1-6]|7[19])|80(?:[2-4]|6[0-589])\",\"11|2[02]|33|4[04]|79(?:[124-6]|3(?:[02-9]|1[0-24-9])|7(?:1|9[1-6]))|80(?:[2-4]|6[0-589])\"],\"0$1\",1],[\"(\\\\d{3})(\\\\d{3})(\\\\d{4})\",\"$1 $2 $3\",[\"1(?:2[0-249]|3[0-25]|4[145]|[68]|7[1257])|2(?:1[257]|3[013]|4[01]|5[0137]|6[0158]|78|8[1568])|3(?:26|4[1-3]|5[34]|6[01489]|7[02-46]|8[159])|4(?:1[36]|2[1-47]|5[12]|6[0-26-9]|7[0-24-9]|8[013-57]|9[014-7])|5(?:1[025]|22|[36][25]|4[28]|5[12]|[78]1)|6(?:12|[2-4]1|5[17]|6[13]|80)|7(?:12|3[134]|61|88)|8(?:16|2[014]|3[126]|6[136]|7[078]|8[34]|91)|(?:43|59|75)[15]|(?:1[59]|29|67)[14]\",\"1(?:2[0-24]|3[0-25]|4[145]|[59][14]|6[1-9]|7[1257]|8[1-57-9])|2(?:1[257]|3[013]|4[01]|5[0137]|6[058]|78|8[1568]|9[14])|3(?:26|4[1-3]|5[34]|6[01489]|7[02-46]|8[159])|4(?:1[36]|2[1-47]|3[15]|5[12]|6[0-26-9]|7[0-24-9]|8[013-57]|9[014-7])|5(?:1[025]|22|[36][25]|4[28]|[578]1|9[15])|674|7(?:(?:3[34]|5[15])[2-6]|61[346]|88[0-8])|8(?:70[2-6]|84[235-7]|91[3-7])|(?:1(?:29|60|8[06])|261|552|6(?:12|[2-47]1|5[17]|6[13]|80)|7(?:12|31)|8(?:16|2[014]|3[126]|6[136]|7[78]|83))[2-7]\",\"1(?:2[0-24]|3[0-25]|4[145]|[59][14]|6[1-9]|7[1257]|8[1-57-9])|2(?:1[257]|3[013]|4[01]|5[0137]|6[058]|78|8[1568]|9[14])|3(?:26|4[1-3]|5[34]|6[01489]|7[02-46]|8[159])|4(?:1[36]|2[1-47]|3[15]|5[12]|6[0-26-9]|7[0-24-9]|8[013-57]|9[014-7])|5(?:1[025]|22|[36][25]|4[28]|[578]1|9[15])|6(?:12(?:[2-6]|7[0-8])|74[2-7])|7(?:3171|5[15][2-6]|61[346]|88(?:[2-7]|82))|8(?:70[2-6]|84(?:[2356]|7[19])|91(?:[3-6]|7[19]))|73[134][2-6]|8(?:16|2[014]|3[126]|6[136]|7[78]|83)(?:[2-6]|7[19])|(?:1(?:29|60|8[06])|261|552|6(?:[2-4]1|5[17]|6[13]|7(?:1|4[0189])|80)|7(?:12|88[01]))[2-7]\"],\"0$1\",1],[\"(\\\\d{4})(\\\\d{3})(\\\\d{3})\",\"$1 $2 $3\",[\"1(?:[2-479]|5[0235-9])|[2-5]|6(?:1[1358]|2[2457-9]|3[2-5]|4[235-7]|5[2-689]|6[24578]|7[235689]|8[1-6])|7(?:1[013-9]|3[129]|5[29]|6[02-5]|70)|807\",\"1(?:[2-479]|5[0235-9])|[2-5]|6(?:1[1358]|2(?:[2457]|84|95)|3(?:[2-4]|55)|4[235-7]|5[2-689]|6[24578]|7(?:[23569]|8[0-57-9])|8[1-6])|7(?:1(?:[013-8]|9[6-9])|3(?:17|2[0-49]|9[2-57])|5(?:2[1-3]|9[0-6])|6(?:0[5689]|2[5-9]|3[02-8]|4|5[0-367])|70[13-7])|807[19]\",\"1(?:[2-479]|5(?:[0236-9]|5[013-9]))|[2-5]|6(?:2(?:84|95)|355|8(?:28[235-7]|3))|73179|807(?:1|9[1-3])|(?:1552|6(?:(?:1[1358]|2[2457]|3[2-4]|4[235-7]|5[2-689]|6[24578])\\\\d|7(?:[23569]\\\\d|8[0-57-9])|8(?:[14-6]\\\\d|2[0-79]))|7(?:1(?:[013-8]\\\\d|9[6-9])|3(?:2[0-49]|9[2-57])|5(?:2[1-3]|9[0-6])|6(?:0[5689]|2[5-9]|3[02-8]|4\\\\d|5[0-367])|70[13-7]))[2-7]\"],\"0$1\",1],[\"(\\\\d{5})(\\\\d{5})\",\"$1 $2\",[\"16|[6-9]\"],\"0$1\",1],[\"(\\\\d{4})(\\\\d{2,4})(\\\\d{4})\",\"$1 $2 $3\",[\"18[06]\",\"18[06]0\"],0,1],[\"(\\\\d{4})(\\\\d{3})(\\\\d{3})(\\\\d{3})\",\"$1 $2 $3 $4\",[\"18\"],0,1]],\"0\"],\"IO\":[\"246\",\"00\",\"3\\\\d{6}\",[7],[[\"(\\\\d{3})(\\\\d{4})\",\"$1 $2\",[\"3\"]]]],\"IQ\":[\"964\",\"00\",\"(?:1|7\\\\d\\\\d)\\\\d{7}|[2-6]\\\\d{7,8}\",[8,9,10],[[\"(\\\\d)(\\\\d{3})(\\\\d{4})\",\"$1 $2 $3\",[\"1\"],\"0$1\"],[\"(\\\\d{2})(\\\\d{3})(\\\\d{3,4})\",\"$1 $2 $3\",[\"[2-6]\"],\"0$1\"],[\"(\\\\d{3})(\\\\d{3})(\\\\d{4})\",\"$1 $2 $3\",[\"7\"],\"0$1\"]],\"0\"],\"IR\":[\"98\",\"00\",\"[1-9]\\\\d{9}|(?:[1-8]\\\\d\\\\d|9)\\\\d{3,4}\",[4,5,6,7,10],[[\"(\\\\d{4,5})\",\"$1\",[\"96\"],\"0$1\"],[\"(\\\\d{2})(\\\\d{4,5})\",\"$1 $2\",[\"(?:1[137]|2[13-68]|3[1458]|4[145]|5[1468]|6[16]|7[1467]|8[13467])[12689]\"],\"0$1\"],[\"(\\\\d{3})(\\\\d{3})(\\\\d{3,4})\",\"$1 $2 $3\",[\"9\"],\"0$1\"],[\"(\\\\d{2})(\\\\d{4})(\\\\d{4})\",\"$1 $2 $3\",[\"[1-8]\"],\"0$1\"]],\"0\"],\"IS\":[\"354\",\"00|1(?:0(?:01|[12]0)|100)\",\"(?:38\\\\d|[4-9])\\\\d{6}\",[7,9],[[\"(\\\\d{3})(\\\\d{4})\",\"$1 $2\",[\"[4-9]\"]],[\"(\\\\d{3})(\\\\d{3})(\\\\d{3})\",\"$1 $2 $3\",[\"3\"]]],0,0,0,0,0,0,0,\"00\"],\"IT\":[\"39\",\"00\",\"0\\\\d{5,11}|1\\\\d{8,10}|3(?:[0-8]\\\\d{7,10}|9\\\\d{7,8})|(?:43|55|70)\\\\d{8}|8\\\\d{5}(?:\\\\d{2,4})?\",[6,7,8,9,10,11,12],[[\"(\\\\d{2})(\\\\d{4,6})\",\"$1 $2\",[\"0[26]\"]],[\"(\\\\d{3})(\\\\d{3,6})\",\"$1 $2\",[\"0[13-57-9][0159]|8(?:03|4[17]|9[2-5])\",\"0[13-57-9][0159]|8(?:03|4[17]|9(?:2|3[04]|[45][0-4]))\"]],[\"(\\\\d{4})(\\\\d{2,6})\",\"$1 $2\",[\"0(?:[13-579][2-46-8]|8[236-8])\"]],[\"(\\\\d{4})(\\\\d{4})\",\"$1 $2\",[\"894\"]],[\"(\\\\d{2})(\\\\d{3,4})(\\\\d{4})\",\"$1 $2 $3\",[\"0[26]|5\"]],[\"(\\\\d{3})(\\\\d{3})(\\\\d{3,4})\",\"$1 $2 $3\",[\"1(?:44|[679])|[378]|43\"]],[\"(\\\\d{3})(\\\\d{3,4})(\\\\d{4})\",\"$1 $2 $3\",[\"0[13-57-9][0159]|14\"]],[\"(\\\\d{2})(\\\\d{4})(\\\\d{5})\",\"$1 $2 $3\",[\"0[26]\"]],[\"(\\\\d{4})(\\\\d{3})(\\\\d{4})\",\"$1 $2 $3\",[\"0\"]],[\"(\\\\d{3})(\\\\d{4})(\\\\d{4,5})\",\"$1 $2 $3\",[\"[03]\"]]],0,0,0,0,0,0,[[\"0(?:669[0-79]\\\\d{1,6}|831\\\\d{2,8})|0(?:1(?:[0159]\\\\d|[27][1-5]|31|4[1-4]|6[1356]|8[2-57])|2\\\\d\\\\d|3(?:[0159]\\\\d|2[1-4]|3[12]|[48][1-6]|6[2-59]|7[1-7])|4(?:[0159]\\\\d|[23][1-9]|4[245]|6[1-5]|7[1-4]|81)|5(?:[0159]\\\\d|2[1-5]|3[2-6]|4[1-79]|6[4-6]|7[1-578]|8[3-8])|6(?:[0-57-9]\\\\d|6[0-8])|7(?:[0159]\\\\d|2[12]|3[1-7]|4[2-46]|6[13569]|7[13-6]|8[1-59])|8(?:[0159]\\\\d|2[3-578]|3[2356]|[6-8][1-5])|9(?:[0159]\\\\d|[238][1-5]|4[12]|6[1-8]|7[1-6]))\\\\d{2,7}\"],[\"3[2-9]\\\\d{7,8}|(?:31|43)\\\\d{8}\",[9,10]],[\"80(?:0\\\\d{3}|3)\\\\d{3}\",[6,9]],[\"(?:0878\\\\d{3}|89(?:2\\\\d|3[04]|4(?:[0-4]|[5-9]\\\\d\\\\d)|5[0-4]))\\\\d\\\\d|(?:1(?:44|6[346])|89(?:38|5[5-9]|9))\\\\d{6}\",[6,8,9,10]],[\"1(?:78\\\\d|99)\\\\d{6}\",[9,10]],[\"3[2-8]\\\\d{9,10}\",[11,12]],0,0,[\"55\\\\d{8}\",[10]],[\"84(?:[08]\\\\d{3}|[17])\\\\d{3}\",[6,9]]]],\"JE\":[\"44\",\"00\",\"1534\\\\d{6}|(?:[3578]\\\\d|90)\\\\d{8}\",[10],0,\"0\",0,\"([0-24-8]\\\\d{5})$|0|180020\",\"1534$1\",0,0,[[\"1534[0-24-8]\\\\d{5}\"],[\"7(?:(?:(?:50|82)9|937)\\\\d|7(?:00[378]|97\\\\d))\\\\d{5}\"],[\"80(?:07(?:35|81)|8901)\\\\d{4}\"],[\"(?:8(?:4(?:4(?:4(?:05|42|69)|703)|5(?:041|800))|7(?:0002|1206))|90(?:066[59]|1810|71(?:07|55)))\\\\d{4}\"],[\"701511\\\\d{4}\"],0,[\"(?:3(?:0(?:07(?:35|81)|8901)|3\\\\d{4}|4(?:4(?:4(?:05|42|69)|703)|5(?:041|800))|7(?:0002|1206))|55\\\\d{4})\\\\d{4}\"],[\"76(?:464|652)\\\\d{5}|76(?:0[0-28]|2[356]|34|4[01347]|5[49]|6[0-369]|77|8[14]|9[139])\\\\d{6}\"],[\"56\\\\d{8}\"]]],\"JM\":[\"1\",\"011\",\"(?:[58]\\\\d\\\\d|658|900)\\\\d{7}\",[10],0,\"1\",0,0,0,0,\"658|876\"],\"JO\":[\"962\",\"00\",\"(?:(?:[2689]|7\\\\d)\\\\d|32|427|53)\\\\d{6}\",[8,9],[[\"(\\\\d)(\\\\d{3})(\\\\d{4})\",\"$1 $2 $3\",[\"[2356]|87\"],\"(0$1)\"],[\"(\\\\d{3})(\\\\d{5,6})\",\"$1 $2\",[\"[89]\"],\"0$1\"],[\"(\\\\d{2})(\\\\d{7})\",\"$1 $2\",[\"70\"],\"0$1\"],[\"(\\\\d)(\\\\d{4})(\\\\d{4})\",\"$1 $2 $3\",[\"[47]\"],\"0$1\"]],\"0\"],\"JP\":[\"81\",\"010\",\"00[1-9]\\\\d{6,14}|[25-9]\\\\d{9}|(?:00|[1-9]\\\\d\\\\d)\\\\d{6}\",[8,9,10,11,12,13,14,15,16,17],[[\"(\\\\d{3})(\\\\d{3})(\\\\d{3})\",\"$1-$2-$3\",[\"(?:12|57|99)0\"],\"0$1\"],[\"(\\\\d{4})(\\\\d)(\\\\d{4})\",\"$1-$2-$3\",[\"1(?:26|3[79]|4[56]|5[4-68]|6[3-5])|499|5(?:76|97)|746|8(?:3[89]|47|51)|9(?:80|9[16])\",\"1(?:267|3(?:7[247]|9[278])|466|5(?:47|58|64)|6(?:3[245]|48|5[4-68]))|499[2468]|5(?:76|97)9|7468|8(?:3(?:8[7-9]|96)|477|51[2-9])|9(?:802|9(?:1[23]|69))|1(?:45|58)[67]\",\"1(?:267|3(?:7[247]|9[278])|466|5(?:47|58|64)|6(?:3[245]|48|5[4-68]))|499[2468]|5(?:769|979[2-69])|7468|8(?:3(?:8[7-9]|96[2457-9])|477|51[2-9])|9(?:802|9(?:1[23]|69))|1(?:45|58)[67]\"],\"0$1\"],[\"(\\\\d{2})(\\\\d{3})(\\\\d{4})\",\"$1-$2-$3\",[\"60\"],\"0$1\"],[\"(\\\\d)(\\\\d{4})(\\\\d{4})\",\"$1-$2-$3\",[\"3|4(?:2[09]|7[01])|6[1-9]\",\"3|4(?:2(?:0|9[02-69])|7(?:0[019]|1))|6[1-9]\"],\"0$1\"],[\"(\\\\d{2})(\\\\d{3})(\\\\d{4})\",\"$1-$2-$3\",[\"1(?:1|5[45]|77|88|9[69])|2(?:2[1-37]|3[0-269]|4[59]|5|6[24]|7[1-358]|8[1369]|9[0-38])|4(?:[28][1-9]|3[0-57]|[45]|6[248]|7[2-579]|9[29])|5(?:2|3[0459]|4[0-369]|5[29]|8[02389]|9[0-389])|7(?:2[02-46-9]|34|[58]|6[0249]|7[57]|9[2-6])|8(?:2[124589]|3[26-9]|49|51|6|7[0-468]|8[68]|9[019])|9(?:[23][1-9]|4[15]|5[138]|6[1-3]|7[156]|8[189]|9[1-489])\",\"1(?:1|5(?:4[018]|5[017])|77|88|9[69])|2(?:2(?:[127]|3[014-9])|3[0-269]|4[59]|5(?:[1-3]|5[0-69]|9[19])|62|7(?:[1-35]|8[0189])|8(?:[16]|3[0134]|9[0-5])|9(?:[028]|17))|4(?:2(?:[13-79]|8[014-6])|3[0-57]|[45]|6[248]|7[2-47]|8[1-9]|9[29])|5(?:2|3(?:[045]|9[0-8])|4[0-369]|5[29]|8[02389]|9[0-3])|7(?:2[02-46-9]|34|[58]|6[0249]|7[57]|9(?:[23]|4[0-59]|5[01569]|6[0167]))|8(?:2(?:[1258]|4[0-39]|9[0-2469])|3(?:[29]|60)|49|51|6(?:[0-24]|36|5[0-3589]|7[23]|9[01459])|7[0-468]|8[68])|9(?:[23][1-9]|4[15]|5[138]|6[1-3]|7[156]|8[189]|9(?:[1289]|3[34]|4[0178]))|(?:264|837)[016-9]|2(?:57|93)[015-9]|(?:25[0468]|422|838)[01]|(?:47[59]|59[89]|8(?:6[68]|9))[019]\",\"1(?:1|5(?:4[018]|5[017])|77|88|9[69])|2(?:2[127]|3[0-269]|4[59]|5(?:[1-3]|5[0-69]|9(?:17|99))|6(?:2|4[016-9])|7(?:[1-35]|8[0189])|8(?:[16]|3[0134]|9[0-5])|9(?:[028]|17))|4(?:2(?:[13-79]|8[014-6])|3[0-57]|[45]|6[248]|7[2-47]|9[29])|5(?:2|3(?:[045]|9(?:[0-58]|6[4-9]|7[0-35689]))|4[0-369]|5[29]|8[02389]|9[0-3])|7(?:2[02-46-9]|34|[58]|6[0249]|7[57]|9(?:[23]|4[0-59]|5[01569]|6[0167]))|8(?:2(?:[1258]|4[0-39]|9[0169])|3(?:[29]|60|7(?:[017-9]|6[6-8]))|49|51|6(?:[0-24]|36[2-57-9]|5(?:[0-389]|5[23])|6(?:[01]|9[178])|7(?:2[2-468]|3[78])|9[0145])|7[0-468]|8[68])|9(?:4[15]|5[138]|7[156]|8[189]|9(?:[1289]|3(?:31|4[357])|4[0178]))|(?:8294|96)[1-3]|2(?:57|93)[015-9]|(?:223|8699)[014-9]|(?:25[0468]|422|838)[01]|(?:48|8292|9[23])[1-9]|(?:47[59]|59[89]|8(?:68|9))[019]\"],\"0$1\"],[\"(\\\\d{3})(\\\\d{2})(\\\\d{4})\",\"$1-$2-$3\",[\"[14]|[289][2-9]|5[3-9]|7[2-4679]\"],\"0$1\"],[\"(\\\\d{3})(\\\\d{3})(\\\\d{4})\",\"$1-$2-$3\",[\"800\"],\"0$1\"],[\"(\\\\d{2})(\\\\d{4})(\\\\d{4})\",\"$1-$2-$3\",[\"[25-9]\"],\"0$1\"]],\"0\",0,\"(000[2569]\\\\d{4,6})$|(?:(?:003768)0?)|0\",\"$1\"],\"KE\":[\"254\",\"000\",\"(?:[17]\\\\d\\\\d|900)\\\\d{6}|(?:2|80)0\\\\d{6,7}|[4-6]\\\\d{6,8}\",[7,8,9,10],[[\"(\\\\d{2})(\\\\d{5,7})\",\"$1 $2\",[\"[24-6]\"],\"0$1\"],[\"(\\\\d{3})(\\\\d{6})\",\"$1 $2\",[\"[17]\"],\"0$1\"],[\"(\\\\d{3})(\\\\d{3})(\\\\d{3,4})\",\"$1 $2 $3\",[\"[89]\"],\"0$1\"]],\"0\"],\"KG\":[\"996\",\"00\",\"8\\\\d{9}|[235-9]\\\\d{8}\",[9,10],[[\"(\\\\d{4})(\\\\d{5})\",\"$1 $2\",[\"3(?:1[346]|[24-79])\"],\"0$1\"],[\"(\\\\d{3})(\\\\d{3})(\\\\d{3})\",\"$1 $2 $3\",[\"[235-79]|88\"],\"0$1\"],[\"(\\\\d{3})(\\\\d{3})(\\\\d)(\\\\d{2,3})\",\"$1 $2 $3 $4\",[\"8\"],\"0$1\"]],\"0\"],\"KH\":[\"855\",\"00[14-9]\",\"1\\\\d{9}|[1-9]\\\\d{7,8}\",[8,9,10],[[\"(\\\\d{2})(\\\\d{3})(\\\\d{3,4})\",\"$1 $2 $3\",[\"[1-9]\"],\"0$1\"],[\"(\\\\d{4})(\\\\d{3})(\\\\d{3})\",\"$1 $2 $3\",[\"1\"]]],\"0\"],\"KI\":[\"686\",\"00\",\"(?:[37]\\\\d|6[0-79])\\\\d{6}|(?:[2-48]\\\\d|50)\\\\d{3}\",[5,8],0,\"0\"],\"KM\":[\"269\",\"00\",\"[3478]\\\\d{6}\",[7],[[\"(\\\\d{3})(\\\\d{2})(\\\\d{2})\",\"$1 $2 $3\",[\"[3478]\"]]]],\"KN\":[\"1\",\"011\",\"(?:[58]\\\\d\\\\d|900)\\\\d{7}\",[10],0,\"1\",0,\"([2-7]\\\\d{6})$|1\",\"869$1\",0,\"869\"],\"KP\":[\"850\",\"00|99\",\"85\\\\d{6}|(?:19\\\\d|[2-7])\\\\d{7}\",[8,10],[[\"(\\\\d{2})(\\\\d{3})(\\\\d{3})\",\"$1 $2 $3\",[\"8\"],\"0$1\"],[\"(\\\\d)(\\\\d{3})(\\\\d{4})\",\"$1 $2 $3\",[\"[2-7]\"],\"0$1\"],[\"(\\\\d{3})(\\\\d{3})(\\\\d{4})\",\"$1 $2 $3\",[\"1\"],\"0$1\"]],\"0\"],\"KR\":[\"82\",\"00(?:[125689]|3(?:[46]5|91)|7(?:00|27|3|55|6[126]))\",\"00[1-9]\\\\d{8,11}|(?:[12]|5\\\\d{3})\\\\d{7}|[13-6]\\\\d{9}|(?:[1-6]\\\\d|80)\\\\d{7}|[3-6]\\\\d{4,5}|(?:00|7)0\\\\d{8}\",[5,6,8,9,10,11,12,13,14],[[\"(\\\\d{2})(\\\\d{3,4})\",\"$1-$2\",[\"(?:3[1-3]|[46][1-4]|5[1-5])1\"],\"0$1\"],[\"(\\\\d{4})(\\\\d{4})\",\"$1-$2\",[\"1\"]],[\"(\\\\d)(\\\\d{3,4})(\\\\d{4})\",\"$1-$2-$3\",[\"2\"],\"0$1\"],[\"(\\\\d{2})(\\\\d{3})(\\\\d{4})\",\"$1-$2-$3\",[\"[36]0|8\"],\"0$1\"],[\"(\\\\d{2})(\\\\d{3,4})(\\\\d{4})\",\"$1-$2-$3\",[\"[1346]|5[1-5]\"],\"0$1\"],[\"(\\\\d{2})(\\\\d{4})(\\\\d{4})\",\"$1-$2-$3\",[\"[57]\"],\"0$1\"],[\"(\\\\d{2})(\\\\d{5})(\\\\d{4})\",\"$1-$2-$3\",[\"5\"],\"0$1\"]],\"0\",0,\"0(8(?:[1-46-8]|5\\\\d\\\\d))?\"],\"KW\":[\"965\",\"00\",\"18\\\\d{5}|(?:[2569]\\\\d|41)\\\\d{6}\",[7,8],[[\"(\\\\d{4})(\\\\d{3,4})\",\"$1 $2\",[\"[169]|2(?:[235]|4[1-35-9])|52\"]],[\"(\\\\d{3})(\\\\d{5})\",\"$1 $2\",[\"[245]\"]]]],\"KY\":[\"1\",\"011\",\"(?:345|[58]\\\\d\\\\d|900)\\\\d{7}\",[10],0,\"1\",0,\"([2-9]\\\\d{6})$|1\",\"345$1\",0,\"345\"],\"KZ\":[\"7\",\"810\",\"8\\\\d{13}|[78]\\\\d{9}\",[10,14],0,\"8\",0,0,0,0,\"7\",0,\"8~10\"],\"LA\":[\"856\",\"00\",\"[23]\\\\d{9}|3\\\\d{8}|(?:[235-8]\\\\d|41)\\\\d{6}\",[8,9,10],[[\"(\\\\d{2})(\\\\d{3})(\\\\d{3})\",\"$1 $2 $3\",[\"2[13]|3[14]|[4-8]\"],\"0$1\"],[\"(\\\\d{2})(\\\\d{2})(\\\\d{2})(\\\\d{3})\",\"$1 $2 $3 $4\",[\"3\"],\"0$1\"],[\"(\\\\d{2})(\\\\d{2})(\\\\d{3})(\\\\d{3})\",\"$1 $2 $3 $4\",[\"[23]\"],\"0$1\"]],\"0\"],\"LB\":[\"961\",\"00\",\"[27-9]\\\\d{7}|[13-9]\\\\d{6}\",[7,8],[[\"(\\\\d)(\\\\d{3})(\\\\d{3})\",\"$1 $2 $3\",[\"[13-69]|7(?:[2-57]|62|8[0-6]|9[04-9])|8[02-9]\"],\"0$1\"],[\"(\\\\d{2})(\\\\d{3})(\\\\d{3})\",\"$1 $2 $3\",[\"[27-9]\"]]],\"0\"],\"LC\":[\"1\",\"011\",\"(?:[58]\\\\d\\\\d|758|900)\\\\d{7}\",[10],0,\"1\",0,\"([2-8]\\\\d{6})$|1\",\"758$1\",0,\"758\"],\"LI\":[\"423\",\"00\",\"[68]\\\\d{8}|(?:[2378]\\\\d|90)\\\\d{5}\",[7,9],[[\"(\\\\d{3})(\\\\d{2})(\\\\d{2})\",\"$1 $2 $3\",[\"[2379]|8(?:0[09]|7)\",\"[2379]|8(?:0(?:02|9)|7)\"]],[\"(\\\\d{3})(\\\\d{3})(\\\\d{3})\",\"$1 $2 $3\",[\"8\"]],[\"(\\\\d{2})(\\\\d{3})(\\\\d{4})\",\"$1 $2 $3\",[\"69\"]],[\"(\\\\d{3})(\\\\d{3})(\\\\d{3})\",\"$1 $2 $3\",[\"6\"]]],\"0\",0,\"(1001)|0\"],\"LK\":[\"94\",\"00\",\"[1-9]\\\\d{8}\",[9],[[\"(\\\\d{2})(\\\\d{3})(\\\\d{4})\",\"$1 $2 $3\",[\"7\"],\"0$1\"],[\"(\\\\d{3})(\\\\d{3})(\\\\d{3})\",\"$1 $2 $3\",[\"[1-689]\"],\"0$1\"]],\"0\"],\"LR\":[\"231\",\"00\",\"(?:[2457]\\\\d|33|88)\\\\d{7}|(?:2\\\\d|[4-6])\\\\d{6}\",[7,8,9],[[\"(\\\\d)(\\\\d{3})(\\\\d{3})\",\"$1 $2 $3\",[\"4[67]|[56]\"],\"0$1\"],[\"(\\\\d{2})(\\\\d{3})(\\\\d{3})\",\"$1 $2 $3\",[\"2\"],\"0$1\"],[\"(\\\\d{2})(\\\\d{3})(\\\\d{4})\",\"$1 $2 $3\",[\"[2-578]\"],\"0$1\"]],\"0\"],\"LS\":[\"266\",\"00\",\"(?:[256]\\\\d\\\\d|800)\\\\d{5}\",[8],[[\"(\\\\d{4})(\\\\d{4})\",\"$1 $2\",[\"[2568]\"]]]],\"LT\":[\"370\",\"00\",\"(?:[3469]\\\\d|52|[78]0)\\\\d{6}\",[8],[[\"(\\\\d)(\\\\d{3})(\\\\d{4})\",\"$1 $2 $3\",[\"52[0-7]\"],\"(0-$1)\",1],[\"(\\\\d{3})(\\\\d{2})(\\\\d{3})\",\"$1 $2 $3\",[\"[7-9]\"],\"0 $1\",1],[\"(\\\\d{2})(\\\\d{6})\",\"$1 $2\",[\"37|4(?:[15]|6[1-8])\"],\"(0-$1)\",1],[\"(\\\\d{3})(\\\\d{5})\",\"$1 $2\",[\"[3-6]\"],\"(0-$1)\",1]],\"0\",0,\"[08]\"],\"LU\":[\"352\",\"00\",\"35[013-9]\\\\d{4,8}|6\\\\d{8}|35\\\\d{2,4}|(?:[2457-9]\\\\d|3[0-46-9])\\\\d{2,9}\",[4,5,6,7,8,9,10,11],[[\"(\\\\d{2})(\\\\d{3})\",\"$1 $2\",[\"2(?:0[2-689]|[2-9])|[3-57]|8(?:0[2-9]|[13-9])|9(?:0[89]|[2-579])\"]],[\"(\\\\d{2})(\\\\d{2})(\\\\d{2})\",\"$1 $2 $3\",[\"2(?:0[2-689]|[2-9])|[3-57]|8(?:0[2-9]|[13-9])|9(?:0[89]|[2-579])\"]],[\"(\\\\d{2})(\\\\d{2})(\\\\d{3})\",\"$1 $2 $3\",[\"20[2-689]\"]],[\"(\\\\d{2})(\\\\d{2})(\\\\d{2})(\\\\d{1,2})\",\"$1 $2 $3 $4\",[\"20\"]],[\"(\\\\d{2})(\\\\d{2})(\\\\d{2})(\\\\d{1,5})\",\"$1 $2 $3 $4\",[\"[3-57]|8[13-9]|9(?:0[89]|[2-579])|(?:2|80)[2-9]\"]],[\"(\\\\d{3})(\\\\d{2})(\\\\d{3})\",\"$1 $2 $3\",[\"80[01]|90[015]\"]],[\"(\\\\d{2})(\\\\d{2})(\\\\d{2})(\\\\d{3})\",\"$1 $2 $3 $4\",[\"20\"]],[\"(\\\\d{3})(\\\\d{3})(\\\\d{3})\",\"$1 $2 $3\",[\"6\"]],[\"(\\\\d{2})(\\\\d{2})(\\\\d{2})(\\\\d{2})(\\\\d{1,2})\",\"$1 $2 $3 $4 $5\",[\"20\"]]],0,0,\"(15(?:0[06]|1[12]|[35]5|4[04]|6[26]|77|88|99)\\\\d)\"],\"LV\":[\"371\",\"00\",\"(?:[268]\\\\d|78|90)\\\\d{6}\",[8],[[\"(\\\\d{2})(\\\\d{3})(\\\\d{3})\",\"$1 $2 $3\",[\"[2679]|8[01]\"]]]],\"LY\":[\"218\",\"00\",\"[2-9]\\\\d{8}\",[9],[[\"(\\\\d{2})(\\\\d{7})\",\"$1-$2\",[\"[2-9]\"],\"0$1\"]],\"0\"],\"MA\":[\"212\",\"00\",\"[5-8]\\\\d{8}\",[9],[[\"(\\\\d{4})(\\\\d{5})\",\"$1-$2\",[\"892\"],\"0$1\"],[\"(\\\\d{2})(\\\\d{7})\",\"$1-$2\",[\"8(?:0[0-7]|9)\"],\"0$1\"],[\"(\\\\d)(\\\\d{2})(\\\\d{2})(\\\\d{2})(\\\\d{2})\",\"$1 $2 $3 $4 $5\",[\"[5-8]\"],\"0$1\"]],\"0\",0,0,0,0,\"[5-8]\"],\"MC\":[\"377\",\"00\",\"(?:[3489]|[67]\\\\d)\\\\d{7}\",[8,9],[[\"(\\\\d{2})(\\\\d{3})(\\\\d{3})\",\"$1 $2 $3\",[\"4\"],\"0$1\"],[\"(\\\\d{2})(\\\\d{2})(\\\\d{2})(\\\\d{2})\",\"$1 $2 $3 $4\",[\"[389]\"]],[\"(\\\\d)(\\\\d{2})(\\\\d{2})(\\\\d{2})(\\\\d{2})\",\"$1 $2 $3 $4 $5\",[\"[67]\"],\"0$1\"]],\"0\"],\"MD\":[\"373\",\"00\",\"(?:[235-7]\\\\d|[89]0)\\\\d{6}\",[8],[[\"(\\\\d{3})(\\\\d{5})\",\"$1 $2\",[\"[89]\"],\"0$1\"],[\"(\\\\d{2})(\\\\d{3})(\\\\d{3})\",\"$1 $2 $3\",[\"22|3\"],\"0$1\"],[\"(\\\\d{3})(\\\\d{2})(\\\\d{3})\",\"$1 $2 $3\",[\"[25-7]\"],\"0$1\"]],\"0\"],\"ME\":[\"382\",\"00\",\"(?:20|[3-79]\\\\d)\\\\d{6}|80\\\\d{6,7}\",[8,9],[[\"(\\\\d{2})(\\\\d{3})(\\\\d{3,4})\",\"$1 $2 $3\",[\"[2-9]\"],\"0$1\"]],\"0\"],\"MF\":[\"590\",\"00\",\"7090\\\\d{5}|(?:[56]9|[89]\\\\d)\\\\d{7}\",[9],0,\"0\",0,0,0,0,0,[[\"(?:59(?:0(?:0[079]|[14]3|[27][79]|3[03-7]|5[0-268]|87)|87\\\\d)|80[6-9]\\\\d\\\\d)\\\\d{4}\"],[\"(?:69(?:0\\\\d\\\\d|1(?:2[2-9]|3[0-5]))|7090[0-4])\\\\d{4}\"],[\"80[0-5]\\\\d{6}\"],[\"8[129]\\\\d{7}\"],0,0,0,0,[\"9(?:(?:39[5-7]|76[018])\\\\d|475[0-6])\\\\d{4}\"]]],\"MG\":[\"261\",\"00\",\"[23]\\\\d{8}\",[9],[[\"(\\\\d{2})(\\\\d{2})(\\\\d{3})(\\\\d{2})\",\"$1 $2 $3 $4\",[\"[23]\"],\"0$1\"]],\"0\",0,\"([24-9]\\\\d{6})$|0\",\"20$1\"],\"MH\":[\"692\",\"011\",\"329\\\\d{4}|(?:[256]\\\\d|45)\\\\d{5}\",[7],[[\"(\\\\d{3})(\\\\d{4})\",\"$1-$2\",[\"[2-6]\"]]],\"1\"],\"MK\":[\"389\",\"00\",\"[2-578]\\\\d{7}\",[8],[[\"(\\\\d)(\\\\d{3})(\\\\d{4})\",\"$1 $2 $3\",[\"2|34[47]|4(?:[37]7|5[47]|64)\"],\"0$1\"],[\"(\\\\d{2})(\\\\d{3})(\\\\d{3})\",\"$1 $2 $3\",[\"[347]\"],\"0$1\"],[\"(\\\\d{3})(\\\\d)(\\\\d{2})(\\\\d{2})\",\"$1 $2 $3 $4\",[\"[58]\"],\"0$1\"]],\"0\"],\"ML\":[\"223\",\"00\",\"[24-9]\\\\d{7}\",[8],[[\"(\\\\d{2})(\\\\d{2})(\\\\d{2})(\\\\d{2})\",\"$1 $2 $3 $4\",[\"[24-9]\"]]]],\"MM\":[\"95\",\"00\",\"1\\\\d{5,7}|95\\\\d{6}|(?:[4-7]|9[0-46-9])\\\\d{6,8}|(?:2|8\\\\d)\\\\d{5,8}\",[6,7,8,9,10],[[\"(\\\\d)(\\\\d{2})(\\\\d{3})\",\"$1 $2 $3\",[\"16|2\"],\"0$1\"],[\"(\\\\d{2})(\\\\d{2})(\\\\d{3})\",\"$1 $2 $3\",[\"4(?:[2-46]|5[3-5])|5|6(?:[1-689]|7[235-7])|7(?:[0-4]|5[2-7])|8[1-5]|(?:60|86)[23]\"],\"0$1\"],[\"(\\\\d)(\\\\d{3})(\\\\d{3,4})\",\"$1 $2 $3\",[\"[12]|452|678|86\",\"[12]|452|6788|86\"],\"0$1\"],[\"(\\\\d{2})(\\\\d{3})(\\\\d{3,4})\",\"$1 $2 $3\",[\"[4-7]|8[1-35]\"],\"0$1\"],[\"(\\\\d)(\\\\d{3})(\\\\d{4,6})\",\"$1 $2 $3\",[\"9(?:2[0-4]|[35-9]|4[137-9])\"],\"0$1\"],[\"(\\\\d)(\\\\d{4})(\\\\d{4})\",\"$1 $2 $3\",[\"2\"],\"0$1\"],[\"(\\\\d{3})(\\\\d{3})(\\\\d{4})\",\"$1 $2 $3\",[\"8\"],\"0$1\"],[\"(\\\\d)(\\\\d{3})(\\\\d{3})(\\\\d{3})\",\"$1 $2 $3 $4\",[\"92\"],\"0$1\"],[\"(\\\\d)(\\\\d{5})(\\\\d{4})\",\"$1 $2 $3\",[\"9\"],\"0$1\"]],\"0\"],\"MN\":[\"976\",\"001\",\"[12]\\\\d{7,9}|[5-9]\\\\d{7}\",[8,9,10],[[\"(\\\\d{2})(\\\\d{2})(\\\\d{4})\",\"$1 $2 $3\",[\"11|2[16]\"],\"0$1\"],[\"(\\\\d{4})(\\\\d{4})\",\"$1 $2\",[\"[5-9]\"]],[\"(\\\\d{3})(\\\\d{5,6})\",\"$1 $2\",[\"[12]2[1-3]\"],\"0$1\"],[\"(\\\\d{4})(\\\\d{5,6})\",\"$1 $2\",[\"[12](?:27|3[2-8]|4[2-68]|5[1-4689])\",\"[12](?:27|3[2-8]|4[2-68]|5[1-4689])[0-3]\"],\"0$1\"],[\"(\\\\d{5})(\\\\d{4,5})\",\"$1 $2\",[\"[12]\"],\"0$1\"]],\"0\"],\"MO\":[\"853\",\"00\",\"0800\\\\d{3}|(?:28|[68]\\\\d)\\\\d{6}\",[7,8],[[\"(\\\\d{4})(\\\\d{3})\",\"$1 $2\",[\"0\"]],[\"(\\\\d{4})(\\\\d{4})\",\"$1 $2\",[\"[268]\"]]]],\"MP\":[\"1\",\"011\",\"[58]\\\\d{9}|(?:67|90)0\\\\d{7}\",[10],0,\"1\",0,\"([2-9]\\\\d{6})$|1\",\"670$1\",0,\"670\"],\"MQ\":[\"596\",\"00\",\"7091\\\\d{5}|(?:[56]9|[89]\\\\d)\\\\d{7}\",[9],[[\"(\\\\d{3})(\\\\d{2})(\\\\d{2})(\\\\d{2})\",\"$1 $2 $3 $4\",[\"[5-79]|8(?:0[6-9]|[36])\"],\"0$1\"],[\"(\\\\d{3})(\\\\d{2})(\\\\d{2})(\\\\d{2})\",\"$1 $2 $3 $4\",[\"8\"],\"0$1\"]],\"0\"],\"MR\":[\"222\",\"00\",\"(?:[2-4]\\\\d\\\\d|800)\\\\d{5}\",[8],[[\"(\\\\d{2})(\\\\d{2})(\\\\d{2})(\\\\d{2})\",\"$1 $2 $3 $4\",[\"[2-48]\"]]]],\"MS\":[\"1\",\"011\",\"(?:[58]\\\\d\\\\d|664|900)\\\\d{7}\",[10],0,\"1\",0,\"([34]\\\\d{6})$|1\",\"664$1\",0,\"664\"],\"MT\":[\"356\",\"00\",\"3550\\\\d{4}|(?:[2579]\\\\d\\\\d|800)\\\\d{5}\",[8],[[\"(\\\\d{4})(\\\\d{4})\",\"$1 $2\",[\"[2357-9]\"]]]],\"MU\":[\"230\",\"0(?:0|[24-7]0|3[03])\",\"(?:[57]|8\\\\d\\\\d)\\\\d{7}|[2-468]\\\\d{6}\",[7,8,10],[[\"(\\\\d{3})(\\\\d{4})\",\"$1 $2\",[\"[2-46]|8[013]\"]],[\"(\\\\d{4})(\\\\d{4})\",\"$1 $2\",[\"[57]\"]],[\"(\\\\d{5})(\\\\d{5})\",\"$1 $2\",[\"8\"]]],0,0,0,0,0,0,0,\"020\"],\"MV\":[\"960\",\"0(?:0|19)\",\"(?:800|9[0-57-9]\\\\d)\\\\d{7}|[34679]\\\\d{6}\",[7,10],[[\"(\\\\d{3})(\\\\d{4})\",\"$1-$2\",[\"[34679]\"]],[\"(\\\\d{3})(\\\\d{3})(\\\\d{4})\",\"$1 $2 $3\",[\"[89]\"]]],0,0,0,0,0,0,0,\"00\"],\"MW\":[\"265\",\"00\",\"(?:[1289]\\\\d|31|77)\\\\d{7}|1\\\\d{6}\",[7,9],[[\"(\\\\d)(\\\\d{3})(\\\\d{3})\",\"$1 $2 $3\",[\"1[2-9]\"],\"0$1\"],[\"(\\\\d{3})(\\\\d{2})(\\\\d{2})(\\\\d{2})\",\"$1 $2 $3 $4\",[\"[1-37-9]\"],\"0$1\"]],\"0\"],\"MX\":[\"52\",\"0[09]\",\"[2-9]\\\\d{9}\",[10],[[\"(\\\\d{2})(\\\\d{4})(\\\\d{4})\",\"$1 $2 $3\",[\"33|5[56]|81\"]],[\"(\\\\d{3})(\\\\d{3})(\\\\d{4})\",\"$1 $2 $3\",[\"[2-9]\"]]],0,0,0,0,0,0,0,\"00\"],\"MY\":[\"60\",\"00\",\"1\\\\d{8,9}|(?:3\\\\d|[4-9])\\\\d{7}\",[8,9,10],[[\"(\\\\d)(\\\\d{3})(\\\\d{4})\",\"$1-$2 $3\",[\"[4-79]\"],\"0$1\"],[\"(\\\\d{2})(\\\\d{3})(\\\\d{3,4})\",\"$1-$2 $3\",[\"1(?:[02469]|[378][1-9]|53)|8\",\"1(?:[02469]|[37][1-9]|53|8(?:[1-46-9]|5[7-9]))|8\"],\"0$1\"],[\"(\\\\d)(\\\\d{4})(\\\\d{4})\",\"$1-$2 $3\",[\"3\"],\"0$1\"],[\"(\\\\d)(\\\\d{3})(\\\\d{2})(\\\\d{4})\",\"$1-$2-$3-$4\",[\"1(?:[367]|80)\"]],[\"(\\\\d{3})(\\\\d{3})(\\\\d{4})\",\"$1-$2 $3\",[\"15\"],\"0$1\"],[\"(\\\\d{2})(\\\\d{4})(\\\\d{4})\",\"$1-$2 $3\",[\"1\"],\"0$1\"]],\"0\"],\"MZ\":[\"258\",\"00\",\"(?:2|8\\\\d)\\\\d{7}\",[8,9],[[\"(\\\\d{2})(\\\\d{3})(\\\\d{3,4})\",\"$1 $2 $3\",[\"2|8[2-79]\"]],[\"(\\\\d{3})(\\\\d{3})(\\\\d{3})\",\"$1 $2 $3\",[\"8\"]]]],\"NA\":[\"264\",\"00\",\"[68]\\\\d{7,8}\",[8,9],[[\"(\\\\d{2})(\\\\d{3})(\\\\d{3})\",\"$1 $2 $3\",[\"88\"],\"0$1\"],[\"(\\\\d{2})(\\\\d{3})(\\\\d{3,4})\",\"$1 $2 $3\",[\"6\"],\"0$1\"],[\"(\\\\d{3})(\\\\d{3})(\\\\d{3})\",\"$1 $2 $3\",[\"87\"],\"0$1\"],[\"(\\\\d{2})(\\\\d{3})(\\\\d{4})\",\"$1 $2 $3\",[\"8\"],\"0$1\"]],\"0\"],\"NC\":[\"687\",\"00\",\"(?:050|[2-57-9]\\\\d\\\\d)\\\\d{3}\",[6],[[\"(\\\\d{2})(\\\\d{2})(\\\\d{2})\",\"$1.$2.$3\",[\"[02-57-9]\"]]]],\"NE\":[\"227\",\"00\",\"[027-9]\\\\d{7}\",[8],[[\"(\\\\d{2})(\\\\d{3})(\\\\d{3})\",\"$1 $2 $3\",[\"08\"]],[\"(\\\\d{2})(\\\\d{2})(\\\\d{2})(\\\\d{2})\",\"$1 $2 $3 $4\",[\"[089]|2[013]|7[0467]\"]]]],\"NF\":[\"672\",\"00\",\"[13]\\\\d{5}\",[6],[[\"(\\\\d{2})(\\\\d{4})\",\"$1 $2\",[\"1[0-3]\"]],[\"(\\\\d)(\\\\d{5})\",\"$1 $2\",[\"[13]\"]]],0,0,\"([0-258]\\\\d{4})$\",\"3$1\"],\"NG\":[\"234\",\"009\",\"(?:20|9\\\\d)\\\\d{8}|[78]\\\\d{9,13}\",[10,11,12,13,14],[[\"(\\\\d{3})(\\\\d{3})(\\\\d{3,4})\",\"$1 $2 $3\",[\"[7-9]\"],\"0$1\"],[\"(\\\\d{3})(\\\\d{3})(\\\\d{4})\",\"$1 $2 $3\",[\"20[129]\"],\"0$1\"],[\"(\\\\d{4})(\\\\d{2})(\\\\d{4})\",\"$1 $2 $3\",[\"2\"],\"0$1\"],[\"(\\\\d{3})(\\\\d{4})(\\\\d{4,5})\",\"$1 $2 $3\",[\"[78]\"],\"0$1\"],[\"(\\\\d{3})(\\\\d{5})(\\\\d{5,6})\",\"$1 $2 $3\",[\"[78]\"],\"0$1\"]],\"0\"],\"NI\":[\"505\",\"00\",\"(?:1800|[25-8]\\\\d{3})\\\\d{4}\",[8],[[\"(\\\\d{4})(\\\\d{4})\",\"$1 $2\",[\"[125-8]\"]]]],\"NL\":[\"31\",\"00\",\"(?:[124-7]\\\\d\\\\d|3(?:[02-9]\\\\d|1[0-8]))\\\\d{6}|8\\\\d{6,9}|9\\\\d{6,10}|1\\\\d{4,5}\",[5,6,7,8,9,10,11],[[\"(\\\\d{3})(\\\\d{4,7})\",\"$1 $2\",[\"[89]0\"],\"0$1\"],[\"(\\\\d{2})(\\\\d{7})\",\"$1 $2\",[\"66\"],\"0$1\"],[\"(\\\\d)(\\\\d{8})\",\"$1 $2\",[\"6\"],\"0$1\"],[\"(\\\\d{3})(\\\\d{3})(\\\\d{3})\",\"$1 $2 $3\",[\"1[16-8]|2[259]|3[124]|4[17-9]|5[124679]\"],\"0$1\"],[\"(\\\\d{2})(\\\\d{3})(\\\\d{4})\",\"$1 $2 $3\",[\"[1-578]|91\"],\"0$1\"],[\"(\\\\d{3})(\\\\d{3})(\\\\d{5})\",\"$1 $2 $3\",[\"9\"],\"0$1\"]],\"0\"],\"NO\":[\"47\",\"00\",\"(?:0|[2-9]\\\\d{3})\\\\d{4}\",[5,8],[[\"(\\\\d{3})(\\\\d{2})(\\\\d{3})\",\"$1 $2 $3\",[\"8\"]],[\"(\\\\d{2})(\\\\d{2})(\\\\d{2})(\\\\d{2})\",\"$1 $2 $3 $4\",[\"[2-79]\"]]],0,0,0,0,0,\"[02-689]|7[0-8]\"],\"NP\":[\"977\",\"00\",\"(?:1\\\\d|9)\\\\d{9}|[1-9]\\\\d{7}\",[8,10,11],[[\"(\\\\d)(\\\\d{7})\",\"$1-$2\",[\"1[2-6]\"],\"0$1\"],[\"(\\\\d{2})(\\\\d{6})\",\"$1-$2\",[\"1[01]|[2-8]|9(?:[1-59]|[67][2-6])\"],\"0$1\"],[\"(\\\\d{3})(\\\\d{7})\",\"$1-$2\",[\"9\"]]],\"0\"],\"NR\":[\"674\",\"00\",\"(?:222|444|(?:55|8\\\\d)\\\\d|666|777|999)\\\\d{4}\",[7],[[\"(\\\\d{3})(\\\\d{4})\",\"$1 $2\",[\"[24-9]\"]]]],\"NU\":[\"683\",\"00\",\"(?:[4-7]|888\\\\d)\\\\d{3}\",[4,7],[[\"(\\\\d{3})(\\\\d{4})\",\"$1 $2\",[\"8\"]]]],\"NZ\":[\"64\",\"0(?:0|161)\",\"[1289]\\\\d{9}|50\\\\d{5}(?:\\\\d{2,3})?|[27-9]\\\\d{7,8}|(?:[34]\\\\d|6[0-35-9])\\\\d{6}|8\\\\d{4,6}\",[5,6,7,8,9,10],[[\"(\\\\d{2})(\\\\d{3,8})\",\"$1 $2\",[\"8[1-79]\"],\"0$1\"],[\"(\\\\d{3})(\\\\d{2})(\\\\d{2,3})\",\"$1 $2 $3\",[\"50[036-8]|8|90\",\"50(?:[0367]|88)|8|90\"],\"0$1\"],[\"(\\\\d)(\\\\d{3})(\\\\d{4})\",\"$1 $2 $3\",[\"24|[346]|7[2-57-9]|9[2-9]\"],\"0$1\"],[\"(\\\\d{3})(\\\\d{3})(\\\\d{3,4})\",\"$1 $2 $3\",[\"2(?:10|74)|[589]\"],\"0$1\"],[\"(\\\\d{2})(\\\\d{3,4})(\\\\d{4})\",\"$1 $2 $3\",[\"1|2[028]\"],\"0$1\"],[\"(\\\\d{2})(\\\\d{3})(\\\\d{3,5})\",\"$1 $2 $3\",[\"2(?:[169]|7[0-35-9])|7\"],\"0$1\"]],\"0\",0,0,0,0,0,0,\"00\"],\"OM\":[\"968\",\"00\",\"(?:1505|[279]\\\\d{3}|500)\\\\d{4}|800\\\\d{5,6}\",[7,8,9],[[\"(\\\\d{3})(\\\\d{4,6})\",\"$1 $2\",[\"[58]\"]],[\"(\\\\d{2})(\\\\d{6})\",\"$1 $2\",[\"2\"]],[\"(\\\\d{4})(\\\\d{4})\",\"$1 $2\",[\"[179]\"]]]],\"PA\":[\"507\",\"00\",\"(?:00800|8\\\\d{3})\\\\d{6}|[68]\\\\d{7}|[1-57-9]\\\\d{6}\",[7,8,10,11],[[\"(\\\\d{3})(\\\\d{4})\",\"$1-$2\",[\"[1-57-9]\"]],[\"(\\\\d{4})(\\\\d{4})\",\"$1-$2\",[\"[68]\"]],[\"(\\\\d{3})(\\\\d{3})(\\\\d{4})\",\"$1 $2 $3\",[\"8\"]]]],\"PE\":[\"51\",\"00|19(?:1[124]|77|90)00\",\"(?:[14-8]|9\\\\d)\\\\d{7}\",[8,9],[[\"(\\\\d{3})(\\\\d{5})\",\"$1 $2\",[\"80\"],\"(0$1)\"],[\"(\\\\d)(\\\\d{7})\",\"$1 $2\",[\"1\"],\"(0$1)\"],[\"(\\\\d{2})(\\\\d{6})\",\"$1 $2\",[\"[4-8]\"],\"(0$1)\"],[\"(\\\\d{3})(\\\\d{3})(\\\\d{3})\",\"$1 $2 $3\",[\"9\"]]],\"0\",0,0,0,0,0,0,\"00\",\" Anexo \"],\"PF\":[\"689\",\"00\",\"4\\\\d{5}(?:\\\\d{2})?|8\\\\d{7,8}\",[6,8,9],[[\"(\\\\d{2})(\\\\d{2})(\\\\d{2})\",\"$1 $2 $3\",[\"44\"]],[\"(\\\\d{2})(\\\\d{2})(\\\\d{2})(\\\\d{2})\",\"$1 $2 $3 $4\",[\"4|8[7-9]\"]],[\"(\\\\d{3})(\\\\d{2})(\\\\d{2})(\\\\d{2})\",\"$1 $2 $3 $4\",[\"8\"]]]],\"PG\":[\"675\",\"00|140[1-3]\",\"(?:180|[78]\\\\d{3})\\\\d{4}|(?:[2-589]\\\\d|64)\\\\d{5}\",[7,8],[[\"(\\\\d{3})(\\\\d{4})\",\"$1 $2\",[\"18|[2-69]|85\"]],[\"(\\\\d{4})(\\\\d{4})\",\"$1 $2\",[\"[78]\"]]],0,0,0,0,0,0,0,\"00\"],\"PH\":[\"63\",\"00\",\"(?:[2-7]|9\\\\d)\\\\d{8}|2\\\\d{5}|(?:1800|8)\\\\d{7,9}\",[6,8,9,10,11,12,13],[[\"(\\\\d)(\\\\d{5})\",\"$1 $2\",[\"2\"],\"(0$1)\"],[\"(\\\\d{4})(\\\\d{4,6})\",\"$1 $2\",[\"3(?:23|39|46)|4(?:2[3-6]|[35]9|4[26]|76)|544|88[245]|(?:52|64|86)2\",\"3(?:230|397|461)|4(?:2(?:35|[46]4|51)|396|4(?:22|63)|59[347]|76[15])|5(?:221|446)|642[23]|8(?:622|8(?:[24]2|5[13]))\"],\"(0$1)\"],[\"(\\\\d{5})(\\\\d{4})\",\"$1 $2\",[\"346|4(?:27|9[35])|883\",\"3469|4(?:279|9(?:30|56))|8834\"],\"(0$1)\"],[\"(\\\\d)(\\\\d{4})(\\\\d{4})\",\"$1 $2 $3\",[\"2\"],\"(0$1)\"],[\"(\\\\d{2})(\\\\d{3})(\\\\d{4})\",\"$1 $2 $3\",[\"[3-7]|8[2-8]\"],\"(0$1)\"],[\"(\\\\d{3})(\\\\d{3})(\\\\d{4})\",\"$1 $2 $3\",[\"[89]\"],\"0$1\"],[\"(\\\\d{4})(\\\\d{3})(\\\\d{4})\",\"$1 $2 $3\",[\"1\"]],[\"(\\\\d{4})(\\\\d{1,2})(\\\\d{3})(\\\\d{4})\",\"$1 $2 $3 $4\",[\"1\"]]],\"0\"],\"PK\":[\"92\",\"00\",\"122\\\\d{6}|[24-8]\\\\d{10,11}|9(?:[013-9]\\\\d{8,10}|2(?:[01]\\\\d\\\\d|2(?:[06-8]\\\\d|1[01]))\\\\d{7})|(?:[2-8]\\\\d{3}|92(?:[0-7]\\\\d|8[1-9]))\\\\d{6}|[24-9]\\\\d{8}|[89]\\\\d{7}\",[8,9,10,11,12],[[\"(\\\\d{3})(\\\\d{3})(\\\\d{2,7})\",\"$1 $2 $3\",[\"[89]0\"],\"0$1\"],[\"(\\\\d{4})(\\\\d{5})\",\"$1 $2\",[\"1\"]],[\"(\\\\d{3})(\\\\d{6,7})\",\"$1 $2\",[\"2(?:3[2358]|4[2-4]|9[2-8])|45[3479]|54[2-467]|60[468]|72[236]|8(?:2[2-689]|3[23578]|4[3478]|5[2356])|9(?:2[2-8]|3[27-9]|4[2-6]|6[3569]|9[25-8])\",\"9(?:2[3-8]|98)|(?:2(?:3[2358]|4[2-4]|9[2-8])|45[3479]|54[2-467]|60[468]|72[236]|8(?:2[2-689]|3[23578]|4[3478]|5[2356])|9(?:22|3[27-9]|4[2-6]|6[3569]|9[25-7]))[2-9]\"],\"(0$1)\"],[\"(\\\\d{2})(\\\\d{7,8})\",\"$1 $2\",[\"(?:2[125]|4[0-246-9]|5[1-35-7]|6[1-8]|7[14]|8[16]|91)[2-9]\"],\"(0$1)\"],[\"(\\\\d{5})(\\\\d{5})\",\"$1 $2\",[\"58\"],\"(0$1)\"],[\"(\\\\d{3})(\\\\d{7})\",\"$1 $2\",[\"3\"],\"0$1\"],[\"(\\\\d{2})(\\\\d{3})(\\\\d{3})(\\\\d{3})\",\"$1 $2 $3 $4\",[\"2[125]|4[0-246-9]|5[1-35-7]|6[1-8]|7[14]|8[16]|91\"],\"(0$1)\"],[\"(\\\\d{3})(\\\\d{3})(\\\\d{3})(\\\\d{3})\",\"$1 $2 $3 $4\",[\"[24-9]\"],\"(0$1)\"]],\"0\"],\"PL\":[\"48\",\"00\",\"(?:6|8\\\\d\\\\d)\\\\d{7}|[1-9]\\\\d{6}(?:\\\\d{2})?|[26]\\\\d{5}\",[6,7,8,9,10],[[\"(\\\\d{5})\",\"$1\",[\"19\"]],[\"(\\\\d{3})(\\\\d{3})\",\"$1 $2\",[\"11|20|64\"]],[\"(\\\\d{2})(\\\\d{2})(\\\\d{3})\",\"$1 $2 $3\",[\"30|(?:1[2-8]|2[2-69]|3[2-4]|4[1-468]|5[24-689]|6[1-3578]|7[14-7]|8[1-79]|9[145])1\",\"30|(?:1[2-8]|2[2-69]|3[2-4]|4[1-468]|5[24-689]|6[1-3578]|7[14-7]|8[1-79]|9[145])19\"]],[\"(\\\\d{3})(\\\\d{2})(\\\\d{2,3})\",\"$1 $2 $3\",[\"64\"]],[\"(\\\\d{3})(\\\\d{3})(\\\\d{3})\",\"$1 $2 $3\",[\"21|39|45|5[0137]|6[0469]|7[02389]|8(?:0[14]|8)\"]],[\"(\\\\d{2})(\\\\d{3})(\\\\d{2})(\\\\d{2})\",\"$1 $2 $3 $4\",[\"1[2-8]|[2-7]|8[1-79]|9[145]\"]],[\"(\\\\d{3})(\\\\d{3})(\\\\d{3,4})\",\"$1 $2 $3\",[\"8\"]]]],\"PM\":[\"508\",\"00\",\"[78]\\\\d{8}|[2-9]\\\\d{5}\",[6,9],[[\"(\\\\d{2})(\\\\d{2})(\\\\d{2})\",\"$1 $2 $3\",[\"[2-9]\"],\"0$1\"],[\"(\\\\d{3})(\\\\d{3})(\\\\d{3})\",\"$1 $2 $3\",[\"7\"]],[\"(\\\\d{3})(\\\\d{2})(\\\\d{2})(\\\\d{2})\",\"$1 $2 $3 $4\",[\"8\"],\"0$1\"]],\"0\"],\"PR\":[\"1\",\"011\",\"(?:[589]\\\\d\\\\d|787)\\\\d{7}\",[10],0,\"1\",0,0,0,0,\"787|939\"],\"PS\":[\"970\",\"00\",\"[2489]2\\\\d{6}|(?:1\\\\d|5)\\\\d{8}\",[8,9,10],[[\"(\\\\d)(\\\\d{3})(\\\\d{4})\",\"$1 $2 $3\",[\"[2489]\"],\"0$1\"],[\"(\\\\d{3})(\\\\d{3})(\\\\d{3})\",\"$1 $2 $3\",[\"5\"],\"0$1\"],[\"(\\\\d{4})(\\\\d{3})(\\\\d{3})\",\"$1 $2 $3\",[\"1\"]]],\"0\"],\"PT\":[\"351\",\"00\",\"1693\\\\d{5}|(?:[26-9]\\\\d|30)\\\\d{7}\",[9],[[\"(\\\\d{2})(\\\\d{3})(\\\\d{4})\",\"$1 $2 $3\",[\"2[12]\"]],[\"(\\\\d{3})(\\\\d{3})(\\\\d{3})\",\"$1 $2 $3\",[\"16|[236-9]\"]]]],\"PW\":[\"680\",\"01[12]\",\"(?:[24-8]\\\\d\\\\d|345|900)\\\\d{4}\",[7],[[\"(\\\\d{3})(\\\\d{4})\",\"$1 $2\",[\"[2-9]\"]]]],\"PY\":[\"595\",\"00\",\"[36-8]\\\\d{5,8}|4\\\\d{6,8}|59\\\\d{6}|9\\\\d{5,10}|(?:2\\\\d|5[0-8])\\\\d{6,7}\",[6,7,8,9,10,11],[[\"(\\\\d{3})(\\\\d{3,6})\",\"$1 $2\",[\"[2-9]0\"],\"0$1\"],[\"(\\\\d{2})(\\\\d{5})\",\"$1 $2\",[\"3[289]|4[246-8]|61|7[1-3]|8[1-36]\"],\"(0$1)\"],[\"(\\\\d{3})(\\\\d{4,5})\",\"$1 $2\",[\"2[279]|3[13-5]|4[359]|5|6(?:[34]|7[1-46-8])|7[46-8]|85\"],\"(0$1)\"],[\"(\\\\d{2})(\\\\d{3})(\\\\d{3,4})\",\"$1 $2 $3\",[\"2[14-68]|3[26-9]|4[1246-8]|6(?:1|75)|7[1-35]|8[1-36]\"],\"(0$1)\"],[\"(\\\\d{2})(\\\\d{3})(\\\\d{4})\",\"$1 $2 $3\",[\"87\"]],[\"(\\\\d{3})(\\\\d{6})\",\"$1 $2\",[\"9(?:[5-79]|8[1-7])\"],\"0$1\"],[\"(\\\\d{3})(\\\\d{3})(\\\\d{3})\",\"$1 $2 $3\",[\"[2-8]\"],\"0$1\"],[\"(\\\\d{4})(\\\\d{3})(\\\\d{4})\",\"$1 $2 $3\",[\"9\"]]],\"0\"],\"QA\":[\"974\",\"00\",\"800\\\\d{4}|(?:2|800)\\\\d{6}|(?:0080|[3-7])\\\\d{7}\",[7,8,9,11],[[\"(\\\\d{3})(\\\\d{4})\",\"$1 $2\",[\"2[136]|8\"]],[\"(\\\\d{4})(\\\\d{4})\",\"$1 $2\",[\"[3-7]\"]]]],\"RE\":[\"262\",\"00\",\"709\\\\d{6}|(?:26|[689]\\\\d)\\\\d{7}\",[9],[[\"(\\\\d{3})(\\\\d{2})(\\\\d{2})(\\\\d{2})\",\"$1 $2 $3 $4\",[\"[26-9]\"],\"0$1\"]],\"0\",0,0,0,0,0,[[\"2631[0-6]\\\\d{4}|26(?:2\\\\d|30|88)\\\\d{5}\"],[\"(?:69(?:2\\\\d\\\\d|3(?:[06][0-6]|1[0-3]|2[0-2]|3[0-39]|4\\\\d|5[0-5]|7[0-37]|8[0-8]|9[0-479]))|7092[0-3])\\\\d{4}\"],[\"80\\\\d{7}\"],[\"89[1-37-9]\\\\d{6}\"],0,0,0,0,[\"9(?:399[0-3]|479[0-6]|76(?:2[278]|3[0-37]))\\\\d{4}\"],[\"8(?:1[019]|2[0156]|84|90)\\\\d{6}\"]]],\"RO\":[\"40\",\"00\",\"(?:[236-8]\\\\d|90)\\\\d{7}|[23]\\\\d{5}\",[6,9],[[\"(\\\\d{3})(\\\\d{3})\",\"$1 $2\",[\"2[3-6]\",\"2[3-6]\\\\d9\"],\"0$1\"],[\"(\\\\d{2})(\\\\d{4})\",\"$1 $2\",[\"219|31\"],\"0$1\"],[\"(\\\\d{2})(\\\\d{3})(\\\\d{4})\",\"$1 $2 $3\",[\"[23]1\"],\"0$1\"],[\"(\\\\d{3})(\\\\d{3})(\\\\d{3})\",\"$1 $2 $3\",[\"[236-9]\"],\"0$1\"]],\"0\",0,0,0,0,0,0,0,\" int \"],\"RS\":[\"381\",\"00\",\"38[02-9]\\\\d{6,9}|6\\\\d{7,9}|90\\\\d{4,8}|38\\\\d{5,6}|(?:7\\\\d\\\\d|800)\\\\d{3,9}|(?:[12]\\\\d|3[0-79])\\\\d{5,10}\",[6,7,8,9,10,11,12],[[\"(\\\\d{3})(\\\\d{3,9})\",\"$1 $2\",[\"(?:2[389]|39)0|[7-9]\"],\"0$1\"],[\"(\\\\d{2})(\\\\d{5,10})\",\"$1 $2\",[\"[1-36]\"],\"0$1\"]],\"0\"],\"RU\":[\"7\",\"810\",\"8\\\\d{13}|[347-9]\\\\d{9}\",[10,14],[[\"(\\\\d{4})(\\\\d{2})(\\\\d{2})(\\\\d{2})\",\"$1 $2 $3 $4\",[\"7(?:1[0-8]|2[1-9])\",\"7(?:1(?:[0-356]2|4[29]|7|8[27])|2(?:1[23]|[2-9]2))\",\"7(?:1(?:[0-356]2|4[29]|7|8[27])|2(?:13[03-69]|62[013-9]))|72[1-57-9]2\"],\"8 ($1)\",1],[\"(\\\\d{5})(\\\\d)(\\\\d{2})(\\\\d{2})\",\"$1 $2 $3 $4\",[\"7(?:1[0-68]|2[1-9])\",\"7(?:1(?:[06][3-6]|[18]|2[35]|[3-5][3-5])|2(?:[13][3-5]|[24-689]|7[457]))\",\"7(?:1(?:0(?:[356]|4[023])|[18]|2(?:3[013-9]|5)|3[45]|43[013-79]|5(?:3[1-8]|4[1-7]|5)|6(?:3[0-35-9]|[4-6]))|2(?:1(?:3[178]|[45])|[24-689]|3[35]|7[457]))|7(?:14|23)4[0-8]|71(?:33|45)[1-79]\"],\"8 ($1)\",1],[\"(\\\\d{3})(\\\\d{3})(\\\\d{4})\",\"$1 $2 $3\",[\"7\"],\"8 ($1)\",1],[\"(\\\\d{3})(\\\\d{3})(\\\\d{2})(\\\\d{2})\",\"$1 $2-$3-$4\",[\"[349]|8(?:[02-7]|1[1-8])\"],\"8 ($1)\",1],[\"(\\\\d{4})(\\\\d{4})(\\\\d{3})(\\\\d{3})\",\"$1 $2 $3 $4\",[\"8\"],\"8 ($1)\"]],\"8\",0,0,0,0,\"[3489]\",0,\"8~10\"],\"RW\":[\"250\",\"00\",\"(?:06|[27]\\\\d\\\\d|[89]00)\\\\d{6}\",[8,9],[[\"(\\\\d{2})(\\\\d{2})(\\\\d{2})(\\\\d{2})\",\"$1 $2 $3 $4\",[\"0\"]],[\"(\\\\d{3})(\\\\d{3})(\\\\d{3})\",\"$1 $2 $3\",[\"2\"]],[\"(\\\\d{3})(\\\\d{3})(\\\\d{3})\",\"$1 $2 $3\",[\"[7-9]\"],\"0$1\"]],\"0\"],\"SA\":[\"966\",\"00\",\"(?:[15]\\\\d|800|92)\\\\d{7}\",[9,10],[[\"(\\\\d{4})(\\\\d{5})\",\"$1 $2\",[\"9\"]],[\"(\\\\d{2})(\\\\d{3})(\\\\d{4})\",\"$1 $2 $3\",[\"1\"],\"0$1\"],[\"(\\\\d{2})(\\\\d{3})(\\\\d{4})\",\"$1 $2 $3\",[\"5\"],\"0$1\"],[\"(\\\\d{3})(\\\\d{3})(\\\\d{4})\",\"$1 $2 $3\",[\"8\"]]],\"0\"],\"SB\":[\"677\",\"0[01]\",\"[6-9]\\\\d{6}|[1-6]\\\\d{4}\",[5,7],[[\"(\\\\d{2})(\\\\d{5})\",\"$1 $2\",[\"6[89]|7|8[4-9]|9(?:[1-8]|9[0-8])\"]]]],\"SC\":[\"248\",\"010|0[0-2]\",\"(?:[2489]\\\\d|64)\\\\d{5}\",[7],[[\"(\\\\d)(\\\\d{3})(\\\\d{3})\",\"$1 $2 $3\",[\"[246]|9[57]\"]]],0,0,0,0,0,0,0,\"00\"],\"SD\":[\"249\",\"00\",\"[19]\\\\d{8}\",[9],[[\"(\\\\d{2})(\\\\d{3})(\\\\d{4})\",\"$1 $2 $3\",[\"[19]\"],\"0$1\"]],\"0\"],\"SE\":[\"46\",\"00\",\"(?:[26]\\\\d\\\\d|9)\\\\d{9}|[1-9]\\\\d{8}|[1-689]\\\\d{7}|[1-4689]\\\\d{6}|2\\\\d{5}\",[6,7,8,9,10,12],[[\"(\\\\d{2})(\\\\d{2,3})(\\\\d{2})\",\"$1-$2 $3\",[\"20\"],\"0$1\",0,\"$1 $2 $3\"],[\"(\\\\d{3})(\\\\d{4})\",\"$1-$2\",[\"9(?:00|39|44|9)\"],\"0$1\",0,\"$1 $2\"],[\"(\\\\d{2})(\\\\d{3})(\\\\d{2})\",\"$1-$2 $3\",[\"[12][136]|3[356]|4[0246]|6[03]|90[1-9]\"],\"0$1\",0,\"$1 $2 $3\"],[\"(\\\\d)(\\\\d{2,3})(\\\\d{2})(\\\\d{2})\",\"$1-$2 $3 $4\",[\"8\"],\"0$1\",0,\"$1 $2 $3 $4\"],[\"(\\\\d{3})(\\\\d{2,3})(\\\\d{2})\",\"$1-$2 $3\",[\"1[2457]|2(?:[247-9]|5[0138])|3[0247-9]|4[1357-9]|5[0-35-9]|6(?:[125689]|4[02-57]|7[0-2])|9(?:[125-8]|3[02-5]|4[0-3])\"],\"0$1\",0,\"$1 $2 $3\"],[\"(\\\\d{3})(\\\\d{2,3})(\\\\d{3})\",\"$1-$2 $3\",[\"9(?:00|39|44)\"],\"0$1\",0,\"$1 $2 $3\"],[\"(\\\\d{2})(\\\\d{2,3})(\\\\d{2})(\\\\d{2})\",\"$1-$2 $3 $4\",[\"1[13689]|2[0136]|3[1356]|4[0246]|54|6[03]|90[1-9]\"],\"0$1\",0,\"$1 $2 $3 $4\"],[\"(\\\\d{2})(\\\\d{3})(\\\\d{2})(\\\\d{2})\",\"$1-$2 $3 $4\",[\"10|7\"],\"0$1\",0,\"$1 $2 $3 $4\"],[\"(\\\\d)(\\\\d{3})(\\\\d{3})(\\\\d{2})\",\"$1-$2 $3 $4\",[\"8\"],\"0$1\",0,\"$1 $2 $3 $4\"],[\"(\\\\d{3})(\\\\d{2})(\\\\d{2})(\\\\d{2})\",\"$1-$2 $3 $4\",[\"[13-5]|2(?:[247-9]|5[0138])|6(?:[124-689]|7[0-2])|9(?:[125-8]|3[02-5]|4[0-3])\"],\"0$1\",0,\"$1 $2 $3 $4\"],[\"(\\\\d{3})(\\\\d{2})(\\\\d{2})(\\\\d{3})\",\"$1-$2 $3 $4\",[\"9\"],\"0$1\",0,\"$1 $2 $3 $4\"],[\"(\\\\d{3})(\\\\d{2})(\\\\d{3})(\\\\d{2})(\\\\d{2})\",\"$1-$2 $3 $4 $5\",[\"[26]\"],\"0$1\",0,\"$1 $2 $3 $4 $5\"]],\"0\"],\"SG\":[\"65\",\"0[0-3]\\\\d\",\"(?:(?:1\\\\d|8)\\\\d\\\\d|7000)\\\\d{7}|[3689]\\\\d{7}\",[8,10,11],[[\"(\\\\d{4})(\\\\d{4})\",\"$1 $2\",[\"[369]|8(?:0[1-9]|[1-9])\"]],[\"(\\\\d{3})(\\\\d{3})(\\\\d{4})\",\"$1 $2 $3\",[\"8\"]],[\"(\\\\d{4})(\\\\d{4})(\\\\d{3})\",\"$1 $2 $3\",[\"7\"]],[\"(\\\\d{4})(\\\\d{3})(\\\\d{4})\",\"$1 $2 $3\",[\"1\"]]]],\"SH\":[\"290\",\"00\",\"(?:[256]\\\\d|8)\\\\d{3}\",[4,5],0,0,0,0,0,0,\"[256]\"],\"SI\":[\"386\",\"00|10(?:22|66|88|99)\",\"[1-7]\\\\d{7}|8\\\\d{4,7}|90\\\\d{4,6}\",[5,6,7,8],[[\"(\\\\d{2})(\\\\d{3,6})\",\"$1 $2\",[\"8[09]|9\"],\"0$1\"],[\"(\\\\d{3})(\\\\d{5})\",\"$1 $2\",[\"59|8\"],\"0$1\"],[\"(\\\\d{2})(\\\\d{3})(\\\\d{3})\",\"$1 $2 $3\",[\"[37][01]|4[013]|51|6\"],\"0$1\"],[\"(\\\\d)(\\\\d{3})(\\\\d{2})(\\\\d{2})\",\"$1 $2 $3 $4\",[\"[1-57]\"],\"(0$1)\"]],\"0\",0,0,0,0,0,0,\"00\"],\"SJ\":[\"47\",\"00\",\"0\\\\d{4}|(?:[489]\\\\d|79)\\\\d{6}\",[5,8],0,0,0,0,0,0,\"79\"],\"SK\":[\"421\",\"00\",\"[2-689]\\\\d{8}|[2-59]\\\\d{6}|[2-5]\\\\d{5}\",[6,7,9],[[\"(\\\\d)(\\\\d{2})(\\\\d{3,4})\",\"$1 $2 $3\",[\"21\"],\"0$1\"],[\"(\\\\d{2})(\\\\d{2})(\\\\d{2,3})\",\"$1 $2 $3\",[\"[3-5][1-8]1\",\"[3-5][1-8]1[67]\"],\"0$1\"],[\"(\\\\d)(\\\\d{3})(\\\\d{3})(\\\\d{2})\",\"$1 $2 $3 $4\",[\"2\"],\"0$1\"],[\"(\\\\d{3})(\\\\d{3})(\\\\d{3})\",\"$1 $2 $3\",[\"[689]\"],\"0$1\"],[\"(\\\\d{2})(\\\\d{3})(\\\\d{2})(\\\\d{2})\",\"$1 $2 $3 $4\",[\"[3-5]\"],\"0$1\"]],\"0\"],\"SL\":[\"232\",\"00\",\"(?:[237-9]\\\\d|66)\\\\d{6}\",[8],[[\"(\\\\d{2})(\\\\d{6})\",\"$1 $2\",[\"[236-9]\"],\"(0$1)\"]],\"0\"],\"SM\":[\"378\",\"00\",\"(?:0549|[5-7]\\\\d)\\\\d{6}\",[8,10],[[\"(\\\\d{2})(\\\\d{2})(\\\\d{2})(\\\\d{2})\",\"$1 $2 $3 $4\",[\"[5-7]\"]],[\"(\\\\d{4})(\\\\d{6})\",\"$1 $2\",[\"0\"]]],0,0,\"([89]\\\\d{5})$\",\"0549$1\"],\"SN\":[\"221\",\"00\",\"(?:[378]\\\\d|93)\\\\d{7}\",[9],[[\"(\\\\d{3})(\\\\d{2})(\\\\d{2})(\\\\d{2})\",\"$1 $2 $3 $4\",[\"8\"]],[\"(\\\\d{2})(\\\\d{3})(\\\\d{2})(\\\\d{2})\",\"$1 $2 $3 $4\",[\"[379]\"]]]],\"SO\":[\"252\",\"00\",\"[346-9]\\\\d{8}|[12679]\\\\d{7}|[1-5]\\\\d{6}|[1348]\\\\d{5}\",[6,7,8,9],[[\"(\\\\d{2})(\\\\d{4})\",\"$1 $2\",[\"8[125]\"]],[\"(\\\\d{6})\",\"$1\",[\"[134]\"]],[\"(\\\\d)(\\\\d{6})\",\"$1 $2\",[\"[15]|2[0-79]|3[0-46-8]|4[0-7]\"]],[\"(\\\\d{2})(\\\\d{5,7})\",\"$1 $2\",[\"1|28|9[2-9]\"]],[\"(\\\\d)(\\\\d{7})\",\"$1 $2\",[\"[267]|904\"]],[\"(\\\\d{2})(\\\\d{3})(\\\\d{4})\",\"$1 $2 $3\",[\"[346-9]\"]]],\"0\"],\"SR\":[\"597\",\"00\",\"(?:[2-5]|[6-9]\\\\d)\\\\d{5}\",[6,7],[[\"(\\\\d{2})(\\\\d{2})(\\\\d{2})\",\"$1-$2-$3\",[\"56\"]],[\"(\\\\d{3})(\\\\d{3})\",\"$1-$2\",[\"[2-5]\"]],[\"(\\\\d{3})(\\\\d{4})\",\"$1-$2\",[\"[6-9]\"]]]],\"SS\":[\"211\",\"00\",\"[19]\\\\d{8}\",[9],[[\"(\\\\d{3})(\\\\d{3})(\\\\d{3})\",\"$1 $2 $3\",[\"[19]\"],\"0$1\"]],\"0\"],\"ST\":[\"239\",\"00\",\"(?:22|9\\\\d)\\\\d{5}\",[7],[[\"(\\\\d{3})(\\\\d{4})\",\"$1 $2\",[\"[29]\"]]]],\"SV\":[\"503\",\"00\",\"[25-7]\\\\d{7}|(?:80\\\\d|900)\\\\d{4}(?:\\\\d{4})?\",[7,8,11],[[\"(\\\\d{3})(\\\\d{4})\",\"$1 $2\",[\"[89]\"]],[\"(\\\\d{4})(\\\\d{4})\",\"$1 $2\",[\"[25-7]\"]],[\"(\\\\d{3})(\\\\d{4})(\\\\d{4})\",\"$1 $2 $3\",[\"[89]\"]]]],\"SX\":[\"1\",\"011\",\"7215\\\\d{6}|(?:[58]\\\\d\\\\d|900)\\\\d{7}\",[10],0,\"1\",0,\"(5\\\\d{6})$|1\",\"721$1\",0,\"721\"],\"SY\":[\"963\",\"00\",\"[1-359]\\\\d{8}|[1-5]\\\\d{7}\",[8,9],[[\"(\\\\d{2})(\\\\d{3})(\\\\d{3,4})\",\"$1 $2 $3\",[\"[1-4]|5[1-3]\"],\"0$1\",1],[\"(\\\\d{3})(\\\\d{3})(\\\\d{3})\",\"$1 $2 $3\",[\"[59]\"],\"0$1\",1]],\"0\"],\"SZ\":[\"268\",\"00\",\"0800\\\\d{4}|(?:[237]\\\\d|900)\\\\d{6}\",[8,9],[[\"(\\\\d{4})(\\\\d{4})\",\"$1 $2\",[\"[0237]\"]],[\"(\\\\d{5})(\\\\d{4})\",\"$1 $2\",[\"9\"]]]],\"TA\":[\"290\",\"00\",\"8\\\\d{3}\",[4],0,0,0,0,0,0,\"8\"],\"TC\":[\"1\",\"011\",\"(?:[58]\\\\d\\\\d|649|900)\\\\d{7}\",[10],0,\"1\",0,\"([2-479]\\\\d{6})$|1\",\"649$1\",0,\"649\"],\"TD\":[\"235\",\"00|16\",\"(?:22|[3689]\\\\d|77)\\\\d{6}\",[8],[[\"(\\\\d{2})(\\\\d{2})(\\\\d{2})(\\\\d{2})\",\"$1 $2 $3 $4\",[\"[236-9]\"]]],0,0,0,0,0,0,0,\"00\"],\"TG\":[\"228\",\"00\",\"[279]\\\\d{7}\",[8],[[\"(\\\\d{2})(\\\\d{2})(\\\\d{2})(\\\\d{2})\",\"$1 $2 $3 $4\",[\"[279]\"]]]],\"TH\":[\"66\",\"00[1-9]\",\"(?:001800|[2-57]|[689]\\\\d)\\\\d{7}|1\\\\d{7,9}\",[8,9,10,13],[[\"(\\\\d)(\\\\d{3})(\\\\d{4})\",\"$1 $2 $3\",[\"2\"],\"0$1\"],[\"(\\\\d{2})(\\\\d{3})(\\\\d{3,4})\",\"$1 $2 $3\",[\"[13-9]\"],\"0$1\"],[\"(\\\\d{4})(\\\\d{3})(\\\\d{3})\",\"$1 $2 $3\",[\"1\"]]],\"0\"],\"TJ\":[\"992\",\"810\",\"(?:[0-57-9]\\\\d|66)\\\\d{7}\",[9],[[\"(\\\\d{6})(\\\\d)(\\\\d{2})\",\"$1 $2 $3\",[\"331\",\"3317\"]],[\"(\\\\d{3})(\\\\d{2})(\\\\d{4})\",\"$1 $2 $3\",[\"44[02-479]|[34]7\"]],[\"(\\\\d{4})(\\\\d)(\\\\d{4})\",\"$1 $2 $3\",[\"3(?:[1245]|3[12])\"]],[\"(\\\\d{2})(\\\\d{3})(\\\\d{4})\",\"$1 $2 $3\",[\"\\\\d\"]]],0,0,0,0,0,0,0,\"8~10\"],\"TK\":[\"690\",\"00\",\"[2-47]\\\\d{3,6}\",[4,5,6,7]],\"TL\":[\"670\",\"00\",\"7\\\\d{7}|(?:[2-47]\\\\d|[89]0)\\\\d{5}\",[7,8],[[\"(\\\\d{3})(\\\\d{4})\",\"$1 $2\",[\"[2-489]|70\"]],[\"(\\\\d{4})(\\\\d{4})\",\"$1 $2\",[\"7\"]]]],\"TM\":[\"993\",\"810\",\"(?:[1-6]\\\\d|71)\\\\d{6}\",[8],[[\"(\\\\d{2})(\\\\d{2})(\\\\d{2})(\\\\d{2})\",\"$1 $2-$3-$4\",[\"12\"],\"(8 $1)\"],[\"(\\\\d{3})(\\\\d)(\\\\d{2})(\\\\d{2})\",\"$1 $2-$3-$4\",[\"[1-5]\"],\"(8 $1)\"],[\"(\\\\d{2})(\\\\d{6})\",\"$1 $2\",[\"[67]\"],\"8 $1\"]],\"8\",0,0,0,0,0,0,\"8~10\"],\"TN\":[\"216\",\"00\",\"[2-57-9]\\\\d{7}\",[8],[[\"(\\\\d{2})(\\\\d{3})(\\\\d{3})\",\"$1 $2 $3\",[\"[2-57-9]\"]]]],\"TO\":[\"676\",\"00\",\"(?:0800|(?:[5-8]\\\\d\\\\d|999)\\\\d)\\\\d{3}|[2-8]\\\\d{4}\",[5,7],[[\"(\\\\d{2})(\\\\d{3})\",\"$1-$2\",[\"[2-4]|50|6[09]|7[0-24-69]|8[05]\"]],[\"(\\\\d{4})(\\\\d{3})\",\"$1 $2\",[\"0\"]],[\"(\\\\d{3})(\\\\d{4})\",\"$1 $2\",[\"[5-9]\"]]]],\"TR\":[\"90\",\"00\",\"4\\\\d{6}|8\\\\d{11,12}|(?:[2-58]\\\\d\\\\d|900)\\\\d{7}\",[7,10,12,13],[[\"(\\\\d{3})(\\\\d{3})(\\\\d{4})\",\"$1 $2 $3\",[\"512|8[01589]|90\"],\"0$1\",1],[\"(\\\\d{3})(\\\\d{3})(\\\\d{2})(\\\\d{2})\",\"$1 $2 $3 $4\",[\"5[0-79]\"],\"0$1\",1],[\"(\\\\d{3})(\\\\d{3})(\\\\d{2})(\\\\d{2})\",\"$1 $2 $3 $4\",[\"[24][1-8]|3[1-9]\"],\"(0$1)\",1],[\"(\\\\d{3})(\\\\d{3})(\\\\d{6,7})\",\"$1 $2 $3\",[\"80\"],\"0$1\",1]],\"0\"],\"TT\":[\"1\",\"011\",\"(?:[58]\\\\d\\\\d|900)\\\\d{7}\",[10],0,\"1\",0,\"([2-46-8]\\\\d{6})$|1\",\"868$1\",0,\"868\"],\"TV\":[\"688\",\"00\",\"(?:2|7\\\\d\\\\d|90)\\\\d{4}\",[5,6,7],[[\"(\\\\d{2})(\\\\d{3})\",\"$1 $2\",[\"2\"]],[\"(\\\\d{2})(\\\\d{4})\",\"$1 $2\",[\"90\"]],[\"(\\\\d{2})(\\\\d{5})\",\"$1 $2\",[\"7\"]]]],\"TW\":[\"886\",\"0(?:0[25-79]|19)\",\"[2-689]\\\\d{8}|7\\\\d{9,10}|[2-8]\\\\d{7}|2\\\\d{6}\",[7,8,9,10,11],[[\"(\\\\d{2})(\\\\d)(\\\\d{4})\",\"$1 $2 $3\",[\"202\"],\"0$1\"],[\"(\\\\d{3})(\\\\d{5})\",\"$1 $2\",[\"826\"],\"0$1\"],[\"(\\\\d{3})(\\\\d{2})(\\\\d{3})\",\"$1 $2 $3\",[\"83\"],\"0$1\"],[\"(\\\\d{2})(\\\\d{2})(\\\\d{4})\",\"$1 $2 $3\",[\"82\"],\"0$1\"],[\"(\\\\d{2})(\\\\d{3})(\\\\d{3,4})\",\"$1 $2 $3\",[\"[25]0|37|49|8[09]\"],\"0$1\"],[\"(\\\\d)(\\\\d{3,4})(\\\\d{4})\",\"$1 $2 $3\",[\"[23568]|4(?:0[02-48]|[1-478])|7[1-9]\",\"[23568]|4(?:0[2-48]|[1-478])|(?:400|7)[1-9]\"],\"0$1\"],[\"(\\\\d{3})(\\\\d{3})(\\\\d{3})\",\"$1 $2 $3\",[\"[49]\"],\"0$1\"],[\"(\\\\d{2})(\\\\d{4})(\\\\d{4,5})\",\"$1 $2 $3\",[\"7\"],\"0$1\"]],\"0\",0,0,0,0,0,0,0,\"#\"],\"TZ\":[\"255\",\"00[056]\",\"(?:[25-8]\\\\d|41|90)\\\\d{7}\",[9],[[\"(\\\\d{3})(\\\\d{2})(\\\\d{4})\",\"$1 $2 $3\",[\"[89]\"],\"0$1\"],[\"(\\\\d{2})(\\\\d{3})(\\\\d{4})\",\"$1 $2 $3\",[\"[24]\"],\"0$1\"],[\"(\\\\d{2})(\\\\d{7})\",\"$1 $2\",[\"5\"]],[\"(\\\\d{3})(\\\\d{3})(\\\\d{3})\",\"$1 $2 $3\",[\"[67]\"],\"0$1\"]],\"0\"],\"UA\":[\"380\",\"00\",\"[89]\\\\d{9}|[3-9]\\\\d{8}\",[9,10],[[\"(\\\\d{3})(\\\\d{3})(\\\\d{3})\",\"$1 $2 $3\",[\"6[12][29]|(?:3[1-8]|4[136-8]|5[12457]|6[49])2|(?:56|65)[24]\",\"6[12][29]|(?:35|4[1378]|5[12457]|6[49])2|(?:56|65)[24]|(?:3[1-46-8]|46)2[013-9]\"],\"0$1\"],[\"(\\\\d{4})(\\\\d{5})\",\"$1 $2\",[\"3[1-8]|4(?:[1367]|[45][6-9]|8[4-6])|5(?:[1-5]|6[0135689]|7[4-6])|6(?:[12][3-7]|[459])\",\"3[1-8]|4(?:[1367]|[45][6-9]|8[4-6])|5(?:[1-5]|6(?:[015689]|3[02389])|7[4-6])|6(?:[12][3-7]|[459])\"],\"0$1\"],[\"(\\\\d{2})(\\\\d{3})(\\\\d{4})\",\"$1 $2 $3\",[\"[3-7]|89|9[1-9]\"],\"0$1\"],[\"(\\\\d{3})(\\\\d{3})(\\\\d{3,4})\",\"$1 $2 $3\",[\"[89]\"],\"0$1\"]],\"0\",0,0,0,0,0,0,\"0~0\"],\"UG\":[\"256\",\"00[057]\",\"800\\\\d{6}|(?:[29]0|[347]\\\\d)\\\\d{7}\",[9],[[\"(\\\\d{4})(\\\\d{5})\",\"$1 $2\",[\"202\",\"2024\"],\"0$1\"],[\"(\\\\d{3})(\\\\d{6})\",\"$1 $2\",[\"[27-9]|4(?:6[45]|[7-9])\"],\"0$1\"],[\"(\\\\d{2})(\\\\d{7})\",\"$1 $2\",[\"[34]\"],\"0$1\"]],\"0\"],\"US\":[\"1\",\"011\",\"[2-9]\\\\d{9}|3\\\\d{6}\",[10],[[\"(\\\\d{3})(\\\\d{4})\",\"$1-$2\",[\"310\"],0,1],[\"(\\\\d{3})(\\\\d{3})(\\\\d{4})\",\"($1) $2-$3\",[\"[2-9]\"],0,1,\"$1-$2-$3\"]],\"1\",0,0,0,0,0,[[\"(?:274[27]|(?:472|983)[2-47-9])\\\\d{6}|(?:2(?:0[1-35-9]|1[02-9]|2[03-57-9]|3[1459]|4[08]|5[1-46]|6[0279]|7[0269]|8[13])|3(?:0[1-57-9]|1[02-9]|2[013-79]|3[0-24679]|4[167]|5[0-3]|6[01349]|8[056])|4(?:0[124-9]|1[02-579]|2[3-5]|3[0245]|4[023578]|58|6[349]|7[0589]|8[04])|5(?:0[1-57-9]|1[0235-8]|20|3[0149]|4[01]|5[179]|6[1-47]|7[0-5]|8[0256])|6(?:0[1-35-9]|1[024-9]|2[03689]|3[016]|4[0156]|5[01679]|6[0-279]|78|8[0-269])|7(?:0[1-46-8]|1[2-9]|2[04-8]|3[0-2478]|4[0378]|5[47]|6[02359]|7[0-59]|8[156])|8(?:0[1-68]|1[02-8]|2[0168]|3[0-2589]|4[03578]|5[046-9]|6[02-5]|7[028])|9(?:0[1346-9]|1[02-9]|2[0589]|3[0146-8]|4[01357-9]|5[12469]|7[0-3589]|8[04-69]))[2-9]\\\\d{6}\"],[\"\"],[\"8(?:00|33|44|55|66|77|88)[2-9]\\\\d{6}\"],[\"900[2-9]\\\\d{6}\"],[\"52(?:3(?:[2-46-9][02-9]\\\\d|5(?:[02-46-9]\\\\d|5[0-46-9]))|4(?:[2-478][02-9]\\\\d|5(?:[034]\\\\d|2[024-9]|5[0-46-9])|6(?:0[1-9]|[2-9]\\\\d)|9(?:[05-9]\\\\d|2[0-5]|49)))\\\\d{4}|52[34][2-9]1[02-9]\\\\d{4}|5(?:00|2[125-9]|3[23]|44|66|77|88)[2-9]\\\\d{6}\"]]],\"UY\":[\"598\",\"0(?:0|1[3-9]\\\\d)\",\"0004\\\\d{2,9}|[1249]\\\\d{7}|2\\\\d{3,4}|(?:[49]\\\\d|80)\\\\d{5}\",[4,5,6,7,8,9,10,11,12,13],[[\"(\\\\d{4,5})\",\"$1\",[\"21\"]],[\"(\\\\d{3})(\\\\d{3,4})\",\"$1 $2\",[\"0\"]],[\"(\\\\d{3})(\\\\d{4})\",\"$1 $2\",[\"[49]0|8\"],\"0$1\"],[\"(\\\\d{2})(\\\\d{3})(\\\\d{3})\",\"$1 $2 $3\",[\"9\"],\"0$1\"],[\"(\\\\d{4})(\\\\d{4})\",\"$1 $2\",[\"[124]\"]],[\"(\\\\d{3})(\\\\d{3})(\\\\d{2,4})\",\"$1 $2 $3\",[\"0\"]],[\"(\\\\d{3})(\\\\d{3})(\\\\d{3})(\\\\d{2,4})\",\"$1 $2 $3 $4\",[\"0\"]]],\"0\",0,0,0,0,0,0,\"00\",\" int. \"],\"UZ\":[\"998\",\"00\",\"(?:20|33|[5-9]\\\\d)\\\\d{7}\",[9],[[\"(\\\\d{2})(\\\\d{3})(\\\\d{2})(\\\\d{2})\",\"$1 $2 $3 $4\",[\"[235-9]\"]]]],\"VA\":[\"39\",\"00\",\"0\\\\d{5,10}|3[0-8]\\\\d{7,10}|55\\\\d{8}|8\\\\d{5}(?:\\\\d{2,4})?|(?:1\\\\d|39)\\\\d{7,8}\",[6,7,8,9,10,11,12],0,0,0,0,0,0,\"06698\"],\"VC\":[\"1\",\"011\",\"(?:[58]\\\\d\\\\d|784|900)\\\\d{7}\",[10],0,\"1\",0,\"([2-7]\\\\d{6})$|1\",\"784$1\",0,\"784\"],\"VE\":[\"58\",\"00\",\"[68]00\\\\d{7}|(?:[24]\\\\d|[59]0)\\\\d{8}\",[10],[[\"(\\\\d{3})(\\\\d{7})\",\"$1-$2\",[\"[24-689]\"],\"0$1\"]],\"0\"],\"VG\":[\"1\",\"011\",\"(?:284|[58]\\\\d\\\\d|900)\\\\d{7}\",[10],0,\"1\",0,\"([2-578]\\\\d{6})$|1\",\"284$1\",0,\"284\"],\"VI\":[\"1\",\"011\",\"[58]\\\\d{9}|(?:34|90)0\\\\d{7}\",[10],0,\"1\",0,\"([2-9]\\\\d{6})$|1\",\"340$1\",0,\"340\"],\"VN\":[\"84\",\"00\",\"[12]\\\\d{9}|[135-9]\\\\d{8}|[16]\\\\d{6,7}|7\\\\d{6}\",[7,8,9,10],[[\"(\\\\d{4})(\\\\d{4,6})\",\"$1 $2\",[\"1(?:2[02]|[89])\"],0,1],[\"(\\\\d{2})(\\\\d{3})(\\\\d{2})(\\\\d{2})\",\"$1 $2 $3 $4\",[\"1[26]|6\"],\"0$1\",1],[\"(\\\\d{3})(\\\\d{3})(\\\\d{3})\",\"$1 $2 $3\",[\"[357-9]\"],\"0$1\",1],[\"(\\\\d{2})(\\\\d{4})(\\\\d{4})\",\"$1 $2 $3\",[\"2[48]\"],\"0$1\",1],[\"(\\\\d{3})(\\\\d{4})(\\\\d{3})\",\"$1 $2 $3\",[\"2\"],\"0$1\",1]],\"0\"],\"VU\":[\"678\",\"00\",\"[57-9]\\\\d{6}|(?:[238]\\\\d|48)\\\\d{3}\",[5,7],[[\"(\\\\d{3})(\\\\d{4})\",\"$1 $2\",[\"[57-9]\"]]]],\"WF\":[\"681\",\"00\",\"(?:40|72|8\\\\d{4})\\\\d{4}|[89]\\\\d{5}\",[6,9],[[\"(\\\\d{2})(\\\\d{2})(\\\\d{2})\",\"$1 $2 $3\",[\"[47-9]\"]],[\"(\\\\d{3})(\\\\d{2})(\\\\d{2})(\\\\d{2})\",\"$1 $2 $3 $4\",[\"8\"]]]],\"WS\":[\"685\",\"0\",\"(?:[2-6]|8\\\\d{5})\\\\d{4}|[78]\\\\d{6}|[68]\\\\d{5}\",[5,6,7,10],[[\"(\\\\d{5})\",\"$1\",[\"[2-5]|6[1-9]\"]],[\"(\\\\d{3})(\\\\d{3,7})\",\"$1 $2\",[\"[68]\"]],[\"(\\\\d{2})(\\\\d{5})\",\"$1 $2\",[\"7\"]]]],\"XK\":[\"383\",\"00\",\"2\\\\d{7,8}|3\\\\d{7,11}|(?:4\\\\d\\\\d|[89]00)\\\\d{5}\",[8,9,10,11,12],[[\"(\\\\d{3})(\\\\d{5})\",\"$1 $2\",[\"[89]\"],\"0$1\"],[\"(\\\\d{2})(\\\\d{3})(\\\\d{3})\",\"$1 $2 $3\",[\"[2-4]\"],\"0$1\"],[\"(\\\\d{3})(\\\\d{3})(\\\\d{3})\",\"$1 $2 $3\",[\"2|39\"],\"0$1\"],[\"(\\\\d{2})(\\\\d{7,10})\",\"$1 $2\",[\"3\"],\"0$1\"]],\"0\"],\"YE\":[\"967\",\"00\",\"(?:1|7\\\\d)\\\\d{7}|[1-7]\\\\d{6}\",[7,8,9],[[\"(\\\\d)(\\\\d{3})(\\\\d{3,4})\",\"$1 $2 $3\",[\"[1-6]|7(?:[24-6]|8[0-7])\"],\"0$1\"],[\"(\\\\d{3})(\\\\d{3})(\\\\d{3})\",\"$1 $2 $3\",[\"7\"],\"0$1\"]],\"0\"],\"YT\":[\"262\",\"00\",\"(?:639\\\\d|7093)\\\\d{5}|(?:26|80|9\\\\d)\\\\d{7}\",[9],0,\"0\",0,0,0,0,0,[[\"26(?:89\\\\d|9(?:0[0-467]|15|5[0-4]|6\\\\d|[78]0))\\\\d{4}\"],[\"(?:639(?:0[0-79]|1[019]|[267]\\\\d|3[09]|40|5[05-9]|9[04-79])|7093[5-7])\\\\d{4}\"],[\"80\\\\d{7}\"],0,0,0,0,0,[\"9(?:(?:39|47)8[01]|769\\\\d)\\\\d{4}\"]]],\"ZA\":[\"27\",\"00\",\"[1-79]\\\\d{8}|8\\\\d{4,9}\",[5,6,7,8,9,10],[[\"(\\\\d{2})(\\\\d{3,4})\",\"$1 $2\",[\"8[1-4]\"],\"0$1\"],[\"(\\\\d{2})(\\\\d{3})(\\\\d{2,3})\",\"$1 $2 $3\",[\"8[1-4]\"],\"0$1\"],[\"(\\\\d{3})(\\\\d{3})(\\\\d{3})\",\"$1 $2 $3\",[\"860\"],\"0$1\"],[\"(\\\\d{2})(\\\\d{3})(\\\\d{4})\",\"$1 $2 $3\",[\"[1-9]\"],\"0$1\"],[\"(\\\\d{3})(\\\\d{3})(\\\\d{4})\",\"$1 $2 $3\",[\"8\"],\"0$1\"]],\"0\"],\"ZM\":[\"260\",\"00\",\"800\\\\d{6}|(?:21|[579]\\\\d|63)\\\\d{7}\",[9],[[\"(\\\\d{3})(\\\\d{3})(\\\\d{3})\",\"$1 $2 $3\",[\"[28]\"],\"0$1\"],[\"(\\\\d{2})(\\\\d{7})\",\"$1 $2\",[\"[579]\"],\"0$1\"]],\"0\"],\"ZW\":[\"263\",\"00\",\"2(?:[0-57-9]\\\\d{6,8}|6[0-24-9]\\\\d{6,7})|[38]\\\\d{9}|[35-8]\\\\d{8}|[3-6]\\\\d{7}|[1-689]\\\\d{6}|[1-3569]\\\\d{5}|[1356]\\\\d{4}\",[5,6,7,8,9,10],[[\"(\\\\d{3})(\\\\d{3,5})\",\"$1 $2\",[\"2(?:0[45]|2[278]|[49]8)|3(?:[09]8|17)|6(?:[29]8|37|75)|[23][78]|(?:33|5[15]|6[68])[78]\"],\"0$1\"],[\"(\\\\d)(\\\\d{3})(\\\\d{2,4})\",\"$1 $2 $3\",[\"[49]\"],\"0$1\"],[\"(\\\\d{3})(\\\\d{4})\",\"$1 $2\",[\"80\"],\"0$1\"],[\"(\\\\d{2})(\\\\d{7})\",\"$1 $2\",[\"24|8[13-59]|(?:2[05-79]|39|5[45]|6[15-8])2\",\"2(?:02[014]|4|[56]20|[79]2)|392|5(?:42|525)|6(?:[16-8]21|52[013])|8[13-59]\"],\"(0$1)\"],[\"(\\\\d{2})(\\\\d{3})(\\\\d{4})\",\"$1 $2 $3\",[\"7\"],\"0$1\"],[\"(\\\\d{3})(\\\\d{3})(\\\\d{3,4})\",\"$1 $2 $3\",[\"2(?:1[39]|2[0157]|[378]|[56][14])|3(?:12|29)\",\"2(?:1[39]|2[0157]|[378]|[56][14])|3(?:123|29)\"],\"0$1\"],[\"(\\\\d{4})(\\\\d{6})\",\"$1 $2\",[\"8\"],\"0$1\"],[\"(\\\\d{2})(\\\\d{3,5})\",\"$1 $2\",[\"1|2(?:0[0-36-9]|12|29|[56])|3(?:1[0-689]|[24-6])|5(?:[0236-9]|1[2-4])|6(?:[013-59]|7[0-46-9])|(?:33|55|6[68])[0-69]|(?:29|3[09]|62)[0-79]\"],\"0$1\"],[\"(\\\\d{2})(\\\\d{3})(\\\\d{3,4})\",\"$1 $2 $3\",[\"29[013-9]|39|54\"],\"0$1\"],[\"(\\\\d{4})(\\\\d{3,5})\",\"$1 $2\",[\"(?:25|54)8\",\"258|5483\"],\"0$1\"]],\"0\"]},\"nonGeographic\":{\"800\":[\"800\",0,\"(?:00|[1-9]\\\\d)\\\\d{6}\",[8],[[\"(\\\\d{4})(\\\\d{4})\",\"$1 $2\",[\"\\\\d\"]]],0,0,0,0,0,0,[0,0,[\"(?:00|[1-9]\\\\d)\\\\d{6}\"]]],\"808\":[\"808\",0,\"[1-9]\\\\d{7}\",[8],[[\"(\\\\d{4})(\\\\d{4})\",\"$1 $2\",[\"[1-9]\"]]],0,0,0,0,0,0,[0,0,0,0,0,0,0,0,0,[\"[1-9]\\\\d{7}\"]]],\"870\":[\"870\",0,\"7\\\\d{11}|[235-7]\\\\d{8}\",[9,12],[[\"(\\\\d{3})(\\\\d{3})(\\\\d{3})\",\"$1 $2 $3\",[\"[235-7]\"]]],0,0,0,0,0,0,[0,[\"(?:[356]|774[45])\\\\d{8}|7[6-8]\\\\d{7}\"],0,0,0,0,0,0,[\"2\\\\d{8}\",[9]]]],\"878\":[\"878\",0,\"10\\\\d{10}\",[12],[[\"(\\\\d{2})(\\\\d{5})(\\\\d{5})\",\"$1 $2 $3\",[\"1\"]]],0,0,0,0,0,0,[0,0,0,0,0,0,0,0,[\"10\\\\d{10}\"]]],\"881\":[\"881\",0,\"6\\\\d{9}|[0-36-9]\\\\d{8}\",[9,10],[[\"(\\\\d)(\\\\d{3})(\\\\d{5})\",\"$1 $2 $3\",[\"[0-37-9]\"]],[\"(\\\\d)(\\\\d{3})(\\\\d{5,6})\",\"$1 $2 $3\",[\"6\"]]],0,0,0,0,0,0,[0,[\"6\\\\d{9}|[0-36-9]\\\\d{8}\"]]],\"882\":[\"882\",0,\"[13]\\\\d{6}(?:\\\\d{2,5})?|[19]\\\\d{7}|(?:[25]\\\\d\\\\d|4)\\\\d{7}(?:\\\\d{2})?\",[7,8,9,10,11,12],[[\"(\\\\d{2})(\\\\d{5})\",\"$1 $2\",[\"16|342\"]],[\"(\\\\d{2})(\\\\d{6})\",\"$1 $2\",[\"49\"]],[\"(\\\\d{2})(\\\\d{2})(\\\\d{4})\",\"$1 $2 $3\",[\"1[36]|9\"]],[\"(\\\\d{2})(\\\\d{4})(\\\\d{3})\",\"$1 $2 $3\",[\"3[23]\"]],[\"(\\\\d{2})(\\\\d{3,4})(\\\\d{4})\",\"$1 $2 $3\",[\"16\"]],[\"(\\\\d{2})(\\\\d{4})(\\\\d{4})\",\"$1 $2 $3\",[\"10|23|3(?:[15]|4[57])|4|5[12]\"]],[\"(\\\\d{3})(\\\\d{4})(\\\\d{4})\",\"$1 $2 $3\",[\"34\"]],[\"(\\\\d{2})(\\\\d{4,5})(\\\\d{5})\",\"$1 $2 $3\",[\"[1-35]\"]]],0,0,0,0,0,0,[0,[\"342\\\\d{4}|(?:337|49)\\\\d{6}|(?:3(?:2|47|7\\\\d{3})|5(?:0\\\\d{3}|2[0-2]))\\\\d{7}\",[7,8,9,10,12]],0,0,0,[\"348[57]\\\\d{7}\",[11]],0,0,[\"1(?:3(?:0[0347]|[13][0139]|2[035]|4[013568]|6[0459]|7[06]|8[15-8]|9[0689])\\\\d{4}|6\\\\d{5,10})|(?:345\\\\d|9[89])\\\\d{6}|(?:10|2(?:3|85\\\\d)|3(?:[15]|[69]\\\\d\\\\d)|4[15-8]|51)\\\\d{8}\"]]],\"883\":[\"883\",0,\"(?:[1-4]\\\\d|51)\\\\d{6,10}\",[8,9,10,11,12],[[\"(\\\\d{3})(\\\\d{3})(\\\\d{2,8})\",\"$1 $2 $3\",[\"[14]|2[24-689]|3[02-689]|51[24-9]\"]],[\"(\\\\d{3})(\\\\d{3})(\\\\d{3})\",\"$1 $2 $3\",[\"510\"]],[\"(\\\\d{3})(\\\\d{3})(\\\\d{4})\",\"$1 $2 $3\",[\"21\"]],[\"(\\\\d{4})(\\\\d{4})(\\\\d{4})\",\"$1 $2 $3\",[\"51[13]\"]],[\"(\\\\d{3})(\\\\d{3})(\\\\d{3})(\\\\d{3})\",\"$1 $2 $3 $4\",[\"[235]\"]]],0,0,0,0,0,0,[0,0,0,0,0,0,0,0,[\"(?:2(?:00\\\\d\\\\d|10)|(?:370[1-9]|51\\\\d0)\\\\d)\\\\d{7}|51(?:00\\\\d{5}|[24-9]0\\\\d{4,7})|(?:1[0-79]|2[24-689]|3[02-689]|4[0-4])0\\\\d{5,9}\"]]],\"888\":[\"888\",0,\"\\\\d{11}\",[11],[[\"(\\\\d{3})(\\\\d{3})(\\\\d{5})\",\"$1 $2 $3\"]],0,0,0,0,0,0,[0,0,0,0,0,0,[\"\\\\d{11}\"]]],\"979\":[\"979\",0,\"[1359]\\\\d{8}\",[9],[[\"(\\\\d)(\\\\d{4})(\\\\d{4})\",\"$1 $2 $3\",[\"[1359]\"]]],0,0,0,0,0,0,[0,0,0,[\"[1359]\\\\d{8}\"]]]}}","// Importing from a \".js\" file is a workaround for Node.js \"ES Modules\"\r\n// importing system which is even uncapable of importing \"*.json\" files.\r\nimport metadata from '../../metadata.min.json.js'\r\n\r\nexport default function withMetadataArgument(func, _arguments) {\r\n\tvar args = Array.prototype.slice.call(_arguments)\r\n\targs.push(metadata)\r\n\treturn func.apply(this, args)\r\n}","// The minimum length of the national significant number.\nexport var MIN_LENGTH_FOR_NSN = 2;\n\n// The ITU says the maximum length should be 15,\n// but one can find longer numbers in Germany.\nexport var MAX_LENGTH_FOR_NSN = 17;\n\n// The maximum length of the country calling code.\nexport var MAX_LENGTH_COUNTRY_CODE = 3;\n\n// Digits accepted in phone numbers\n// (ascii, fullwidth, arabic-indic, and eastern arabic digits).\nexport var VALID_DIGITS = \"0-9\\uFF10-\\uFF19\\u0660-\\u0669\\u06F0-\\u06F9\";\n\n// `DASHES` will be right after the opening square bracket of the \"character class\"\nvar DASHES = \"-\\u2010-\\u2015\\u2212\\u30FC\\uFF0D\";\nvar SLASHES = \"\\uFF0F/\";\nvar DOTS = \"\\uFF0E.\";\nexport var WHITESPACE = \" \\xA0\\xAD\\u200B\\u2060\\u3000\";\nvar BRACKETS = \"()\\uFF08\\uFF09\\uFF3B\\uFF3D\\\\[\\\\]\";\n// export const OPENING_BRACKETS = '(\\uFF08\\uFF3B\\\\\\['\nvar TILDES = \"~\\u2053\\u223C\\uFF5E\";\n\n// Regular expression of acceptable punctuation found in phone numbers. This\n// excludes punctuation found as a leading character only. This consists of dash\n// characters, white space characters, full stops, slashes, square brackets,\n// parentheses and tildes. Full-width variants are also present.\nexport var VALID_PUNCTUATION = \"\".concat(DASHES).concat(SLASHES).concat(DOTS).concat(WHITESPACE).concat(BRACKETS).concat(TILDES);\nexport var PLUS_CHARS = \"+\\uFF0B\";\n// const LEADING_PLUS_CHARS_PATTERN = new RegExp('^[' + PLUS_CHARS + ']+')\n//# sourceMappingURL=constants.js.map","function _typeof(o) { \"@babel/helpers - typeof\"; return _typeof = \"function\" == typeof Symbol && \"symbol\" == typeof Symbol.iterator ? function (o) { return typeof o; } : function (o) { return o && \"function\" == typeof Symbol && o.constructor === Symbol && o !== Symbol.prototype ? \"symbol\" : typeof o; }, _typeof(o); }\nfunction _defineProperties(e, r) { for (var t = 0; t < r.length; t++) { var o = r[t]; o.enumerable = o.enumerable || !1, o.configurable = !0, \"value\" in o && (o.writable = !0), Object.defineProperty(e, _toPropertyKey(o.key), o); } }\nfunction _createClass(e, r, t) { return r && _defineProperties(e.prototype, r), t && _defineProperties(e, t), Object.defineProperty(e, \"prototype\", { writable: !1 }), e; }\nfunction _toPropertyKey(t) { var i = _toPrimitive(t, \"string\"); return \"symbol\" == _typeof(i) ? i : i + \"\"; }\nfunction _toPrimitive(t, r) { if (\"object\" != _typeof(t) || !t) return t; var e = t[Symbol.toPrimitive]; if (void 0 !== e) { var i = e.call(t, r || \"default\"); if (\"object\" != _typeof(i)) return i; throw new TypeError(\"@@toPrimitive must return a primitive value.\"); } return (\"string\" === r ? String : Number)(t); }\nfunction _classCallCheck(a, n) { if (!(a instanceof n)) throw new TypeError(\"Cannot call a class as a function\"); }\nfunction _callSuper(t, o, e) { return o = _getPrototypeOf(o), _possibleConstructorReturn(t, _isNativeReflectConstruct() ? Reflect.construct(o, e || [], _getPrototypeOf(t).constructor) : o.apply(t, e)); }\nfunction _possibleConstructorReturn(t, e) { if (e && (\"object\" == _typeof(e) || \"function\" == typeof e)) return e; if (void 0 !== e) throw new TypeError(\"Derived constructors may only return object or undefined\"); return _assertThisInitialized(t); }\nfunction _assertThisInitialized(e) { if (void 0 === e) throw new ReferenceError(\"this hasn't been initialised - super() hasn't been called\"); return e; }\nfunction _inherits(t, e) { if (\"function\" != typeof e && null !== e) throw new TypeError(\"Super expression must either be null or a function\"); t.prototype = Object.create(e && e.prototype, { constructor: { value: t, writable: !0, configurable: !0 } }), Object.defineProperty(t, \"prototype\", { writable: !1 }), e && _setPrototypeOf(t, e); }\nfunction _wrapNativeSuper(t) { var r = \"function\" == typeof Map ? new Map() : void 0; return _wrapNativeSuper = function _wrapNativeSuper(t) { if (null === t || !_isNativeFunction(t)) return t; if (\"function\" != typeof t) throw new TypeError(\"Super expression must either be null or a function\"); if (void 0 !== r) { if (r.has(t)) return r.get(t); r.set(t, Wrapper); } function Wrapper() { return _construct(t, arguments, _getPrototypeOf(this).constructor); } return Wrapper.prototype = Object.create(t.prototype, { constructor: { value: Wrapper, enumerable: !1, writable: !0, configurable: !0 } }), _setPrototypeOf(Wrapper, t); }, _wrapNativeSuper(t); }\nfunction _construct(t, e, r) { if (_isNativeReflectConstruct()) return Reflect.construct.apply(null, arguments); var o = [null]; o.push.apply(o, e); var p = new (t.bind.apply(t, o))(); return r && _setPrototypeOf(p, r.prototype), p; }\nfunction _isNativeReflectConstruct() { try { var t = !Boolean.prototype.valueOf.call(Reflect.construct(Boolean, [], function () {})); } catch (t) {} return (_isNativeReflectConstruct = function _isNativeReflectConstruct() { return !!t; })(); }\nfunction _isNativeFunction(t) { try { return -1 !== Function.toString.call(t).indexOf(\"[native code]\"); } catch (n) { return \"function\" == typeof t; } }\nfunction _setPrototypeOf(t, e) { return _setPrototypeOf = Object.setPrototypeOf ? Object.setPrototypeOf.bind() : function (t, e) { return t.__proto__ = e, t; }, _setPrototypeOf(t, e); }\nfunction _getPrototypeOf(t) { return _getPrototypeOf = Object.setPrototypeOf ? Object.getPrototypeOf.bind() : function (t) { return t.__proto__ || Object.getPrototypeOf(t); }, _getPrototypeOf(t); }\n// https://stackoverflow.com/a/46971044/970769\n// \"Breaking changes in Typescript 2.1\"\n// \"Extending built-ins like Error, Array, and Map may no longer work.\"\n// \"As a recommendation, you can manually adjust the prototype immediately after any super(...) calls.\"\n// https://github.com/Microsoft/TypeScript-wiki/blob/main/Breaking-Changes.md#extending-built-ins-like-error-array-and-map-may-no-longer-work\nvar ParseError = /*#__PURE__*/function (_Error) {\n function ParseError(code) {\n var _this;\n _classCallCheck(this, ParseError);\n _this = _callSuper(this, ParseError, [code]);\n // Set the prototype explicitly.\n // Any subclass of FooError will have to manually set the prototype as well.\n Object.setPrototypeOf(_this, ParseError.prototype);\n _this.name = _this.constructor.name;\n return _this;\n }\n _inherits(ParseError, _Error);\n return _createClass(ParseError);\n}(/*#__PURE__*/_wrapNativeSuper(Error));\nexport { ParseError as default };\n//# sourceMappingURL=ParseError.js.map","// Copy-pasted from:\n// https://github.com/substack/semver-compare/blob/master/index.js\n//\n// Inlining this function because some users reported issues with\n// importing from `semver-compare` in a browser with ES6 \"native\" modules.\n//\n// Fixes `semver-compare` not being able to compare versions with alpha/beta/etc \"tags\".\n// https://github.com/catamphetamine/libphonenumber-js/issues/381\nexport default function (a, b) {\n a = a.split('-');\n b = b.split('-');\n var pa = a[0].split('.');\n var pb = b[0].split('.');\n for (var i = 0; i < 3; i++) {\n var na = Number(pa[i]);\n var nb = Number(pb[i]);\n if (na > nb) return 1;\n if (nb > na) return -1;\n if (!isNaN(na) && isNaN(nb)) return 1;\n if (isNaN(na) && !isNaN(nb)) return -1;\n }\n if (a[1] && b[1]) {\n return a[1] > b[1] ? 1 : a[1] < b[1] ? -1 : 0;\n }\n return !a[1] && b[1] ? 1 : a[1] && !b[1] ? -1 : 0;\n}\n//# sourceMappingURL=semver-compare.js.map","var objectConstructor = {}.constructor;\nexport default function isObject(object) {\n return object !== undefined && object !== null && object.constructor === objectConstructor;\n}\n//# sourceMappingURL=isObject.js.map","var CALLING_CODE_REG_EXP = /^\\d+$/;\nexport default function isCallingCode(string) {\n return CALLING_CODE_REG_EXP.test(string);\n}\n//# sourceMappingURL=isCallingCode.js.map","function _readOnlyError(r) { throw new TypeError('\"' + r + '\" is read-only'); }\nfunction _typeof(o) { \"@babel/helpers - typeof\"; return _typeof = \"function\" == typeof Symbol && \"symbol\" == typeof Symbol.iterator ? function (o) { return typeof o; } : function (o) { return o && \"function\" == typeof Symbol && o.constructor === Symbol && o !== Symbol.prototype ? \"symbol\" : typeof o; }, _typeof(o); }\nfunction _classCallCheck(a, n) { if (!(a instanceof n)) throw new TypeError(\"Cannot call a class as a function\"); }\nfunction _defineProperties(e, r) { for (var t = 0; t < r.length; t++) { var o = r[t]; o.enumerable = o.enumerable || !1, o.configurable = !0, \"value\" in o && (o.writable = !0), Object.defineProperty(e, _toPropertyKey(o.key), o); } }\nfunction _createClass(e, r, t) { return r && _defineProperties(e.prototype, r), t && _defineProperties(e, t), Object.defineProperty(e, \"prototype\", { writable: !1 }), e; }\nfunction _toPropertyKey(t) { var i = _toPrimitive(t, \"string\"); return \"symbol\" == _typeof(i) ? i : i + \"\"; }\nfunction _toPrimitive(t, r) { if (\"object\" != _typeof(t) || !t) return t; var e = t[Symbol.toPrimitive]; if (void 0 !== e) { var i = e.call(t, r || \"default\"); if (\"object\" != _typeof(i)) return i; throw new TypeError(\"@@toPrimitive must return a primitive value.\"); } return (\"string\" === r ? String : Number)(t); }\nimport compare from './tools/semver-compare.js';\nimport isObject from './helpers/isObject.js';\nimport isCallingCode from './helpers/isCallingCode.js';\n\n// Added \"possibleLengths\" and renamed\n// \"country_phone_code_to_countries\" to \"country_calling_codes\".\nvar V2 = '1.0.18';\n\n// Added \"idd_prefix\" and \"default_idd_prefix\".\nvar V3 = '1.2.0';\n\n// Moved `001` country code to \"nonGeographic\" section of metadata.\nvar V4 = '1.7.35';\nvar DEFAULT_EXT_PREFIX = ' ext. ';\n\n/**\r\n * See: https://gitlab.com/catamphetamine/libphonenumber-js/blob/master/METADATA.md\r\n */\nvar Metadata = /*#__PURE__*/function () {\n /**\r\n * @param {object} metadata — Metadata JSON.\r\n */\n function Metadata(metadata) {\n _classCallCheck(this, Metadata);\n validateMetadata(metadata);\n this.metadata = metadata;\n setVersion.call(this, metadata);\n }\n return _createClass(Metadata, [{\n key: \"getCountries\",\n value: function getCountries() {\n return Object.keys(this.metadata.countries).filter(function (_) {\n return _ !== '001';\n });\n }\n }, {\n key: \"getCountryMetadata\",\n value: function getCountryMetadata(countryCode) {\n return this.metadata.countries[countryCode];\n }\n }, {\n key: \"nonGeographic\",\n value: function nonGeographic() {\n if (this.v1 || this.v2 || this.v3) return;\n // `nonGeographical` was a typo.\n // It's present in metadata generated from `1.7.35` to `1.7.37`.\n // The test case could be found by searching for \"nonGeographical\".\n return this.metadata.nonGeographic || this.metadata.nonGeographical;\n }\n }, {\n key: \"hasCountry\",\n value: function hasCountry(country) {\n return this.getCountryMetadata(country) !== undefined;\n }\n }, {\n key: \"hasCallingCode\",\n value: function hasCallingCode(callingCode) {\n if (this.getCountryCodesForCallingCode(callingCode)) {\n return true;\n }\n if (this.nonGeographic()) {\n if (this.nonGeographic()[callingCode]) {\n return true;\n }\n } else {\n // A hacky workaround for old custom metadata (generated before V4).\n var countryCodes = this.countryCallingCodes()[callingCode];\n if (countryCodes && countryCodes.length === 1 && countryCodes[0] === '001') {\n return true;\n }\n }\n }\n }, {\n key: \"isNonGeographicCallingCode\",\n value: function isNonGeographicCallingCode(callingCode) {\n if (this.nonGeographic()) {\n return this.nonGeographic()[callingCode] ? true : false;\n } else {\n return this.getCountryCodesForCallingCode(callingCode) ? false : true;\n }\n }\n\n // Deprecated.\n }, {\n key: \"country\",\n value: function country(countryCode) {\n return this.selectNumberingPlan(countryCode);\n }\n\n /**\r\n * Selects a telephone numbering plan based on either a country code or a calling code.\r\n * @param {string} argument — Country code or calling code.\r\n * @param {string} legacyArgumentCallingCode — Legacy argument: calling code, if the first argument is not passed.\r\n */\n }, {\n key: \"selectNumberingPlan\",\n value: function selectNumberingPlan(argument, legacyArgumentCallingCode) {\n var countryCode;\n var callingCode;\n if (argument) {\n if (isCallingCode(argument)) {\n callingCode = argument;\n } else {\n countryCode = argument;\n }\n }\n // Previously, the signature of this method was: `.selectNumberingPlan(country, callingCode)`.\n // And if `country` argument wasn't passed, it looked into the second argument `callingCode`.\n // Now it's preferred to only pass either `country` or `callingCode` as the first argument.\n if (legacyArgumentCallingCode) {\n callingCode = legacyArgumentCallingCode;\n }\n\n // Select a telephone numbering plan.\n if (countryCode && countryCode !== '001') {\n var countryMetadata = this.getCountryMetadata(countryCode);\n if (!countryMetadata) {\n throw new Error(\"Unknown country: \".concat(countryCode));\n }\n this.numberingPlan = new NumberingPlan(countryMetadata, this);\n } else if (callingCode) {\n if (!this.hasCallingCode(callingCode)) {\n throw new Error(\"Unknown calling code: \".concat(callingCode));\n }\n this.numberingPlan = new NumberingPlan(this.getNumberingPlanMetadata(callingCode), this);\n } else {\n this.numberingPlan = undefined;\n }\n return this;\n }\n }, {\n key: \"getCountryCodesForCallingCode\",\n value: function getCountryCodesForCallingCode(callingCode) {\n var countryCodes = this.countryCallingCodes()[callingCode];\n if (countryCodes) {\n // Metadata before V4 included \"non-geographic entity\" calling codes\n // inside `country_calling_codes` (for example, `\"881\":[\"001\"]`).\n // Now the semantics of `country_calling_codes` has changed:\n // it's specifically for \"countries\" now.\n // Older versions of custom metadata will simply skip parsing\n // \"non-geographic entity\" phone numbers with new versions\n // of this library: it's not considered a bug,\n // because such numbers are extremely rare,\n // and developers extremely rarely use custom metadata.\n if (countryCodes.length === 1 && countryCodes[0].length === 3) {\n return;\n }\n return countryCodes;\n }\n }\n }, {\n key: \"getCountryCodeForCallingCode\",\n value: function getCountryCodeForCallingCode(callingCode) {\n var countryCodes = this.getCountryCodesForCallingCode(callingCode);\n if (countryCodes) {\n return countryCodes[0];\n }\n }\n }, {\n key: \"getNumberingPlanMetadata\",\n value: function getNumberingPlanMetadata(callingCode) {\n // If a calling code is specified, choose the telephone numbering plan\n // of the \"default\" country for this calling code.\n // For example, if calling code `1` is passed,\n // the telephone numbering plan of `US` will be selected.\n var countryCode = this.getCountryCodeForCallingCode(callingCode);\n if (countryCode) {\n return this.getCountryMetadata(countryCode);\n }\n if (this.nonGeographic()) {\n var metadata = this.nonGeographic()[callingCode];\n if (metadata) {\n return metadata;\n }\n } else {\n // A hacky workaround for old custom metadata (generated before V4).\n // In that metadata, there was no concept of \"non-geographic\" metadata\n // so metadata for `001` country code was stored along with other countries.\n // The test case can be found by searching for:\n // \"should work around `nonGeographic` metadata not existing\".\n var countryCodes = this.countryCallingCodes()[callingCode];\n if (countryCodes && countryCodes.length === 1 && countryCodes[0] === '001') {\n return this.metadata.countries['001'];\n }\n }\n }\n\n // Deprecated.\n }, {\n key: \"countryCallingCode\",\n value: function countryCallingCode() {\n return this.numberingPlan.callingCode();\n }\n\n // Deprecated.\n }, {\n key: \"IDDPrefix\",\n value: function IDDPrefix() {\n return this.numberingPlan.IDDPrefix();\n }\n\n // Deprecated.\n }, {\n key: \"defaultIDDPrefix\",\n value: function defaultIDDPrefix() {\n return this.numberingPlan.defaultIDDPrefix();\n }\n\n // Deprecated.\n }, {\n key: \"nationalNumberPattern\",\n value: function nationalNumberPattern() {\n return this.numberingPlan.nationalNumberPattern();\n }\n\n // Deprecated.\n }, {\n key: \"possibleLengths\",\n value: function possibleLengths() {\n return this.numberingPlan.possibleLengths();\n }\n\n // Deprecated.\n }, {\n key: \"formats\",\n value: function formats() {\n return this.numberingPlan.formats();\n }\n\n // Deprecated.\n }, {\n key: \"nationalPrefixForParsing\",\n value: function nationalPrefixForParsing() {\n return this.numberingPlan.nationalPrefixForParsing();\n }\n\n // Deprecated.\n }, {\n key: \"nationalPrefixTransformRule\",\n value: function nationalPrefixTransformRule() {\n return this.numberingPlan.nationalPrefixTransformRule();\n }\n\n // Deprecated.\n }, {\n key: \"leadingDigits\",\n value: function leadingDigits() {\n return this.numberingPlan.leadingDigits();\n }\n\n // Deprecated.\n }, {\n key: \"hasTypes\",\n value: function hasTypes() {\n return this.numberingPlan.hasTypes();\n }\n\n // Deprecated.\n }, {\n key: \"type\",\n value: function type(_type) {\n return this.numberingPlan.type(_type);\n }\n\n // Deprecated.\n }, {\n key: \"ext\",\n value: function ext() {\n return this.numberingPlan.ext();\n }\n }, {\n key: \"countryCallingCodes\",\n value: function countryCallingCodes() {\n if (this.v1) return this.metadata.country_phone_code_to_countries;\n return this.metadata.country_calling_codes;\n }\n\n // Deprecated.\n }, {\n key: \"chooseCountryByCountryCallingCode\",\n value: function chooseCountryByCountryCallingCode(callingCode) {\n return this.selectNumberingPlan(callingCode);\n }\n }, {\n key: \"hasSelectedNumberingPlan\",\n value: function hasSelectedNumberingPlan() {\n return this.numberingPlan !== undefined;\n }\n }]);\n}();\nexport { Metadata as default };\nvar NumberingPlan = /*#__PURE__*/function () {\n function NumberingPlan(metadata, globalMetadataObject) {\n _classCallCheck(this, NumberingPlan);\n this.globalMetadataObject = globalMetadataObject;\n this.metadata = metadata;\n setVersion.call(this, globalMetadataObject.metadata);\n }\n return _createClass(NumberingPlan, [{\n key: \"callingCode\",\n value: function callingCode() {\n return this.metadata[0];\n }\n\n // When multiple countries share the same calling code,\n // all phone number formatting rules are included in the metadata\n // of the \"default\" country for that calling code.\n // Any other countries' metdata doesn't include any formatting rules.\n // Google developers said that such storage architecture was chosen for performance reasons.\n //\n // For example, for NANPA region (\"North American Numbering Plan Administration\",\n // which includes USA, Canada, Cayman Islands, Bahamas, etc) all formatting rules\n // are contained in the metadata of `US` country.\n //\n // This is not public API.\n //\n }, {\n key: \"_getDefaultCountryMetadataForThisCallingCode\",\n value: function _getDefaultCountryMetadataForThisCallingCode() {\n return this.globalMetadataObject.getNumberingPlanMetadata(this.callingCode());\n }\n\n // Deprecated.\n }, {\n key: \"getDefaultCountryMetadataForRegion\",\n value: function getDefaultCountryMetadataForRegion() {\n return this._getDefaultCountryMetadataForThisCallingCode();\n }\n\n // Is always present.\n }, {\n key: \"IDDPrefix\",\n value: function IDDPrefix() {\n if (this.v1 || this.v2) return;\n return this.metadata[1];\n }\n\n // Is only present when a country supports multiple IDD prefixes.\n }, {\n key: \"defaultIDDPrefix\",\n value: function defaultIDDPrefix() {\n if (this.v1 || this.v2) return;\n return this.metadata[12];\n }\n }, {\n key: \"nationalNumberPattern\",\n value: function nationalNumberPattern() {\n if (this.v1 || this.v2) return this.metadata[1];\n return this.metadata[2];\n }\n\n // \"possible length\" data is always present in Google's metadata.\n }, {\n key: \"possibleLengths\",\n value: function possibleLengths() {\n if (this.v1) return;\n return this.metadata[this.v2 ? 2 : 3];\n }\n }, {\n key: \"_getFormats\",\n value: function _getFormats(metadata) {\n return metadata[this.v1 ? 2 : this.v2 ? 3 : 4];\n }\n\n // For countries of the same region (e.g. NANPA)\n // formats are all stored in the \"main\" country for that region.\n // E.g. \"RU\" and \"KZ\", \"US\" and \"CA\".\n }, {\n key: \"formats\",\n value: function formats() {\n var _this = this;\n var formats = this._getFormats(this.metadata) || this._getFormats(this._getDefaultCountryMetadataForThisCallingCode()) || [];\n return formats.map(function (_) {\n return new Format(_, _this);\n });\n }\n }, {\n key: \"nationalPrefix\",\n value: function nationalPrefix() {\n return this.metadata[this.v1 ? 3 : this.v2 ? 4 : 5];\n }\n }, {\n key: \"_getNationalPrefixFormattingRule\",\n value: function _getNationalPrefixFormattingRule(metadata) {\n return metadata[this.v1 ? 4 : this.v2 ? 5 : 6];\n }\n\n // For countries of the same region (e.g. NANPA)\n // national prefix formatting rule is stored in the \"main\" country for that region.\n // E.g. \"RU\" and \"KZ\", \"US\" and \"CA\".\n }, {\n key: \"nationalPrefixFormattingRule\",\n value: function nationalPrefixFormattingRule() {\n return this._getNationalPrefixFormattingRule(this.metadata) || this._getNationalPrefixFormattingRule(this._getDefaultCountryMetadataForThisCallingCode());\n }\n }, {\n key: \"_nationalPrefixForParsing\",\n value: function _nationalPrefixForParsing() {\n return this.metadata[this.v1 ? 5 : this.v2 ? 6 : 7];\n }\n }, {\n key: \"nationalPrefixForParsing\",\n value: function nationalPrefixForParsing() {\n // If `national_prefix_for_parsing` is not set explicitly,\n // then infer it from `national_prefix` (if any)\n return this._nationalPrefixForParsing() || this.nationalPrefix();\n }\n }, {\n key: \"nationalPrefixTransformRule\",\n value: function nationalPrefixTransformRule() {\n return this.metadata[this.v1 ? 6 : this.v2 ? 7 : 8];\n }\n }, {\n key: \"_getNationalPrefixIsOptionalWhenFormatting\",\n value: function _getNationalPrefixIsOptionalWhenFormatting() {\n return !!this.metadata[this.v1 ? 7 : this.v2 ? 8 : 9];\n }\n\n // For countries of the same region (e.g. NANPA)\n // \"national prefix is optional when formatting\" flag is\n // stored in the \"main\" country for that region.\n // E.g. \"RU\" and \"KZ\", \"US\" and \"CA\".\n }, {\n key: \"nationalPrefixIsOptionalWhenFormattingInNationalFormat\",\n value: function nationalPrefixIsOptionalWhenFormattingInNationalFormat() {\n return this._getNationalPrefixIsOptionalWhenFormatting(this.metadata) || this._getNationalPrefixIsOptionalWhenFormatting(this._getDefaultCountryMetadataForThisCallingCode());\n }\n }, {\n key: \"leadingDigits\",\n value: function leadingDigits() {\n return this.metadata[this.v1 ? 8 : this.v2 ? 9 : 10];\n }\n }, {\n key: \"types\",\n value: function types() {\n return this.metadata[this.v1 ? 9 : this.v2 ? 10 : 11];\n }\n }, {\n key: \"hasTypes\",\n value: function hasTypes() {\n // Versions 1.2.0 - 1.2.4: can be `[]`.\n /* istanbul ignore next */\n if (this.types() && this.types().length === 0) {\n return false;\n }\n // Versions <= 1.2.4: can be `undefined`.\n // Version >= 1.2.5: can be `0`.\n return !!this.types();\n }\n }, {\n key: \"type\",\n value: function type(_type2) {\n if (this.hasTypes() && getType(this.types(), _type2)) {\n return new Type(getType(this.types(), _type2), this);\n }\n }\n }, {\n key: \"ext\",\n value: function ext() {\n if (this.v1 || this.v2) return DEFAULT_EXT_PREFIX;\n return this.metadata[13] || DEFAULT_EXT_PREFIX;\n }\n }]);\n}();\nvar Format = /*#__PURE__*/function () {\n function Format(format, metadata) {\n _classCallCheck(this, Format);\n this._format = format;\n this.metadata = metadata;\n }\n return _createClass(Format, [{\n key: \"pattern\",\n value: function pattern() {\n return this._format[0];\n }\n }, {\n key: \"format\",\n value: function format() {\n return this._format[1];\n }\n }, {\n key: \"leadingDigitsPatterns\",\n value: function leadingDigitsPatterns() {\n return this._format[2] || [];\n }\n }, {\n key: \"nationalPrefixFormattingRule\",\n value: function nationalPrefixFormattingRule() {\n return this._format[3] || this.metadata.nationalPrefixFormattingRule();\n }\n }, {\n key: \"nationalPrefixIsOptionalWhenFormattingInNationalFormat\",\n value: function nationalPrefixIsOptionalWhenFormattingInNationalFormat() {\n return !!this._format[4] || this.metadata.nationalPrefixIsOptionalWhenFormattingInNationalFormat();\n }\n }, {\n key: \"nationalPrefixIsMandatoryWhenFormattingInNationalFormat\",\n value: function nationalPrefixIsMandatoryWhenFormattingInNationalFormat() {\n // National prefix is omitted if there's no national prefix formatting rule\n // set for this country, or when the national prefix formatting rule\n // contains no national prefix itself, or when this rule is set but\n // national prefix is optional for this phone number format\n // (and it is not enforced explicitly)\n return this.usesNationalPrefix() && !this.nationalPrefixIsOptionalWhenFormattingInNationalFormat();\n }\n\n // Checks whether national prefix formatting rule contains national prefix.\n }, {\n key: \"usesNationalPrefix\",\n value: function usesNationalPrefix() {\n return this.nationalPrefixFormattingRule() &&\n // Check that national prefix formatting rule is not a \"dummy\" one.\n !FIRST_GROUP_ONLY_PREFIX_PATTERN.test(this.nationalPrefixFormattingRule())\n // In compressed metadata, `this.nationalPrefixFormattingRule()` is `0`\n // when `national_prefix_formatting_rule` is not present.\n // So, `true` or `false` are returned explicitly here, so that\n // `0` number isn't returned.\n ? true : false;\n }\n }, {\n key: \"internationalFormat\",\n value: function internationalFormat() {\n return this._format[5] || this.format();\n }\n }]);\n}();\n/**\r\n * A pattern that is used to determine if the national prefix formatting rule\r\n * has the first group only, i.e., does not start with the national prefix.\r\n * Note that the pattern explicitly allows for unbalanced parentheses.\r\n */\nvar FIRST_GROUP_ONLY_PREFIX_PATTERN = /^\\(?\\$1\\)?$/;\nvar Type = /*#__PURE__*/function () {\n function Type(type, metadata) {\n _classCallCheck(this, Type);\n this.type = type;\n this.metadata = metadata;\n }\n return _createClass(Type, [{\n key: \"pattern\",\n value: function pattern() {\n if (this.metadata.v1) return this.type;\n return this.type[0];\n }\n }, {\n key: \"possibleLengths\",\n value: function possibleLengths() {\n if (this.metadata.v1) return;\n return this.type[1] || this.metadata.possibleLengths();\n }\n }]);\n}();\nfunction getType(types, type) {\n switch (type) {\n case 'FIXED_LINE':\n return types[0];\n case 'MOBILE':\n return types[1];\n case 'TOLL_FREE':\n return types[2];\n case 'PREMIUM_RATE':\n return types[3];\n case 'PERSONAL_NUMBER':\n return types[4];\n case 'VOICEMAIL':\n return types[5];\n case 'UAN':\n return types[6];\n case 'PAGER':\n return types[7];\n case 'VOIP':\n return types[8];\n case 'SHARED_COST':\n return types[9];\n }\n}\nexport function validateMetadata(metadata) {\n if (!metadata) {\n throw new Error('[libphonenumber-js] `metadata` argument not passed. Check your arguments.');\n }\n\n // `country_phone_code_to_countries` was renamed to `country_calling_codes` in `1.0.18`.\n // For that reason, it's not used in this detection algorithm.\n // Instead, it detects by `countries: {}` property existence.\n if (!isObject(metadata) || !isObject(metadata.countries)) {\n 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(isObject(metadata) ? 'an object of shape: { ' + Object.keys(metadata).join(', ') + ' }' : 'a ' + typeOf(metadata) + ': ' + metadata, \".\"));\n }\n}\n\n// Babel transforms `typeof` into some \"branches\"\n// so istanbul will show this as \"branch not covered\".\n/* istanbul ignore next */\nvar typeOf = function typeOf(_) {\n return _typeof(_);\n};\n\n/**\r\n * Returns extension prefix for a country.\r\n * @param {string} country\r\n * @param {object} metadata\r\n * @return {string?}\r\n * @example\r\n * // Returns \" ext. \"\r\n * getExtPrefix(\"US\")\r\n */\nexport function getExtPrefix(country, metadataJson) {\n var metadata = new Metadata(metadataJson);\n if (metadata.hasCountry(country)) {\n return metadata.selectNumberingPlan(country).ext();\n }\n return DEFAULT_EXT_PREFIX;\n}\n\n/**\r\n * Returns \"country calling code\" for a country.\r\n * Throws an error if the country doesn't exist or isn't supported by this library.\r\n * @param {string} country\r\n * @param {object} metadataJson\r\n * @return {string}\r\n * @example\r\n * // Returns \"44\"\r\n * getCountryCallingCode(\"GB\")\r\n */\nexport function getCountryCallingCode(country, metadataJson) {\n var metadata = new Metadata(metadataJson);\n if (metadata.hasCountry(country)) {\n return metadata.selectNumberingPlan(country).countryCallingCode();\n }\n throw new Error(\"Unknown country: \".concat(country));\n}\n\n/**\r\n * Tells if a country code is supported.\r\n * @param {string} country\r\n * @param {object} metadataJson\r\n * @return {boolean}\r\n * @example\r\n * // Returns `true`\r\n * isSupportedCountry(\"GB\")\r\n */\nexport function isSupportedCountry(country, metadataJson) {\n // const metadata = new Metadata(metadataJson)\n // return metadata.hasCountry(country)\n return metadataJson.countries.hasOwnProperty(country);\n}\n\n/**\r\n * Sets `v1`/`v2`/`v3`/`v4` properties on `this` object.\r\n * @param {object} metadata — Metadata JSON\r\n */\nfunction setVersion(metadata) {\n var version = metadata.version;\n if (typeof version === 'number') {\n this.v1 = version === 1;\n this.v2 = version === 2;\n this.v3 = version === 3;\n this.v4 = version === 4;\n } else {\n if (!version) {\n this.v1 = true;\n } else if (compare(version, V3) === -1) {\n this.v2 = true;\n } else if (compare(version, V4) === -1) {\n this.v3 = true;\n } else {\n this.v4 = true;\n }\n }\n}\n//# sourceMappingURL=metadata.js.map","import { VALID_DIGITS } from '../../constants.js';\n\n// The RFC 3966 format for extensions.\nvar RFC3966_EXTN_PREFIX = ';ext=';\n\n/**\r\n * Helper method for constructing regular expressions for parsing. Creates\r\n * an expression that captures up to max_length digits.\r\n * @return {string} RegEx pattern to capture extension digits.\r\n */\nvar getExtensionDigitsPattern = function getExtensionDigitsPattern(maxLength) {\n return \"([\".concat(VALID_DIGITS, \"]{1,\").concat(maxLength, \"})\");\n};\n\n/**\r\n * Helper initialiser method to create the regular-expression pattern to match\r\n * extensions.\r\n * Copy-pasted from Google's `libphonenumber`:\r\n * https://github.com/google/libphonenumber/blob/55b2646ec9393f4d3d6661b9c82ef9e258e8b829/javascript/i18n/phonenumbers/phonenumberutil.js#L759-L766\r\n * @return {string} RegEx pattern to capture extensions.\r\n */\nexport default function createExtensionPattern(purpose) {\n // We cap the maximum length of an extension based on the ambiguity of the way\n // the extension is prefixed. As per ITU, the officially allowed length for\n // extensions is actually 40, but we don't support this since we haven't seen real\n // examples and this introduces many false interpretations as the extension labels\n // are not standardized.\n /** @type {string} */\n var extLimitAfterExplicitLabel = '20';\n /** @type {string} */\n var extLimitAfterLikelyLabel = '15';\n /** @type {string} */\n var extLimitAfterAmbiguousChar = '9';\n /** @type {string} */\n var extLimitWhenNotSure = '6';\n\n /** @type {string} */\n var possibleSeparatorsBetweenNumberAndExtLabel = \"[ \\xA0\\\\t,]*\";\n // Optional full stop (.) or colon, followed by zero or more spaces/tabs/commas.\n /** @type {string} */\n var possibleCharsAfterExtLabel = \"[:\\\\.\\uFF0E]?[ \\xA0\\\\t,-]*\";\n /** @type {string} */\n var optionalExtnSuffix = \"#?\";\n\n // Here the extension is called out in more explicit way, i.e mentioning it obvious\n // patterns like \"ext.\".\n /** @type {string} */\n var explicitExtLabels = \"(?:e?xt(?:ensi(?:o\\u0301?|\\xF3))?n?|\\uFF45?\\uFF58\\uFF54\\uFF4E?|\\u0434\\u043E\\u0431|anexo)\";\n // One-character symbols that can be used to indicate an extension, and less\n // commonly used or more ambiguous extension labels.\n /** @type {string} */\n var ambiguousExtLabels = \"(?:[x\\uFF58#\\uFF03~\\uFF5E]|int|\\uFF49\\uFF4E\\uFF54)\";\n // When extension is not separated clearly.\n /** @type {string} */\n var ambiguousSeparator = \"[- ]+\";\n // This is the same as possibleSeparatorsBetweenNumberAndExtLabel, but not matching\n // comma as extension label may have it.\n /** @type {string} */\n var possibleSeparatorsNumberExtLabelNoComma = \"[ \\xA0\\\\t]*\";\n // \",,\" is commonly used for auto dialling the extension when connected. First\n // comma is matched through possibleSeparatorsBetweenNumberAndExtLabel, so we do\n // not repeat it here. Semi-colon works in Iphone and Android also to pop up a\n // button with the extension number following.\n /** @type {string} */\n var autoDiallingAndExtLabelsFound = \"(?:,{2}|;)\";\n\n /** @type {string} */\n var rfcExtn = RFC3966_EXTN_PREFIX + getExtensionDigitsPattern(extLimitAfterExplicitLabel);\n /** @type {string} */\n var explicitExtn = possibleSeparatorsBetweenNumberAndExtLabel + explicitExtLabels + possibleCharsAfterExtLabel + getExtensionDigitsPattern(extLimitAfterExplicitLabel) + optionalExtnSuffix;\n /** @type {string} */\n var ambiguousExtn = possibleSeparatorsBetweenNumberAndExtLabel + ambiguousExtLabels + possibleCharsAfterExtLabel + getExtensionDigitsPattern(extLimitAfterAmbiguousChar) + optionalExtnSuffix;\n /** @type {string} */\n var americanStyleExtnWithSuffix = ambiguousSeparator + getExtensionDigitsPattern(extLimitWhenNotSure) + \"#\";\n\n /** @type {string} */\n var autoDiallingExtn = possibleSeparatorsNumberExtLabelNoComma + autoDiallingAndExtLabelsFound + possibleCharsAfterExtLabel + getExtensionDigitsPattern(extLimitAfterLikelyLabel) + optionalExtnSuffix;\n /** @type {string} */\n var onlyCommasExtn = possibleSeparatorsNumberExtLabelNoComma + \"(?:,)+\" + possibleCharsAfterExtLabel + getExtensionDigitsPattern(extLimitAfterAmbiguousChar) + optionalExtnSuffix;\n\n // The first regular expression covers RFC 3966 format, where the extension is added\n // using \";ext=\". The second more generic where extension is mentioned with explicit\n // labels like \"ext:\". In both the above cases we allow more numbers in extension than\n // any other extension labels. The third one captures when single character extension\n // labels or less commonly used labels are used. In such cases we capture fewer\n // extension digits in order to reduce the chance of falsely interpreting two\n // numbers beside each other as a number + extension. The fourth one covers the\n // special case of American numbers where the extension is written with a hash\n // at the end, such as \"- 503#\". The fifth one is exclusively for extension\n // autodialling formats which are used when dialling and in this case we accept longer\n // extensions. The last one is more liberal on the number of commas that acts as\n // extension labels, so we have a strict cap on the number of digits in such extensions.\n return rfcExtn + \"|\" + explicitExtn + \"|\" + ambiguousExtn + \"|\" + americanStyleExtnWithSuffix + \"|\" + autoDiallingExtn + \"|\" + onlyCommasExtn;\n}\n//# sourceMappingURL=createExtensionPattern.js.map","import { MIN_LENGTH_FOR_NSN, VALID_DIGITS, VALID_PUNCTUATION, PLUS_CHARS } from '../constants.js';\nimport createExtensionPattern from './extension/createExtensionPattern.js';\n\n// Regular expression of viable phone numbers. This is location independent.\n// Checks we have at least three leading digits, and only valid punctuation,\n// alpha characters and digits in the phone number. Does not include extension\n// data. The symbol 'x' is allowed here as valid punctuation since it is often\n// used as a placeholder for carrier codes, for example in Brazilian phone\n// numbers. We also allow multiple '+' characters at the start.\n//\n// Corresponds to the following:\n// [digits]{minLengthNsn}|\n// plus_sign*\n// (([punctuation]|[star])*[digits]){3,}([punctuation]|[star]|[digits]|[alpha])*\n//\n// The first reg-ex is to allow short numbers (two digits long) to be parsed if\n// they are entered as \"15\" etc, but only if there is no punctuation in them.\n// The second expression restricts the number of digits to three or more, but\n// then allows them to be in international form, and to have alpha-characters\n// and punctuation. We split up the two reg-exes here and combine them when\n// creating the reg-ex VALID_PHONE_NUMBER_PATTERN itself so we can prefix it\n// with ^ and append $ to each branch.\n//\n// \"Note VALID_PUNCTUATION starts with a -,\n// so must be the first in the range\" (c) Google devs.\n// (wtf did they mean by saying that; probably nothing)\n//\nvar MIN_LENGTH_PHONE_NUMBER_PATTERN = '[' + VALID_DIGITS + ']{' + MIN_LENGTH_FOR_NSN + '}';\n//\n// And this is the second reg-exp:\n// (see MIN_LENGTH_PHONE_NUMBER_PATTERN for a full description of this reg-exp)\n//\nexport var VALID_PHONE_NUMBER = '[' + PLUS_CHARS + ']{0,1}' + '(?:' + '[' + VALID_PUNCTUATION + ']*' + '[' + VALID_DIGITS + ']' + '){3,}' + '[' + VALID_PUNCTUATION + VALID_DIGITS + ']*';\n\n// This regular expression isn't present in Google's `libphonenumber`\n// and is only used to determine whether the phone number being input\n// is too short for it to even consider it a \"valid\" number.\n// This is just a way to differentiate between a really invalid phone\n// number like \"abcde\" and a valid phone number that a user has just\n// started inputting, like \"+1\" or \"1\": both these cases would be\n// considered `NOT_A_NUMBER` by Google's `libphonenumber`, but this\n// library can provide a more detailed error message — whether it's\n// really \"not a number\", or is it just a start of a valid phone number.\nvar VALID_PHONE_NUMBER_START_REG_EXP = new RegExp('^' + '[' + PLUS_CHARS + ']{0,1}' + '(?:' + '[' + VALID_PUNCTUATION + ']*' + '[' + VALID_DIGITS + ']' + '){1,2}' + '$', 'i');\nexport var VALID_PHONE_NUMBER_WITH_EXTENSION = VALID_PHONE_NUMBER +\n// Phone number extensions\n'(?:' + createExtensionPattern() + ')?';\n\n// The combined regular expression for valid phone numbers:\n//\nvar VALID_PHONE_NUMBER_PATTERN = new RegExp(\n// Either a short two-digit-only phone number\n'^' + MIN_LENGTH_PHONE_NUMBER_PATTERN + '$' + '|' +\n// Or a longer fully parsed phone number (min 3 characters)\n'^' + VALID_PHONE_NUMBER_WITH_EXTENSION + '$', 'i');\n\n// Checks to see if the string of characters could possibly be a phone number at\n// all. At the moment, checks to see that the string begins with at least 2\n// digits, ignoring any punctuation commonly found in phone numbers. This method\n// does not require the number to be normalized in advance - but does assume\n// that leading non-number symbols have been removed, such as by the method\n// `extract_possible_number`.\n//\nexport default function isViablePhoneNumber(number) {\n return number.length >= MIN_LENGTH_FOR_NSN && VALID_PHONE_NUMBER_PATTERN.test(number);\n}\n\n// This is just a way to differentiate between a really invalid phone\n// number like \"abcde\" and a valid phone number that a user has just\n// started inputting, like \"+1\" or \"1\": both these cases would be\n// considered `NOT_A_NUMBER` by Google's `libphonenumber`, but this\n// library can provide a more detailed error message — whether it's\n// really \"not a number\", or is it just a start of a valid phone number.\nexport function isViablePhoneNumberStart(number) {\n return VALID_PHONE_NUMBER_START_REG_EXP.test(number);\n}\n//# sourceMappingURL=isViablePhoneNumber.js.map","import createExtensionPattern from './createExtensionPattern.js';\n\n// Regexp of all known extension prefixes used by different regions followed by\n// 1 or more valid digits, for use when parsing.\nvar EXTN_PATTERN = new RegExp('(?:' + createExtensionPattern() + ')$', 'i');\n\n// Strips any extension (as in, the part of the number dialled after the call is\n// connected, usually indicated with extn, ext, x or similar) from the end of\n// the number, and returns it.\nexport default function extractExtension(number) {\n var start = number.search(EXTN_PATTERN);\n if (start < 0) {\n return {};\n }\n // If we find a potential extension, and the number preceding this is a viable\n // number, we assume it is an extension.\n var numberWithoutExtension = number.slice(0, start);\n var matches = number.match(EXTN_PATTERN);\n var i = 1;\n while (i < matches.length) {\n if (matches[i]) {\n return {\n number: numberWithoutExtension,\n ext: matches[i]\n };\n }\n i++;\n }\n}\n//# sourceMappingURL=extractExtension.js.map","function _createForOfIteratorHelperLoose(r, e) { var t = \"undefined\" != typeof Symbol && r[Symbol.iterator] || r[\"@@iterator\"]; if (t) return (t = t.call(r)).next.bind(t); if (Array.isArray(r) || (t = _unsupportedIterableToArray(r)) || e && r && \"number\" == typeof r.length) { t && (r = t); var o = 0; return function () { return o >= r.length ? { done: !0 } : { done: !1, value: r[o++] }; }; } throw new TypeError(\"Invalid attempt to iterate non-iterable instance.\\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.\"); }\nfunction _unsupportedIterableToArray(r, a) { if (r) { if (\"string\" == typeof r) return _arrayLikeToArray(r, a); var t = {}.toString.call(r).slice(8, -1); return \"Object\" === t && r.constructor && (t = r.constructor.name), \"Map\" === t || \"Set\" === t ? Array.from(r) : \"Arguments\" === t || /^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(t) ? _arrayLikeToArray(r, a) : void 0; } }\nfunction _arrayLikeToArray(r, a) { (null == a || a > r.length) && (a = r.length); for (var e = 0, n = Array(a); e < a; e++) n[e] = r[e]; return n; }\n// These mappings map a character (key) to a specific digit that should\n// replace it for normalization purposes. Non-European digits that\n// may be used in phone numbers are mapped to a European equivalent.\n//\n// E.g. in Iraq they don't write `+442323234` but rather `+٤٤٢٣٢٣٢٣٤`.\n//\nexport var DIGITS = {\n '0': '0',\n '1': '1',\n '2': '2',\n '3': '3',\n '4': '4',\n '5': '5',\n '6': '6',\n '7': '7',\n '8': '8',\n '9': '9',\n \"\\uFF10\": '0',\n // Fullwidth digit 0\n \"\\uFF11\": '1',\n // Fullwidth digit 1\n \"\\uFF12\": '2',\n // Fullwidth digit 2\n \"\\uFF13\": '3',\n // Fullwidth digit 3\n \"\\uFF14\": '4',\n // Fullwidth digit 4\n \"\\uFF15\": '5',\n // Fullwidth digit 5\n \"\\uFF16\": '6',\n // Fullwidth digit 6\n \"\\uFF17\": '7',\n // Fullwidth digit 7\n \"\\uFF18\": '8',\n // Fullwidth digit 8\n \"\\uFF19\": '9',\n // Fullwidth digit 9\n \"\\u0660\": '0',\n // Arabic-indic digit 0\n \"\\u0661\": '1',\n // Arabic-indic digit 1\n \"\\u0662\": '2',\n // Arabic-indic digit 2\n \"\\u0663\": '3',\n // Arabic-indic digit 3\n \"\\u0664\": '4',\n // Arabic-indic digit 4\n \"\\u0665\": '5',\n // Arabic-indic digit 5\n \"\\u0666\": '6',\n // Arabic-indic digit 6\n \"\\u0667\": '7',\n // Arabic-indic digit 7\n \"\\u0668\": '8',\n // Arabic-indic digit 8\n \"\\u0669\": '9',\n // Arabic-indic digit 9\n \"\\u06F0\": '0',\n // Eastern-Arabic digit 0\n \"\\u06F1\": '1',\n // Eastern-Arabic digit 1\n \"\\u06F2\": '2',\n // Eastern-Arabic digit 2\n \"\\u06F3\": '3',\n // Eastern-Arabic digit 3\n \"\\u06F4\": '4',\n // Eastern-Arabic digit 4\n \"\\u06F5\": '5',\n // Eastern-Arabic digit 5\n \"\\u06F6\": '6',\n // Eastern-Arabic digit 6\n \"\\u06F7\": '7',\n // Eastern-Arabic digit 7\n \"\\u06F8\": '8',\n // Eastern-Arabic digit 8\n \"\\u06F9\": '9' // Eastern-Arabic digit 9\n};\nexport function parseDigit(character) {\n return DIGITS[character];\n}\n\n/**\r\n * Parses phone number digits from a string.\r\n * Drops all punctuation leaving only digits.\r\n * Also converts wide-ascii and arabic-indic numerals to conventional numerals.\r\n * E.g. in Iraq they don't write `+442323234` but rather `+٤٤٢٣٢٣٢٣٤`.\r\n * @param {string} string\r\n * @return {string}\r\n * @example\r\n * ```js\r\n * parseDigits('8 (800) 555')\r\n * // Outputs '8800555'.\r\n * ```\r\n */\nexport default function parseDigits(string) {\n var result = '';\n // Using `.split('')` here instead of normal `for ... of`\n // because the importing application doesn't neccessarily include an ES6 polyfill.\n // The `.split('')` approach discards \"exotic\" UTF-8 characters\n // (the ones consisting of four bytes) but digits\n // (including non-European ones) don't fall into that range\n // so such \"exotic\" characters would be discarded anyway.\n for (var _iterator = _createForOfIteratorHelperLoose(string.split('')), _step; !(_step = _iterator()).done;) {\n var character = _step.value;\n var digit = parseDigit(character);\n if (digit) {\n result += digit;\n }\n }\n return result;\n}\n//# sourceMappingURL=parseDigits.js.map","function _createForOfIteratorHelperLoose(r, e) { var t = \"undefined\" != typeof Symbol && r[Symbol.iterator] || r[\"@@iterator\"]; if (t) return (t = t.call(r)).next.bind(t); if (Array.isArray(r) || (t = _unsupportedIterableToArray(r)) || e && r && \"number\" == typeof r.length) { t && (r = t); var o = 0; return function () { return o >= r.length ? { done: !0 } : { done: !1, value: r[o++] }; }; } throw new TypeError(\"Invalid attempt to iterate non-iterable instance.\\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.\"); }\nfunction _unsupportedIterableToArray(r, a) { if (r) { if (\"string\" == typeof r) return _arrayLikeToArray(r, a); var t = {}.toString.call(r).slice(8, -1); return \"Object\" === t && r.constructor && (t = r.constructor.name), \"Map\" === t || \"Set\" === t ? Array.from(r) : \"Arguments\" === t || /^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(t) ? _arrayLikeToArray(r, a) : void 0; } }\nfunction _arrayLikeToArray(r, a) { (null == a || a > r.length) && (a = r.length); for (var e = 0, n = Array(a); e < a; e++) n[e] = r[e]; return n; }\nimport { parseDigit } from './helpers/parseDigits.js';\n\n/**\r\n * Parses phone number characters from a string.\r\n * Drops all punctuation leaving only digits and the leading `+` sign (if any).\r\n * Also converts wide-ascii and arabic-indic numerals to conventional numerals.\r\n * E.g. in Iraq they don't write `+442323234` but rather `+٤٤٢٣٢٣٢٣٤`.\r\n * @param {string} string\r\n * @return {string}\r\n * @example\r\n * ```js\r\n * // Outputs '8800555'.\r\n * parseIncompletePhoneNumber('8 (800) 555')\r\n * // Outputs '+7800555'.\r\n * parseIncompletePhoneNumber('+7 800 555')\r\n * ```\r\n */\nexport default function parseIncompletePhoneNumber(string) {\n var result = '';\n // Using `.split('')` here instead of normal `for ... of`\n // because the importing application doesn't neccessarily include an ES6 polyfill.\n // The `.split('')` approach discards \"exotic\" UTF-8 characters\n // (the ones consisting of four bytes) but digits\n // (including non-European ones) don't fall into that range\n // so such \"exotic\" characters would be discarded anyway.\n for (var _iterator = _createForOfIteratorHelperLoose(string.split('')), _step; !(_step = _iterator()).done;) {\n var character = _step.value;\n result += parsePhoneNumberCharacter(character, result) || '';\n }\n return result;\n}\n\n/**\r\n * Parses next character while parsing phone number digits (including a `+`)\r\n * from text: discards everything except `+` and digits, and `+` is only allowed\r\n * at the start of a phone number.\r\n * For example, is used in `react-phone-number-input` where it uses\r\n * [`input-format`](https://gitlab.com/catamphetamine/input-format).\r\n * @param {string} character - Yet another character from raw input string.\r\n * @param {string?} prevParsedCharacters - Previous parsed characters.\r\n * @param {function?} eventListener - An optional \"on event\" function.\r\n * @return {string?} The parsed character.\r\n */\nexport function parsePhoneNumberCharacter(character, prevParsedCharacters, eventListener) {\n // Only allow a leading `+`.\n if (character === '+') {\n // If this `+` is not the first parsed character\n // then discard it.\n if (prevParsedCharacters) {\n // `eventListener` argument was added to this `export`ed function on Dec 26th, 2023.\n // Any 3rd-party code that used to `import` and call this function before that\n // won't be passing any `eventListener` argument.\n //\n // The addition of the `eventListener` argument was to fix the slightly-weird behavior\n // of parsing an input string when the user inputs something like `\"2+7\"\n // https://github.com/catamphetamine/react-phone-number-input/issues/437\n //\n // If the parser encounters an unexpected `+` in a string being parsed\n // then it simply discards that out-of-place `+` and any following characters.\n //\n if (typeof eventListener === 'function') {\n eventListener('end');\n }\n return;\n }\n return '+';\n }\n // Allow digits.\n return parseDigit(character);\n}\n//# sourceMappingURL=parseIncompletePhoneNumber.js.map","function _createForOfIteratorHelperLoose(r, e) { var t = \"undefined\" != typeof Symbol && r[Symbol.iterator] || r[\"@@iterator\"]; if (t) return (t = t.call(r)).next.bind(t); if (Array.isArray(r) || (t = _unsupportedIterableToArray(r)) || e && r && \"number\" == typeof r.length) { t && (r = t); var o = 0; return function () { return o >= r.length ? { done: !0 } : { done: !1, value: r[o++] }; }; } throw new TypeError(\"Invalid attempt to iterate non-iterable instance.\\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.\"); }\nfunction _unsupportedIterableToArray(r, a) { if (r) { if (\"string\" == typeof r) return _arrayLikeToArray(r, a); var t = {}.toString.call(r).slice(8, -1); return \"Object\" === t && r.constructor && (t = r.constructor.name), \"Map\" === t || \"Set\" === t ? Array.from(r) : \"Arguments\" === t || /^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(t) ? _arrayLikeToArray(r, a) : void 0; } }\nfunction _arrayLikeToArray(r, a) { (null == a || a > r.length) && (a = r.length); for (var e = 0, n = Array(a); e < a; e++) n[e] = r[e]; return n; }\n/**\r\n * Merges two arrays.\r\n * @param {*} a\r\n * @param {*} b\r\n * @return {*}\r\n */\nexport default function mergeArrays(a, b) {\n var merged = a.slice();\n for (var _iterator = _createForOfIteratorHelperLoose(b), _step; !(_step = _iterator()).done;) {\n var element = _step.value;\n if (a.indexOf(element) < 0) {\n merged.push(element);\n }\n }\n return merged.sort(function (a, b) {\n return a - b;\n });\n\n // ES6 version, requires Set polyfill.\n // let merged = new Set(a)\n // for (const element of b) {\n // \tmerged.add(i)\n // }\n // return Array.from(merged).sort((a, b) => a - b)\n}\n//# sourceMappingURL=mergeArrays.js.map","import Metadata from '../metadata.js';\nimport mergeArrays from './mergeArrays.js';\n\n/**\r\n * Checks phone number length against the phone numbering plan selected in metadata.\r\n * Optionally, it could be restrained by a specific country.\r\n * @param {string} nationalNumber\r\n * @param {string?} country — Specific country to use rather than the one that is pre-selected in the metadata instance.\r\n * @param {Metadata} metadata — Metadata instance with a selected numbering plan.\r\n * @returns {string}\r\n */\nexport default function checkNumberLength(nationalNumber, country, metadata) {\n return checkNumberLengthForType(nationalNumber, undefined, country, metadata);\n}\n\n/**\r\n * Checks phone number length against the phone numbering plan selected in metadata.\r\n * Optionally, it could be restrained by a specific phone number type or a specific country.\r\n * @param {string} nationalNumber\r\n * @param {string?} type — Specific phone number type.\r\n * @param {string?} country — Specific country to use instead of the one that is pre-selected in the metadata instance.\r\n * @param {Metadata} metadata — Metadata instance with a selected numbering plan.\r\n * @returns {string} See the README on `validatePhoneNumberLength()` function, with an addition of a special case: when phone numbers of type `type` aren't possible in the telephone numbering plan, it will return \"INVALID_LENGTH\".\r\n */\n// Checks whether a number is possible for a certain `country` based on the number length.\n//\n// This function is not supported by metadata generated with ancient versions of\n// `libphonenumber-js` (before version `1.0.18`) which didn't include \"possible lengths\".\n//\n// There was also a known issue with `checkNumberLength()` function:\n// if a number is possible only in a certain `country` among several `countries`\n// that share the same \"country calling code\", that function would check\n// the possibility of the phone number only in the \"main\" `country` for the \"country calling code\"\n// and would not check if it's actually be possible in the speciifc `country`.\n//\n// For example, \"+1310xxxx\" numbers are valid in Canada.\n// However, they are not possible in the US due to being too short.\n// Since Canada and the US share the same country calling code — \"+1\" —\n// `checkNumberLength()` function used to return not \"IS_POSSIBLE\" for \"+1310xxxx\" numbers.\n//\n// In such cases, when using \"/max\" metadata, `isValid()` could output `true`\n// but at the same time `isPossible()` could output `false`, which was contradictory.\n//\n// See https://issuetracker.google.com/issues/335892662 for the discusson in Google's issues.\n//\n// The solution suggested by Google was implemented: an optional `country` argument\n// was added to `checkNumberLength()` function. If present, that `country` will be used\n// to check phone number length for that specific `country` rather than the \"main\" country\n// for the shared \"country calling code\".\n//\nexport function checkNumberLengthForType(nationalNumber, type, country, metadata) {\n if (country) {\n // If a specific `country` is specified, re-create a metadata instance with it.\n metadata = new Metadata(metadata.metadata);\n metadata.selectNumberingPlan(country);\n }\n var type_info = metadata.type(type);\n\n // There should always be \"<possiblePengths/>\" set for every type element.\n // This is declared in the XML schema.\n // For size efficiency, where a sub-description (e.g. fixed-line)\n // has the same \"<possiblePengths/>\" as the \"general description\", this is missing,\n // so we fall back to the \"general description\". Where no numbers of the type\n // exist at all, there is one possible length (-1) which is guaranteed\n // not to match the length of any real phone number.\n var possible_lengths = type_info && type_info.possibleLengths() || metadata.possibleLengths();\n // let local_lengths = type_info && type.possibleLengthsLocal() || metadata.possibleLengthsLocal()\n\n // Metadata before version `1.0.18` didn't contain `possible_lengths`.\n if (!possible_lengths) {\n return 'IS_POSSIBLE';\n }\n if (type === 'FIXED_LINE_OR_MOBILE') {\n // No such country in metadata.\n /* istanbul ignore next */\n if (!metadata.type('FIXED_LINE')) {\n // The rare case has been encountered where no fixedLine data is available\n // (true for some non-geographic entities), so we just check mobile.\n return checkNumberLengthForType(nationalNumber, 'MOBILE', country, metadata);\n }\n var mobile_type = metadata.type('MOBILE');\n if (mobile_type) {\n // Merge the mobile data in if there was any. \"Concat\" creates a new\n // array, it doesn't edit possible_lengths in place, so we don't need a copy.\n // Note that when adding the possible lengths from mobile, we have\n // to again check they aren't empty since if they are this indicates\n // they are the same as the general desc and should be obtained from there.\n possible_lengths = mergeArrays(possible_lengths, mobile_type.possibleLengths());\n // The current list is sorted; we need to merge in the new list and\n // re-sort (duplicates are okay). Sorting isn't so expensive because\n // the lists are very small.\n\n // if (local_lengths) {\n // \tlocal_lengths = mergeArrays(local_lengths, mobile_type.possibleLengthsLocal())\n // } else {\n // \tlocal_lengths = mobile_type.possibleLengthsLocal()\n // }\n }\n }\n // If the type doesn't exist then return 'INVALID_LENGTH'.\n else if (type && !type_info) {\n return 'INVALID_LENGTH';\n }\n var actual_length = nationalNumber.length;\n\n // In `libphonenumber-js` all \"local-only\" formats are dropped for simplicity.\n // // This is safe because there is never an overlap beween the possible lengths\n // // and the local-only lengths; this is checked at build time.\n // if (local_lengths && local_lengths.indexOf(nationalNumber.length) >= 0)\n // {\n // \treturn 'IS_POSSIBLE_LOCAL_ONLY'\n // }\n\n var minimum_length = possible_lengths[0];\n if (minimum_length === actual_length) {\n return 'IS_POSSIBLE';\n }\n if (minimum_length > actual_length) {\n return 'TOO_SHORT';\n }\n if (possible_lengths[possible_lengths.length - 1] < actual_length) {\n return 'TOO_LONG';\n }\n\n // We skip the first element since we've already checked it.\n return possible_lengths.indexOf(actual_length, 1) >= 0 ? 'IS_POSSIBLE' : 'INVALID_LENGTH';\n}\n//# sourceMappingURL=checkNumberLength.js.map","import Metadata from './metadata.js';\nimport checkNumberLength from './helpers/checkNumberLength.js';\n\n/**\r\n * Checks if a phone number is \"possible\" (basically just checks its length).\r\n *\r\n * isPossible(phoneNumberInstance, { ..., v2: true }, metadata)\r\n *\r\n * isPossible({ phone: '8005553535', country: 'RU' }, { ... }, metadata)\r\n * isPossible({ phone: '8005553535', country: 'RU' }, undefined, metadata)\r\n *\r\n * @param {object|PhoneNumber} input — If `options.v2: true` flag is passed, the `input` should be a `PhoneNumber` instance. Otherwise, it should be an object of shape `{ phone: '...', country: '...' }`.\r\n * @param {object} [options]\r\n * @param {object} metadataJson\r\n * @return {string}\r\n */\nexport default function isPossiblePhoneNumber(input, options, metadataJson) {\n /* istanbul ignore if */\n if (options === undefined) {\n options = {};\n }\n var metadata = new Metadata(metadataJson);\n if (options.v2) {\n if (!input.countryCallingCode) {\n throw new Error('Invalid phone number object passed');\n }\n metadata.selectNumberingPlan(input.country || input.countryCallingCode);\n } else {\n if (!input.phone) {\n return false;\n }\n if (input.country) {\n if (!metadata.hasCountry(input.country)) {\n throw new Error(\"Unknown country: \".concat(input.country));\n }\n metadata.selectNumberingPlan(input.country);\n } else {\n if (!input.countryCallingCode) {\n throw new Error('Invalid phone number object passed');\n }\n metadata.selectNumberingPlan(input.countryCallingCode);\n }\n }\n\n // Old (legacy) metadata (< 1.0.18) had no \"possible length\" data.\n // So `isPossibleNumber()` function is supported only for non-legacy metadata.\n if (metadata.possibleLengths()) {\n return isPossibleNumber(input.phone || input.nationalNumber, metadata);\n }\n\n // There was a bug in versions from `1.7.35` to `1.7.37` of `libphonenumber-js`\n // where \"possible_lengths\" property was missing from \"non-geographical\" numbering plans' metadata.\n // After that, the bug was noticed and fixed.\n // So for versions from `1.7.35` to `1.7.37`, just assume that all \"non=geotraphical\" numbers are possible.\n // The reason is that the bug was noticed relatively quickly (within a day or so)\n // and it's unlikely that anyone generated their custom metadata in that short time span.\n // And if they didn't generate any custom metadata then a follow-up package update would've silently fixed the bug.\n if (input.countryCallingCode && metadata.isNonGeographicCallingCode(input.countryCallingCode)) {\n return true;\n }\n\n // `isPossibleNumber()` function is not supported.\n throw new Error('Missing \"possibleLengths\" in metadata. Perhaps the metadata has been generated before v1.0.18.');\n}\n\n/**\r\n * Tells if a given national (significant) number is possible\r\n * @param {string} nationalNumber\r\n * @param {Metadata} metadata = Metadata instance with a pre-selected telephone numbering plan.\r\n * @returns {boolean}\r\n */\nexport function isPossibleNumber(nationalNumber, metadata) {\n switch (checkNumberLength(nationalNumber, undefined, metadata)) {\n case 'IS_POSSIBLE':\n return true;\n // This library ignores \"local-only\" phone numbers (for simplicity).\n // See the readme for more info on what are \"local-only\" phone numbers.\n // case 'IS_POSSIBLE_LOCAL_ONLY':\n // \treturn !isInternational\n default:\n return false;\n }\n}\n//# sourceMappingURL=isPossible.js.map","/**\r\n * Checks whether the entire input sequence can be matched\r\n * against the regular expression.\r\n * @return {boolean}\r\n */\nexport default function matchesEntirely(text, regularExpressionText) {\n // If the assigning of the `''` default value is moved to the arguments above,\n // the code coverage would decrease for some weird reason.\n text = text || '';\n return new RegExp('^(?:' + regularExpressionText + ')$').test(text);\n}\n//# sourceMappingURL=matchesEntirely.js.map","function _createForOfIteratorHelperLoose(r, e) { var t = \"undefined\" != typeof Symbol && r[Symbol.iterator] || r[\"@@iterator\"]; if (t) return (t = t.call(r)).next.bind(t); if (Array.isArray(r) || (t = _unsupportedIterableToArray(r)) || e && r && \"number\" == typeof r.length) { t && (r = t); var o = 0; return function () { return o >= r.length ? { done: !0 } : { done: !1, value: r[o++] }; }; } throw new TypeError(\"Invalid attempt to iterate non-iterable instance.\\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.\"); }\nfunction _unsupportedIterableToArray(r, a) { if (r) { if (\"string\" == typeof r) return _arrayLikeToArray(r, a); var t = {}.toString.call(r).slice(8, -1); return \"Object\" === t && r.constructor && (t = r.constructor.name), \"Map\" === t || \"Set\" === t ? Array.from(r) : \"Arguments\" === t || /^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(t) ? _arrayLikeToArray(r, a) : void 0; } }\nfunction _arrayLikeToArray(r, a) { (null == a || a > r.length) && (a = r.length); for (var e = 0, n = Array(a); e < a; e++) n[e] = r[e]; return n; }\nimport Metadata from '../metadata.js';\nimport matchesEntirely from './matchesEntirely.js';\nvar NON_FIXED_LINE_PHONE_TYPES = ['MOBILE', 'PREMIUM_RATE', 'TOLL_FREE', 'SHARED_COST', 'VOIP', 'PERSONAL_NUMBER', 'PAGER', 'UAN', 'VOICEMAIL'];\n\n// Finds out national phone number type (fixed line, mobile, etc)\nexport default function getNumberType(input, options, metadataJson) {\n // If assigning the `{}` default value is moved to the arguments above,\n // code coverage would decrease for some weird reason.\n options = options || {};\n\n // When `parse()` returns an empty object — `{}` —\n // that means that the phone number is malformed,\n // so it can't possibly be valid.\n if (!input.country && !input.countryCallingCode) {\n return;\n }\n var metadata = new Metadata(metadataJson);\n metadata.selectNumberingPlan(input.country || input.countryCallingCode);\n var nationalNumber = options.v2 ? input.nationalNumber : input.phone;\n\n // The following is copy-pasted from the original function:\n // https://github.com/googlei18n/libphonenumber/blob/3ea547d4fbaa2d0b67588904dfa5d3f2557c27ff/javascript/i18n/phonenumbers/phonenumberutil.js#L2835\n\n // Is this national number even valid for this country\n if (!matchesEntirely(nationalNumber, metadata.nationalNumberPattern())) {\n return;\n }\n\n // Is it fixed line number\n if (isNumberTypeEqualTo(nationalNumber, 'FIXED_LINE', metadata)) {\n // Because duplicate regular expressions are removed\n // to reduce metadata size, if \"mobile\" pattern is \"\"\n // then it means it was removed due to being a duplicate of the fixed-line pattern.\n //\n if (metadata.type('MOBILE') && metadata.type('MOBILE').pattern() === '') {\n return 'FIXED_LINE_OR_MOBILE';\n }\n\n // `MOBILE` type pattern isn't included if it matched `FIXED_LINE` one.\n // For example, for \"US\" country.\n // Old metadata (< `1.0.18`) had a specific \"types\" data structure\n // that happened to be `undefined` for `MOBILE` in that case.\n // Newer metadata (>= `1.0.18`) has another data structure that is\n // not `undefined` for `MOBILE` in that case (it's just an empty array).\n // So this `if` is just for backwards compatibility with old metadata.\n if (!metadata.type('MOBILE')) {\n return 'FIXED_LINE_OR_MOBILE';\n }\n\n // Check if the number happens to qualify as both fixed line and mobile.\n // (no such country in the minimal metadata set)\n /* istanbul ignore if */\n if (isNumberTypeEqualTo(nationalNumber, 'MOBILE', metadata)) {\n return 'FIXED_LINE_OR_MOBILE';\n }\n return 'FIXED_LINE';\n }\n for (var _iterator = _createForOfIteratorHelperLoose(NON_FIXED_LINE_PHONE_TYPES), _step; !(_step = _iterator()).done;) {\n var type = _step.value;\n if (isNumberTypeEqualTo(nationalNumber, type, metadata)) {\n return type;\n }\n }\n}\nexport function isNumberTypeEqualTo(nationalNumber, type, metadata) {\n var typeDefinition = metadata.type(type);\n if (!typeDefinition || !typeDefinition.pattern()) {\n return false;\n }\n\n // Check if any possible number lengths are present;\n // if so, we use them to avoid checking\n // the validation pattern if they don't match.\n // If they are absent, this means they match\n // the general description, which we have\n // already checked before a specific number type.\n if (typeDefinition.possibleLengths() && typeDefinition.possibleLengths().indexOf(nationalNumber.length) < 0) {\n return false;\n }\n return matchesEntirely(nationalNumber, typeDefinition.pattern());\n}\n//# sourceMappingURL=getNumberType.js.map","import Metadata from './metadata.js';\nimport matchesEntirely from './helpers/matchesEntirely.js';\nimport getNumberType from './helpers/getNumberType.js';\n\n/**\r\n * Checks if a given phone number is valid.\r\n *\r\n * isValid(phoneNumberInstance, { ..., v2: true }, metadata)\r\n *\r\n * isPossible({ phone: '8005553535', country: 'RU' }, { ... }, metadata)\r\n * isPossible({ phone: '8005553535', country: 'RU' }, undefined, metadata)\r\n *\r\n * If the `number` is a string, it will be parsed to an object,\r\n * but only if it contains only valid phone number characters (including punctuation).\r\n * If the `number` is an object, it is used as is.\r\n *\r\n * The optional `defaultCountry` argument is the default country.\r\n * I.e. it does not restrict to just that country,\r\n * e.g. in those cases where several countries share\r\n * the same phone numbering rules (NANPA, Britain, etc).\r\n * For example, even though the number `07624 369230`\r\n * belongs to the Isle of Man (\"IM\" country code)\r\n * calling `isValidNumber('07624369230', 'GB', metadata)`\r\n * still returns `true` because the country is not restricted to `GB`,\r\n * it's just that `GB` is the default one for the phone numbering rules.\r\n * For restricting the country see `isValidNumberForRegion()`\r\n * though restricting a country might not be a good idea.\r\n * https://github.com/googlei18n/libphonenumber/blob/master/FAQ.md#when-should-i-use-isvalidnumberforregion\r\n *\r\n * Examples:\r\n *\r\n * ```js\r\n * isValidNumber('+78005553535', metadata)\r\n * isValidNumber('8005553535', 'RU', metadata)\r\n * isValidNumber('88005553535', 'RU', metadata)\r\n * isValidNumber({ phone: '8005553535', country: 'RU' }, metadata)\r\n * ```\r\n */\nexport default function isValidNumber(input, options, metadataJson) {\n // If assigning the `{}` default value is moved to the arguments above,\n // code coverage would decrease for some weird reason.\n options = options || {};\n var metadata = new Metadata(metadataJson);\n metadata.selectNumberingPlan(input.country || input.countryCallingCode);\n\n // By default, countries only have type regexps when it's required for\n // distinguishing different countries having the same `countryCallingCode`.\n if (metadata.hasTypes()) {\n return getNumberType(input, options, metadata.metadata) !== undefined;\n }\n\n // If there are no type regexps for this country in metadata then use\n // `nationalNumberPattern` as a \"better than nothing\" replacement.\n var nationalNumber = options.v2 ? input.nationalNumber : input.phone;\n return matchesEntirely(nationalNumber, metadata.nationalNumberPattern());\n}\n//# sourceMappingURL=isValid.js.map","var COUNTRY_CODE_REG_EXP = /^[A-Z]{2}$/;\nexport default function isCountryCode(string) {\n return COUNTRY_CODE_REG_EXP.test(string);\n}\n//# sourceMappingURL=isCountryCode.js.map","import Metadata from '../metadata.js';\nimport isCountryCode from './isCountryCode.js';\nvar USE_NON_GEOGRAPHIC_COUNTRY_CODE = false;\nexport default function getCountryAndCallingCodeFromOneOfThem(countryOrCallingCode, metadataJson) {\n var country;\n var callingCode;\n var metadata = new Metadata(metadataJson);\n // If country code is passed then derive `countryCallingCode` from it.\n // Also store the country code as `.country`.\n if (isCountryCode(countryOrCallingCode)) {\n country = countryOrCallingCode;\n metadata.selectNumberingPlan(country);\n callingCode = metadata.countryCallingCode();\n } else {\n callingCode = countryOrCallingCode;\n /* istanbul ignore if */\n if (USE_NON_GEOGRAPHIC_COUNTRY_CODE) {\n if (metadata.isNonGeographicCallingCode(callingCode)) {\n country = '001';\n }\n }\n }\n return {\n country: country,\n callingCode: callingCode\n };\n}\n//# sourceMappingURL=getCountryAndCallingCodeFromOneOfThem.js.map","import Metadata from '../metadata.js';\n\n/**\r\n * Returns a list of countries that the phone number could potentially belong to.\r\n * @param {string} callingCode — Calling code.\r\n * @param {string} nationalNumber — National (significant) number.\r\n * @param {object} metadata — Metadata.\r\n * @return {string[]} A list of possible countries.\r\n */\nexport default function getPossibleCountriesForNumber(callingCode, nationalNumber, metadata) {\n var _metadata = new Metadata(metadata);\n var possibleCountries = _metadata.getCountryCodesForCallingCode(callingCode);\n if (!possibleCountries) {\n return [];\n }\n return possibleCountries.filter(function (country) {\n return couldNationalNumberBelongToCountry(nationalNumber, country, metadata);\n });\n}\nfunction couldNationalNumberBelongToCountry(nationalNumber, country, metadataJson) {\n var metadata = new Metadata(metadataJson);\n metadata.selectNumberingPlan(country);\n return metadata.numberingPlan.possibleLengths().indexOf(nationalNumber.length) >= 0;\n}\n//# sourceMappingURL=getPossibleCountriesForNumber.js.map","import Metadata from '../metadata.js';\nimport { VALID_DIGITS } from '../constants.js';\nvar CAPTURING_DIGIT_PATTERN = new RegExp('([' + VALID_DIGITS + '])');\nexport default function stripIddPrefix(number, country, callingCode, metadataJson) {\n if (!country) {\n return;\n }\n\n // Get the IDD prefix pattern.\n var metadata = new Metadata(metadataJson);\n metadata.selectNumberingPlan(country || callingCode);\n var IDDPrefixPattern = new RegExp(metadata.IDDPrefix());\n\n // Check if the number is IDD-prefixed.\n if (number.search(IDDPrefixPattern) !== 0) {\n return;\n }\n\n // Strip IDD prefix.\n number = number.slice(number.match(IDDPrefixPattern)[0].length);\n\n // If there're any digits after an IDD prefix,\n // then those digits are a country calling code.\n // Since no country code starts with a `0`,\n // the code below validates that the next digit (if present) is not `0`.\n var matchedGroups = number.match(CAPTURING_DIGIT_PATTERN);\n if (matchedGroups && matchedGroups[1] != null && matchedGroups[1].length > 0) {\n if (matchedGroups[1] === '0') {\n return;\n }\n }\n return number;\n}\n//# sourceMappingURL=stripIddPrefix.js.map","/**\r\n * Strips any national prefix (such as 0, 1) present in a\r\n * (possibly incomplete) number provided.\r\n * \"Carrier codes\" are only used in Colombia and Brazil,\r\n * and only when dialing within those countries from a mobile phone to a fixed line number.\r\n * Sometimes it won't actually strip national prefix\r\n * and will instead prepend some digits to the `number`:\r\n * for example, when number `2345678` is passed with `VI` country selected,\r\n * it will return `{ number: \"3402345678\" }`, because `340` area code is prepended.\r\n * @param {string} number — National number digits.\r\n * @param {object} metadata — Metadata with country selected.\r\n * @return {object} `{ nationalNumber: string, nationalPrefix: string? carrierCode: string? }`. Even if a national prefix was extracted, it's not necessarily present in the returned object, so don't rely on its presence in the returned object in order to find out whether a national prefix has been extracted or not.\r\n */\nexport default function extractNationalNumberFromPossiblyIncompleteNumber(number, metadata) {\n if (number && metadata.numberingPlan.nationalPrefixForParsing()) {\n // See METADATA.md for the description of\n // `national_prefix_for_parsing` and `national_prefix_transform_rule`.\n // Attempt to parse the first digits as a national prefix.\n var prefixPattern = new RegExp('^(?:' + metadata.numberingPlan.nationalPrefixForParsing() + ')');\n var prefixMatch = prefixPattern.exec(number);\n if (prefixMatch) {\n var nationalNumber;\n var carrierCode;\n // https://gitlab.com/catamphetamine/libphonenumber-js/-/blob/master/METADATA.md#national_prefix_for_parsing--national_prefix_transform_rule\n // If a `national_prefix_for_parsing` has any \"capturing groups\"\n // then it means that the national (significant) number is equal to\n // those \"capturing groups\" transformed via `national_prefix_transform_rule`,\n // and nothing could be said about the actual national prefix:\n // what is it and was it even there.\n // If a `national_prefix_for_parsing` doesn't have any \"capturing groups\",\n // then everything it matches is a national prefix.\n // To determine whether `national_prefix_for_parsing` matched any\n // \"capturing groups\", the value of the result of calling `.exec()`\n // is looked at, and if it has non-undefined values where there're\n // \"capturing groups\" in the regular expression, then it means\n // that \"capturing groups\" have been matched.\n // It's not possible to tell whether there'll be any \"capturing gropus\"\n // before the matching process, because a `national_prefix_for_parsing`\n // could exhibit both behaviors.\n var capturedGroupsCount = prefixMatch.length - 1;\n var hasCapturedGroups = capturedGroupsCount > 0 && prefixMatch[capturedGroupsCount];\n if (metadata.nationalPrefixTransformRule() && hasCapturedGroups) {\n nationalNumber = number.replace(prefixPattern, metadata.nationalPrefixTransformRule());\n // If there's more than one captured group,\n // then carrier code is the second one.\n if (capturedGroupsCount > 1) {\n carrierCode = prefixMatch[1];\n }\n }\n // If there're no \"capturing groups\",\n // or if there're \"capturing groups\" but no\n // `national_prefix_transform_rule`,\n // then just strip the national prefix from the number,\n // and possibly a carrier code.\n // Seems like there could be more.\n else {\n // `prefixBeforeNationalNumber` is the whole substring matched by\n // the `national_prefix_for_parsing` regular expression.\n // There seem to be no guarantees that it's just a national prefix.\n // For example, if there's a carrier code, it's gonna be a\n // part of `prefixBeforeNationalNumber` too.\n var prefixBeforeNationalNumber = prefixMatch[0];\n nationalNumber = number.slice(prefixBeforeNationalNumber.length);\n // If there's at least one captured group,\n // then carrier code is the first one.\n if (hasCapturedGroups) {\n carrierCode = prefixMatch[1];\n }\n }\n // Tries to guess whether a national prefix was present in the input.\n // This is not something copy-pasted from Google's library:\n // they don't seem to have an equivalent for that.\n // So this isn't an \"officially approved\" way of doing something like that.\n // But since there seems no other existing method, this library uses it.\n var nationalPrefix;\n if (hasCapturedGroups) {\n var possiblePositionOfTheFirstCapturedGroup = number.indexOf(prefixMatch[1]);\n var possibleNationalPrefix = number.slice(0, possiblePositionOfTheFirstCapturedGroup);\n // Example: an Argentinian (AR) phone number `0111523456789`.\n // `prefixMatch[0]` is `01115`, and `$1` is `11`,\n // and the rest of the phone number is `23456789`.\n // The national number is transformed via `9$1` to `91123456789`.\n // National prefix `0` is detected being present at the start.\n // if (possibleNationalPrefix.indexOf(metadata.numberingPlan.nationalPrefix()) === 0) {\n if (possibleNationalPrefix === metadata.numberingPlan.nationalPrefix()) {\n nationalPrefix = metadata.numberingPlan.nationalPrefix();\n }\n } else {\n nationalPrefix = prefixMatch[0];\n }\n return {\n nationalNumber: nationalNumber,\n nationalPrefix: nationalPrefix,\n carrierCode: carrierCode\n };\n }\n }\n return {\n nationalNumber: number\n };\n}\n//# sourceMappingURL=extractNationalNumberFromPossiblyIncompleteNumber.js.map","function _createForOfIteratorHelperLoose(r, e) { var t = \"undefined\" != typeof Symbol && r[Symbol.iterator] || r[\"@@iterator\"]; if (t) return (t = t.call(r)).next.bind(t); if (Array.isArray(r) || (t = _unsupportedIterableToArray(r)) || e && r && \"number\" == typeof r.length) { t && (r = t); var o = 0; return function () { return o >= r.length ? { done: !0 } : { done: !1, value: r[o++] }; }; } throw new TypeError(\"Invalid attempt to iterate non-iterable instance.\\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.\"); }\nfunction _unsupportedIterableToArray(r, a) { if (r) { if (\"string\" == typeof r) return _arrayLikeToArray(r, a); var t = {}.toString.call(r).slice(8, -1); return \"Object\" === t && r.constructor && (t = r.constructor.name), \"Map\" === t || \"Set\" === t ? Array.from(r) : \"Arguments\" === t || /^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(t) ? _arrayLikeToArray(r, a) : void 0; } }\nfunction _arrayLikeToArray(r, a) { (null == a || a > r.length) && (a = r.length); for (var e = 0, n = Array(a); e < a; e++) n[e] = r[e]; return n; }\nimport Metadata from '../metadata.js';\nimport getNumberType from './getNumberType.js';\n\n/**\r\n * Returns the exact country that a given national (significant) number belongs to\r\n * in case of ambiguity, i.e. when multiple countries share the same \"country calling code\".\r\n * @param {string} [nationalNumber]\r\n * @param {string[]} countries — A list of countries that share the same calling code.\r\n * @param {object} metadata — Metadata JSON.\r\n * @returns {string?} Returns the exact country this number belongs to, or `undefined` if the exact country couldn't be determined.\r\n */\nexport default function getCountryByNationalNumber(nationalNumber, countries, metadataJson) {\n // Create a new `metadata` instance because it will be selecting a `country`.\n var metadata = new Metadata(metadataJson);\n\n // const matchingCountries = []\n\n for (var _iterator = _createForOfIteratorHelperLoose(countries), _step; !(_step = _iterator()).done;) {\n var country = _step.value;\n metadata.selectNumberingPlan(country);\n // \"Leading digits\" patterns are only defined for about 20% of all countries.\n // By definition, matching \"leading digits\" is a sufficient but not a necessary\n // condition for a phone number to belong to a country.\n // The point of \"leading digits\" check is that it's the fastest one to get a match.\n // https://gitlab.com/catamphetamine/libphonenumber-js/blob/master/METADATA.md#leading_digits\n // I'd suppose that \"leading digits\" patterns are mutually exclusive for different countries\n // because of the intended use of that feature.\n if (metadata.leadingDigits()) {\n if (nationalNumber && nationalNumber.search(metadata.leadingDigits()) === 0) {\n return country;\n }\n }\n // Else perform full validation with all of those\n // fixed-line/mobile/etc regular expressions.\n else if (getNumberType({\n phone: nationalNumber,\n country: country\n }, undefined, metadata.metadata)) {\n // When multiple countries share the same \"country calling code\",\n // type patterns aren't guaranteed to be unique among them.\n // For example, both `US` and `CA` have the same pattern for `toll_free` numbers.\n // https://gitlab.com/catamphetamine/libphonenumber-js/-/issues/103#note_1417147572\n //\n // That means that this `if` condition could be `true` for multiple countries from the list.\n // Currently, it just returns the first one, which is also the \"main\" country for the \"country calling code\".\n // In an example with `toll_free` numbers above, `\"US\"` would be returned even though\n // it could as well be `\"CA\"`.\n //\n // There was also a time when this attempted to be overly smart\n // and kept track of all such multiple matching countries\n // and then picked the one that matched the `defaultCountry`, if provided.\n // For example, with `toll_free` numbers above, and with `defaultCountry: \"CA\"`,\n // it would've returned `\"CA\"` instead of `\"US\"`.\n // Later it turned out that such \"overly smart\" behavior turned out to be just confusing,\n // so this \"overly smart\" country detection was reverted to returning the \"main\" country\n // for the \"country calling code\".\n // https://gitlab.com/catamphetamine/libphonenumber-js/-/issues/154\n //\n return country;\n //\n // The \"overly smart\" behavior code:\n //\n // if (defaultCountry) {\n // \tif (country === defaultCountry) {\n // \t\treturn country\n // \t} else {\n // \t\tmatchingCountries.push(country)\n // \t}\n // } else {\n // \treturn country\n // }\n }\n }\n\n // // Return the first (\"main\") one of the `matchingCountries`.\n // if (matchingCountries.length > 0) {\n // \treturn matchingCountries[0]\n // }\n}\n//# sourceMappingURL=getCountryByNationalNumber.js.map","import getCountryByNationalNumber from './getCountryByNationalNumber.js';\nvar USE_NON_GEOGRAPHIC_COUNTRY_CODE = false;\n\n/**\r\n * Returns the exact country that a given national (significant) number belongs to\r\n * in case of ambiguity, i.e. when multiple countries share the same \"country calling code\".\r\n * @param {string} [callingCode]\r\n * @param {string} [options.nationalNumber] — National (significant) number.\r\n * @param {Metadata} options.metadata — Metadata instance.\r\n * @returns {string?} Returns the most suitable country for this calling code and national (significant) number.\r\n */\nexport default function getCountryByCallingCode(callingCode, _ref) {\n var nationalNumber = _ref.nationalNumber,\n metadata = _ref.metadata;\n /* istanbul ignore if */\n if (USE_NON_GEOGRAPHIC_COUNTRY_CODE) {\n if (metadata.isNonGeographicCallingCode(callingCode)) {\n return '001';\n }\n }\n var possibleCountries = metadata.getCountryCodesForCallingCode(callingCode);\n if (!possibleCountries) {\n return;\n }\n // If there's just one country corresponding to the country code,\n // then just return it, without further phone number digits validation.\n if (possibleCountries.length === 1) {\n return possibleCountries[0];\n }\n return getCountryByNationalNumber(nationalNumber, possibleCountries, metadata.metadata);\n}\n//# sourceMappingURL=getCountryByCallingCode.js.map","import extractNationalNumberFromPossiblyIncompleteNumber from './extractNationalNumberFromPossiblyIncompleteNumber.js';\nimport matchesEntirely from './matchesEntirely.js';\nimport checkNumberLength from './checkNumberLength.js';\nimport getCountryByCallingCode from './getCountryByCallingCode.js';\n\n/**\r\n * Strips national prefix and carrier code from a complete phone number.\r\n * The difference from the non-\"FromCompleteNumber\" function is that\r\n * it won't extract national prefix if the resultant number is too short\r\n * to be a complete number for the selected phone numbering plan.\r\n * @param {string} number — Complete phone number digits.\r\n * @param {string?} country — Specific country to use instead of the one that is pre-selected in the metadata instance.\r\n * @param {Metadata} metadata — Metadata instance with a selected numbering plan.\r\n * @return {object} `{ nationalNumber: string, carrierCode: string? }`.\r\n */\nexport default function extractNationalNumber(number, country, metadata) {\n // Parsing national prefixes and carrier codes\n // is only required for local phone numbers\n // but some people don't understand that\n // and sometimes write international phone numbers\n // with national prefixes (or maybe even carrier codes).\n // http://ucken.blogspot.ru/2016/03/trunk-prefixes-in-skype4b.html\n // Google's original library forgives such mistakes\n // and so does this library, because it has been requested:\n // https://github.com/catamphetamine/libphonenumber-js/issues/127\n var _extractNationalNumbe = extractNationalNumberFromPossiblyIncompleteNumber(number, metadata),\n carrierCode = _extractNationalNumbe.carrierCode,\n nationalNumber = _extractNationalNumbe.nationalNumber;\n if (nationalNumber !== number) {\n if (!shouldHaveExtractedNationalPrefix(number, nationalNumber, metadata)) {\n // Don't strip the national prefix.\n return {\n nationalNumber: number\n };\n }\n // Check the national (significant) number length after extracting national prefix and carrier code.\n // Legacy generated metadata (before `1.0.18`) didn't support the \"possible lengths\" feature,\n // so this `if` will only be executed with newer metadata.\n if (metadata.numberingPlan.possibleLengths()) {\n // If an exact `country` is not specified, attempt to detect it from the assumed national number.\n if (!country) {\n country = getCountryByCallingCode(metadata.numberingPlan.callingCode(), {\n nationalNumber: nationalNumber,\n metadata: metadata\n });\n }\n\n // The number remaining after stripping the national prefix and carrier code\n // should be long enough to have a possible length for the country.\n // Otherwise, don't strip the national prefix and carrier code,\n // since the original number could be a valid number.\n // This check has been copy-pasted \"as is\" from Google's original library:\n // https://github.com/google/libphonenumber/blob/876268eb1ad6cdc1b7b5bef17fc5e43052702d57/java/libphonenumber/src/com/google/i18n/phonenumbers/PhoneNumberUtil.java#L3236-L3250\n // It doesn't check for the \"possibility\" of the original `number`.\n // I guess it's fine not checking that one. It works as is anyway.\n if (!isPossibleIncompleteNationalNumber(nationalNumber, country, metadata)) {\n // Don't strip the national prefix.\n return {\n nationalNumber: number\n };\n }\n }\n }\n return {\n nationalNumber: nationalNumber,\n carrierCode: carrierCode\n };\n}\n\n// In some countries, the same digit could be a national prefix\n// or a leading digit of a valid phone number.\n// For example, in Russia, national prefix is `8`,\n// and also `800 555 35 35` is a valid number\n// in which `8` is not a national prefix, but the first digit\n// of a national (significant) number.\n// Same's with Belarus:\n// `82004910060` is a valid national (significant) number,\n// but `2004910060` is not.\n// To support such cases (to prevent the code from always stripping\n// national prefix), a condition is imposed: a national prefix\n// is not extracted when the original number is \"viable\" and the\n// resultant number is not, a \"viable\" national number being the one\n// that matches `national_number_pattern`.\nfunction shouldHaveExtractedNationalPrefix(nationalNumberBefore, nationalNumberAfter, metadata) {\n // The equivalent in Google's code is:\n // https://github.com/google/libphonenumber/blob/e326fa1fc4283bb05eb35cb3c15c18f98a31af33/java/libphonenumber/src/com/google/i18n/phonenumbers/PhoneNumberUtil.java#L2969-L3004\n if (matchesEntirely(nationalNumberBefore, metadata.nationalNumberPattern()) && !matchesEntirely(nationalNumberAfter, metadata.nationalNumberPattern())) {\n return false;\n }\n // This \"is possible\" national number (length) check has been commented out\n // because it's superceded by the (effectively) same check done in the\n // `extractNationalNumber()` function after it calls `shouldHaveExtractedNationalPrefix()`.\n // In other words, why run the same check twice if it could only be run once.\n // // Check the national (significant) number length after extracting national prefix and carrier code.\n // // Fixes a minor \"weird behavior\" bug: https://gitlab.com/catamphetamine/libphonenumber-js/-/issues/57\n // // (Legacy generated metadata (before `1.0.18`) didn't support the \"possible lengths\" feature).\n // if (metadata.possibleLengths()) {\n // \tif (isPossibleIncompleteNationalNumber(nationalNumberBefore, metadata) &&\n // \t\t!isPossibleIncompleteNationalNumber(nationalNumberAfter, metadata)) {\n // \t\treturn false\n // \t}\n // }\n return true;\n}\n\n/**\r\n * Tells if a given incomplete national number is possible or not.\r\n * @param {string} nationalNumber\r\n * @param {string?} country — Specific country rather than the one that is pre-selected in the metadata instance.\r\n * @param {Metadata} metadata — Metadata instance with a selected numbering plan.\r\n * @returns {boolean}\r\n */\nfunction isPossibleIncompleteNationalNumber(nationalNumber, country, metadata) {\n switch (checkNumberLength(nationalNumber, country, metadata)) {\n case 'TOO_SHORT':\n case 'INVALID_LENGTH':\n // This library ignores \"local-only\" phone numbers (for simplicity).\n // See the readme for more info on what are \"local-only\" phone numbers.\n // case 'IS_POSSIBLE_LOCAL_ONLY':\n return false;\n default:\n return true;\n }\n}\n//# sourceMappingURL=extractNationalNumber.js.map","import Metadata from '../metadata.js';\nimport matchesEntirely from './matchesEntirely.js';\nimport extractNationalNumber from './extractNationalNumber.js';\nimport checkNumberLength from './checkNumberLength.js';\nimport getCountryCallingCode from '../getCountryCallingCode.js';\n\n/**\r\n * Sometimes some people incorrectly input international phone numbers\r\n * without the leading `+`. This function corrects such input.\r\n * @param {string} number — Phone number digits (only digits, no `+`).\r\n * @param {string} [country] — Exact country of the phone number.\r\n * @param {string} [defaultCountry]\r\n * @param {string} [defaultCallingCode]\r\n * @param {object} metadataJson\r\n * @return {object} `{ countryCallingCode: string?, number: string }`, where `countryCallingCode` is the calling code that was extracted from the input `number` string, and `number` is the originally passed `number` without the extracted calling code.\r\n */\nexport default function extractCountryCallingCodeFromInternationalNumberWithoutPlusSign(number, country, defaultCountry, defaultCallingCode, metadataJson) {\n // Validate arguments.\n // The `number` is known to be in a non-international form\n // because there's no leading \"+\" character.\n // Therefore, there must be either `country` or `defaultCountry` or `defaultCallingCode`.\n // Otherwise, there'd be no source for the calling code to search for in the `number`.\n if (!(country || defaultCountry || defaultCallingCode)) {\n // There's no source for the calling code to search for in the `number`.\n return {\n number: number\n };\n }\n var countryCallingCode = country || defaultCountry ? getCountryCallingCode(country || defaultCountry, metadataJson) : defaultCallingCode;\n if (number.indexOf(countryCallingCode) === 0) {\n var metadata = new Metadata(metadataJson);\n metadata.selectNumberingPlan(country || defaultCountry || defaultCallingCode);\n var possibleShorterNumber = number.slice(countryCallingCode.length);\n var _extractNationalNumbe = extractNationalNumber(possibleShorterNumber, undefined, metadata),\n possibleShorterNationalNumber = _extractNationalNumbe.nationalNumber;\n var _extractNationalNumbe2 = extractNationalNumber(number, undefined, metadata),\n nationalNumber = _extractNationalNumbe2.nationalNumber;\n\n // If the number was not valid before but is valid now,\n // or if it was too long before, we consider the number\n // with the country calling code stripped to be a better result\n // and keep that instead.\n // For example, in Germany (+49), `49` is a valid area code,\n // so if a number starts with `49`, it could be both a valid\n // national German number or an international number without\n // a leading `+`.\n if (!matchesEntirely(nationalNumber, metadata.nationalNumberPattern()) && matchesEntirely(possibleShorterNationalNumber, metadata.nationalNumberPattern()) || checkNumberLength(nationalNumber, undefined, metadata) === 'TOO_LONG') {\n return {\n countryCallingCode: countryCallingCode,\n number: possibleShorterNumber\n };\n }\n }\n return {\n number: number\n };\n}\n//# sourceMappingURL=extractCountryCallingCodeFromInternationalNumberWithoutPlusSign.js.map","import stripIddPrefix from './stripIddPrefix.js';\nimport extractCountryCallingCodeFromInternationalNumberWithoutPlusSign from './extractCountryCallingCodeFromInternationalNumberWithoutPlusSign.js';\nimport Metadata from '../metadata.js';\nimport { MAX_LENGTH_COUNTRY_CODE } from '../constants.js';\n\n/**\r\n * Attempts to extract a calling code from a phone number.\r\n * * If the phone number is found to be \"international\":\r\n * * It will attempt to identify the calling code part of it and whether that part is complete and valid.\r\n * * If the calling code part is complete and valid, it will return two properties:\r\n * that calling code part (without `+`) and the rest of the digits.\r\n * * Otherwise, i.e. if the calling code part is incomplete or invalid,\r\n * it will return an empty object.\r\n * * Otherwise, i.e. if the phone number is national, there's no callind code to extract\r\n * so it will just return the originally-passed `number` string as the only property.\r\n * @param {string} number — Phone number digits (possibly with a `+`).\r\n * @param {string} [country] — Country.\r\n * @param {string} [defaultCountry] — Default country.\r\n * @param {string} [defaultCallingCode] — Default calling code (some phone numbering plans are non-geographic).\r\n * @param {object} metadataJson\r\n * @return {object} `{ countryCallingCodeSource: string?, countryCallingCode: string?, number: string }`, where `countryCallingCodeSource` tells how the returned calling code was extracted (if it was extracted), `countryCallingCode` is the calling code that was extracted from the input `number` string, and `number` is the originally passed `number` without the extracted calling code (and without a `+`). If the calling code is present but incomplete or invalid, it will return an empty object.\r\n * @example\r\n * // Returns `{ countryCallingCode: \"1\", number: \"2133734253\" }`.\r\n * extractCountryCallingCode('2133734253', 'US', null, null, metadata)\r\n * extractCountryCallingCode('2133734253', null, 'US', null, metadata)\r\n * extractCountryCallingCode('2133734253', null, null, '1', metadata)\r\n * extractCountryCallingCode('+12133734253', null, null, null, metadata)\r\n * extractCountryCallingCode('+12133734253', null, 'RU', null, metadata)\r\n */\nexport default function extractCountryCallingCode(number, country, defaultCountry, defaultCallingCode, metadataJson) {\n if (!number) {\n return {};\n }\n var isNumberWithIddPrefix;\n\n // If this is not an international phone number,\n // then either extract an \"IDD\" prefix, or extract a\n // country calling code from a number by autocorrecting it\n // by prepending a leading `+` in cases when it starts\n // with the country calling code.\n // https://wikitravel.org/en/International_dialling_prefix\n // https://github.com/catamphetamine/libphonenumber-js/issues/376\n if (number[0] !== '+') {\n // Convert an \"out-of-country\" dialing phone number\n // to a proper international phone number.\n var numberWithoutIDD = stripIddPrefix(number, country || defaultCountry, defaultCallingCode, metadataJson);\n // If an IDD prefix was stripped then\n // convert the number to international one\n // for subsequent parsing.\n if (numberWithoutIDD && numberWithoutIDD !== number) {\n isNumberWithIddPrefix = true;\n number = '+' + numberWithoutIDD;\n } else {\n // Check to see if the number starts with the country calling code\n // for the default country. If so, we remove the country calling code,\n // and do some checks on the validity of the number before and after.\n // https://github.com/catamphetamine/libphonenumber-js/issues/376\n if (country || defaultCountry || defaultCallingCode) {\n var _extractCountryCallin = extractCountryCallingCodeFromInternationalNumberWithoutPlusSign(number, country, defaultCountry, defaultCallingCode, metadataJson),\n countryCallingCode = _extractCountryCallin.countryCallingCode,\n shorterNumber = _extractCountryCallin.number;\n if (countryCallingCode) {\n return {\n countryCallingCodeSource: 'FROM_NUMBER_WITHOUT_PLUS_SIGN',\n countryCallingCode: countryCallingCode,\n number: shorterNumber\n };\n }\n }\n return {\n // No need to set it to `UNSPECIFIED`. It can be just `undefined`.\n // countryCallingCodeSource: 'UNSPECIFIED',\n number: number\n };\n }\n }\n\n // `number` can only be international at this point.\n\n // Fast abortion: country codes do not begin with a '0'\n if (number[1] === '0') {\n return {};\n }\n var metadata = new Metadata(metadataJson);\n\n // The thing with country phone codes\n // is that they are orthogonal to each other\n // i.e. there's no such country phone code A\n // for which country phone code B exists\n // where B starts with A.\n // Therefore, while scanning digits,\n // if a valid country code is found,\n // that means that it is the country code.\n //\n var i = 2;\n while (i - 1 <= MAX_LENGTH_COUNTRY_CODE && i <= number.length) {\n var _countryCallingCode = number.slice(1, i);\n if (metadata.hasCallingCode(_countryCallingCode)) {\n metadata.selectNumberingPlan(_countryCallingCode);\n return {\n countryCallingCodeSource: isNumberWithIddPrefix ? 'FROM_NUMBER_WITH_IDD' : 'FROM_NUMBER_WITH_PLUS_SIGN',\n countryCallingCode: _countryCallingCode,\n number: number.slice(i)\n };\n }\n i++;\n }\n return {};\n}\n\n// The possible values for the returned `countryCallingCodeSource` are:\n//\n// Copy-pasted from:\n// https://github.com/google/libphonenumber/blob/master/resources/phonenumber.proto\n//\n// // The source from which the country_code is derived. This is not set in the\n// // general parsing method, but in the method that parses and keeps raw_input.\n// // New fields could be added upon request.\n// enum CountryCodeSource {\n// // Default value returned if this is not set, because the phone number was\n// // created using parse, not parseAndKeepRawInput. hasCountryCodeSource will\n// // return false if this is the case.\n// UNSPECIFIED = 0;\n//\n// // The country_code is derived based on a phone number with a leading \"+\",\n// // e.g. the French number \"+33 1 42 68 53 00\".\n// FROM_NUMBER_WITH_PLUS_SIGN = 1;\n//\n// // The country_code is derived based on a phone number with a leading IDD,\n// // e.g. the French number \"011 33 1 42 68 53 00\", as it is dialled from US.\n// FROM_NUMBER_WITH_IDD = 5;\n//\n// // The country_code is derived based on a phone number without a leading\n// // \"+\", e.g. the French number \"33 1 42 68 53 00\" when defaultCountry is\n// // supplied as France.\n// FROM_NUMBER_WITHOUT_PLUS_SIGN = 10;\n//\n// // The country_code is derived NOT based on the phone number itself, but\n// // from the defaultCountry parameter provided in the parsing function by the\n// // clients. This happens mostly for numbers written in the national format\n// // (without country code). For example, this would be set when parsing the\n// // French number \"01 42 68 53 00\", when defaultCountry is supplied as\n// // France.\n// FROM_DEFAULT_COUNTRY = 20;\n// }\n//# sourceMappingURL=extractCountryCallingCode.js.map","import { VALID_PUNCTUATION } from '../constants.js';\n\n// Removes brackets and replaces dashes with spaces.\n//\n// E.g. \"(999) 111-22-33\" -> \"999 111 22 33\"\n//\n// For some reason Google's metadata contains `<intlFormat/>`s with brackets and dashes.\n// Meanwhile, there's no single opinion about using punctuation in international phone numbers.\n//\n// For example, Google's `<intlFormat/>` for USA is `+1 213-373-4253`.\n// And here's a quote from WikiPedia's \"North American Numbering Plan\" page:\n// https://en.wikipedia.org/wiki/North_American_Numbering_Plan\n//\n// \"The country calling code for all countries participating in the NANP is 1.\n// In international format, an NANP number should be listed as +1 301 555 01 00,\n// where 301 is an area code (Maryland).\"\n//\n// I personally prefer the international format without any punctuation.\n// For example, brackets are remnants of the old age, meaning that the\n// phone number part in brackets (so called \"area code\") can be omitted\n// if dialing within the same \"area\".\n// And hyphens were clearly introduced for splitting local numbers into memorizable groups.\n// For example, remembering \"5553535\" is difficult but \"555-35-35\" is much simpler.\n// Imagine a man taking a bus from home to work and seeing an ad with a phone number.\n// He has a couple of seconds to memorize that number until it passes by.\n// If it were spaces instead of hyphens the man wouldn't necessarily get it,\n// but with hyphens instead of spaces the grouping is more explicit.\n// I personally think that hyphens introduce visual clutter,\n// so I prefer replacing them with spaces in international numbers.\n// In the modern age all output is done on displays where spaces are clearly distinguishable\n// so hyphens can be safely replaced with spaces without losing any legibility.\n//\nexport default function applyInternationalSeparatorStyle(formattedNumber) {\n return formattedNumber.replace(new RegExp(\"[\".concat(VALID_PUNCTUATION, \"]+\"), 'g'), ' ').trim();\n}\n//# sourceMappingURL=applyInternationalSeparatorStyle.js.map","import applyInternationalSeparatorStyle from './applyInternationalSeparatorStyle.js';\n\n// This was originally set to $1 but there are some countries for which the\n// first group is not used in the national pattern (e.g. Argentina) so the $1\n// group does not match correctly. Therefore, we use `\\d`, so that the first\n// group actually used in the pattern will be matched.\nexport var FIRST_GROUP_PATTERN = /(\\$\\d)/;\nexport default function formatNationalNumberUsingFormat(number, format, _ref) {\n var useInternationalFormat = _ref.useInternationalFormat,\n withNationalPrefix = _ref.withNationalPrefix,\n carrierCode = _ref.carrierCode,\n metadata = _ref.metadata;\n var formattedNumber = number.replace(new RegExp(format.pattern()), useInternationalFormat ? format.internationalFormat() :\n // This library doesn't use `domestic_carrier_code_formatting_rule`,\n // because that one is only used when formatting phone numbers\n // for dialing from a mobile phone, and this is not a dialing library.\n // carrierCode && format.domesticCarrierCodeFormattingRule()\n // \t// First, replace the $CC in the formatting rule with the desired carrier code.\n // \t// Then, replace the $FG in the formatting rule with the first group\n // \t// and the carrier code combined in the appropriate way.\n // \t? format.format().replace(FIRST_GROUP_PATTERN, format.domesticCarrierCodeFormattingRule().replace('$CC', carrierCode))\n // \t: (\n // \t\twithNationalPrefix && format.nationalPrefixFormattingRule()\n // \t\t\t? format.format().replace(FIRST_GROUP_PATTERN, format.nationalPrefixFormattingRule())\n // \t\t\t: format.format()\n // \t)\n withNationalPrefix && format.nationalPrefixFormattingRule() ? format.format().replace(FIRST_GROUP_PATTERN, format.nationalPrefixFormattingRule()) : format.format());\n if (useInternationalFormat) {\n return applyInternationalSeparatorStyle(formattedNumber);\n }\n return formattedNumber;\n}\n//# sourceMappingURL=formatNationalNumberUsingFormat.js.map","import Metadata from '../metadata.js';\n\n/**\r\n * Pattern that makes it easy to distinguish whether a region has a single\r\n * international dialing prefix or not. If a region has a single international\r\n * prefix (e.g. 011 in USA), it will be represented as a string that contains\r\n * a sequence of ASCII digits, and possibly a tilde, which signals waiting for\r\n * the tone. If there are multiple available international prefixes in a\r\n * region, they will be represented as a regex string that always contains one\r\n * or more characters that are not ASCII digits or a tilde.\r\n */\nvar SINGLE_IDD_PREFIX_REG_EXP = /^[\\d]+(?:[~\\u2053\\u223C\\uFF5E][\\d]+)?$/;\n\n// If the `country` supports IDD calling, it returns a preferred IDD prefix.\n// If the `country` doesn't support IDD calling, it returns `undefined`.\nexport default function getIddPrefix(country, callingCode, metadata) {\n var countryMetadata = new Metadata(metadata);\n countryMetadata.selectNumberingPlan(country || callingCode);\n if (countryMetadata.defaultIDDPrefix()) {\n return countryMetadata.defaultIDDPrefix();\n }\n if (SINGLE_IDD_PREFIX_REG_EXP.test(countryMetadata.IDDPrefix())) {\n return countryMetadata.IDDPrefix();\n }\n}\n//# sourceMappingURL=getIddPrefix.js.map","function _slicedToArray(r, e) { return _arrayWithHoles(r) || _iterableToArrayLimit(r, e) || _unsupportedIterableToArray(r, e) || _nonIterableRest(); }\nfunction _nonIterableRest() { throw new TypeError(\"Invalid attempt to destructure non-iterable instance.\\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.\"); }\nfunction _iterableToArrayLimit(r, l) { var t = null == r ? null : \"undefined\" != typeof Symbol && r[Symbol.iterator] || r[\"@@iterator\"]; if (null != t) { var e, n, i, u, a = [], f = !0, o = !1; try { if (i = (t = t.call(r)).next, 0 === l) { if (Object(t) !== t) return; f = !1; } else for (; !(f = (e = i.call(t)).done) && (a.push(e.value), a.length !== l); f = !0); } catch (r) { o = !0, n = r; } finally { try { if (!f && null != t[\"return\"] && (u = t[\"return\"](), Object(u) !== u)) return; } finally { if (o) throw n; } } return a; } }\nfunction _arrayWithHoles(r) { if (Array.isArray(r)) return r; }\nfunction _createForOfIteratorHelperLoose(r, e) { var t = \"undefined\" != typeof Symbol && r[Symbol.iterator] || r[\"@@iterator\"]; if (t) return (t = t.call(r)).next.bind(t); if (Array.isArray(r) || (t = _unsupportedIterableToArray(r)) || e && r && \"number\" == typeof r.length) { t && (r = t); var o = 0; return function () { return o >= r.length ? { done: !0 } : { done: !1, value: r[o++] }; }; } throw new TypeError(\"Invalid attempt to iterate non-iterable instance.\\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.\"); }\nfunction _unsupportedIterableToArray(r, a) { if (r) { if (\"string\" == typeof r) return _arrayLikeToArray(r, a); var t = {}.toString.call(r).slice(8, -1); return \"Object\" === t && r.constructor && (t = r.constructor.name), \"Map\" === t || \"Set\" === t ? Array.from(r) : \"Arguments\" === t || /^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(t) ? _arrayLikeToArray(r, a) : void 0; } }\nfunction _arrayLikeToArray(r, a) { (null == a || a > r.length) && (a = r.length); for (var e = 0, n = Array(a); e < a; e++) n[e] = r[e]; return n; }\nimport isViablePhoneNumber from './isViablePhoneNumber.js';\n\n// https://www.ietf.org/rfc/rfc3966.txt\n\n/**\r\n * @param {string} text - Phone URI (RFC 3966).\r\n * @return {object} `{ ?number, ?ext }`.\r\n */\nexport function parseRFC3966(text) {\n var number;\n var ext;\n\n // Replace \"tel:\" with \"tel=\" for parsing convenience.\n text = text.replace(/^tel:/, 'tel=');\n for (var _iterator = _createForOfIteratorHelperLoose(text.split(';')), _step; !(_step = _iterator()).done;) {\n var part = _step.value;\n var _part$split = part.split('='),\n _part$split2 = _slicedToArray(_part$split, 2),\n name = _part$split2[0],\n value = _part$split2[1];\n switch (name) {\n case 'tel':\n number = value;\n break;\n case 'ext':\n ext = value;\n break;\n case 'phone-context':\n // Only \"country contexts\" are supported.\n // \"Domain contexts\" are ignored.\n if (value[0] === '+') {\n number = value + number;\n }\n break;\n }\n }\n\n // If the phone number is not viable, then abort.\n if (!isViablePhoneNumber(number)) {\n return {};\n }\n var result = {\n number: number\n };\n if (ext) {\n result.ext = ext;\n }\n return result;\n}\n\n/**\r\n * @param {object} - `{ ?number, ?extension }`.\r\n * @return {string} Phone URI (RFC 3966).\r\n */\nexport function formatRFC3966(_ref) {\n var number = _ref.number,\n ext = _ref.ext;\n if (!number) {\n return '';\n }\n if (number[0] !== '+') {\n throw new Error(\"\\\"formatRFC3966()\\\" expects \\\"number\\\" to be in E.164 format.\");\n }\n return \"tel:\".concat(number).concat(ext ? ';ext=' + ext : '');\n}\n//# sourceMappingURL=RFC3966.js.map","// This is a port of Google Android `libphonenumber`'s\n// `phonenumberutil.js` of December 31th, 2018.\n//\n// https://github.com/googlei18n/libphonenumber/commits/master/javascript/i18n/phonenumbers/phonenumberutil.js\n\nimport matchesEntirely from './helpers/matchesEntirely.js';\nimport formatNationalNumberUsingFormat from './helpers/formatNationalNumberUsingFormat.js';\nimport Metadata, { getCountryCallingCode } from './metadata.js';\nimport getIddPrefix from './helpers/getIddPrefix.js';\nimport { formatRFC3966 } from './helpers/RFC3966.js';\nvar DEFAULT_OPTIONS = {\n formatExtension: function formatExtension(formattedNumber, extension, metadata) {\n return \"\".concat(formattedNumber).concat(metadata.ext()).concat(extension);\n }\n};\n\n/**\r\n * Formats a phone number.\r\n *\r\n * format(phoneNumberInstance, 'INTERNATIONAL', { ..., v2: true }, metadata)\r\n * format(phoneNumberInstance, 'NATIONAL', { ..., v2: true }, metadata)\r\n *\r\n * format({ phone: '8005553535', country: 'RU' }, 'INTERNATIONAL', { ... }, metadata)\r\n * format({ phone: '8005553535', country: 'RU' }, 'NATIONAL', undefined, metadata)\r\n *\r\n * @param {object|PhoneNumber} input — If `options.v2: true` flag is passed, the `input` should be a `PhoneNumber` instance. Otherwise, it should be an object of shape `{ phone: '...', country: '...' }`.\r\n * @param {string} format\r\n * @param {object} [options]\r\n * @param {object} metadataJson\r\n * @return {string}\r\n */\nexport default function formatNumber(input, format, options, metadataJson) {\n // Apply default options.\n if (options) {\n // Using ES6 \"rest spread\" syntax here didn't work with `babel`/`istanbul`\n // for some weird reason: this line of code would cause the code coverage\n // to show as not 100%. That's because `babel`/`istanbul`, for some weird reason,\n // apparently doesn't know how to properly exclude Babel polyfills from code coverage.\n //\n // options = { ...DEFAULT_OPTIONS, ...options }\n //\n options = merge({}, DEFAULT_OPTIONS, options);\n } else {\n options = DEFAULT_OPTIONS;\n }\n var metadata = new Metadata(metadataJson);\n\n // Normally, the `input` object is supposed to be a `PhoneNumber` class instance.\n // Also, according to the `PhoneNumber` class source code, `country` can't be \"001\".\n // It means that normally `input.country` or `input.countryCallingCode` is supposed\n // to be present because either of the two is always required to exist in a `PhoneNumber` instance.\n // This means that realistically, it's gonna step into either the first `if`\n // or the following `else if`, and normally it won't even reach the legacy-compatibility\n // `else return input.phone || ''` part.\n // So normally, it won't ever return an empty string here.\n if (input.country && input.country !== '001') {\n // Validate `input.country`.\n if (!metadata.hasCountry(input.country)) {\n throw new Error(\"Unknown country: \".concat(input.country));\n }\n metadata.selectNumberingPlan(input.country);\n } else if (input.countryCallingCode) {\n metadata.selectNumberingPlan(input.countryCallingCode);\n } else return input.phone || '';\n var countryCallingCode = metadata.countryCallingCode();\n var nationalNumber = options.v2 ? input.nationalNumber : input.phone;\n\n // This variable should have been declared inside `case`s\n // but Babel has a bug and it says \"duplicate variable declaration\".\n var number;\n switch (format) {\n case 'NATIONAL':\n // Normally, the `input` object is supposed to be a `PhoneNumber` class instance,\n // and a `PhoneNumber` class instance is always required to have a `nationalNumber`.\n // This means that the `if (!nationalNumber)` below is just for legacy-compatibility\n // and it normally can't really happen, so normally it won't ever return an empty string here.\n if (!nationalNumber) {\n return '';\n }\n number = formatNationalNumber(nationalNumber, input.carrierCode, 'NATIONAL', metadata, options);\n return addExtension(number, input.ext, metadata, options.formatExtension);\n case 'INTERNATIONAL':\n // Legacy argument support.\n // (`{ country: ..., phone: '' }`)\n if (!nationalNumber) {\n return \"+\".concat(countryCallingCode);\n }\n number = formatNationalNumber(nationalNumber, null, 'INTERNATIONAL', metadata, options);\n number = \"+\".concat(countryCallingCode, \" \").concat(number);\n return addExtension(number, input.ext, metadata, options.formatExtension);\n case 'E.164':\n // `E.164` doesn't define \"phone number extensions\".\n return \"+\".concat(countryCallingCode).concat(nationalNumber);\n case 'RFC3966':\n return formatRFC3966({\n number: \"+\".concat(countryCallingCode).concat(nationalNumber),\n ext: input.ext\n });\n\n // For reference, here's Google's IDD formatter:\n // https://github.com/google/libphonenumber/blob/32719cf74e68796788d1ca45abc85dcdc63ba5b9/java/libphonenumber/src/com/google/i18n/phonenumbers/PhoneNumberUtil.java#L1546\n // Not saying that this IDD formatter replicates it 1:1, but it seems to work.\n // Who would even need to format phone numbers in IDD format anyway?\n case 'IDD':\n // If the required `fromCountry` parameter is not passed, it will return `undefined`.\n if (!options.fromCountry) {\n return;\n // throw new Error('`fromCountry` option not passed for IDD-prefixed formatting.')\n }\n var formattedNumber = formatIDD(nationalNumber, input.carrierCode, countryCallingCode, options.fromCountry, metadata);\n // If the country of the phone number doesn't support IDD calling, it will return `undefined`.\n if (!formattedNumber) {\n return;\n }\n return addExtension(formattedNumber, input.ext, metadata, options.formatExtension);\n default:\n throw new Error(\"Unknown \\\"format\\\" argument passed to \\\"formatNumber()\\\": \\\"\".concat(format, \"\\\"\"));\n }\n}\nfunction formatNationalNumber(number, carrierCode, formatAs, metadata, options) {\n var format = chooseFormatForNumber(metadata.formats(), number);\n if (!format) {\n return number;\n }\n return formatNationalNumberUsingFormat(number, format, {\n useInternationalFormat: formatAs === 'INTERNATIONAL',\n withNationalPrefix: format.nationalPrefixIsOptionalWhenFormattingInNationalFormat() && options && options.nationalPrefix === false ? false : true,\n carrierCode: carrierCode,\n metadata: metadata\n });\n}\nexport function chooseFormatForNumber(availableFormats, nationalNumber) {\n // Using a `for ... of` loop here didn't work with `babel`/`istanbul`:\n // for some weird reason, it showed code coverage less than 100%.\n // That's because `babel`/`istanbul`, for some weird reason,\n // apparently doesn't know how to properly exclude Babel polyfills from code coverage.\n //\n // for (const format of availableFormats) { ... }\n //\n return pickFirstMatchingElement(availableFormats, function (format) {\n // Validate leading digits.\n // The test case for \"else path\" could be found by searching for\n // \"format.leadingDigitsPatterns().length === 0\".\n if (format.leadingDigitsPatterns().length > 0) {\n // The last leading_digits_pattern is used here, as it is the most detailed\n var lastLeadingDigitsPattern = format.leadingDigitsPatterns()[format.leadingDigitsPatterns().length - 1];\n // If leading digits don't match then move on to the next phone number format\n if (nationalNumber.search(lastLeadingDigitsPattern) !== 0) {\n return false;\n }\n }\n // Check that the national number matches the phone number format regular expression\n return matchesEntirely(nationalNumber, format.pattern());\n });\n}\nfunction addExtension(formattedNumber, ext, metadata, formatExtension) {\n return ext ? formatExtension(formattedNumber, ext, metadata) : formattedNumber;\n}\nfunction formatIDD(nationalNumber, carrierCode, countryCallingCode, fromCountry, metadata) {\n var fromCountryCallingCode = getCountryCallingCode(fromCountry, metadata.metadata);\n // When calling within the same country calling code.\n if (fromCountryCallingCode === countryCallingCode) {\n var formattedNumber = formatNationalNumber(nationalNumber, carrierCode, 'NATIONAL', metadata);\n // For NANPA regions, return the national format for these regions\n // but prefix it with the country calling code.\n if (countryCallingCode === '1') {\n return countryCallingCode + ' ' + formattedNumber;\n }\n // If regions share a country calling code, the country calling code need\n // not be dialled. This also applies when dialling within a region, so this\n // if clause covers both these cases. Technically this is the case for\n // dialling from La Reunion to other overseas departments of France (French\n // Guiana, Martinique, Guadeloupe), but not vice versa - so we don't cover\n // this edge case for now and for those cases return the version including\n // country calling code. Details here:\n // http://www.petitfute.com/voyage/225-info-pratiques-reunion\n //\n return formattedNumber;\n }\n var iddPrefix = getIddPrefix(fromCountry, undefined, metadata.metadata);\n if (iddPrefix) {\n return \"\".concat(iddPrefix, \" \").concat(countryCallingCode, \" \").concat(formatNationalNumber(nationalNumber, null, 'INTERNATIONAL', metadata));\n }\n}\nfunction merge() {\n var i = 1;\n for (var _len = arguments.length, objects = new Array(_len), _key = 0; _key < _len; _key++) {\n objects[_key] = arguments[_key];\n }\n while (i < objects.length) {\n if (objects[i]) {\n for (var key in objects[i]) {\n objects[0][key] = objects[i][key];\n }\n }\n i++;\n }\n return objects[0];\n}\nfunction pickFirstMatchingElement(elements, testFunction) {\n var i = 0;\n while (i < elements.length) {\n if (testFunction(elements[i])) {\n return elements[i];\n }\n i++;\n }\n}\n//# sourceMappingURL=format.js.map","function _typeof(o) { \"@babel/helpers - typeof\"; return _typeof = \"function\" == typeof Symbol && \"symbol\" == typeof Symbol.iterator ? function (o) { return typeof o; } : function (o) { return o && \"function\" == typeof Symbol && o.constructor === Symbol && o !== Symbol.prototype ? \"symbol\" : typeof o; }, _typeof(o); }\nfunction ownKeys(e, r) { var t = Object.keys(e); if (Object.getOwnPropertySymbols) { var o = Object.getOwnPropertySymbols(e); r && (o = o.filter(function (r) { return Object.getOwnPropertyDescriptor(e, r).enumerable; })), t.push.apply(t, o); } return t; }\nfunction _objectSpread(e) { for (var r = 1; r < arguments.length; r++) { var t = null != arguments[r] ? arguments[r] : {}; r % 2 ? ownKeys(Object(t), !0).forEach(function (r) { _defineProperty(e, r, t[r]); }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(e, Object.getOwnPropertyDescriptors(t)) : ownKeys(Object(t)).forEach(function (r) { Object.defineProperty(e, r, Object.getOwnPropertyDescriptor(t, r)); }); } return e; }\nfunction _defineProperty(e, r, t) { return (r = _toPropertyKey(r)) in e ? Object.defineProperty(e, r, { value: t, enumerable: !0, configurable: !0, writable: !0 }) : e[r] = t, e; }\nfunction _classCallCheck(a, n) { if (!(a instanceof n)) throw new TypeError(\"Cannot call a class as a function\"); }\nfunction _defineProperties(e, r) { for (var t = 0; t < r.length; t++) { var o = r[t]; o.enumerable = o.enumerable || !1, o.configurable = !0, \"value\" in o && (o.writable = !0), Object.defineProperty(e, _toPropertyKey(o.key), o); } }\nfunction _createClass(e, r, t) { return r && _defineProperties(e.prototype, r), t && _defineProperties(e, t), Object.defineProperty(e, \"prototype\", { writable: !1 }), e; }\nfunction _toPropertyKey(t) { var i = _toPrimitive(t, \"string\"); return \"symbol\" == _typeof(i) ? i : i + \"\"; }\nfunction _toPrimitive(t, r) { if (\"object\" != _typeof(t) || !t) return t; var e = t[Symbol.toPrimitive]; if (void 0 !== e) { var i = e.call(t, r || \"default\"); if (\"object\" != _typeof(i)) return i; throw new TypeError(\"@@toPrimitive must return a primitive value.\"); } return (\"string\" === r ? String : Number)(t); }\nimport Metadata, { validateMetadata } from './metadata.js';\nimport isPossibleNumber from './isPossible.js';\nimport isValidNumber from './isValid.js';\nimport getNumberType from './helpers/getNumberType.js';\nimport getCountryAndCallingCodeFromOneOfThem from './helpers/getCountryAndCallingCodeFromOneOfThem.js';\nimport getPossibleCountriesForNumber from './helpers/getPossibleCountriesForNumber.js';\nimport extractCountryCallingCode from './helpers/extractCountryCallingCode.js';\nimport isObject from './helpers/isObject.js';\nimport formatNumber from './format.js';\nvar USE_NON_GEOGRAPHIC_COUNTRY_CODE = false;\nvar PhoneNumber = /*#__PURE__*/function () {\n /**\r\n * @param {string} countryOrCountryCallingCode\r\n * @param {string} nationalNumber\r\n * @param {object} metadata — Metadata JSON\r\n * @return {PhoneNumber}\r\n */\n function PhoneNumber(countryOrCountryCallingCode, nationalNumber, metadata) {\n _classCallCheck(this, PhoneNumber);\n // Validate `countryOrCountryCallingCode` argument.\n if (!countryOrCountryCallingCode) {\n throw new TypeError('First argument is required');\n }\n if (typeof countryOrCountryCallingCode !== 'string') {\n throw new TypeError('First argument must be a string');\n }\n\n // In case of public API use: `constructor(number, metadata)`.\n // Transform the arguments from `constructor(number, metadata)` to\n // `constructor(countryOrCountryCallingCode, nationalNumber, metadata)`.\n if (countryOrCountryCallingCode[0] === '+' && !nationalNumber) {\n throw new TypeError('`metadata` argument not passed');\n }\n if (isObject(nationalNumber) && isObject(nationalNumber.countries)) {\n metadata = nationalNumber;\n var e164Number = countryOrCountryCallingCode;\n if (!E164_NUMBER_REGEXP.test(e164Number)) {\n throw new Error('Invalid `number` argument passed: must consist of a \"+\" followed by digits');\n }\n var _extractCountryCallin = extractCountryCallingCode(e164Number, undefined, undefined, undefined, metadata),\n _countryCallingCode = _extractCountryCallin.countryCallingCode,\n number = _extractCountryCallin.number;\n nationalNumber = number;\n countryOrCountryCallingCode = _countryCallingCode;\n if (!nationalNumber) {\n throw new Error('Invalid `number` argument passed: too short');\n }\n }\n\n // Validate `nationalNumber` argument.\n if (!nationalNumber) {\n throw new TypeError('`nationalNumber` argument is required');\n }\n if (typeof nationalNumber !== 'string') {\n throw new TypeError('`nationalNumber` argument must be a string');\n }\n\n // Validate `metadata` argument.\n validateMetadata(metadata);\n\n // Initialize properties.\n var _getCountryAndCalling = getCountryAndCallingCodeFromOneOfThem(countryOrCountryCallingCode, metadata),\n country = _getCountryAndCalling.country,\n countryCallingCode = _getCountryAndCalling.callingCode;\n this.country = country;\n this.countryCallingCode = countryCallingCode;\n this.nationalNumber = nationalNumber;\n this.number = '+' + this.countryCallingCode + this.nationalNumber;\n // Exclude `metadata` property output from `PhoneNumber.toString()`\n // so that it doesn't clutter the console output of Node.js.\n // Previously, when Node.js did `console.log(new PhoneNumber(...))`,\n // it would output the whole internal structure of the `metadata` object.\n this.getMetadata = function () {\n return metadata;\n };\n }\n return _createClass(PhoneNumber, [{\n key: \"setExt\",\n value: function setExt(ext) {\n this.ext = ext;\n }\n }, {\n key: \"getPossibleCountries\",\n value: function getPossibleCountries() {\n if (this.country) {\n return [this.country];\n }\n return getPossibleCountriesForNumber(this.countryCallingCode, this.nationalNumber, this.getMetadata());\n }\n }, {\n key: \"isPossible\",\n value: function isPossible() {\n return isPossibleNumber(this, {\n v2: true\n }, this.getMetadata());\n }\n }, {\n key: \"isValid\",\n value: function isValid() {\n return isValidNumber(this, {\n v2: true\n }, this.getMetadata());\n }\n }, {\n key: \"isNonGeographic\",\n value: function isNonGeographic() {\n var metadata = new Metadata(this.getMetadata());\n return metadata.isNonGeographicCallingCode(this.countryCallingCode);\n }\n }, {\n key: \"isEqual\",\n value: function isEqual(phoneNumber) {\n return this.number === phoneNumber.number && this.ext === phoneNumber.ext;\n }\n\n // `validateLength()` method was originally meant to be an equivalent for `validatePhoneNumberLength()`.\n //\n // Later, it became apparent that it's not really a true equivalent.\n // The reason is that a `PhoneNumber` instance is not created\n // when the phone number string is too short for it to be considered a valid phone number:\n // * When there must be at least 2 national (significant) number digits: `\"1\"`.\n // * When the country calling code part of an international number is incomplete: `\"+12\"`.\n //\n // So leaving this `validateLength()` method here would suggest a hidden anti-pattern\n // of using it instead of `validatePhoneNumberLength()` while ignoring\n // the \"too short to be even possible\" case from phone number length validation.\n // And ignoring that case wouldn't make any sense in a real-world application\n // because it would still be a valid case that should be handled.\n //\n // Because of that, this method was eventually commented out in order to not introduce\n // that kind of an anti-pattern.\n //\n // validateLength() {\n // \tconst result = checkNumberLength(\n // \t\tthis.nationalNumber,\n // \t\tundefined,\n // \t\tthis.getMetadata()\n // \t)\n // \tif (result !== 'IS_POSSIBLE') {\n // \t\treturn result\n // \t}\n // }\n }, {\n key: \"getType\",\n value: function getType() {\n return getNumberType(this, {\n v2: true\n }, this.getMetadata());\n }\n }, {\n key: \"format\",\n value: function format(_format, options) {\n return formatNumber(this, _format, options ? _objectSpread(_objectSpread({}, options), {}, {\n v2: true\n }) : {\n v2: true\n }, this.getMetadata());\n }\n }, {\n key: \"formatNational\",\n value: function formatNational(options) {\n return this.format('NATIONAL', options);\n }\n }, {\n key: \"formatInternational\",\n value: function formatInternational(options) {\n return this.format('INTERNATIONAL', options);\n }\n }, {\n key: \"getURI\",\n value: function getURI(options) {\n return this.format('RFC3966', options);\n }\n }]);\n}();\nexport { PhoneNumber as default };\nvar E164_NUMBER_REGEXP = /^\\+\\d+$/;\n//# sourceMappingURL=PhoneNumber.js.map","// When phone numbers are written in `RFC3966` format — `\"tel:+12133734253\"` —\n// they can have their \"calling code\" part written separately in a `phone-context` parameter.\n// Example: `\"tel:12133734253;phone-context=+1\"`.\n// This function parses the full phone number from the local number and the `phone-context`\n// when the `phone-context` contains a `+` sign.\n\nimport { VALID_DIGITS\n// PLUS_CHARS\n} from '../constants.js';\nexport var PLUS_SIGN = '+';\nvar RFC3966_VISUAL_SEPARATOR_ = '[\\\\-\\\\.\\\\(\\\\)]?';\nvar RFC3966_PHONE_DIGIT_ = '(' + '[' + VALID_DIGITS + ']' + '|' + RFC3966_VISUAL_SEPARATOR_ + ')';\nvar RFC3966_GLOBAL_NUMBER_DIGITS_ = '^' + '\\\\' + PLUS_SIGN + RFC3966_PHONE_DIGIT_ + '*' + '[' + VALID_DIGITS + ']' + RFC3966_PHONE_DIGIT_ + '*' + '$';\n\n/**\r\n * Regular expression of valid global-number-digits for the phone-context\r\n * parameter, following the syntax defined in RFC3966.\r\n */\nvar RFC3966_GLOBAL_NUMBER_DIGITS_PATTERN_ = new RegExp(RFC3966_GLOBAL_NUMBER_DIGITS_, 'g');\n\n// In this port of Google's library, we don't accept alpha characters in phone numbers.\n// const ALPHANUM_ = VALID_ALPHA_ + VALID_DIGITS\nvar ALPHANUM_ = VALID_DIGITS;\nvar RFC3966_DOMAINLABEL_ = '[' + ALPHANUM_ + ']+((\\\\-)*[' + ALPHANUM_ + '])*';\nvar VALID_ALPHA_ = 'a-zA-Z';\nvar RFC3966_TOPLABEL_ = '[' + VALID_ALPHA_ + ']+((\\\\-)*[' + ALPHANUM_ + '])*';\nvar RFC3966_DOMAINNAME_ = '^(' + RFC3966_DOMAINLABEL_ + '\\\\.)*' + RFC3966_TOPLABEL_ + '\\\\.?$';\n\n/**\r\n * Regular expression of valid domainname for the phone-context parameter,\r\n * following the syntax defined in RFC3966.\r\n */\nvar RFC3966_DOMAINNAME_PATTERN_ = new RegExp(RFC3966_DOMAINNAME_, 'g');\nexport var RFC3966_PREFIX_ = 'tel:';\nexport var RFC3966_PHONE_CONTEXT_ = ';phone-context=';\nexport var RFC3966_ISDN_SUBADDRESS_ = ';isub=';\n\n/**\r\n * Extracts the value of the phone-context parameter of `numberToExtractFrom`,\r\n * following the syntax defined in RFC3966.\r\n *\r\n * @param {string} numberToExtractFrom\r\n * @return {string|null} the extracted string (possibly empty), or `null` if no phone-context parameter is found.\r\n */\nexport default function extractPhoneContext(numberToExtractFrom) {\n var indexOfPhoneContext = numberToExtractFrom.indexOf(RFC3966_PHONE_CONTEXT_);\n // If no phone-context parameter is present\n if (indexOfPhoneContext < 0) {\n return null;\n }\n var phoneContextStart = indexOfPhoneContext + RFC3966_PHONE_CONTEXT_.length;\n // If phone-context parameter is empty\n if (phoneContextStart >= numberToExtractFrom.length) {\n return '';\n }\n var phoneContextEnd = numberToExtractFrom.indexOf(';', phoneContextStart);\n // If phone-context is not the last parameter\n if (phoneContextEnd >= 0) {\n return numberToExtractFrom.substring(phoneContextStart, phoneContextEnd);\n } else {\n return numberToExtractFrom.substring(phoneContextStart);\n }\n}\n\n/**\r\n * Returns whether the value of phoneContext follows the syntax defined in RFC3966.\r\n *\r\n * @param {string|null} phoneContext\r\n * @return {boolean}\r\n */\nexport function isPhoneContextValid(phoneContext) {\n if (phoneContext === null) {\n return true;\n }\n if (phoneContext.length === 0) {\n return false;\n }\n\n // Does phone-context value match pattern of global-number-digits or domainname.\n return RFC3966_GLOBAL_NUMBER_DIGITS_PATTERN_.test(phoneContext) || RFC3966_DOMAINNAME_PATTERN_.test(phoneContext);\n}\n//# sourceMappingURL=extractPhoneContext.js.map","import extractPhoneContext, { isPhoneContextValid, PLUS_SIGN, RFC3966_PREFIX_, RFC3966_PHONE_CONTEXT_, RFC3966_ISDN_SUBADDRESS_ } from './extractPhoneContext.js';\nimport ParseError from '../ParseError.js';\n\n/**\r\n * @param {string} numberToParse\r\n * @param {string} nationalNumber\r\n * @return {}\r\n */\nexport default function extractFormattedPhoneNumberFromPossibleRfc3966NumberUri(numberToParse, _ref) {\n var extractFormattedPhoneNumber = _ref.extractFormattedPhoneNumber;\n var phoneContext = extractPhoneContext(numberToParse);\n if (!isPhoneContextValid(phoneContext)) {\n throw new ParseError('NOT_A_NUMBER');\n }\n var phoneNumberString;\n if (phoneContext === null) {\n // Extract a possible number from the string passed in.\n // (this strips leading characters that could not be the start of a phone number)\n phoneNumberString = extractFormattedPhoneNumber(numberToParse) || '';\n } else {\n phoneNumberString = '';\n\n // If the phone context contains a phone number prefix, we need to capture\n // it, whereas domains will be ignored.\n if (phoneContext.charAt(0) === PLUS_SIGN) {\n phoneNumberString += phoneContext;\n }\n\n // Now append everything between the \"tel:\" prefix and the phone-context.\n // This should include the national number, an optional extension or\n // isdn-subaddress component. Note we also handle the case when \"tel:\" is\n // missing, as we have seen in some of the phone number inputs.\n // In that case, we append everything from the beginning.\n var indexOfRfc3966Prefix = numberToParse.indexOf(RFC3966_PREFIX_);\n var indexOfNationalNumber;\n // RFC 3966 \"tel:\" prefix is preset at this stage because\n // `isPhoneContextValid()` requires it to be present.\n /* istanbul ignore else */\n if (indexOfRfc3966Prefix >= 0) {\n indexOfNationalNumber = indexOfRfc3966Prefix + RFC3966_PREFIX_.length;\n } else {\n indexOfNationalNumber = 0;\n }\n var indexOfPhoneContext = numberToParse.indexOf(RFC3966_PHONE_CONTEXT_);\n phoneNumberString += numberToParse.substring(indexOfNationalNumber, indexOfPhoneContext);\n }\n\n // Delete the isdn-subaddress and everything after it if it is present.\n // Note extension won't appear at the same time with isdn-subaddress\n // according to paragraph 5.3 of the RFC3966 spec.\n var indexOfIsdn = phoneNumberString.indexOf(RFC3966_ISDN_SUBADDRESS_);\n if (indexOfIsdn > 0) {\n phoneNumberString = phoneNumberString.substring(0, indexOfIsdn);\n }\n // If both phone context and isdn-subaddress are absent but other\n // parameters are present, the parameters are left in nationalNumber.\n // This is because we are concerned about deleting content from a potential\n // number string when there is no strong evidence that the number is\n // actually written in RFC3966.\n\n if (phoneNumberString !== '') {\n return phoneNumberString;\n }\n}\n//# sourceMappingURL=extractFormattedPhoneNumberFromPossibleRfc3966NumberUri.js.map","// This is a port of Google Android `libphonenumber`'s\n// `phonenumberutil.js` of December 31th, 2018.\n//\n// https://github.com/googlei18n/libphonenumber/commits/master/javascript/i18n/phonenumbers/phonenumberutil.js\n\nimport { VALID_DIGITS, PLUS_CHARS, MIN_LENGTH_FOR_NSN, MAX_LENGTH_FOR_NSN } from './constants.js';\nimport ParseError from './ParseError.js';\nimport Metadata from './metadata.js';\nimport isViablePhoneNumber, { isViablePhoneNumberStart } from './helpers/isViablePhoneNumber.js';\nimport extractExtension from './helpers/extension/extractExtension.js';\nimport parseIncompletePhoneNumber from './parseIncompletePhoneNumber.js';\nimport getCountryCallingCode from './getCountryCallingCode.js';\nimport { isPossibleNumber } from './isPossible.js';\n// import { parseRFC3966 } from './helpers/RFC3966.js'\nimport PhoneNumber from './PhoneNumber.js';\nimport matchesEntirely from './helpers/matchesEntirely.js';\nimport extractCountryCallingCode from './helpers/extractCountryCallingCode.js';\nimport extractNationalNumber from './helpers/extractNationalNumber.js';\n// import stripIddPrefix from './helpers/stripIddPrefix.js'\nimport getCountryByCallingCode from './helpers/getCountryByCallingCode.js';\nimport extractFormattedPhoneNumberFromPossibleRfc3966NumberUri from './helpers/extractFormattedPhoneNumberFromPossibleRfc3966NumberUri.js';\n\n// We don't allow input strings for parsing to be longer than 250 chars.\n// This prevents malicious input from consuming CPU.\nvar MAX_INPUT_STRING_LENGTH = 250;\n\n// This consists of the plus symbol, digits, and arabic-indic digits.\nvar PHONE_NUMBER_START_PATTERN = new RegExp('[' + PLUS_CHARS + VALID_DIGITS + ']');\n\n// Regular expression of trailing characters that we want to remove.\n// A trailing `#` is sometimes used when writing phone numbers with extensions in US.\n// Example: \"+1 (645) 123 1234-910#\" number has extension \"910\".\nvar AFTER_PHONE_NUMBER_END_PATTERN = new RegExp('[^' + VALID_DIGITS + '#' + ']+$');\nvar USE_NON_GEOGRAPHIC_COUNTRY_CODE = false;\n\n// Examples:\n//\n// ```js\n// parse('8 (800) 555-35-35', 'RU')\n// parse('8 (800) 555-35-35', 'RU', metadata)\n// parse('8 (800) 555-35-35', { country: { default: 'RU' } })\n// parse('8 (800) 555-35-35', { country: { default: 'RU' } }, metadata)\n// parse('+7 800 555 35 35')\n// parse('+7 800 555 35 35', metadata)\n// ```\n//\n\n/**\r\n * Parses a phone number.\r\n *\r\n * parse('123456789', { defaultCountry: 'RU', v2: true }, metadata)\r\n * parse('123456789', { defaultCountry: 'RU' }, metadata)\r\n * parse('123456789', undefined, metadata)\r\n *\r\n * @param {string} input\r\n * @param {object} [options]\r\n * @param {object} metadataJson\r\n * @return {object|PhoneNumber?} If `options.v2: true` flag is passed, it returns a `PhoneNumber?` instance. Otherwise, returns an object of shape `{ phone: '...', country: '...' }` (or just `{}` if no phone number was parsed).\r\n */\nexport default function parse(text, options, metadataJson) {\n // If assigning the `{}` default value is moved to the arguments above,\n // code coverage would decrease for some weird reason.\n options = options || {};\n var metadata = new Metadata(metadataJson);\n\n // Validate `defaultCountry`.\n if (options.defaultCountry && !metadata.hasCountry(options.defaultCountry)) {\n if (options.v2) {\n throw new ParseError('INVALID_COUNTRY');\n }\n throw new Error(\"Unknown country: \".concat(options.defaultCountry));\n }\n\n // Parse the phone number.\n var _parseInput = parseInput(text, options.v2, options.extract),\n formattedPhoneNumber = _parseInput.number,\n ext = _parseInput.ext,\n error = _parseInput.error;\n\n // If the phone number is not viable then return nothing.\n if (!formattedPhoneNumber) {\n if (options.v2) {\n if (error === 'TOO_SHORT') {\n throw new ParseError('TOO_SHORT');\n }\n throw new ParseError('NOT_A_NUMBER');\n }\n return {};\n }\n var _parsePhoneNumber = parsePhoneNumber(formattedPhoneNumber, options.defaultCountry, options.defaultCallingCode,\n // If `country` is returned, its numbering plan will also be selected in `metadata`.\n // Otherwise, if `countryCallingCode` is returned, its numbering plan will also be selected in `metadata`.\n // Otherwise, if neither `country` nor `countryCallingCode` are returned, no numbering plan will be selected in `metadata`.\n metadata),\n country = _parsePhoneNumber.country,\n nationalNumber = _parsePhoneNumber.nationalNumber,\n countryCallingCode = _parsePhoneNumber.countryCallingCode,\n countryCallingCodeSource = _parsePhoneNumber.countryCallingCodeSource,\n carrierCode = _parsePhoneNumber.carrierCode;\n if (!metadata.hasSelectedNumberingPlan()) {\n if (options.v2) {\n throw new ParseError('INVALID_COUNTRY');\n }\n return {};\n }\n\n // Validate national (significant) number length.\n if (!nationalNumber || nationalNumber.length < MIN_LENGTH_FOR_NSN) {\n // Won't throw here because the regexp already demands length > 1.\n /* istanbul ignore if */\n if (options.v2) {\n throw new ParseError('TOO_SHORT');\n }\n // Google's demo just throws an error in this case.\n return {};\n }\n\n // Validate national (significant) number length.\n //\n // A sidenote:\n //\n // They say that sometimes national (significant) numbers\n // can be longer than `MAX_LENGTH_FOR_NSN` (e.g. in Germany).\n // https://github.com/googlei18n/libphonenumber/blob/7e1748645552da39c4e1ba731e47969d97bdb539/resources/phonenumber.proto#L36\n // Such numbers will just be discarded.\n //\n if (nationalNumber.length > MAX_LENGTH_FOR_NSN) {\n if (options.v2) {\n throw new ParseError('TOO_LONG');\n }\n // Google's demo just throws an error in this case.\n return {};\n }\n if (options.v2) {\n var phoneNumber = new PhoneNumber(countryCallingCode, nationalNumber, metadata.metadata);\n if (country) {\n phoneNumber.country = country;\n }\n if (carrierCode) {\n phoneNumber.carrierCode = carrierCode;\n }\n if (ext) {\n phoneNumber.ext = ext;\n }\n phoneNumber.__countryCallingCodeSource = countryCallingCodeSource;\n return phoneNumber;\n }\n\n // Check if national phone number pattern matches the number.\n // National number pattern is different for each country,\n // even for those ones which are part of the \"NANPA\" group.\n var valid = (options.extended ? metadata.hasSelectedNumberingPlan() : country) ? matchesEntirely(nationalNumber, metadata.nationalNumberPattern()) : false;\n if (!options.extended) {\n return valid ? result(country, nationalNumber, ext) : {};\n }\n\n // isInternational: countryCallingCode !== undefined\n\n return {\n country: country,\n countryCallingCode: countryCallingCode,\n carrierCode: carrierCode,\n valid: valid,\n possible: valid ? true : options.extended === true && metadata.possibleLengths() && isPossibleNumber(nationalNumber, metadata) ? true : false,\n phone: nationalNumber,\n ext: ext\n };\n}\n\n/**\r\n * Extracts a formatted phone number from text.\r\n * Doesn't guarantee that the extracted phone number\r\n * is a valid phone number (for example, doesn't validate its length).\r\n * @param {string} text\r\n * @param {boolean} [extract] — If `false`, then will parse the entire `text` as a phone number.\r\n * @param {boolean} [throwOnError] — By default, it won't throw if the text is too long.\r\n * @return {string}\r\n * @example\r\n * // Returns \"(213) 373-4253\".\r\n * extractFormattedPhoneNumber(\"Call (213) 373-4253 for assistance.\")\r\n */\nfunction _extractFormattedPhoneNumber(text, extract, throwOnError) {\n if (!text) {\n return;\n }\n if (text.length > MAX_INPUT_STRING_LENGTH) {\n if (throwOnError) {\n throw new ParseError('TOO_LONG');\n }\n return;\n }\n if (extract === false) {\n return text;\n }\n // Attempt to extract a possible number from the string passed in\n var startsAt = text.search(PHONE_NUMBER_START_PATTERN);\n if (startsAt < 0) {\n return;\n }\n return text\n // Trim everything to the left of the phone number\n .slice(startsAt)\n // Remove trailing non-numerical characters\n .replace(AFTER_PHONE_NUMBER_END_PATTERN, '');\n}\n\n/**\r\n * @param {string} text - Input.\r\n * @param {boolean} v2 - Legacy API functions don't pass `v2: true` flag.\r\n * @param {boolean} [extract] - Whether to extract a phone number from `text`, or attempt to parse the entire text as a phone number.\r\n * @return {object} `{ ?number, ?ext }`.\r\n */\nfunction parseInput(text, v2, extract) {\n // // Parse RFC 3966 phone number URI.\n // if (text && text.indexOf('tel:') === 0) {\n // \treturn parseRFC3966(text)\n // }\n // let number = extractFormattedPhoneNumber(text, extract, v2)\n var number = extractFormattedPhoneNumberFromPossibleRfc3966NumberUri(text, {\n extractFormattedPhoneNumber: function extractFormattedPhoneNumber(text) {\n return _extractFormattedPhoneNumber(text, extract, v2);\n }\n });\n // If the phone number is not viable, then abort.\n if (!number) {\n return {};\n }\n if (!isViablePhoneNumber(number)) {\n if (isViablePhoneNumberStart(number)) {\n return {\n error: 'TOO_SHORT'\n };\n }\n return {};\n }\n // Attempt to parse extension first, since it doesn't require region-specific\n // data and we want to have the non-normalised number here.\n var withExtensionStripped = extractExtension(number);\n if (withExtensionStripped.ext) {\n return withExtensionStripped;\n }\n return {\n number: number\n };\n}\n\n/**\r\n * Creates `parse()` result object.\r\n */\nfunction result(country, nationalNumber, ext) {\n var result = {\n country: country,\n phone: nationalNumber\n };\n if (ext) {\n result.ext = ext;\n }\n return result;\n}\n\n/**\r\n * Parses a viable phone number.\r\n * @param {string} formattedPhoneNumber — Example: \"(213) 373-4253\".\r\n * @param {string} [defaultCountry]\r\n * @param {string} [defaultCallingCode]\r\n * @param {Metadata} metadata — Metadata instance with no pre-selected numbering plan. If `country` is returned, its numbering plan will also be selected in `metadata`. Otherwise, if `countryCallingCode` is returned, its numbering plan will also be selected in `metadata`. Otherwise, if neither `country` nor `countryCallingCode` are returned, no numbering plan will be selected in `metadata`.\r\n * @return {object} Returns `{ country: string?, countryCallingCode: string?, nationalNumber: string? }`.\r\n */\nfunction parsePhoneNumber(formattedPhoneNumber, defaultCountry, defaultCallingCode, metadata) {\n // Attempt to extract a calling code from a phone number.\n // * If the phone number is found to be \"international\":\n // * It will attempt to identify the calling code part of it and whether that part is complete and valid.\n // * If the calling code part is complete and valid, it will return two properties:\n // that calling code part (without `+`) and the rest of the digits.\n // * Otherwise, i.e. if the calling code part is incomplete or invalid,\n // it will return an empty object.\n // * Otherwise, i.e. if the phone number is national, there's no callind code to extract\n // so it will just return the originally-passed `number` string as the only property.\n var _extractCountryCallin = extractCountryCallingCode(parseIncompletePhoneNumber(formattedPhoneNumber), undefined,\n // `defaultCountry` and `defaultCallingCode` are only used to detect\n // if it's an \"international\" phone number or not. They won't be used\n // to derive the resulting `countryCallingCode` from them, or anything like that.\n defaultCountry, defaultCallingCode, metadata.metadata),\n countryCallingCodeSource = _extractCountryCallin.countryCallingCodeSource,\n countryCallingCode = _extractCountryCallin.countryCallingCode,\n number = _extractCountryCallin.number;\n\n // The exact country of the phone number\n var country;\n\n // If `formattedPhoneNumber` is passed in \"international\" format,\n // choose a country by `countryCallingCode`.\n if (countryCallingCode) {\n metadata.selectNumberingPlan(countryCallingCode);\n }\n // Else, if `formattedPhoneNumber` is passed in \"national\" format,\n // then `number` is defined and `countryCallingCode` is `undefined`.\n else if (number && (defaultCountry || defaultCallingCode)) {\n if (defaultCountry) {\n country = defaultCountry;\n metadata.selectNumberingPlan(defaultCountry);\n countryCallingCode = metadata.numberingPlan.callingCode();\n } else {\n metadata.selectNumberingPlan(defaultCallingCode);\n countryCallingCode = defaultCallingCode;\n /* istanbul ignore if */\n if (USE_NON_GEOGRAPHIC_COUNTRY_CODE) {\n if (metadata.isNonGeographicCallingCode(countryCallingCode)) {\n country = '001';\n }\n }\n }\n } else return {};\n\n // At this point, `country` could be `undefined` but `countryCallingCode` is always defined.\n //\n // Also, if `country` is defined, its numbering plan is selected in `metadata`.\n // Otherwise, the numering plan for the `countryCallingCode` is selected in `metadata`.\n\n if (!number) {\n return {\n countryCallingCodeSource: countryCallingCodeSource,\n countryCallingCode: countryCallingCode\n };\n }\n var _extractNationalNumbe = extractNationalNumber(parseIncompletePhoneNumber(number), undefined, metadata),\n nationalNumber = _extractNationalNumbe.nationalNumber,\n carrierCode = _extractNationalNumbe.carrierCode;\n\n // Sometimes there are several countries\n // corresponding to the same country phone code\n // (e.g. NANPA countries all having `1` country phone code).\n // Therefore, to reliably determine the exact country,\n // national (significant) number should have been parsed first.\n //\n // When `metadata.json` is generated, all \"ambiguous\" country phone codes\n // get their countries populated with the full set of\n // \"phone number type\" regular expressions.\n //\n var exactCountry = getCountryByCallingCode(countryCallingCode, {\n nationalNumber: nationalNumber,\n metadata: metadata\n });\n if (exactCountry) {\n country = exactCountry;\n /* istanbul ignore if */\n if (exactCountry === '001') {\n // Can't happen with `USE_NON_GEOGRAPHIC_COUNTRY_CODE` being `false`.\n // If `USE_NON_GEOGRAPHIC_COUNTRY_CODE` is set to `true` for some reason,\n // then remove the \"istanbul ignore if\".\n } else {\n metadata.selectNumberingPlan(country);\n }\n }\n return {\n country: country,\n countryCallingCode: countryCallingCode,\n countryCallingCodeSource: countryCallingCodeSource,\n nationalNumber: nationalNumber,\n carrierCode: carrierCode\n };\n}\n//# sourceMappingURL=parse.js.map","function _typeof(o) { \"@babel/helpers - typeof\"; return _typeof = \"function\" == typeof Symbol && \"symbol\" == typeof Symbol.iterator ? function (o) { return typeof o; } : function (o) { return o && \"function\" == typeof Symbol && o.constructor === Symbol && o !== Symbol.prototype ? \"symbol\" : typeof o; }, _typeof(o); }\nfunction ownKeys(e, r) { var t = Object.keys(e); if (Object.getOwnPropertySymbols) { var o = Object.getOwnPropertySymbols(e); r && (o = o.filter(function (r) { return Object.getOwnPropertyDescriptor(e, r).enumerable; })), t.push.apply(t, o); } return t; }\nfunction _objectSpread(e) { for (var r = 1; r < arguments.length; r++) { var t = null != arguments[r] ? arguments[r] : {}; r % 2 ? ownKeys(Object(t), !0).forEach(function (r) { _defineProperty(e, r, t[r]); }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(e, Object.getOwnPropertyDescriptors(t)) : ownKeys(Object(t)).forEach(function (r) { Object.defineProperty(e, r, Object.getOwnPropertyDescriptor(t, r)); }); } return e; }\nfunction _defineProperty(e, r, t) { return (r = _toPropertyKey(r)) in e ? Object.defineProperty(e, r, { value: t, enumerable: !0, configurable: !0, writable: !0 }) : e[r] = t, e; }\nfunction _toPropertyKey(t) { var i = _toPrimitive(t, \"string\"); return \"symbol\" == _typeof(i) ? i : i + \"\"; }\nfunction _toPrimitive(t, r) { if (\"object\" != _typeof(t) || !t) return t; var e = t[Symbol.toPrimitive]; if (void 0 !== e) { var i = e.call(t, r || \"default\"); if (\"object\" != _typeof(i)) return i; throw new TypeError(\"@@toPrimitive must return a primitive value.\"); } return (\"string\" === r ? String : Number)(t); }\nimport parse from './parse.js';\nexport default function parsePhoneNumberWithError(text, options, metadata) {\n return parse(text, _objectSpread(_objectSpread({}, options), {}, {\n v2: true\n }), metadata);\n}\n//# sourceMappingURL=parsePhoneNumberWithError_.js.map","function _typeof(o) { \"@babel/helpers - typeof\"; return _typeof = \"function\" == typeof Symbol && \"symbol\" == typeof Symbol.iterator ? function (o) { return typeof o; } : function (o) { return o && \"function\" == typeof Symbol && o.constructor === Symbol && o !== Symbol.prototype ? \"symbol\" : typeof o; }, _typeof(o); }\nfunction ownKeys(e, r) { var t = Object.keys(e); if (Object.getOwnPropertySymbols) { var o = Object.getOwnPropertySymbols(e); r && (o = o.filter(function (r) { return Object.getOwnPropertyDescriptor(e, r).enumerable; })), t.push.apply(t, o); } return t; }\nfunction _objectSpread(e) { for (var r = 1; r < arguments.length; r++) { var t = null != arguments[r] ? arguments[r] : {}; r % 2 ? ownKeys(Object(t), !0).forEach(function (r) { _defineProperty(e, r, t[r]); }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(e, Object.getOwnPropertyDescriptors(t)) : ownKeys(Object(t)).forEach(function (r) { Object.defineProperty(e, r, Object.getOwnPropertyDescriptor(t, r)); }); } return e; }\nfunction _defineProperty(e, r, t) { return (r = _toPropertyKey(r)) in e ? Object.defineProperty(e, r, { value: t, enumerable: !0, configurable: !0, writable: !0 }) : e[r] = t, e; }\nfunction _toPropertyKey(t) { var i = _toPrimitive(t, \"string\"); return \"symbol\" == _typeof(i) ? i : i + \"\"; }\nfunction _toPrimitive(t, r) { if (\"object\" != _typeof(t) || !t) return t; var e = t[Symbol.toPrimitive]; if (void 0 !== e) { var i = e.call(t, r || \"default\"); if (\"object\" != _typeof(i)) return i; throw new TypeError(\"@@toPrimitive must return a primitive value.\"); } return (\"string\" === r ? String : Number)(t); }\nfunction _slicedToArray(r, e) { return _arrayWithHoles(r) || _iterableToArrayLimit(r, e) || _unsupportedIterableToArray(r, e) || _nonIterableRest(); }\nfunction _nonIterableRest() { throw new TypeError(\"Invalid attempt to destructure non-iterable instance.\\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.\"); }\nfunction _unsupportedIterableToArray(r, a) { if (r) { if (\"string\" == typeof r) return _arrayLikeToArray(r, a); var t = {}.toString.call(r).slice(8, -1); return \"Object\" === t && r.constructor && (t = r.constructor.name), \"Map\" === t || \"Set\" === t ? Array.from(r) : \"Arguments\" === t || /^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(t) ? _arrayLikeToArray(r, a) : void 0; } }\nfunction _arrayLikeToArray(r, a) { (null == a || a > r.length) && (a = r.length); for (var e = 0, n = Array(a); e < a; e++) n[e] = r[e]; return n; }\nfunction _iterableToArrayLimit(r, l) { var t = null == r ? null : \"undefined\" != typeof Symbol && r[Symbol.iterator] || r[\"@@iterator\"]; if (null != t) { var e, n, i, u, a = [], f = !0, o = !1; try { if (i = (t = t.call(r)).next, 0 === l) { if (Object(t) !== t) return; f = !1; } else for (; !(f = (e = i.call(t)).done) && (a.push(e.value), a.length !== l); f = !0); } catch (r) { o = !0, n = r; } finally { try { if (!f && null != t[\"return\"] && (u = t[\"return\"](), Object(u) !== u)) return; } finally { if (o) throw n; } } return a; } }\nfunction _arrayWithHoles(r) { if (Array.isArray(r)) return r; }\nimport isObject from './helpers/isObject.js';\n\n// Extracts the following properties from function arguments:\n// * input `text`\n// * `options` object\n// * `metadata` JSON\nexport default function normalizeArguments(args) {\n var _Array$prototype$slic = Array.prototype.slice.call(args),\n _Array$prototype$slic2 = _slicedToArray(_Array$prototype$slic, 4),\n arg_1 = _Array$prototype$slic2[0],\n arg_2 = _Array$prototype$slic2[1],\n arg_3 = _Array$prototype$slic2[2],\n arg_4 = _Array$prototype$slic2[3];\n var text;\n var options;\n var metadata;\n\n // If the phone number is passed as a string.\n // `parsePhoneNumber('88005553535', ...)`.\n if (typeof arg_1 === 'string') {\n text = arg_1;\n } else throw new TypeError('A text for parsing must be a string.');\n\n // If \"default country\" argument is being passed then move it to `options`.\n // `parsePhoneNumber('88005553535', 'RU', [options], metadata)`.\n if (!arg_2 || typeof arg_2 === 'string') {\n if (arg_4) {\n options = arg_3;\n metadata = arg_4;\n } else {\n options = undefined;\n metadata = arg_3;\n }\n if (arg_2) {\n options = _objectSpread({\n defaultCountry: arg_2\n }, options);\n }\n }\n // `defaultCountry` is not passed.\n // Example: `parsePhoneNumber('+78005553535', [options], metadata)`.\n else if (isObject(arg_2)) {\n if (arg_3) {\n options = arg_2;\n metadata = arg_3;\n } else {\n metadata = arg_2;\n }\n } else throw new Error(\"Invalid second argument: \".concat(arg_2));\n return {\n text: text,\n options: options,\n metadata: metadata\n };\n}\n//# sourceMappingURL=normalizeArguments.js.map","import parsePhoneNumberWithError_ from './parsePhoneNumberWithError_.js';\nimport normalizeArguments from './normalizeArguments.js';\nexport default function parsePhoneNumberWithError() {\n var _normalizeArguments = normalizeArguments(arguments),\n text = _normalizeArguments.text,\n options = _normalizeArguments.options,\n metadata = _normalizeArguments.metadata;\n return parsePhoneNumberWithError_(text, options, metadata);\n}\n//# sourceMappingURL=parsePhoneNumberWithError.js.map","function _typeof(o) { \"@babel/helpers - typeof\"; return _typeof = \"function\" == typeof Symbol && \"symbol\" == typeof Symbol.iterator ? function (o) { return typeof o; } : function (o) { return o && \"function\" == typeof Symbol && o.constructor === Symbol && o !== Symbol.prototype ? \"symbol\" : typeof o; }, _typeof(o); }\nfunction ownKeys(e, r) { var t = Object.keys(e); if (Object.getOwnPropertySymbols) { var o = Object.getOwnPropertySymbols(e); r && (o = o.filter(function (r) { return Object.getOwnPropertyDescriptor(e, r).enumerable; })), t.push.apply(t, o); } return t; }\nfunction _objectSpread(e) { for (var r = 1; r < arguments.length; r++) { var t = null != arguments[r] ? arguments[r] : {}; r % 2 ? ownKeys(Object(t), !0).forEach(function (r) { _defineProperty(e, r, t[r]); }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(e, Object.getOwnPropertyDescriptors(t)) : ownKeys(Object(t)).forEach(function (r) { Object.defineProperty(e, r, Object.getOwnPropertyDescriptor(t, r)); }); } return e; }\nfunction _defineProperty(e, r, t) { return (r = _toPropertyKey(r)) in e ? Object.defineProperty(e, r, { value: t, enumerable: !0, configurable: !0, writable: !0 }) : e[r] = t, e; }\nfunction _toPropertyKey(t) { var i = _toPrimitive(t, \"string\"); return \"symbol\" == _typeof(i) ? i : i + \"\"; }\nfunction _toPrimitive(t, r) { if (\"object\" != _typeof(t) || !t) return t; var e = t[Symbol.toPrimitive]; if (void 0 !== e) { var i = e.call(t, r || \"default\"); if (\"object\" != _typeof(i)) return i; throw new TypeError(\"@@toPrimitive must return a primitive value.\"); } return (\"string\" === r ? String : Number)(t); }\nimport parsePhoneNumberWithError from './parsePhoneNumberWithError_.js';\nimport ParseError from './ParseError.js';\nimport { isSupportedCountry } from './metadata.js';\nexport default function parsePhoneNumber(text, options, metadata) {\n // Validate `defaultCountry`.\n if (options && options.defaultCountry && !isSupportedCountry(options.defaultCountry, metadata)) {\n options = _objectSpread(_objectSpread({}, options), {}, {\n defaultCountry: undefined\n });\n }\n // Parse phone number.\n try {\n return parsePhoneNumberWithError(text, options, metadata);\n } catch (error) {\n /* istanbul ignore else */\n if (error instanceof ParseError) {\n //\n } else {\n throw error;\n }\n }\n}\n//# sourceMappingURL=parsePhoneNumber_.js.map","function _typeof(o) { \"@babel/helpers - typeof\"; return _typeof = \"function\" == typeof Symbol && \"symbol\" == typeof Symbol.iterator ? function (o) { return typeof o; } : function (o) { return o && \"function\" == typeof Symbol && o.constructor === Symbol && o !== Symbol.prototype ? \"symbol\" : typeof o; }, _typeof(o); }\nfunction ownKeys(e, r) { var t = Object.keys(e); if (Object.getOwnPropertySymbols) { var o = Object.getOwnPropertySymbols(e); r && (o = o.filter(function (r) { return Object.getOwnPropertyDescriptor(e, r).enumerable; })), t.push.apply(t, o); } return t; }\nfunction _objectSpread(e) { for (var r = 1; r < arguments.length; r++) { var t = null != arguments[r] ? arguments[r] : {}; r % 2 ? ownKeys(Object(t), !0).forEach(function (r) { _defineProperty(e, r, t[r]); }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(e, Object.getOwnPropertyDescriptors(t)) : ownKeys(Object(t)).forEach(function (r) { Object.defineProperty(e, r, Object.getOwnPropertyDescriptor(t, r)); }); } return e; }\nfunction _defineProperty(e, r, t) { return (r = _toPropertyKey(r)) in e ? Object.defineProperty(e, r, { value: t, enumerable: !0, configurable: !0, writable: !0 }) : e[r] = t, e; }\nfunction _toPropertyKey(t) { var i = _toPrimitive(t, \"string\"); return \"symbol\" == _typeof(i) ? i : i + \"\"; }\nfunction _toPrimitive(t, r) { if (\"object\" != _typeof(t) || !t) return t; var e = t[Symbol.toPrimitive]; if (void 0 !== e) { var i = e.call(t, r || \"default\"); if (\"object\" != _typeof(i)) return i; throw new TypeError(\"@@toPrimitive must return a primitive value.\"); } return (\"string\" === r ? String : Number)(t); }\nimport normalizeArguments from './normalizeArguments.js';\nimport parsePhoneNumber from './parsePhoneNumber_.js';\nexport default function isValidPhoneNumber() {\n var _normalizeArguments = normalizeArguments(arguments),\n text = _normalizeArguments.text,\n options = _normalizeArguments.options,\n metadata = _normalizeArguments.metadata;\n options = _objectSpread(_objectSpread({}, options), {}, {\n extract: false\n });\n var phoneNumber = parsePhoneNumber(text, options, metadata);\n return phoneNumber && phoneNumber.isValid() || false;\n}\n//# sourceMappingURL=isValidPhoneNumber.js.map","function _typeof(o) { \"@babel/helpers - typeof\"; return _typeof = \"function\" == typeof Symbol && \"symbol\" == typeof Symbol.iterator ? function (o) { return typeof o; } : function (o) { return o && \"function\" == typeof Symbol && o.constructor === Symbol && o !== Symbol.prototype ? \"symbol\" : typeof o; }, _typeof(o); }\nfunction _classCallCheck(a, n) { if (!(a instanceof n)) throw new TypeError(\"Cannot call a class as a function\"); }\nfunction _defineProperties(e, r) { for (var t = 0; t < r.length; t++) { var o = r[t]; o.enumerable = o.enumerable || !1, o.configurable = !0, \"value\" in o && (o.writable = !0), Object.defineProperty(e, _toPropertyKey(o.key), o); } }\nfunction _createClass(e, r, t) { return r && _defineProperties(e.prototype, r), t && _defineProperties(e, t), Object.defineProperty(e, \"prototype\", { writable: !1 }), e; }\nfunction _toPropertyKey(t) { var i = _toPrimitive(t, \"string\"); return \"symbol\" == _typeof(i) ? i : i + \"\"; }\nfunction _toPrimitive(t, r) { if (\"object\" != _typeof(t) || !t) return t; var e = t[Symbol.toPrimitive]; if (void 0 !== e) { var i = e.call(t, r || \"default\"); if (\"object\" != _typeof(i)) return i; throw new TypeError(\"@@toPrimitive must return a primitive value.\"); } return (\"string\" === r ? String : Number)(t); }\n// This \"state\" object simply holds the state of the \"AsYouType\" parser:\n//\n// Sidenote:\n// `state.callingCode` and `state.country` are somewhat independent from one another\n// and there could be situations when one is defined but the other is not.\n// * Situations when `state.country` would be defined but `state.callingCode` would be `undefined`:\n// \t\t * When `defaultCountry` is specified and inputting a phone number not in \"international\" format.\n// * When `defaultCountry` is specified and inputting a phone number in \"international\" format,\n// but before the `+` character has been input.\n// * Situations when `state.country` would be `undefined` but `state.callingCode` would be defined:\n// * When `defaultCountry` is not specified and inputting a phone number in \"international\" format,\n// and the \"calling code\" part is already complete, but multiple countries share this \"calling code\"\n// and there's not enough national (significant) number digits yet to determine the exact country.\n// * In any other sigutations, `state.country` and `state.callingCode` are either both defined or both `undefined`.\n// * When they're both defined, `state.callingCode` always corresponds to `state.country`.\n// So both are always consistent in this case.\n//\n// * `country?: string` — The exact country of the phone number, if it could be determined.\n// When inputting a phone number in \"international\" format, it will derive the `country` from \"country calling code\" and the phone number digits.\n// When inputting a phone number in \"national\" format, it will derive the `country` from `defaultCountry` that was specified when creating the `AsYouType` formatter.\n// Sidenote: If `USE_NON_GEOGRAPHIC_COUNTRY_CODE` flag was `true`, then for \"non-geographic phone numbers\" `state.country` would've been \"001\".\n// * `callingCode?: string` — \"Country calling code\" that has been extracted from the input phone number.\n// When inputting a phone number in \"international\" format, it will extract the \"country calling code\" from the digits that follow the \"+\" character.\n// When inputting a phone number in \"national\" format, `callingCode` will be `undefined`.\n// * `digits: string` — Phone number digits that have been input so far, including the \"+\" character, if present. In case of inputting non-arabic digits, those will be converted to arabic ones.\n// * `international: boolean` — Whether the phone number is being input in \"international\" format, i.e. with a \"+\" character.\n// * `missingPlus: boolean` — Whether it's a phone number in \"international\" format that is missing the leading \"+\" character for some reason — apparently, Google thinks that it's a common mistake when inputting a phone number.\n// * `IDDPrefix?: string` — An \"IDD prefix\", when the phone number is being input in an \"out-of-country dialing\" format. https://wikitravel.org/en/International_dialling_prefix\n// * `carrierCode?: string` — A \"carrier code\", if the phone number contains it. Normally, those can only be present in Colombia or Brazil, and only when calling from mobile phones to fixed-line numbers.\n// * `nationalPrefix?: string` — \"National prefix\", if present in the phone number input.\n// * `nationalSignificantNumber?: string` — National (significant) number digits that have been input so far.\n// * `nationalSignificantNumberIsModified: boolean` — Tells if the parsed national (significant) number is present as-is in the input string. For example, when inputting \"0343515551212999\" Argentinian mobile number, the parsed national (significant) number is \"93435551212999\". There, one can see how it stripped \"0\" national prefix and prepended a \"9\", because that's how it is instructed to do in Argentina's metadata. So in the described example, the parsed national (significant) number is not present as-is in the input string. Instead, it's \"modified\" in the input string. https://gitlab.com/caamphetamine/libphonenumber-js/-/blob/master/METADATA.md#national_prefix_for_parsing--national_prefix_transform_rule\n// * `prefixBeforeNationalSignificantNumberThatIsNotNationalPrefix?: string` — In some countries, a phone number could have a prefix that is not a \"national prefix\" but rather some other type of \"utility\" prefix.\n// For example, when calling within Australia, one could prepend `1831` prefix to hide caller's phone number.\n// https://gitlab.com/catamphetamine/libphonenumber-js/-/blob/master/METADATA.md#national_prefix_for_parsing--national_prefix_transform_rule\n//\nvar AsYouTypeState = /*#__PURE__*/function () {\n function AsYouTypeState(_ref) {\n var onCountryChange = _ref.onCountryChange,\n onCallingCodeChange = _ref.onCallingCodeChange;\n _classCallCheck(this, AsYouTypeState);\n this.onCountryChange = onCountryChange;\n this.onCallingCodeChange = onCallingCodeChange;\n }\n return _createClass(AsYouTypeState, [{\n key: \"reset\",\n value: function reset(_ref2) {\n var country = _ref2.country,\n callingCode = _ref2.callingCode;\n this.international = false;\n this.missingPlus = false;\n this.IDDPrefix = undefined;\n this.callingCode = undefined;\n this.digits = '';\n this.resetNationalSignificantNumber();\n this.initCountryAndCallingCode(country, callingCode);\n }\n }, {\n key: \"resetNationalSignificantNumber\",\n value: function resetNationalSignificantNumber() {\n this.nationalSignificantNumber = this.getNationalDigits();\n this.nationalSignificantNumberIsModified = false;\n this.nationalPrefix = undefined;\n this.carrierCode = undefined;\n this.prefixBeforeNationalSignificantNumberThatIsNotNationalPrefix = undefined;\n }\n }, {\n key: \"update\",\n value: function update(properties) {\n for (var _i = 0, _Object$keys = Object.keys(properties); _i < _Object$keys.length; _i++) {\n var key = _Object$keys[_i];\n this[key] = properties[key];\n }\n }\n }, {\n key: \"initCountryAndCallingCode\",\n value: function initCountryAndCallingCode(country, callingCode) {\n this.setCountry(country);\n this.setCallingCode(callingCode);\n }\n }, {\n key: \"setCountry\",\n value: function setCountry(country) {\n this.country = country;\n this.onCountryChange(country);\n }\n }, {\n key: \"setCallingCode\",\n value: function setCallingCode(callingCode) {\n this.callingCode = callingCode;\n this.onCallingCodeChange(callingCode, this.country);\n }\n }, {\n key: \"startInternationalNumber\",\n value: function startInternationalNumber(country, callingCode) {\n // Prepend the `+` to parsed input.\n this.international = true;\n // If a default country was set then reset it\n // because an explicitly international phone\n // number is being entered.\n this.initCountryAndCallingCode(country, callingCode);\n }\n }, {\n key: \"appendDigits\",\n value: function appendDigits(nextDigits) {\n this.digits += nextDigits;\n }\n }, {\n key: \"appendNationalSignificantNumberDigits\",\n value: function appendNationalSignificantNumberDigits(nextDigits) {\n this.nationalSignificantNumber += nextDigits;\n }\n\n /**\r\n * Returns the part of `this.digits` that corresponds to the national number.\r\n * Basically, all digits that have been input by the user, except for the\r\n * international prefix and the country calling code part\r\n * (if the number is an international one).\r\n * @return {string}\r\n */\n }, {\n key: \"getNationalDigits\",\n value: function getNationalDigits() {\n if (this.international) {\n return this.digits.slice((this.IDDPrefix ? this.IDDPrefix.length : 0) + (this.callingCode ? this.callingCode.length : 0));\n }\n return this.digits;\n }\n }, {\n key: \"getDigitsWithoutInternationalPrefix\",\n value: function getDigitsWithoutInternationalPrefix() {\n if (this.international) {\n if (this.IDDPrefix) {\n return this.digits.slice(this.IDDPrefix.length);\n }\n }\n return this.digits;\n }\n }]);\n}();\nexport { AsYouTypeState as default };\n//# sourceMappingURL=AsYouTypeState.js.map","function _createForOfIteratorHelperLoose(r, e) { var t = \"undefined\" != typeof Symbol && r[Symbol.iterator] || r[\"@@iterator\"]; if (t) return (t = t.call(r)).next.bind(t); if (Array.isArray(r) || (t = _unsupportedIterableToArray(r)) || e && r && \"number\" == typeof r.length) { t && (r = t); var o = 0; return function () { return o >= r.length ? { done: !0 } : { done: !1, value: r[o++] }; }; } throw new TypeError(\"Invalid attempt to iterate non-iterable instance.\\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.\"); }\nfunction _unsupportedIterableToArray(r, a) { if (r) { if (\"string\" == typeof r) return _arrayLikeToArray(r, a); var t = {}.toString.call(r).slice(8, -1); return \"Object\" === t && r.constructor && (t = r.constructor.name), \"Map\" === t || \"Set\" === t ? Array.from(r) : \"Arguments\" === t || /^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(t) ? _arrayLikeToArray(r, a) : void 0; } }\nfunction _arrayLikeToArray(r, a) { (null == a || a > r.length) && (a = r.length); for (var e = 0, n = Array(a); e < a; e++) n[e] = r[e]; return n; }\n// Should be the same as `DIGIT_PLACEHOLDER` in `libphonenumber-metadata-generator`.\nexport var DIGIT_PLACEHOLDER = 'x'; // '\\u2008' (punctuation space)\nvar DIGIT_PLACEHOLDER_MATCHER = new RegExp(DIGIT_PLACEHOLDER);\n\n// Counts all occurences of a symbol in a string.\n// Unicode-unsafe (because using `.split()`).\nexport function countOccurences(symbol, string) {\n var count = 0;\n // Using `.split('')` to iterate through a string here\n // to avoid requiring `Symbol.iterator` polyfill.\n // `.split('')` is generally not safe for Unicode,\n // but in this particular case for counting brackets it is safe.\n // for (const character of string)\n for (var _iterator = _createForOfIteratorHelperLoose(string.split('')), _step; !(_step = _iterator()).done;) {\n var character = _step.value;\n if (character === symbol) {\n count++;\n }\n }\n return count;\n}\n\n// Repeats a string (or a symbol) N times.\n// http://stackoverflow.com/questions/202605/repeat-string-javascript\nexport function repeat(string, times) {\n if (times < 1) {\n return '';\n }\n var result = '';\n while (times > 1) {\n if (times & 1) {\n result += string;\n }\n times >>= 1;\n string += string;\n }\n return result + string;\n}\nexport function cutAndStripNonPairedParens(string, cutBeforeIndex) {\n if (string[cutBeforeIndex] === ')') {\n cutBeforeIndex++;\n }\n return stripNonPairedParens(string.slice(0, cutBeforeIndex));\n}\nexport function closeNonPairedParens(template, cut_before) {\n var retained_template = template.slice(0, cut_before);\n var opening_braces = countOccurences('(', retained_template);\n var closing_braces = countOccurences(')', retained_template);\n var dangling_braces = opening_braces - closing_braces;\n while (dangling_braces > 0 && cut_before < template.length) {\n if (template[cut_before] === ')') {\n dangling_braces--;\n }\n cut_before++;\n }\n return template.slice(0, cut_before);\n}\nexport function stripNonPairedParens(string) {\n var dangling_braces = [];\n var i = 0;\n while (i < string.length) {\n if (string[i] === '(') {\n dangling_braces.push(i);\n } else if (string[i] === ')') {\n dangling_braces.pop();\n }\n i++;\n }\n var start = 0;\n var cleared_string = '';\n dangling_braces.push(string.length);\n for (var _i = 0, _dangling_braces = dangling_braces; _i < _dangling_braces.length; _i++) {\n var index = _dangling_braces[_i];\n cleared_string += string.slice(start, index);\n start = index + 1;\n }\n return cleared_string;\n}\nexport function populateTemplateWithDigits(template, position, digits) {\n // Using `.split('')` to iterate through a string here\n // to avoid requiring `Symbol.iterator` polyfill.\n // `.split('')` is generally not safe for Unicode,\n // but in this particular case for `digits` it is safe.\n // for (const digit of digits)\n for (var _iterator2 = _createForOfIteratorHelperLoose(digits.split('')), _step2; !(_step2 = _iterator2()).done;) {\n var digit = _step2.value;\n // If there is room for more digits in current `template`,\n // then set the next digit in the `template`,\n // and return the formatted digits so far.\n // If more digits are entered than the current format could handle.\n if (template.slice(position + 1).search(DIGIT_PLACEHOLDER_MATCHER) < 0) {\n return;\n }\n position = template.search(DIGIT_PLACEHOLDER_MATCHER);\n template = template.replace(DIGIT_PLACEHOLDER_MATCHER, digit);\n }\n return [template, position];\n}\n//# sourceMappingURL=AsYouTypeFormatter.util.js.map","import checkNumberLength from './helpers/checkNumberLength.js';\nimport parseDigits from './helpers/parseDigits.js';\nimport formatNationalNumberUsingFormat from './helpers/formatNationalNumberUsingFormat.js';\nexport default function formatCompleteNumber(state, format, _ref) {\n var metadata = _ref.metadata,\n shouldTryNationalPrefixFormattingRule = _ref.shouldTryNationalPrefixFormattingRule,\n getSeparatorAfterNationalPrefix = _ref.getSeparatorAfterNationalPrefix;\n var matcher = new RegExp(\"^(?:\".concat(format.pattern(), \")$\"));\n if (matcher.test(state.nationalSignificantNumber)) {\n return formatNationalNumberWithAndWithoutNationalPrefixFormattingRule(state, format, {\n metadata: metadata,\n shouldTryNationalPrefixFormattingRule: shouldTryNationalPrefixFormattingRule,\n getSeparatorAfterNationalPrefix: getSeparatorAfterNationalPrefix\n });\n }\n}\nexport function canFormatCompleteNumber(nationalSignificantNumber, metadata) {\n return checkNumberLength(nationalSignificantNumber, undefined, metadata) === 'IS_POSSIBLE';\n}\nfunction formatNationalNumberWithAndWithoutNationalPrefixFormattingRule(state, format, _ref2) {\n var metadata = _ref2.metadata,\n shouldTryNationalPrefixFormattingRule = _ref2.shouldTryNationalPrefixFormattingRule,\n getSeparatorAfterNationalPrefix = _ref2.getSeparatorAfterNationalPrefix;\n // `format` has already been checked for `nationalPrefix` requirement.\n\n var nationalSignificantNumber = state.nationalSignificantNumber,\n international = state.international,\n nationalPrefix = state.nationalPrefix,\n carrierCode = state.carrierCode;\n\n // Format the number with using `national_prefix_formatting_rule`.\n // If the resulting formatted number is a valid formatted number, then return it.\n //\n // Google's AsYouType formatter is different in a way that it doesn't try\n // to format using the \"national prefix formatting rule\", and instead it\n // simply prepends a national prefix followed by a \" \" character.\n // This code does that too, but as a fallback.\n // The reason is that \"national prefix formatting rule\" may use parentheses,\n // which wouldn't be included has it used the simpler Google's way.\n //\n if (shouldTryNationalPrefixFormattingRule(format)) {\n var formattedNumber = formatNationalNumber(state, format, {\n useNationalPrefixFormattingRule: true,\n getSeparatorAfterNationalPrefix: getSeparatorAfterNationalPrefix,\n metadata: metadata\n });\n if (formattedNumber) {\n return formattedNumber;\n }\n }\n\n // Format the number without using `national_prefix_formatting_rule`.\n return formatNationalNumber(state, format, {\n useNationalPrefixFormattingRule: false,\n getSeparatorAfterNationalPrefix: getSeparatorAfterNationalPrefix,\n metadata: metadata\n });\n}\nfunction formatNationalNumber(state, format, _ref3) {\n var metadata = _ref3.metadata,\n useNationalPrefixFormattingRule = _ref3.useNationalPrefixFormattingRule,\n getSeparatorAfterNationalPrefix = _ref3.getSeparatorAfterNationalPrefix;\n var formattedNationalNumber = formatNationalNumberUsingFormat(state.nationalSignificantNumber, format, {\n carrierCode: state.carrierCode,\n useInternationalFormat: state.international,\n withNationalPrefix: useNationalPrefixFormattingRule,\n metadata: metadata\n });\n if (!useNationalPrefixFormattingRule) {\n if (state.nationalPrefix) {\n // If a national prefix was extracted, then just prepend it,\n // followed by a \" \" character.\n formattedNationalNumber = state.nationalPrefix + getSeparatorAfterNationalPrefix(format) + formattedNationalNumber;\n } else if (state.prefixBeforeNationalSignificantNumberThatIsNotNationalPrefix) {\n formattedNationalNumber = state.prefixBeforeNationalSignificantNumberThatIsNotNationalPrefix + ' ' + formattedNationalNumber;\n }\n }\n if (isValidFormattedNationalNumber(formattedNationalNumber, state)) {\n return formattedNationalNumber;\n }\n}\n\n// Check that the formatted phone number contains exactly\n// the same digits that have been input by the user.\n// For example, when \"0111523456789\" is input for `AR` country,\n// the extracted `this.nationalSignificantNumber` is \"91123456789\",\n// which means that the national part of `this.digits` isn't simply equal to\n// `this.nationalPrefix` + `this.nationalSignificantNumber`.\n//\n// Also, a `format` can add extra digits to the `this.nationalSignificantNumber`\n// being formatted via `metadata[country].national_prefix_transform_rule`.\n// For example, for `VI` country, it prepends `340` to the national number,\n// and if this check hasn't been implemented, then there would be a bug\n// when `340` \"area coude\" is \"duplicated\" during input for `VI` country:\n// https://github.com/catamphetamine/libphonenumber-js/issues/318\n//\n// So, all these \"gotchas\" are filtered out.\n//\n// In the original Google's code, the comments say:\n// \"Check that we didn't remove nor add any extra digits when we matched\n// this formatting pattern. This usually happens after we entered the last\n// digit during AYTF. Eg: In case of MX, we swallow mobile token (1) when\n// formatted but AYTF should retain all the number entered and not change\n// in order to match a format (of same leading digits and length) display\n// in that way.\"\n// \"If it's the same (i.e entered number and format is same), then it's\n// safe to return this in formatted number as nothing is lost / added.\"\n// Otherwise, don't use this format.\n// https://github.com/google/libphonenumber/commit/3e7c1f04f5e7200f87fb131e6f85c6e99d60f510#diff-9149457fa9f5d608a11bb975c6ef4bc5\n// https://github.com/google/libphonenumber/commit/3ac88c7106e7dcb553bcc794b15f19185928a1c6#diff-2dcb77e833422ee304da348b905cde0b\n//\nfunction isValidFormattedNationalNumber(formattedNationalNumber, state) {\n return parseDigits(formattedNationalNumber) === state.getNationalDigits();\n}\n//# sourceMappingURL=AsYouTypeFormatter.complete.js.map","function _typeof(o) { \"@babel/helpers - typeof\"; return _typeof = \"function\" == typeof Symbol && \"symbol\" == typeof Symbol.iterator ? function (o) { return typeof o; } : function (o) { return o && \"function\" == typeof Symbol && o.constructor === Symbol && o !== Symbol.prototype ? \"symbol\" : typeof o; }, _typeof(o); }\nfunction _classCallCheck(a, n) { if (!(a instanceof n)) throw new TypeError(\"Cannot call a class as a function\"); }\nfunction _defineProperties(e, r) { for (var t = 0; t < r.length; t++) { var o = r[t]; o.enumerable = o.enumerable || !1, o.configurable = !0, \"value\" in o && (o.writable = !0), Object.defineProperty(e, _toPropertyKey(o.key), o); } }\nfunction _createClass(e, r, t) { return r && _defineProperties(e.prototype, r), t && _defineProperties(e, t), Object.defineProperty(e, \"prototype\", { writable: !1 }), e; }\nfunction _toPropertyKey(t) { var i = _toPrimitive(t, \"string\"); return \"symbol\" == _typeof(i) ? i : i + \"\"; }\nfunction _toPrimitive(t, r) { if (\"object\" != _typeof(t) || !t) return t; var e = t[Symbol.toPrimitive]; if (void 0 !== e) { var i = e.call(t, r || \"default\"); if (\"object\" != _typeof(i)) return i; throw new TypeError(\"@@toPrimitive must return a primitive value.\"); } return (\"string\" === r ? String : Number)(t); }\nvar PatternParser = /*#__PURE__*/function () {\n function PatternParser() {\n _classCallCheck(this, PatternParser);\n }\n return _createClass(PatternParser, [{\n key: \"parse\",\n value: function parse(pattern) {\n this.context = [{\n or: true,\n instructions: []\n }];\n this.parsePattern(pattern);\n if (this.context.length !== 1) {\n throw new Error('Non-finalized contexts left when pattern parse ended');\n }\n var _this$context$ = this.context[0],\n branches = _this$context$.branches,\n instructions = _this$context$.instructions;\n if (branches) {\n return {\n op: '|',\n args: branches.concat([expandSingleElementArray(instructions)])\n };\n }\n\n /* istanbul ignore if */\n if (instructions.length === 0) {\n throw new Error('Pattern is required');\n }\n if (instructions.length === 1) {\n return instructions[0];\n }\n return instructions;\n }\n }, {\n key: \"startContext\",\n value: function startContext(context) {\n this.context.push(context);\n }\n }, {\n key: \"endContext\",\n value: function endContext() {\n this.context.pop();\n }\n }, {\n key: \"getContext\",\n value: function getContext() {\n return this.context[this.context.length - 1];\n }\n }, {\n key: \"parsePattern\",\n value: function parsePattern(pattern) {\n if (!pattern) {\n throw new Error('Pattern is required');\n }\n var match = pattern.match(OPERATOR);\n if (!match) {\n if (ILLEGAL_CHARACTER_REGEXP.test(pattern)) {\n throw new Error(\"Illegal characters found in a pattern: \".concat(pattern));\n }\n this.getContext().instructions = this.getContext().instructions.concat(pattern.split(''));\n return;\n }\n var operator = match[1];\n var before = pattern.slice(0, match.index);\n var rightPart = pattern.slice(match.index + operator.length);\n switch (operator) {\n case '(?:':\n if (before) {\n this.parsePattern(before);\n }\n this.startContext({\n or: true,\n instructions: [],\n branches: []\n });\n break;\n case ')':\n if (!this.getContext().or) {\n throw new Error('\")\" operator must be preceded by \"(?:\" operator');\n }\n if (before) {\n this.parsePattern(before);\n }\n if (this.getContext().instructions.length === 0) {\n throw new Error('No instructions found after \"|\" operator in an \"or\" group');\n }\n var _this$getContext = this.getContext(),\n branches = _this$getContext.branches;\n branches.push(expandSingleElementArray(this.getContext().instructions));\n this.endContext();\n this.getContext().instructions.push({\n op: '|',\n args: branches\n });\n break;\n case '|':\n if (!this.getContext().or) {\n throw new Error('\"|\" operator can only be used inside \"or\" groups');\n }\n if (before) {\n this.parsePattern(before);\n }\n // The top-level is an implicit \"or\" group, if required.\n if (!this.getContext().branches) {\n // `branches` are not defined only for the root implicit \"or\" operator.\n /* istanbul ignore else */\n if (this.context.length === 1) {\n this.getContext().branches = [];\n } else {\n throw new Error('\"branches\" not found in an \"or\" group context');\n }\n }\n this.getContext().branches.push(expandSingleElementArray(this.getContext().instructions));\n this.getContext().instructions = [];\n break;\n case '[':\n if (before) {\n this.parsePattern(before);\n }\n this.startContext({\n oneOfSet: true\n });\n break;\n case ']':\n if (!this.getContext().oneOfSet) {\n throw new Error('\"]\" operator must be preceded by \"[\" operator');\n }\n this.endContext();\n this.getContext().instructions.push({\n op: '[]',\n args: parseOneOfSet(before)\n });\n break;\n\n /* istanbul ignore next */\n default:\n throw new Error(\"Unknown operator: \".concat(operator));\n }\n if (rightPart) {\n this.parsePattern(rightPart);\n }\n }\n }]);\n}();\nexport { PatternParser as default };\nfunction parseOneOfSet(pattern) {\n var values = [];\n var i = 0;\n while (i < pattern.length) {\n if (pattern[i] === '-') {\n if (i === 0 || i === pattern.length - 1) {\n throw new Error(\"Couldn't parse a one-of set pattern: \".concat(pattern));\n }\n var prevValue = pattern[i - 1].charCodeAt(0) + 1;\n var nextValue = pattern[i + 1].charCodeAt(0) - 1;\n var value = prevValue;\n while (value <= nextValue) {\n values.push(String.fromCharCode(value));\n value++;\n }\n } else {\n values.push(pattern[i]);\n }\n i++;\n }\n return values;\n}\nvar ILLEGAL_CHARACTER_REGEXP = /[\\(\\)\\[\\]\\?\\:\\|]/;\nvar OPERATOR = new RegExp(\n// any of:\n'(' +\n// or operator\n'\\\\|' +\n// or\n'|' +\n// or group start\n'\\\\(\\\\?\\\\:' +\n// or\n'|' +\n// or group end\n'\\\\)' +\n// or\n'|' +\n// one-of set start\n'\\\\[' +\n// or\n'|' +\n// one-of set end\n'\\\\]' + ')');\nfunction expandSingleElementArray(array) {\n if (array.length === 1) {\n return array[0];\n }\n return array;\n}\n//# sourceMappingURL=AsYouTypeFormatter.PatternParser.js.map","function _createForOfIteratorHelperLoose(r, e) { var t = \"undefined\" != typeof Symbol && r[Symbol.iterator] || r[\"@@iterator\"]; if (t) return (t = t.call(r)).next.bind(t); if (Array.isArray(r) || (t = _unsupportedIterableToArray(r)) || e && r && \"number\" == typeof r.length) { t && (r = t); var o = 0; return function () { return o >= r.length ? { done: !0 } : { done: !1, value: r[o++] }; }; } throw new TypeError(\"Invalid attempt to iterate non-iterable instance.\\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.\"); }\nfunction _unsupportedIterableToArray(r, a) { if (r) { if (\"string\" == typeof r) return _arrayLikeToArray(r, a); var t = {}.toString.call(r).slice(8, -1); return \"Object\" === t && r.constructor && (t = r.constructor.name), \"Map\" === t || \"Set\" === t ? Array.from(r) : \"Arguments\" === t || /^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(t) ? _arrayLikeToArray(r, a) : void 0; } }\nfunction _arrayLikeToArray(r, a) { (null == a || a > r.length) && (a = r.length); for (var e = 0, n = Array(a); e < a; e++) n[e] = r[e]; return n; }\nfunction _typeof(o) { \"@babel/helpers - typeof\"; return _typeof = \"function\" == typeof Symbol && \"symbol\" == typeof Symbol.iterator ? function (o) { return typeof o; } : function (o) { return o && \"function\" == typeof Symbol && o.constructor === Symbol && o !== Symbol.prototype ? \"symbol\" : typeof o; }, _typeof(o); }\nfunction _classCallCheck(a, n) { if (!(a instanceof n)) throw new TypeError(\"Cannot call a class as a function\"); }\nfunction _defineProperties(e, r) { for (var t = 0; t < r.length; t++) { var o = r[t]; o.enumerable = o.enumerable || !1, o.configurable = !0, \"value\" in o && (o.writable = !0), Object.defineProperty(e, _toPropertyKey(o.key), o); } }\nfunction _createClass(e, r, t) { return r && _defineProperties(e.prototype, r), t && _defineProperties(e, t), Object.defineProperty(e, \"prototype\", { writable: !1 }), e; }\nfunction _toPropertyKey(t) { var i = _toPrimitive(t, \"string\"); return \"symbol\" == _typeof(i) ? i : i + \"\"; }\nfunction _toPrimitive(t, r) { if (\"object\" != _typeof(t) || !t) return t; var e = t[Symbol.toPrimitive]; if (void 0 !== e) { var i = e.call(t, r || \"default\"); if (\"object\" != _typeof(i)) return i; throw new TypeError(\"@@toPrimitive must return a primitive value.\"); } return (\"string\" === r ? String : Number)(t); }\nimport PatternParser from './AsYouTypeFormatter.PatternParser.js';\nvar PatternMatcher = /*#__PURE__*/function () {\n function PatternMatcher(pattern) {\n _classCallCheck(this, PatternMatcher);\n this.matchTree = new PatternParser().parse(pattern);\n }\n return _createClass(PatternMatcher, [{\n key: \"match\",\n value: function match(string) {\n var _ref = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : {},\n allowOverflow = _ref.allowOverflow;\n if (!string) {\n throw new Error('String is required');\n }\n var result = _match(string.split(''), this.matchTree, true);\n if (result && result.match) {\n delete result.matchedChars;\n }\n if (result && result.overflow) {\n if (!allowOverflow) {\n return;\n }\n }\n return result;\n }\n }]);\n}();\n/**\r\n * Matches `characters` against a pattern compiled into a `tree`.\r\n * @param {string[]} characters\r\n * @param {Tree} tree — A pattern compiled into a `tree`. See the `*.d.ts` file for the description of the `tree` structure.\r\n * @param {boolean} last — Whether it's the last (rightmost) subtree on its level of the match tree.\r\n * @return {object} See the `*.d.ts` file for the description of the result object.\r\n */\nexport { PatternMatcher as default };\nfunction _match(characters, tree, last) {\n // If `tree` is a string, then `tree` is a single character.\n // That's because when a pattern is parsed, multi-character-string parts\n // of a pattern are compiled into arrays of single characters.\n // I still wrote this piece of code for a \"general\" hypothetical case\n // when `tree` could be a string of several characters, even though\n // such case is not possible with the current implementation.\n if (typeof tree === 'string') {\n var characterString = characters.join('');\n if (tree.indexOf(characterString) === 0) {\n // `tree` is always a single character.\n // If `tree.indexOf(characterString) === 0`\n // then `characters.length === tree.length`.\n /* istanbul ignore else */\n if (characters.length === tree.length) {\n return {\n match: true,\n matchedChars: characters\n };\n }\n // `tree` is always a single character.\n // If `tree.indexOf(characterString) === 0`\n // then `characters.length === tree.length`.\n /* istanbul ignore next */\n return {\n partialMatch: true\n // matchedChars: characters\n };\n }\n if (characterString.indexOf(tree) === 0) {\n if (last) {\n // The `else` path is not possible because `tree` is always a single character.\n // The `else` case for `characters.length > tree.length` would be\n // `characters.length <= tree.length` which means `characters.length <= 1`.\n // `characters` array can't be empty, so that means `characters === [tree]`,\n // which would also mean `tree.indexOf(characterString) === 0` and that'd mean\n // that the `if (tree.indexOf(characterString) === 0)` condition before this\n // `if` condition would be entered, and returned from there, not reaching this code.\n /* istanbul ignore else */\n if (characters.length > tree.length) {\n return {\n overflow: true\n };\n }\n }\n return {\n match: true,\n matchedChars: characters.slice(0, tree.length)\n };\n }\n return;\n }\n if (Array.isArray(tree)) {\n var restCharacters = characters.slice();\n var i = 0;\n while (i < tree.length) {\n var subtree = tree[i];\n var result = _match(restCharacters, subtree, last && i === tree.length - 1);\n if (!result) {\n return;\n } else if (result.overflow) {\n return result;\n } else if (result.match) {\n // Continue with the next subtree with the rest of the characters.\n restCharacters = restCharacters.slice(result.matchedChars.length);\n if (restCharacters.length === 0) {\n if (i === tree.length - 1) {\n return {\n match: true,\n matchedChars: characters\n };\n } else {\n return {\n partialMatch: true\n // matchedChars: characters\n };\n }\n }\n } else {\n /* istanbul ignore else */\n if (result.partialMatch) {\n return {\n partialMatch: true\n // matchedChars: characters\n };\n } else {\n throw new Error(\"Unsupported match result:\\n\".concat(JSON.stringify(result, null, 2)));\n }\n }\n i++;\n }\n // If `last` then overflow has already been checked\n // by the last element of the `tree` array.\n /* istanbul ignore if */\n if (last) {\n return {\n overflow: true\n };\n }\n return {\n match: true,\n matchedChars: characters.slice(0, characters.length - restCharacters.length)\n };\n }\n switch (tree.op) {\n case '|':\n var partialMatch;\n for (var _iterator = _createForOfIteratorHelperLoose(tree.args), _step; !(_step = _iterator()).done;) {\n var branch = _step.value;\n var _result = _match(characters, branch, last);\n if (_result) {\n if (_result.overflow) {\n return _result;\n } else if (_result.match) {\n return {\n match: true,\n matchedChars: _result.matchedChars\n };\n } else {\n /* istanbul ignore else */\n if (_result.partialMatch) {\n partialMatch = true;\n } else {\n throw new Error(\"Unsupported match result:\\n\".concat(JSON.stringify(_result, null, 2)));\n }\n }\n }\n }\n if (partialMatch) {\n return {\n partialMatch: true\n // matchedChars: ...\n };\n }\n // Not even a partial match.\n return;\n case '[]':\n for (var _iterator2 = _createForOfIteratorHelperLoose(tree.args), _step2; !(_step2 = _iterator2()).done;) {\n var _char = _step2.value;\n if (characters[0] === _char) {\n if (characters.length === 1) {\n return {\n match: true,\n matchedChars: characters\n };\n }\n if (last) {\n return {\n overflow: true\n };\n }\n return {\n match: true,\n matchedChars: [_char]\n };\n }\n }\n // No character matches.\n return;\n\n /* istanbul ignore next */\n default:\n throw new Error(\"Unsupported instruction tree: \".concat(tree));\n }\n}\n//# sourceMappingURL=AsYouTypeFormatter.PatternMatcher.js.map","function _typeof(o) { \"@babel/helpers - typeof\"; return _typeof = \"function\" == typeof Symbol && \"symbol\" == typeof Symbol.iterator ? function (o) { return typeof o; } : function (o) { return o && \"function\" == typeof Symbol && o.constructor === Symbol && o !== Symbol.prototype ? \"symbol\" : typeof o; }, _typeof(o); }\nfunction _createForOfIteratorHelperLoose(r, e) { var t = \"undefined\" != typeof Symbol && r[Symbol.iterator] || r[\"@@iterator\"]; if (t) return (t = t.call(r)).next.bind(t); if (Array.isArray(r) || (t = _unsupportedIterableToArray(r)) || e && r && \"number\" == typeof r.length) { t && (r = t); var o = 0; return function () { return o >= r.length ? { done: !0 } : { done: !1, value: r[o++] }; }; } throw new TypeError(\"Invalid attempt to iterate non-iterable instance.\\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.\"); }\nfunction _unsupportedIterableToArray(r, a) { if (r) { if (\"string\" == typeof r) return _arrayLikeToArray(r, a); var t = {}.toString.call(r).slice(8, -1); return \"Object\" === t && r.constructor && (t = r.constructor.name), \"Map\" === t || \"Set\" === t ? Array.from(r) : \"Arguments\" === t || /^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(t) ? _arrayLikeToArray(r, a) : void 0; } }\nfunction _arrayLikeToArray(r, a) { (null == a || a > r.length) && (a = r.length); for (var e = 0, n = Array(a); e < a; e++) n[e] = r[e]; return n; }\nfunction _classCallCheck(a, n) { if (!(a instanceof n)) throw new TypeError(\"Cannot call a class as a function\"); }\nfunction _defineProperties(e, r) { for (var t = 0; t < r.length; t++) { var o = r[t]; o.enumerable = o.enumerable || !1, o.configurable = !0, \"value\" in o && (o.writable = !0), Object.defineProperty(e, _toPropertyKey(o.key), o); } }\nfunction _createClass(e, r, t) { return r && _defineProperties(e.prototype, r), t && _defineProperties(e, t), Object.defineProperty(e, \"prototype\", { writable: !1 }), e; }\nfunction _toPropertyKey(t) { var i = _toPrimitive(t, \"string\"); return \"symbol\" == _typeof(i) ? i : i + \"\"; }\nfunction _toPrimitive(t, r) { if (\"object\" != _typeof(t) || !t) return t; var e = t[Symbol.toPrimitive]; if (void 0 !== e) { var i = e.call(t, r || \"default\"); if (\"object\" != _typeof(i)) return i; throw new TypeError(\"@@toPrimitive must return a primitive value.\"); } return (\"string\" === r ? String : Number)(t); }\nimport { DIGIT_PLACEHOLDER, countOccurences, repeat, cutAndStripNonPairedParens, closeNonPairedParens, stripNonPairedParens, populateTemplateWithDigits } from './AsYouTypeFormatter.util.js';\nimport formatCompleteNumber, { canFormatCompleteNumber } from './AsYouTypeFormatter.complete.js';\nimport PatternMatcher from './AsYouTypeFormatter.PatternMatcher.js';\nimport parseDigits from './helpers/parseDigits.js';\nexport { DIGIT_PLACEHOLDER } from './AsYouTypeFormatter.util.js';\nimport { FIRST_GROUP_PATTERN } from './helpers/formatNationalNumberUsingFormat.js';\nimport { VALID_PUNCTUATION } from './constants.js';\nimport applyInternationalSeparatorStyle from './helpers/applyInternationalSeparatorStyle.js';\n\n// Used in phone number format template creation.\n// Could be any digit, I guess.\nvar DUMMY_DIGIT = '9';\n// I don't know why is it exactly `15`\nvar LONGEST_NATIONAL_PHONE_NUMBER_LENGTH = 15;\n// Create a phone number consisting only of the digit 9 that matches the\n// `number_pattern` by applying the pattern to the \"longest phone number\" string.\nvar LONGEST_DUMMY_PHONE_NUMBER = repeat(DUMMY_DIGIT, LONGEST_NATIONAL_PHONE_NUMBER_LENGTH);\n\n// A set of characters that, if found in a national prefix formatting rules, are an indicator to\n// us that we should separate the national prefix from the number when formatting.\nvar NATIONAL_PREFIX_SEPARATORS_PATTERN = /[- ]/;\n\n// Deprecated: Google has removed some formatting pattern related code from their repo.\n// https://github.com/googlei18n/libphonenumber/commit/a395b4fef3caf57c4bc5f082e1152a4d2bd0ba4c\n// \"We no longer have numbers in formatting matching patterns, only \\d.\"\n// Because this library supports generating custom metadata\n// some users may still be using old metadata so the relevant\n// code seems to stay until some next major version update.\nvar SUPPORT_LEGACY_FORMATTING_PATTERNS = true;\n\n// A pattern that is used to match character classes in regular expressions.\n// An example of a character class is \"[1-4]\".\nvar CREATE_CHARACTER_CLASS_PATTERN = SUPPORT_LEGACY_FORMATTING_PATTERNS && function () {\n return /\\[([^\\[\\]])*\\]/g;\n};\n\n// Any digit in a regular expression that actually denotes a digit. For\n// example, in the regular expression \"80[0-2]\\d{6,10}\", the first 2 digits\n// (8 and 0) are standalone digits, but the rest are not.\n// Two look-aheads are needed because the number following \\\\d could be a\n// two-digit number, since the phone number can be as long as 15 digits.\nvar CREATE_STANDALONE_DIGIT_PATTERN = SUPPORT_LEGACY_FORMATTING_PATTERNS && function () {\n return /\\d(?=[^,}][^,}])/g;\n};\n\n// A regular expression that is used to determine if a `format` is\n// suitable to be used in the \"as you type formatter\".\n// A `format` is suitable when the resulting formatted number has\n// the same digits as the user has entered.\n//\n// In the simplest case, that would mean that the format\n// doesn't add any additional digits when formatting a number.\n// Google says that it also shouldn't add \"star\" (`*`) characters,\n// like it does in some Israeli formats.\n// Such basic format would only contain \"valid punctuation\"\n// and \"captured group\" identifiers ($1, $2, etc).\n//\n// An example of a format that adds additional digits:\n//\n// Country: `AR` (Argentina).\n// Format:\n// {\n// \"pattern\": \"(\\\\d)(\\\\d{2})(\\\\d{4})(\\\\d{4})\",\n// \"leading_digits_patterns\": [\"91\"],\n// \"national_prefix_formatting_rule\": \"0$1\",\n// \"format\": \"$2 15-$3-$4\",\n// \"international_format\": \"$1 $2 $3-$4\"\n// }\n//\n// In the format above, the `format` adds `15` to the digits when formatting a number.\n// A sidenote: this format actually is suitable because `national_prefix_for_parsing`\n// has previously removed `15` from a national number, so re-adding `15` in `format`\n// doesn't actually result in any extra digits added to user's input.\n// But verifying that would be a complex procedure, so the code chooses a simpler path:\n// it simply filters out all `format`s that contain anything but \"captured group\" ids.\n//\n// This regular expression is called `ELIGIBLE_FORMAT_PATTERN` in Google's\n// `libphonenumber` code.\n//\nvar NON_ALTERING_FORMAT_REG_EXP = new RegExp('[' + VALID_PUNCTUATION + ']*' +\n// Google developers say:\n// \"We require that the first matching group is present in the\n// output pattern to ensure no data is lost while formatting.\"\n'\\\\$1' + '[' + VALID_PUNCTUATION + ']*' + '(\\\\$\\\\d[' + VALID_PUNCTUATION + ']*)*' + '$');\n\n// This is the minimum length of the leading digits of a phone number\n// to guarantee the first \"leading digits pattern\" for a phone number format\n// to be preemptive.\nvar MIN_LEADING_DIGITS_LENGTH = 3;\nvar AsYouTypeFormatter = /*#__PURE__*/function () {\n function AsYouTypeFormatter(_ref) {\n var state = _ref.state,\n metadata = _ref.metadata;\n _classCallCheck(this, AsYouTypeFormatter);\n this.metadata = metadata;\n this.resetFormat();\n }\n return _createClass(AsYouTypeFormatter, [{\n key: \"resetFormat\",\n value: function resetFormat() {\n this.chosenFormat = undefined;\n this.template = undefined;\n this.nationalNumberTemplate = undefined;\n this.populatedNationalNumberTemplate = undefined;\n this.populatedNationalNumberTemplatePosition = -1;\n }\n }, {\n key: \"reset\",\n value: function reset(numberingPlan, state) {\n this.resetFormat();\n if (numberingPlan) {\n this.isNANP = numberingPlan.callingCode() === '1';\n this.matchingFormats = numberingPlan.formats();\n if (state.nationalSignificantNumber) {\n this.narrowDownMatchingFormats(state);\n }\n } else {\n this.isNANP = undefined;\n this.matchingFormats = [];\n }\n }\n\n /**\r\n * Formats an updated phone number.\r\n * @param {string} nextDigits — Additional phone number digits.\r\n * @param {object} state — `AsYouType` state.\r\n * @return {[string]} Returns undefined if the updated phone number can't be formatted using any of the available formats.\r\n */\n }, {\n key: \"format\",\n value: function format(nextDigits, state) {\n var _this = this;\n // See if the phone number digits can be formatted as a complete phone number.\n // If not, use the results from `formatNationalNumberWithNextDigits()`,\n // which formats based on the chosen formatting pattern.\n //\n // Attempting to format complete phone number first is how it's done\n // in Google's `libphonenumber`, so this library just follows it.\n // Google's `libphonenumber` code doesn't explain in detail why does it\n // attempt to format digits as a complete phone number\n // instead of just going with a previoulsy (or newly) chosen `format`:\n //\n // \"Checks to see if there is an exact pattern match for these digits.\n // If so, we should use this instead of any other formatting template\n // whose leadingDigitsPattern also matches the input.\"\n //\n if (canFormatCompleteNumber(state.nationalSignificantNumber, this.metadata)) {\n for (var _iterator = _createForOfIteratorHelperLoose(this.matchingFormats), _step; !(_step = _iterator()).done;) {\n var _format = _step.value;\n var formattedCompleteNumber = formatCompleteNumber(state, _format, {\n metadata: this.metadata,\n shouldTryNationalPrefixFormattingRule: function shouldTryNationalPrefixFormattingRule(format) {\n return _this.shouldTryNationalPrefixFormattingRule(format, {\n international: state.international,\n nationalPrefix: state.nationalPrefix\n });\n },\n getSeparatorAfterNationalPrefix: function getSeparatorAfterNationalPrefix(format) {\n return _this.getSeparatorAfterNationalPrefix(format);\n }\n });\n if (formattedCompleteNumber) {\n this.resetFormat();\n this.chosenFormat = _format;\n this.setNationalNumberTemplate(formattedCompleteNumber.replace(/\\d/g, DIGIT_PLACEHOLDER), state);\n this.populatedNationalNumberTemplate = formattedCompleteNumber;\n // With a new formatting template, the matched position\n // using the old template needs to be reset.\n this.populatedNationalNumberTemplatePosition = this.template.lastIndexOf(DIGIT_PLACEHOLDER);\n return formattedCompleteNumber;\n }\n }\n }\n // Format the digits as a partial (incomplete) phone number\n // using the previously chosen formatting pattern (or a newly chosen one).\n return this.formatNationalNumberWithNextDigits(nextDigits, state);\n }\n\n // Formats the next phone number digits.\n }, {\n key: \"formatNationalNumberWithNextDigits\",\n value: function formatNationalNumberWithNextDigits(nextDigits, state) {\n var previouslyChosenFormat = this.chosenFormat;\n\n // Choose a format from the list of matching ones.\n var newlyChosenFormat = this.chooseFormat(state);\n if (newlyChosenFormat) {\n if (newlyChosenFormat === previouslyChosenFormat) {\n // If it can format the next (current) digits\n // using the previously chosen phone number format\n // then return the updated formatted number.\n return this.formatNextNationalNumberDigits(nextDigits);\n } else {\n // If a more appropriate phone number format\n // has been chosen for these \"leading digits\",\n // then re-format the national phone number part\n // using the newly selected format.\n return this.formatNextNationalNumberDigits(state.getNationalDigits());\n }\n }\n }\n }, {\n key: \"narrowDownMatchingFormats\",\n value: function narrowDownMatchingFormats(_ref2) {\n var _this2 = this;\n var nationalSignificantNumber = _ref2.nationalSignificantNumber,\n nationalPrefix = _ref2.nationalPrefix,\n international = _ref2.international;\n var leadingDigits = nationalSignificantNumber;\n\n // \"leading digits\" pattern list starts with a\n // \"leading digits\" pattern fitting a maximum of 3 leading digits.\n // So, after a user inputs 3 digits of a national (significant) phone number\n // this national (significant) number can already be formatted.\n // The next \"leading digits\" pattern is for 4 leading digits max,\n // and the \"leading digits\" pattern after it is for 5 leading digits max, etc.\n\n // This implementation is different from Google's\n // in that it searches for a fitting format\n // even if the user has entered less than\n // `MIN_LEADING_DIGITS_LENGTH` digits of a national number.\n // Because some leading digit patterns already match for a single first digit.\n var leadingDigitsPatternIndex = leadingDigits.length - MIN_LEADING_DIGITS_LENGTH;\n if (leadingDigitsPatternIndex < 0) {\n leadingDigitsPatternIndex = 0;\n }\n this.matchingFormats = this.matchingFormats.filter(function (format) {\n return _this2.formatSuits(format, international, nationalPrefix) && _this2.formatMatches(format, leadingDigits, leadingDigitsPatternIndex);\n });\n\n // If there was a phone number format chosen\n // and it no longer holds given the new leading digits then reset it.\n // The test for this `if` condition is marked as:\n // \"Reset a chosen format when it no longer holds given the new leading digits\".\n // To construct a valid test case for this one can find a country\n // in `PhoneNumberMetadata.xml` yielding one format for 3 `<leadingDigits>`\n // and yielding another format for 4 `<leadingDigits>` (Australia in this case).\n if (this.chosenFormat && this.matchingFormats.indexOf(this.chosenFormat) === -1) {\n this.resetFormat();\n }\n }\n }, {\n key: \"formatSuits\",\n value: function formatSuits(format, international, nationalPrefix) {\n // When a prefix before a national (significant) number is\n // simply a national prefix, then it's parsed as `this.nationalPrefix`.\n // In more complex cases, a prefix before national (significant) number\n // could include a national prefix as well as some \"capturing groups\",\n // and in that case there's no info whether a national prefix has been parsed.\n // If national prefix is not used when formatting a phone number\n // using this format, but a national prefix has been entered by the user,\n // and was extracted, then discard such phone number format.\n // In Google's \"AsYouType\" formatter code, the equivalent would be this part:\n // https://github.com/google/libphonenumber/blob/0a45cfd96e71cad8edb0e162a70fcc8bd9728933/java/libphonenumber/src/com/google/i18n/phonenumbers/AsYouTypeFormatter.java#L175-L184\n if (nationalPrefix && !format.usesNationalPrefix() &&\n // !format.domesticCarrierCodeFormattingRule() &&\n !format.nationalPrefixIsOptionalWhenFormattingInNationalFormat()) {\n return false;\n }\n // If national prefix is mandatory for this phone number format\n // and there're no guarantees that a national prefix is present in user input\n // then discard this phone number format as not suitable.\n // In Google's \"AsYouType\" formatter code, the equivalent would be this part:\n // https://github.com/google/libphonenumber/blob/0a45cfd96e71cad8edb0e162a70fcc8bd9728933/java/libphonenumber/src/com/google/i18n/phonenumbers/AsYouTypeFormatter.java#L185-L193\n if (!international && !nationalPrefix && format.nationalPrefixIsMandatoryWhenFormattingInNationalFormat()) {\n return false;\n }\n return true;\n }\n }, {\n key: \"formatMatches\",\n value: function formatMatches(format, leadingDigits, leadingDigitsPatternIndex) {\n var leadingDigitsPatternsCount = format.leadingDigitsPatterns().length;\n\n // If this format is not restricted to a certain\n // leading digits pattern then it fits.\n // The test case could be found by searching for \"leadingDigitsPatternsCount === 0\".\n if (leadingDigitsPatternsCount === 0) {\n return true;\n }\n\n // Start narrowing down the list of possible formats based on the leading digits.\n // (only previously matched formats take part in the narrowing down process)\n\n // `leading_digits_patterns` start with 3 digits min\n // and then go up from there one digit at a time.\n leadingDigitsPatternIndex = Math.min(leadingDigitsPatternIndex, leadingDigitsPatternsCount - 1);\n var leadingDigitsPattern = format.leadingDigitsPatterns()[leadingDigitsPatternIndex];\n\n // Google imposes a requirement on the leading digits\n // to be minimum 3 digits long in order to be eligible\n // for checking those with a leading digits pattern.\n //\n // Since `leading_digits_patterns` start with 3 digits min,\n // Google's original `libphonenumber` library only starts\n // excluding any non-matching formats only when the\n // national number entered so far is at least 3 digits long,\n // otherwise format matching would give false negatives.\n //\n // For example, when the digits entered so far are `2`\n // and the leading digits pattern is `21` –\n // it's quite obvious in this case that the format could be the one\n // but due to the absence of further digits it would give false negative.\n //\n // Also, `leading_digits_patterns` doesn't always correspond to a single\n // digits count. For example, `60|8` pattern would already match `8`\n // but the `60` part would require having at least two leading digits,\n // so the whole pattern would require inputting two digits first in order to\n // decide on whether it matches the input, even when the input is \"80\".\n //\n // This library — `libphonenumber-js` — allows filtering by `leading_digits_patterns`\n // even when there's only 1 or 2 digits of the national (significant) number.\n // To do that, it uses a non-strict pattern matcher written specifically for that.\n //\n if (leadingDigits.length < MIN_LEADING_DIGITS_LENGTH) {\n // Before leading digits < 3 matching was implemented:\n // return true\n //\n // After leading digits < 3 matching was implemented:\n try {\n return new PatternMatcher(leadingDigitsPattern).match(leadingDigits, {\n allowOverflow: true\n }) !== undefined;\n } catch (error) /* istanbul ignore next */{\n // There's a slight possibility that there could be some undiscovered bug\n // in the pattern matcher code. Since the \"leading digits < 3 matching\"\n // feature is not \"essential\" for operation, it can fall back to the old way\n // in case of any issues rather than halting the application's execution.\n console.error(error);\n return true;\n }\n }\n\n // If at least `MIN_LEADING_DIGITS_LENGTH` digits of a national number are\n // available then use the usual regular expression matching.\n //\n // The whole pattern is wrapped in round brackets (`()`) because\n // the pattern can use \"or\" operator (`|`) at the top level of the pattern.\n //\n return new RegExp(\"^(\".concat(leadingDigitsPattern, \")\")).test(leadingDigits);\n }\n }, {\n key: \"getFormatFormat\",\n value: function getFormatFormat(format, international) {\n return international ? format.internationalFormat() : format.format();\n }\n }, {\n key: \"chooseFormat\",\n value: function chooseFormat(state) {\n var _this3 = this;\n var _loop = function _loop() {\n var format = _step2.value;\n // If this format is currently being used\n // and is still suitable, then stick to it.\n if (_this3.chosenFormat === format) {\n return 0; // break\n }\n // Sometimes, a formatting rule inserts additional digits in a phone number,\n // and \"as you type\" formatter can't do that: it should only use the digits\n // that the user has input.\n //\n // For example, in Argentina, there's a format for mobile phone numbers:\n //\n // {\n // \"pattern\": \"(\\\\d)(\\\\d{2})(\\\\d{4})(\\\\d{4})\",\n // \"leading_digits_patterns\": [\"91\"],\n // \"national_prefix_formatting_rule\": \"0$1\",\n // \"format\": \"$2 15-$3-$4\",\n // \"international_format\": \"$1 $2 $3-$4\"\n // }\n //\n // In that format, `international_format` is used instead of `format`\n // because `format` inserts `15` in the formatted number,\n // and `AsYouType` formatter should only use the digits\n // the user has actually input, without adding any extra digits.\n // In this case, it wouldn't make a difference, because the `15`\n // is first stripped when applying `national_prefix_for_parsing`\n // and then re-added when using `format`, so in reality it doesn't\n // add any new digits to the number, but to detect that, the code\n // would have to be more complex: it would have to try formatting\n // the digits using the format and then see if any digits have\n // actually been added or removed, and then, every time a new digit\n // is input, it should re-check whether the chosen format doesn't\n // alter the digits.\n //\n // Google's code doesn't go that far, and so does this library:\n // it simply requires that a `format` doesn't add any additonal\n // digits to user's input.\n //\n // Also, people in general should move from inputting phone numbers\n // in national format (possibly with national prefixes)\n // and use international phone number format instead:\n // it's a logical thing in the modern age of mobile phones,\n // globalization and the internet.\n //\n /* istanbul ignore if */\n if (!NON_ALTERING_FORMAT_REG_EXP.test(_this3.getFormatFormat(format, state.international))) {\n return 1; // continue\n }\n if (!_this3.createTemplateForFormat(format, state)) {\n // Remove the format if it can't generate a template.\n _this3.matchingFormats = _this3.matchingFormats.filter(function (_) {\n return _ !== format;\n });\n return 1; // continue\n }\n _this3.chosenFormat = format;\n return 0; // break\n },\n _ret;\n // When there are multiple available formats, the formatter uses the first\n // format where a formatting template could be created.\n //\n // For some weird reason, `istanbul` says \"else path not taken\"\n // for the `for of` line below. Supposedly that means that\n // the loop doesn't ever go over the last element in the list.\n // That's true because there always is `this.chosenFormat`\n // when `this.matchingFormats` is non-empty.\n // And, for some weird reason, it doesn't think that the case\n // with empty `this.matchingFormats` qualifies for a valid \"else\" path.\n // So simply muting this `istanbul` warning.\n // It doesn't skip the contents of the `for of` loop,\n // it just skips the `for of` line.\n //\n /* istanbul ignore next */\n for (var _iterator2 = _createForOfIteratorHelperLoose(this.matchingFormats.slice()), _step2; !(_step2 = _iterator2()).done;) {\n _ret = _loop();\n if (_ret === 0) break;\n if (_ret === 1) continue;\n }\n if (!this.chosenFormat) {\n // No format matches the national (significant) phone number.\n this.resetFormat();\n }\n return this.chosenFormat;\n }\n }, {\n key: \"createTemplateForFormat\",\n value: function createTemplateForFormat(format, state) {\n // The formatter doesn't format numbers when numberPattern contains '|', e.g.\n // (20|3)\\d{4}. In those cases we quickly return.\n // (Though there's no such format in current metadata)\n /* istanbul ignore if */\n if (SUPPORT_LEGACY_FORMATTING_PATTERNS && format.pattern().indexOf('|') >= 0) {\n return;\n }\n // Get formatting template for this phone number format\n var template = this.getTemplateForFormat(format, state);\n // If the national number entered is too long\n // for any phone number format, then abort.\n if (template) {\n this.setNationalNumberTemplate(template, state);\n return true;\n }\n }\n }, {\n key: \"getSeparatorAfterNationalPrefix\",\n value: function getSeparatorAfterNationalPrefix(format) {\n // `US` metadata doesn't have a `national_prefix_formatting_rule`,\n // so the `if` condition below doesn't apply to `US`,\n // but in reality there shoudl be a separator\n // between a national prefix and a national (significant) number.\n // So `US` national prefix separator is a \"special\" \"hardcoded\" case.\n if (this.isNANP) {\n return ' ';\n }\n // If a `format` has a `national_prefix_formatting_rule`\n // and that rule has a separator after a national prefix,\n // then it means that there should be a separator\n // between a national prefix and a national (significant) number.\n if (format && format.nationalPrefixFormattingRule() && NATIONAL_PREFIX_SEPARATORS_PATTERN.test(format.nationalPrefixFormattingRule())) {\n return ' ';\n }\n // At this point, there seems to be no clear evidence that\n // there should be a separator between a national prefix\n // and a national (significant) number. So don't insert one.\n return '';\n }\n }, {\n key: \"getInternationalPrefixBeforeCountryCallingCode\",\n value: function getInternationalPrefixBeforeCountryCallingCode(_ref3, options) {\n var IDDPrefix = _ref3.IDDPrefix,\n missingPlus = _ref3.missingPlus;\n if (IDDPrefix) {\n return options && options.spacing === false ? IDDPrefix : IDDPrefix + ' ';\n }\n if (missingPlus) {\n return '';\n }\n return '+';\n }\n }, {\n key: \"getTemplate\",\n value: function getTemplate(state) {\n if (!this.template) {\n return;\n }\n // `this.template` holds the template for a \"complete\" phone number.\n // The currently entered phone number is most likely not \"complete\",\n // so trim all non-populated digits.\n var index = -1;\n var i = 0;\n var internationalPrefix = state.international ? this.getInternationalPrefixBeforeCountryCallingCode(state, {\n spacing: false\n }) : '';\n while (i < internationalPrefix.length + state.getDigitsWithoutInternationalPrefix().length) {\n index = this.template.indexOf(DIGIT_PLACEHOLDER, index + 1);\n i++;\n }\n return cutAndStripNonPairedParens(this.template, index + 1);\n }\n }, {\n key: \"setNationalNumberTemplate\",\n value: function setNationalNumberTemplate(template, state) {\n this.nationalNumberTemplate = template;\n this.populatedNationalNumberTemplate = template;\n // With a new formatting template, the matched position\n // using the old template needs to be reset.\n this.populatedNationalNumberTemplatePosition = -1;\n // For convenience, the public `.template` property\n // contains the whole international number\n // if the phone number being input is international:\n // 'x' for the '+' sign, 'x'es for the country phone code,\n // a spacebar and then the template for the formatted national number.\n if (state.international) {\n this.template = this.getInternationalPrefixBeforeCountryCallingCode(state).replace(/[\\d\\+]/g, DIGIT_PLACEHOLDER) + repeat(DIGIT_PLACEHOLDER, state.callingCode.length) + ' ' + template;\n } else {\n this.template = template;\n }\n }\n\n /**\r\n * Generates formatting template for a national phone number,\r\n * optionally containing a national prefix, for a format.\r\n * @param {Format} format\r\n * @param {string} nationalPrefix\r\n * @return {string}\r\n */\n }, {\n key: \"getTemplateForFormat\",\n value: function getTemplateForFormat(format, _ref4) {\n var nationalSignificantNumber = _ref4.nationalSignificantNumber,\n international = _ref4.international,\n nationalPrefix = _ref4.nationalPrefix,\n prefixBeforeNationalSignificantNumberThatIsNotNationalPrefix = _ref4.prefixBeforeNationalSignificantNumberThatIsNotNationalPrefix;\n var pattern = format.pattern();\n\n /* istanbul ignore else */\n if (SUPPORT_LEGACY_FORMATTING_PATTERNS) {\n pattern = pattern\n // Replace anything in the form of [..] with \\d\n .replace(CREATE_CHARACTER_CLASS_PATTERN(), '\\\\d')\n // Replace any standalone digit (not the one in `{}`) with \\d\n .replace(CREATE_STANDALONE_DIGIT_PATTERN(), '\\\\d');\n }\n\n // Generate a dummy national number (consisting of `9`s)\n // that fits this format's `pattern`.\n //\n // This match will always succeed,\n // because the \"longest dummy phone number\"\n // has enough length to accomodate any possible\n // national phone number format pattern.\n //\n var digits = LONGEST_DUMMY_PHONE_NUMBER.match(pattern)[0];\n\n // If the national number entered is too long\n // for any phone number format, then abort.\n if (nationalSignificantNumber.length > digits.length) {\n return;\n }\n\n // Get a formatting template which can be used to efficiently format\n // a partial number where digits are added one by one.\n\n // Below `strictPattern` is used for the\n // regular expression (with `^` and `$`).\n // This wasn't originally in Google's `libphonenumber`\n // and I guess they don't really need it\n // because they're not using \"templates\" to format phone numbers\n // but I added `strictPattern` after encountering\n // South Korean phone number formatting bug.\n //\n // Non-strict regular expression bug demonstration:\n //\n // this.nationalSignificantNumber : `111111111` (9 digits)\n //\n // pattern : (\\d{2})(\\d{3,4})(\\d{4})\n // format : `$1 $2 $3`\n // digits : `9999999999` (10 digits)\n //\n // '9999999999'.replace(new RegExp(/(\\d{2})(\\d{3,4})(\\d{4})/g), '$1 $2 $3') = \"99 9999 9999\"\n //\n // template : xx xxxx xxxx\n //\n // But the correct template in this case is `xx xxx xxxx`.\n // The template was generated incorrectly because of the\n // `{3,4}` variability in the `pattern`.\n //\n // The fix is, if `this.nationalSignificantNumber` has already sufficient length\n // to satisfy the `pattern` completely then `this.nationalSignificantNumber`\n // is used instead of `digits`.\n\n var strictPattern = new RegExp('^' + pattern + '$');\n var nationalNumberDummyDigits = nationalSignificantNumber.replace(/\\d/g, DUMMY_DIGIT);\n\n // If `this.nationalSignificantNumber` has already sufficient length\n // to satisfy the `pattern` completely then use it\n // instead of `digits`.\n if (strictPattern.test(nationalNumberDummyDigits)) {\n digits = nationalNumberDummyDigits;\n }\n var numberFormat = this.getFormatFormat(format, international);\n var nationalPrefixIncludedInTemplate;\n\n // If a user did input a national prefix (and that's guaranteed),\n // and if a `format` does have a national prefix formatting rule,\n // then see if that national prefix formatting rule\n // prepends exactly the same national prefix the user has input.\n // If that's the case, then use the `format` with the national prefix formatting rule.\n // Otherwise, use the `format` without the national prefix formatting rule,\n // and prepend a national prefix manually to it.\n if (this.shouldTryNationalPrefixFormattingRule(format, {\n international: international,\n nationalPrefix: nationalPrefix\n })) {\n var numberFormatWithNationalPrefix = numberFormat.replace(FIRST_GROUP_PATTERN, format.nationalPrefixFormattingRule());\n // If `national_prefix_formatting_rule` of a `format` simply prepends\n // national prefix at the start of a national (significant) number,\n // then such formatting can be used with `AsYouType` formatter.\n // There seems to be no `else` case: everywhere in metadata,\n // national prefix formatting rule is national prefix + $1,\n // or `($1)`, in which case such format isn't even considered\n // when the user has input a national prefix.\n /* istanbul ignore else */\n if (parseDigits(format.nationalPrefixFormattingRule()) === (nationalPrefix || '') + parseDigits('$1')) {\n numberFormat = numberFormatWithNationalPrefix;\n nationalPrefixIncludedInTemplate = true;\n // Replace all digits of the national prefix in the formatting template\n // with `DIGIT_PLACEHOLDER`s.\n if (nationalPrefix) {\n var i = nationalPrefix.length;\n while (i > 0) {\n numberFormat = numberFormat.replace(/\\d/, DIGIT_PLACEHOLDER);\n i--;\n }\n }\n }\n }\n\n // Generate formatting template for this phone number format.\n var template = digits\n // Format the dummy phone number according to the format.\n .replace(new RegExp(pattern), numberFormat)\n // Replace each dummy digit with a DIGIT_PLACEHOLDER.\n .replace(new RegExp(DUMMY_DIGIT, 'g'), DIGIT_PLACEHOLDER);\n\n // If a prefix of a national (significant) number is not as simple\n // as just a basic national prefix, then just prepend such prefix\n // before the national (significant) number, optionally spacing\n // the two with a whitespace.\n if (!nationalPrefixIncludedInTemplate) {\n if (prefixBeforeNationalSignificantNumberThatIsNotNationalPrefix) {\n // Prepend the prefix to the template manually.\n template = repeat(DIGIT_PLACEHOLDER, prefixBeforeNationalSignificantNumberThatIsNotNationalPrefix.length) + ' ' + template;\n } else if (nationalPrefix) {\n // Prepend national prefix to the template manually.\n template = repeat(DIGIT_PLACEHOLDER, nationalPrefix.length) + this.getSeparatorAfterNationalPrefix(format) + template;\n }\n }\n if (international) {\n template = applyInternationalSeparatorStyle(template);\n }\n return template;\n }\n }, {\n key: \"formatNextNationalNumberDigits\",\n value: function formatNextNationalNumberDigits(digits) {\n var result = populateTemplateWithDigits(this.populatedNationalNumberTemplate, this.populatedNationalNumberTemplatePosition, digits);\n if (!result) {\n // Reset the format.\n this.resetFormat();\n return;\n }\n this.populatedNationalNumberTemplate = result[0];\n this.populatedNationalNumberTemplatePosition = result[1];\n\n // Return the formatted phone number so far.\n return cutAndStripNonPairedParens(this.populatedNationalNumberTemplate, this.populatedNationalNumberTemplatePosition + 1);\n\n // The old way which was good for `input-format` but is not so good\n // for `react-phone-number-input`'s default input (`InputBasic`).\n // return closeNonPairedParens(this.populatedNationalNumberTemplate, this.populatedNationalNumberTemplatePosition + 1)\n // \t.replace(new RegExp(DIGIT_PLACEHOLDER, 'g'), ' ')\n }\n }, {\n key: \"shouldTryNationalPrefixFormattingRule\",\n value: function shouldTryNationalPrefixFormattingRule(format, _ref5) {\n var international = _ref5.international,\n nationalPrefix = _ref5.nationalPrefix;\n if (format.nationalPrefixFormattingRule()) {\n // In some countries, `national_prefix_formatting_rule` is `($1)`,\n // so it applies even if the user hasn't input a national prefix.\n // `format.usesNationalPrefix()` detects such cases.\n var usesNationalPrefix = format.usesNationalPrefix();\n if (usesNationalPrefix && nationalPrefix || !usesNationalPrefix && !international) {\n return true;\n }\n }\n }\n }]);\n}();\nexport { AsYouTypeFormatter as default };\n//# sourceMappingURL=AsYouTypeFormatter.js.map","function _typeof(o) { \"@babel/helpers - typeof\"; return _typeof = \"function\" == typeof Symbol && \"symbol\" == typeof Symbol.iterator ? function (o) { return typeof o; } : function (o) { return o && \"function\" == typeof Symbol && o.constructor === Symbol && o !== Symbol.prototype ? \"symbol\" : typeof o; }, _typeof(o); }\nfunction _slicedToArray(r, e) { return _arrayWithHoles(r) || _iterableToArrayLimit(r, e) || _unsupportedIterableToArray(r, e) || _nonIterableRest(); }\nfunction _nonIterableRest() { throw new TypeError(\"Invalid attempt to destructure non-iterable instance.\\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.\"); }\nfunction _unsupportedIterableToArray(r, a) { if (r) { if (\"string\" == typeof r) return _arrayLikeToArray(r, a); var t = {}.toString.call(r).slice(8, -1); return \"Object\" === t && r.constructor && (t = r.constructor.name), \"Map\" === t || \"Set\" === t ? Array.from(r) : \"Arguments\" === t || /^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(t) ? _arrayLikeToArray(r, a) : void 0; } }\nfunction _arrayLikeToArray(r, a) { (null == a || a > r.length) && (a = r.length); for (var e = 0, n = Array(a); e < a; e++) n[e] = r[e]; return n; }\nfunction _iterableToArrayLimit(r, l) { var t = null == r ? null : \"undefined\" != typeof Symbol && r[Symbol.iterator] || r[\"@@iterator\"]; if (null != t) { var e, n, i, u, a = [], f = !0, o = !1; try { if (i = (t = t.call(r)).next, 0 === l) { if (Object(t) !== t) return; f = !1; } else for (; !(f = (e = i.call(t)).done) && (a.push(e.value), a.length !== l); f = !0); } catch (r) { o = !0, n = r; } finally { try { if (!f && null != t[\"return\"] && (u = t[\"return\"](), Object(u) !== u)) return; } finally { if (o) throw n; } } return a; } }\nfunction _arrayWithHoles(r) { if (Array.isArray(r)) return r; }\nfunction _classCallCheck(a, n) { if (!(a instanceof n)) throw new TypeError(\"Cannot call a class as a function\"); }\nfunction _defineProperties(e, r) { for (var t = 0; t < r.length; t++) { var o = r[t]; o.enumerable = o.enumerable || !1, o.configurable = !0, \"value\" in o && (o.writable = !0), Object.defineProperty(e, _toPropertyKey(o.key), o); } }\nfunction _createClass(e, r, t) { return r && _defineProperties(e.prototype, r), t && _defineProperties(e, t), Object.defineProperty(e, \"prototype\", { writable: !1 }), e; }\nfunction _toPropertyKey(t) { var i = _toPrimitive(t, \"string\"); return \"symbol\" == _typeof(i) ? i : i + \"\"; }\nfunction _toPrimitive(t, r) { if (\"object\" != _typeof(t) || !t) return t; var e = t[Symbol.toPrimitive]; if (void 0 !== e) { var i = e.call(t, r || \"default\"); if (\"object\" != _typeof(i)) return i; throw new TypeError(\"@@toPrimitive must return a primitive value.\"); } return (\"string\" === r ? String : Number)(t); }\nimport _extractCountryCallingCode from './helpers/extractCountryCallingCode.js';\nimport extractCountryCallingCodeFromInternationalNumberWithoutPlusSign from './helpers/extractCountryCallingCodeFromInternationalNumberWithoutPlusSign.js';\nimport extractNationalNumberFromPossiblyIncompleteNumber from './helpers/extractNationalNumberFromPossiblyIncompleteNumber.js';\nimport stripIddPrefix from './helpers/stripIddPrefix.js';\nimport parseDigits from './helpers/parseDigits.js';\nimport { VALID_DIGITS, VALID_PUNCTUATION, PLUS_CHARS } from './constants.js';\nvar VALID_FORMATTED_PHONE_NUMBER_DIGITS_PART = '[' + VALID_PUNCTUATION + VALID_DIGITS + ']+';\nvar VALID_FORMATTED_PHONE_NUMBER_DIGITS_PART_PATTERN = new RegExp('^' + VALID_FORMATTED_PHONE_NUMBER_DIGITS_PART + '$', 'i');\nvar VALID_FORMATTED_PHONE_NUMBER_PART = '(?:' + '[' + PLUS_CHARS + ']' + '[' + VALID_PUNCTUATION + VALID_DIGITS + ']*' + '|' + '[' + VALID_PUNCTUATION + VALID_DIGITS + ']+' + ')';\nvar AFTER_PHONE_NUMBER_DIGITS_END_PATTERN = new RegExp('[^' + VALID_PUNCTUATION + VALID_DIGITS + ']+' + '.*' + '$');\n\n// Tests whether `national_prefix_for_parsing` could match\n// different national prefixes.\n// Matches anything that's not a digit or a square bracket.\nvar COMPLEX_NATIONAL_PREFIX = /[^\\d\\[\\]]/;\nvar AsYouTypeParser = /*#__PURE__*/function () {\n function AsYouTypeParser(_ref) {\n var defaultCountry = _ref.defaultCountry,\n defaultCallingCode = _ref.defaultCallingCode,\n metadata = _ref.metadata,\n onNationalSignificantNumberChange = _ref.onNationalSignificantNumberChange;\n _classCallCheck(this, AsYouTypeParser);\n this.defaultCountry = defaultCountry;\n this.defaultCallingCode = defaultCallingCode;\n this.metadata = metadata;\n this.onNationalSignificantNumberChange = onNationalSignificantNumberChange;\n }\n return _createClass(AsYouTypeParser, [{\n key: \"input\",\n value: function input(text, state) {\n var _extractFormattedDigi = extractFormattedDigitsAndPlus(text),\n _extractFormattedDigi2 = _slicedToArray(_extractFormattedDigi, 2),\n formattedDigits = _extractFormattedDigi2[0],\n hasPlus = _extractFormattedDigi2[1];\n var digits = parseDigits(formattedDigits);\n // Checks for a special case: just a leading `+` has been entered.\n var justLeadingPlus;\n if (hasPlus) {\n if (!state.digits) {\n state.startInternationalNumber(undefined, undefined);\n if (!digits) {\n justLeadingPlus = true;\n }\n }\n }\n if (digits) {\n this.inputDigits(digits, state);\n }\n return {\n digits: digits,\n justLeadingPlus: justLeadingPlus\n };\n }\n\n /**\r\n * Inputs \"next\" phone number digits.\r\n * @param {string} digits\r\n * @return {string} [formattedNumber] Formatted national phone number (if it can be formatted at this stage). Returning `undefined` means \"don't format the national phone number at this stage\".\r\n */\n }, {\n key: \"inputDigits\",\n value: function inputDigits(nextDigits, state) {\n var digits = state.digits;\n var hasReceivedThreeLeadingDigits = digits.length < 3 && digits.length + nextDigits.length >= 3;\n\n // Append phone number digits.\n state.appendDigits(nextDigits);\n\n // Attempt to extract IDD prefix:\n // Some users input their phone number in international format,\n // but in an \"out-of-country\" dialing format instead of using the leading `+`.\n // https://github.com/catamphetamine/libphonenumber-js/issues/185\n // Detect such numbers as soon as there're at least 3 digits.\n // Google's library attempts to extract IDD prefix at 3 digits,\n // so this library just copies that behavior.\n // I guess that's because the most commot IDD prefixes are\n // `00` (Europe) and `011` (US).\n // There exist really long IDD prefixes too:\n // for example, in Australia the default IDD prefix is `0011`,\n // and it could even be as long as `14880011`.\n // An IDD prefix is extracted here, and then every time when\n // there's a new digit and the number couldn't be formatted.\n if (hasReceivedThreeLeadingDigits) {\n this.extractIddPrefix(state);\n }\n if (this.isWaitingForCountryCallingCode(state)) {\n if (!this.extractCountryCallingCode(state)) {\n return;\n }\n } else {\n state.appendNationalSignificantNumberDigits(nextDigits);\n }\n\n // If a phone number is being input in international format,\n // then it's not valid for it to have a national prefix.\n // Still, some people incorrectly input such numbers with a national prefix.\n // In such cases, only attempt to strip a national prefix if the number becomes too long.\n // (but that is done later, not here)\n if (!state.international) {\n if (!this.hasExtractedNationalSignificantNumber) {\n this.extractNationalSignificantNumber(state.getNationalDigits(), function (stateUpdate) {\n return state.update(stateUpdate);\n });\n }\n }\n }\n }, {\n key: \"isWaitingForCountryCallingCode\",\n value: function isWaitingForCountryCallingCode(_ref2) {\n var international = _ref2.international,\n callingCode = _ref2.callingCode;\n return international && !callingCode;\n }\n\n // Extracts a country calling code from a number\n // being entered in internatonal format.\n }, {\n key: \"extractCountryCallingCode\",\n value: function extractCountryCallingCode(state) {\n var _extractCountryCallin = _extractCountryCallingCode('+' + state.getDigitsWithoutInternationalPrefix(), state.country, this.defaultCountry, this.defaultCallingCode, this.metadata.metadata),\n countryCallingCode = _extractCountryCallin.countryCallingCode,\n number = _extractCountryCallin.number;\n if (countryCallingCode) {\n state.setCallingCode(countryCallingCode);\n state.update({\n nationalSignificantNumber: number\n });\n return true;\n }\n }\n }, {\n key: \"reset\",\n value: function reset(numberingPlan) {\n if (numberingPlan) {\n this.hasSelectedNumberingPlan = true;\n var nationalPrefixForParsing = numberingPlan._nationalPrefixForParsing();\n this.couldPossiblyExtractAnotherNationalSignificantNumber = nationalPrefixForParsing && COMPLEX_NATIONAL_PREFIX.test(nationalPrefixForParsing);\n } else {\n this.hasSelectedNumberingPlan = undefined;\n this.couldPossiblyExtractAnotherNationalSignificantNumber = undefined;\n }\n }\n\n /**\r\n * Extracts a national (significant) number from user input.\r\n * Google's library is different in that it only applies `national_prefix_for_parsing`\r\n * and doesn't apply `national_prefix_transform_rule` after that.\r\n * https://github.com/google/libphonenumber/blob/a3d70b0487875475e6ad659af404943211d26456/java/libphonenumber/src/com/google/i18n/phonenumbers/AsYouTypeFormatter.java#L539\r\n * @return {boolean} [extracted]\r\n */\n }, {\n key: \"extractNationalSignificantNumber\",\n value: function extractNationalSignificantNumber(nationalDigits, setState) {\n if (!this.hasSelectedNumberingPlan) {\n return;\n }\n var _extractNationalNumbe = extractNationalNumberFromPossiblyIncompleteNumber(nationalDigits, this.metadata),\n nationalPrefix = _extractNationalNumbe.nationalPrefix,\n nationalNumber = _extractNationalNumbe.nationalNumber,\n carrierCode = _extractNationalNumbe.carrierCode;\n if (nationalNumber === nationalDigits) {\n return;\n }\n this.onExtractedNationalNumber(nationalPrefix, carrierCode, nationalNumber, nationalDigits, setState);\n return true;\n }\n\n /**\r\n * In Google's code this function is called \"attempt to extract longer NDD\".\r\n * \"Some national prefixes are a substring of others\", they say.\r\n * @return {boolean} [result] — Returns `true` if extracting a national prefix produced different results from what they were.\r\n */\n }, {\n key: \"extractAnotherNationalSignificantNumber\",\n value: function extractAnotherNationalSignificantNumber(nationalDigits, prevNationalSignificantNumber, setState) {\n if (!this.hasExtractedNationalSignificantNumber) {\n return this.extractNationalSignificantNumber(nationalDigits, setState);\n }\n if (!this.couldPossiblyExtractAnotherNationalSignificantNumber) {\n return;\n }\n var _extractNationalNumbe2 = extractNationalNumberFromPossiblyIncompleteNumber(nationalDigits, this.metadata),\n nationalPrefix = _extractNationalNumbe2.nationalPrefix,\n nationalNumber = _extractNationalNumbe2.nationalNumber,\n carrierCode = _extractNationalNumbe2.carrierCode;\n // If a national prefix has been extracted previously,\n // then it's always extracted as additional digits are added.\n // That's assuming `extractNationalNumberFromPossiblyIncompleteNumber()`\n // doesn't do anything different from what it currently does.\n // So, just in case, here's this check, though it doesn't occur.\n /* istanbul ignore if */\n if (nationalNumber === prevNationalSignificantNumber) {\n return;\n }\n this.onExtractedNationalNumber(nationalPrefix, carrierCode, nationalNumber, nationalDigits, setState);\n return true;\n }\n }, {\n key: \"onExtractedNationalNumber\",\n value: function onExtractedNationalNumber(nationalPrefix, carrierCode, nationalSignificantNumber, nationalDigits, setState) {\n // Tells if the parsed national (significant) number is present as-is in the input string.\n // For example, when inputting \"0343515551212999\" Argentinian mobile number,\n // the parsed national (significant) number is \"93435551212999\".\n // There, one can see how it stripped \"0\" national prefix and prepended a \"9\",\n // because that's how it is instructed to do in Argentina's metadata.\n // So in the described example, the parsed national (significant) number is not present\n // as-is in the input string. Instead, it's \"modified\" in the input string.\n // https://gitlab.com/catamphetamine/libphonenumber-js/-/blob/master/METADATA.md#national_prefix_for_parsing--national_prefix_transform_rule\n var nationalSignificantNumberIsModified = false;\n\n // In some countries, a phone number could have a prefix that is not a \"national prefix\"\n // but rather some other type of \"utility\" prefix.\n // For example, when calling within Australia, one could prepend `1831` prefix to hide\n // caller's phone number.\n // https://gitlab.com/catamphetamine/libphonenumber-js/-/blob/master/METADATA.md#national_prefix_for_parsing--national_prefix_transform_rule\n var prefixBeforeNationalSignificantNumberThatIsNotNationalPrefix;\n\n // `nationalSignificantNumber` could be empty. In that case, `.lastIndexOf()` still works correctly.\n var nationalSignificantNumberIndex = nationalDigits.lastIndexOf(nationalSignificantNumber);\n\n // If the parsed national (significant) number is the last substring of the `nationalDigits`,\n // then it means that it's present as-is in the input string.\n // In any other case, the parsed national (significant) number is \"modified\" in the input string.\n if (nationalSignificantNumberIndex < 0 || nationalSignificantNumberIndex !== nationalDigits.length - nationalSignificantNumber.length) {\n nationalSignificantNumberIsModified = true;\n } else {\n var prefixBeforeNationalNumber = nationalDigits.slice(0, nationalSignificantNumberIndex);\n // When national (significant) number is equal to the `nationalDigits`,\n // this `onExtractedNationalNumber()` function simply doesn't get called.\n // This means that at this point, `prefixBeforeNationalNumber` is always non-empty.\n // Still, added this `if` check just to prevent potential silly bugs.\n // The `!prefixBeforeNationalNumber` case is not really testable\n // so this line is exluded from the code coverage.\n /* istanbul ignore if */\n if (prefixBeforeNationalNumber) {\n if (prefixBeforeNationalNumber !== nationalPrefix) {\n prefixBeforeNationalSignificantNumberThatIsNotNationalPrefix = prefixBeforeNationalNumber;\n }\n }\n }\n setState({\n nationalPrefix: nationalPrefix,\n carrierCode: carrierCode,\n nationalSignificantNumber: nationalSignificantNumber,\n nationalSignificantNumberIsModified: nationalSignificantNumberIsModified,\n prefixBeforeNationalSignificantNumberThatIsNotNationalPrefix: prefixBeforeNationalSignificantNumberThatIsNotNationalPrefix\n });\n // `onExtractedNationalNumber()` is only called when\n // the national (significant) number actually did change.\n this.hasExtractedNationalSignificantNumber = true;\n this.onNationalSignificantNumberChange();\n }\n }, {\n key: \"reExtractNationalSignificantNumber\",\n value: function reExtractNationalSignificantNumber(state) {\n // Attempt to extract a national prefix.\n //\n // Some people incorrectly input national prefix\n // in an international phone number.\n // For example, some people write British phone numbers as `+44(0)...`.\n //\n // Also, in some rare cases, it is valid for a national prefix\n // to be a part of an international phone number.\n // For example, mobile phone numbers in Mexico are supposed to be\n // dialled internationally using a `1` national prefix,\n // so the national prefix will be part of an international number.\n //\n // Quote from:\n // https://www.mexperience.com/dialing-cell-phones-in-mexico/\n //\n // \"Dialing a Mexican cell phone from abroad\n // When you are calling a cell phone number in Mexico from outside Mexico,\n // it’s necessary to dial an additional “1” after Mexico’s country code\n // (which is “52”) and before the area code.\n // You also ignore the 045, and simply dial the area code and the\n // cell phone’s number.\n //\n // If you don’t add the “1”, you’ll receive a recorded announcement\n // asking you to redial using it.\n //\n // For example, if you are calling from the USA to a cell phone\n // in Mexico City, you would dial +52 – 1 – 55 – 1234 5678.\n // (Note that this is different to calling a land line in Mexico City\n // from abroad, where the number dialed would be +52 – 55 – 1234 5678)\".\n //\n // Google's demo output:\n // https://libphonenumber.appspot.com/phonenumberparser?number=%2b5215512345678&country=MX\n //\n if (this.extractAnotherNationalSignificantNumber(state.getNationalDigits(), state.nationalSignificantNumber, function (stateUpdate) {\n return state.update(stateUpdate);\n })) {\n return true;\n }\n // If no format matches the phone number, then it could be\n // \"a really long IDD\" (quote from a comment in Google's library).\n // An IDD prefix is first extracted when the user has entered at least 3 digits,\n // and then here — every time when there's a new digit and the number\n // couldn't be formatted.\n // For example, in Australia the default IDD prefix is `0011`,\n // and it could even be as long as `14880011`.\n //\n // Could also check `!hasReceivedThreeLeadingDigits` here\n // to filter out the case when this check duplicates the one\n // already performed when there're 3 leading digits,\n // but it's not a big deal, and in most cases there\n // will be a suitable `format` when there're 3 leading digits.\n //\n if (this.extractIddPrefix(state)) {\n this.extractCallingCodeAndNationalSignificantNumber(state);\n return true;\n }\n // Google's AsYouType formatter supports sort of an \"autocorrection\" feature\n // when it \"autocorrects\" numbers that have been input for a country\n // with that country's calling code.\n // Such \"autocorrection\" feature looks weird, but different people have been requesting it:\n // https://github.com/catamphetamine/libphonenumber-js/issues/376\n // https://github.com/catamphetamine/libphonenumber-js/issues/375\n // https://github.com/catamphetamine/libphonenumber-js/issues/316\n if (this.fixMissingPlus(state)) {\n this.extractCallingCodeAndNationalSignificantNumber(state);\n return true;\n }\n }\n }, {\n key: \"extractIddPrefix\",\n value: function extractIddPrefix(state) {\n // An IDD prefix can't be present in a number written with a `+`.\n // Also, don't re-extract an IDD prefix if has already been extracted.\n var international = state.international,\n IDDPrefix = state.IDDPrefix,\n digits = state.digits,\n nationalSignificantNumber = state.nationalSignificantNumber;\n if (international || IDDPrefix) {\n return;\n }\n // Some users input their phone number in \"out-of-country\"\n // dialing format instead of using the leading `+`.\n // https://github.com/catamphetamine/libphonenumber-js/issues/185\n // Detect such numbers.\n var numberWithoutIDD = stripIddPrefix(digits, this.defaultCountry, this.defaultCallingCode, this.metadata.metadata);\n if (numberWithoutIDD !== undefined && numberWithoutIDD !== digits) {\n // If an IDD prefix was stripped then convert the IDD-prefixed number\n // to international number for subsequent parsing.\n state.update({\n IDDPrefix: digits.slice(0, digits.length - numberWithoutIDD.length)\n });\n this.startInternationalNumber(state, {\n country: undefined,\n callingCode: undefined\n });\n return true;\n }\n }\n }, {\n key: \"fixMissingPlus\",\n value: function fixMissingPlus(state) {\n if (!state.international) {\n var _extractCountryCallin2 = extractCountryCallingCodeFromInternationalNumberWithoutPlusSign(state.digits, state.country, this.defaultCountry, this.defaultCallingCode, this.metadata.metadata),\n newCallingCode = _extractCountryCallin2.countryCallingCode;\n if (newCallingCode) {\n state.update({\n missingPlus: true\n });\n this.startInternationalNumber(state, {\n country: state.country,\n callingCode: newCallingCode\n });\n return true;\n }\n }\n }\n }, {\n key: \"startInternationalNumber\",\n value: function startInternationalNumber(state, _ref3) {\n var country = _ref3.country,\n callingCode = _ref3.callingCode;\n state.startInternationalNumber(country, callingCode);\n // If a national (significant) number has been extracted before, reset it.\n if (state.nationalSignificantNumber) {\n state.resetNationalSignificantNumber();\n this.onNationalSignificantNumberChange();\n this.hasExtractedNationalSignificantNumber = undefined;\n }\n }\n }, {\n key: \"extractCallingCodeAndNationalSignificantNumber\",\n value: function extractCallingCodeAndNationalSignificantNumber(state) {\n if (this.extractCountryCallingCode(state)) {\n // `this.extractCallingCode()` is currently called when the number\n // couldn't be formatted during the standard procedure.\n // Normally, the national prefix would be re-extracted\n // for an international number if such number couldn't be formatted,\n // but since it's already not able to be formatted,\n // there won't be yet another retry, so also extract national prefix here.\n this.extractNationalSignificantNumber(state.getNationalDigits(), function (stateUpdate) {\n return state.update(stateUpdate);\n });\n }\n }\n }]);\n}();\n/**\r\n * Extracts formatted phone number from text (if there's any).\r\n * @param {string} text\r\n * @return {string} [formattedPhoneNumber]\r\n */\nexport { AsYouTypeParser as default };\nfunction extractFormattedPhoneNumber(text) {\n // Attempt to extract a possible number from the string passed in.\n var startsAt = text.search(VALID_FORMATTED_PHONE_NUMBER_PART);\n if (startsAt < 0) {\n return;\n }\n // Trim everything to the left of the phone number.\n text = text.slice(startsAt);\n // Trim the `+`.\n var hasPlus;\n if (text[0] === '+') {\n hasPlus = true;\n text = text.slice('+'.length);\n }\n // Trim everything to the right of the phone number.\n text = text.replace(AFTER_PHONE_NUMBER_DIGITS_END_PATTERN, '');\n // Re-add the previously trimmed `+`.\n if (hasPlus) {\n text = '+' + text;\n }\n return text;\n}\n\n/**\r\n * Extracts formatted phone number digits (and a `+`) from text (if there're any).\r\n * @param {string} text\r\n * @return {any[]}\r\n */\nfunction _extractFormattedDigitsAndPlus(text) {\n // Extract a formatted phone number part from text.\n var extractedNumber = extractFormattedPhoneNumber(text) || '';\n // Trim a `+`.\n if (extractedNumber[0] === '+') {\n return [extractedNumber.slice('+'.length), true];\n }\n return [extractedNumber];\n}\n\n/**\r\n * Extracts formatted phone number digits (and a `+`) from text (if there're any).\r\n * @param {string} text\r\n * @return {any[]}\r\n */\nexport function extractFormattedDigitsAndPlus(text) {\n var _extractFormattedDigi3 = _extractFormattedDigitsAndPlus(text),\n _extractFormattedDigi4 = _slicedToArray(_extractFormattedDigi3, 2),\n formattedDigits = _extractFormattedDigi4[0],\n hasPlus = _extractFormattedDigi4[1];\n // If the extracted phone number part\n // can possibly be a part of some valid phone number\n // then parse phone number characters from a formatted phone number.\n if (!VALID_FORMATTED_PHONE_NUMBER_DIGITS_PART_PATTERN.test(formattedDigits)) {\n formattedDigits = '';\n }\n return [formattedDigits, hasPlus];\n}\n//# sourceMappingURL=AsYouTypeParser.js.map","function _typeof(o) { \"@babel/helpers - typeof\"; return _typeof = \"function\" == typeof Symbol && \"symbol\" == typeof Symbol.iterator ? function (o) { return typeof o; } : function (o) { return o && \"function\" == typeof Symbol && o.constructor === Symbol && o !== Symbol.prototype ? \"symbol\" : typeof o; }, _typeof(o); }\nfunction _slicedToArray(r, e) { return _arrayWithHoles(r) || _iterableToArrayLimit(r, e) || _unsupportedIterableToArray(r, e) || _nonIterableRest(); }\nfunction _nonIterableRest() { throw new TypeError(\"Invalid attempt to destructure non-iterable instance.\\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.\"); }\nfunction _unsupportedIterableToArray(r, a) { if (r) { if (\"string\" == typeof r) return _arrayLikeToArray(r, a); var t = {}.toString.call(r).slice(8, -1); return \"Object\" === t && r.constructor && (t = r.constructor.name), \"Map\" === t || \"Set\" === t ? Array.from(r) : \"Arguments\" === t || /^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(t) ? _arrayLikeToArray(r, a) : void 0; } }\nfunction _arrayLikeToArray(r, a) { (null == a || a > r.length) && (a = r.length); for (var e = 0, n = Array(a); e < a; e++) n[e] = r[e]; return n; }\nfunction _iterableToArrayLimit(r, l) { var t = null == r ? null : \"undefined\" != typeof Symbol && r[Symbol.iterator] || r[\"@@iterator\"]; if (null != t) { var e, n, i, u, a = [], f = !0, o = !1; try { if (i = (t = t.call(r)).next, 0 === l) { if (Object(t) !== t) return; f = !1; } else for (; !(f = (e = i.call(t)).done) && (a.push(e.value), a.length !== l); f = !0); } catch (r) { o = !0, n = r; } finally { try { if (!f && null != t[\"return\"] && (u = t[\"return\"](), Object(u) !== u)) return; } finally { if (o) throw n; } } return a; } }\nfunction _arrayWithHoles(r) { if (Array.isArray(r)) return r; }\nfunction _classCallCheck(a, n) { if (!(a instanceof n)) throw new TypeError(\"Cannot call a class as a function\"); }\nfunction _defineProperties(e, r) { for (var t = 0; t < r.length; t++) { var o = r[t]; o.enumerable = o.enumerable || !1, o.configurable = !0, \"value\" in o && (o.writable = !0), Object.defineProperty(e, _toPropertyKey(o.key), o); } }\nfunction _createClass(e, r, t) { return r && _defineProperties(e.prototype, r), t && _defineProperties(e, t), Object.defineProperty(e, \"prototype\", { writable: !1 }), e; }\nfunction _toPropertyKey(t) { var i = _toPrimitive(t, \"string\"); return \"symbol\" == _typeof(i) ? i : i + \"\"; }\nfunction _toPrimitive(t, r) { if (\"object\" != _typeof(t) || !t) return t; var e = t[Symbol.toPrimitive]; if (void 0 !== e) { var i = e.call(t, r || \"default\"); if (\"object\" != _typeof(i)) return i; throw new TypeError(\"@@toPrimitive must return a primitive value.\"); } return (\"string\" === r ? String : Number)(t); }\nimport Metadata from './metadata.js';\nimport PhoneNumber from './PhoneNumber.js';\nimport checkNumberLength from './helpers/checkNumberLength.js';\nimport AsYouTypeState from './AsYouTypeState.js';\nimport AsYouTypeFormatter, { DIGIT_PLACEHOLDER } from './AsYouTypeFormatter.js';\nimport AsYouTypeParser, { extractFormattedDigitsAndPlus } from './AsYouTypeParser.js';\nimport getCountryByCallingCode from './helpers/getCountryByCallingCode.js';\nimport getCountryByNationalNumber from './helpers/getCountryByNationalNumber.js';\nimport isObject from './helpers/isObject.js';\nvar USE_NON_GEOGRAPHIC_COUNTRY_CODE = false;\nvar AsYouType = /*#__PURE__*/function () {\n /**\r\n * @param {(string|object)?} [optionsOrDefaultCountry] - The default country used for parsing non-international phone numbers. Can also be an `options` object.\r\n * @param {Object} metadata\r\n */\n function AsYouType(optionsOrDefaultCountry, metadata) {\n _classCallCheck(this, AsYouType);\n // Metadata instance is created once and stays constant.\n // This is required because other utility classes such as `AsYouTypeFormatter`\n // will use this metadata instance \"reference\" and will assume that it stays constant.\n this.metadata = new Metadata(metadata);\n var _this$getCountryAndCa = this.getCountryAndCallingCode(optionsOrDefaultCountry),\n _this$getCountryAndCa2 = _slicedToArray(_this$getCountryAndCa, 2),\n defaultCountry = _this$getCountryAndCa2[0],\n defaultCallingCode = _this$getCountryAndCa2[1];\n // `this.defaultCountry` and `this.defaultCallingCode` aren't required to be in sync.\n // For example, `this.defaultCountry` could be `\"AR\"` and `this.defaultCallingCode` could be `undefined`.\n // So `this.defaultCountry` and `this.defaultCallingCode` are totally independent.\n this.defaultCountry = defaultCountry;\n this.defaultCallingCode = defaultCallingCode;\n this.reset();\n }\n return _createClass(AsYouType, [{\n key: \"getCountryAndCallingCode\",\n value: function getCountryAndCallingCode(optionsOrDefaultCountry) {\n // Set `defaultCountry` and `defaultCallingCode` options.\n var defaultCountry;\n var defaultCallingCode;\n // Turns out `null` also has type \"object\". Weird.\n if (optionsOrDefaultCountry) {\n if (isObject(optionsOrDefaultCountry)) {\n defaultCountry = optionsOrDefaultCountry.defaultCountry;\n defaultCallingCode = optionsOrDefaultCountry.defaultCallingCode;\n } else {\n defaultCountry = optionsOrDefaultCountry;\n }\n }\n if (defaultCountry && !this.metadata.hasCountry(defaultCountry)) {\n defaultCountry = undefined;\n }\n if (defaultCallingCode) {\n /* istanbul ignore if */\n if (USE_NON_GEOGRAPHIC_COUNTRY_CODE) {\n if (this.metadata.isNonGeographicCallingCode(defaultCallingCode)) {\n defaultCountry = '001';\n }\n }\n }\n return [defaultCountry, defaultCallingCode];\n }\n\n /**\r\n * Inputs \"next\" phone number characters.\r\n * @param {string} text\r\n * @return {string} Formatted phone number characters that have been input so far.\r\n */\n }, {\n key: \"input\",\n value: function input(text) {\n var _this$parser$input = this.parser.input(text, this.state),\n digits = _this$parser$input.digits,\n justLeadingPlus = _this$parser$input.justLeadingPlus;\n if (justLeadingPlus) {\n this.formattedOutput = '+';\n } else if (digits) {\n this.determineTheCountryIfNeeded();\n // Match the available formats by the currently available leading digits.\n if (this.state.nationalSignificantNumber) {\n this.formatter.narrowDownMatchingFormats(this.state);\n }\n var formattedNationalNumber;\n if (this.metadata.hasSelectedNumberingPlan()) {\n formattedNationalNumber = this.formatter.format(digits, this.state);\n }\n if (formattedNationalNumber === undefined) {\n // See if another national (significant) number could be re-extracted.\n if (this.parser.reExtractNationalSignificantNumber(this.state)) {\n this.determineTheCountryIfNeeded();\n // If it could, then re-try formatting the new national (significant) number.\n var nationalDigits = this.state.getNationalDigits();\n if (nationalDigits) {\n formattedNationalNumber = this.formatter.format(nationalDigits, this.state);\n }\n }\n }\n this.formattedOutput = formattedNationalNumber ? this.getFullNumber(formattedNationalNumber) : this.getNonFormattedNumber();\n }\n return this.formattedOutput;\n }\n }, {\n key: \"reset\",\n value: function reset() {\n var _this = this;\n this.state = new AsYouTypeState({\n onCountryChange: function onCountryChange(country) {\n // Before version `1.6.0`, the official `AsYouType` formatter API\n // included a `.country` property on an `AsYouType` instance.\n // Since that property (along with the others) have been moved to\n // `this.state`, `this.country` property is emulated for compatibility\n // with the old versions.\n _this.country = country;\n },\n onCallingCodeChange: function onCallingCodeChange(callingCode, country) {\n _this.metadata.selectNumberingPlan(country || callingCode);\n _this.formatter.reset(_this.metadata.numberingPlan, _this.state);\n _this.parser.reset(_this.metadata.numberingPlan);\n }\n });\n this.formatter = new AsYouTypeFormatter({\n state: this.state,\n metadata: this.metadata\n });\n this.parser = new AsYouTypeParser({\n defaultCountry: this.defaultCountry,\n defaultCallingCode: this.defaultCallingCode,\n metadata: this.metadata,\n state: this.state,\n onNationalSignificantNumberChange: function onNationalSignificantNumberChange() {\n _this.determineTheCountryIfNeeded();\n _this.formatter.reset(_this.metadata.numberingPlan, _this.state);\n }\n });\n this.state.reset({\n country: this.defaultCountry,\n callingCode: this.defaultCallingCode\n });\n this.formattedOutput = '';\n return this;\n }\n\n /**\r\n * Returns `true` if the phone number is being input in international format.\r\n * In other words, returns `true` if and only if the parsed phone number starts with a `\"+\"`.\r\n * @return {boolean}\r\n */\n }, {\n key: \"isInternational\",\n value: function isInternational() {\n return this.state.international;\n }\n\n /**\r\n * Returns the \"calling code\" part of the phone number when it's being input\r\n * in an international format.\r\n * If no valid calling code has been entered so far, returns `undefined`.\r\n * @return {string} [callingCode]\r\n */\n }, {\n key: \"getCallingCode\",\n value: function getCallingCode() {\n // If the number is being input in national format and some \"default calling code\"\n // has been passed to `AsYouType` constructor, then `this.state.callingCode`\n // is equal to that \"default calling code\".\n //\n // If the number is being input in national format and no \"default calling code\"\n // has been passed to `AsYouType` constructor, then returns `undefined`,\n // even if a \"default country\" has been passed to `AsYouType` constructor.\n //\n if (this.isInternational()) {\n return this.state.callingCode;\n }\n }\n\n // A legacy alias.\n }, {\n key: \"getCountryCallingCode\",\n value: function getCountryCallingCode() {\n return this.getCallingCode();\n }\n\n /**\r\n * Returns a two-letter country code of the phone number.\r\n * Returns `undefined` for \"non-geographic\" phone numbering plans.\r\n * Returns `undefined` if no phone number has been input yet.\r\n * @return {string} [country]\r\n */\n }, {\n key: \"getCountry\",\n value: function getCountry() {\n var digits = this.state.digits;\n // Return `undefined` if no digits have been input yet.\n if (digits) {\n return this._getCountry();\n }\n }\n\n /**\r\n * Returns a two-letter country code of the phone number.\r\n * Returns `undefined` for \"non-geographic\" phone numbering plans.\r\n * @return {string} [country]\r\n */\n }, {\n key: \"_getCountry\",\n value: function _getCountry() {\n var country = this.state.country;\n /* istanbul ignore if */\n if (USE_NON_GEOGRAPHIC_COUNTRY_CODE) {\n // `AsYouType.getCountry()` returns `undefined`\n // for \"non-geographic\" phone numbering plans.\n if (country === '001') {\n return;\n }\n }\n return country;\n }\n }, {\n key: \"determineTheCountryIfNeeded\",\n value: function determineTheCountryIfNeeded() {\n // Suppose a user enters a phone number in international format,\n // and there're several countries corresponding to that country calling code,\n // and a country has been derived from the number, and then\n // a user enters one more digit and the number is no longer\n // valid for the derived country, so the country should be re-derived\n // on every new digit in those cases.\n //\n // If the phone number is being input in national format,\n // then it could be a case when `defaultCountry` wasn't specified\n // when creating `AsYouType` instance, and just `defaultCallingCode` was specified,\n // and that \"calling code\" could correspond to a \"non-geographic entity\",\n // or there could be several countries corresponding to that country calling code.\n // In those cases, `this.country` is `undefined` and should be derived\n // from the number. Again, if country calling code is ambiguous, then\n // `this.country` should be re-derived with each new digit.\n //\n if (!this.state.country || this.isCountryCallingCodeAmbiguous()) {\n this.determineTheCountry();\n }\n }\n\n // Prepends `+CountryCode ` in case of an international phone number\n }, {\n key: \"getFullNumber\",\n value: function getFullNumber(formattedNationalNumber) {\n var _this2 = this;\n if (this.isInternational()) {\n var prefix = function prefix(text) {\n return _this2.formatter.getInternationalPrefixBeforeCountryCallingCode(_this2.state, {\n spacing: text ? true : false\n }) + text;\n };\n var callingCode = this.state.callingCode;\n if (!callingCode) {\n return prefix(\"\".concat(this.state.getDigitsWithoutInternationalPrefix()));\n }\n if (!formattedNationalNumber) {\n return prefix(callingCode);\n }\n return prefix(\"\".concat(callingCode, \" \").concat(formattedNationalNumber));\n }\n return formattedNationalNumber;\n }\n }, {\n key: \"getNonFormattedNationalNumberWithPrefix\",\n value: function getNonFormattedNationalNumberWithPrefix() {\n var _this$state = this.state,\n nationalSignificantNumber = _this$state.nationalSignificantNumber,\n prefixBeforeNationalSignificantNumberThatIsNotNationalPrefix = _this$state.prefixBeforeNationalSignificantNumberThatIsNotNationalPrefix,\n nationalPrefix = _this$state.nationalPrefix;\n var number = nationalSignificantNumber;\n var prefix = prefixBeforeNationalSignificantNumberThatIsNotNationalPrefix || nationalPrefix;\n if (prefix) {\n number = prefix + number;\n }\n return number;\n }\n }, {\n key: \"getNonFormattedNumber\",\n value: function getNonFormattedNumber() {\n var nationalSignificantNumberIsModified = this.state.nationalSignificantNumberIsModified;\n return this.getFullNumber(nationalSignificantNumberIsModified ? this.state.getNationalDigits() : this.getNonFormattedNationalNumberWithPrefix());\n }\n }, {\n key: \"getNonFormattedTemplate\",\n value: function getNonFormattedTemplate() {\n var number = this.getNonFormattedNumber();\n if (number) {\n return number.replace(/[\\+\\d]/g, DIGIT_PLACEHOLDER);\n }\n }\n }, {\n key: \"isCountryCallingCodeAmbiguous\",\n value: function isCountryCallingCodeAmbiguous() {\n var callingCode = this.state.callingCode;\n var countryCodes = this.metadata.getCountryCodesForCallingCode(callingCode);\n return countryCodes && countryCodes.length > 1;\n }\n\n // Determines the exact country of the phone number\n // entered so far based on the country phone code\n // and the national phone number.\n }, {\n key: \"determineTheCountry\",\n value: function determineTheCountry() {\n // Get a more precise country code for this national number.\n // It is possible that the precise country couldn't be determined\n // in cases when there're multiple countries sharing the same calling code.\n // In that case, `country` will be `undefined`.\n var country = getCountryByCallingCode(this.isInternational() ? this.state.callingCode : this.defaultCallingCode, {\n nationalNumber: this.state.nationalSignificantNumber,\n metadata: this.metadata\n });\n // If the derived country is indeed more precise,\n // or if no country could be derived for the updated phone number.\n if (country !== this.state.country) {\n // Set (or reset) the more precise country.\n this.state.setCountry(country);\n // If a more precise country could be derived.\n if (country) {\n // Select a more precise telephone numbering plan.\n // For example, consider that `AsYouType` instance was created with `defaultCountry: \"US\"` argument.\n // In that case, the metadata instance will be using \"US\" metadata.\n // But then the user could input a Canadian phone number, in which case\n // the metadata instance should be switched to Canadian telephone numbering plan.\n // It is required to do that because later `canFormatCompleteNumber()` function will be called,\n // and that function relies on the precise country being pre-selected in the metadata instance.\n // Or, for example, `checkNumberLength()` function also relies on same thing.\n this.metadata.selectNumberingPlan(country);\n }\n }\n }\n\n /**\r\n * Returns a E.164 phone number value for the user's input.\r\n *\r\n * For example, for country `\"US\"` and input `\"(222) 333-4444\"`\r\n * it will return `\"+12223334444\"`.\r\n *\r\n * For international phone number input, it will also auto-correct\r\n * some minor errors such as using a national prefix when writing\r\n * an international phone number. For example, if the user inputs\r\n * `\"+44 0 7400 000000\"` then it will return an auto-corrected\r\n * `\"+447400000000\"` phone number value.\r\n *\r\n * Will return `undefined` if no digits have been input,\r\n * or when inputting a phone number in national format and no\r\n * default country or default \"country calling code\" have been set.\r\n *\r\n * @return {string} [value]\r\n */\n }, {\n key: \"getNumberValue\",\n value: function getNumberValue() {\n var _this$state2 = this.state,\n digits = _this$state2.digits,\n callingCode = _this$state2.callingCode,\n country = _this$state2.country,\n nationalSignificantNumber = _this$state2.nationalSignificantNumber;\n\n // Will return `undefined` if no digits have been input.\n if (!digits) {\n return;\n }\n if (this.isInternational()) {\n if (callingCode) {\n return '+' + callingCode + nationalSignificantNumber;\n } else {\n return '+' + digits;\n }\n } else {\n if (country || callingCode) {\n var callingCode_ = country ? this.metadata.countryCallingCode() : callingCode;\n return '+' + callingCode_ + nationalSignificantNumber;\n }\n }\n }\n\n /**\r\n * Returns an instance of `PhoneNumber` class.\r\n * Will return `undefined` if no national (significant) number\r\n * digits have been entered so far, or if no `defaultCountry` has been\r\n * set and the user enters a phone number not in international format.\r\n */\n }, {\n key: \"getNumber\",\n value: function getNumber() {\n var _this$state3 = this.state,\n nationalSignificantNumber = _this$state3.nationalSignificantNumber,\n carrierCode = _this$state3.carrierCode,\n callingCode = _this$state3.callingCode;\n if (!nationalSignificantNumber) {\n return;\n }\n\n // `this._getCountry()` is basically same as `this.state.country`\n // with the only change that it returns `undefined` in case of a\n // \"non-geographic\" numbering plan instead of `\"001\"` \"internal use\" value.\n var country = this._getCountry();\n\n // Sidenote:\n // `state.callingCode` and `state.country` are somewhat independent from one another\n // and there could be situations when one is defined but the other is not.\n // See the comment in `AsYouTypeState.js` for more info on when that is possible.\n\n if (!country && !callingCode) {\n return;\n }\n\n // By default, if `defaultCountry` parameter was passed when\n // creating `AsYouType` instance, `state.country` is gonna be\n // that `defaultCountry`, which doesn't entirely conform with\n // `parsePhoneNumber()`'s behavior where it attempts to determine\n // the country more precisely in cases when multiple countries\n // could correspond to the same `countryCallingCode`.\n // https://gitlab.com/catamphetamine/libphonenumber-js/-/issues/103#note_1417192969\n //\n // Because `AsYouType.getNumber()` method is supposed to be a 1:1\n // equivalent for `parsePhoneNumber(AsYouType.getNumberValue())`,\n // it means that it should also behave accordingly in such cases of `country` ambiguity.\n // That's how users of this library would expect it to behave anyway.\n //\n // So here it checks if `state.country` is same as the `defaultCountry`,\n // and if it is, it attempts to get rid of any potential ambiguity.\n //\n if (country) {\n if (country === this.defaultCountry) {\n // // Create a `Metadata` instance just to get the calling code of the `country`.\n // const metadata = new Metadata(this.metadata.metadata)\n // // `state.callingCode` and `state.country` are somewhat independent from one another\n // // and there could be situations when one is defined but the other is not.\n // // See the comment in `AsYouTypeState.js` for more info on when that is possible.\n // // Here, it only passes `state.country` because there's no need to pass `state.callingCode`\n // // because `state.country` is known to be defined.\n // metadata.selectNumberingPlan(country)\n // const countryCallingCode = metadata.numberingPlan.callingCode()\n\n // Instead of getting `countryCallingCode` value above,\n // it could simply read it from the existing metadata instance.\n var countryCallingCode = this.metadata.numberingPlan.callingCode();\n\n // Attempt to rule out any potential country code ambiguity, if present.\n var exactCountry = getExactCountryForMultiCountryCallingCode(countryCallingCode, nationalSignificantNumber, this.metadata);\n if (exactCountry) {\n country = exactCountry;\n }\n }\n }\n var phoneNumber = new PhoneNumber(country || callingCode, nationalSignificantNumber, this.metadata.metadata);\n if (carrierCode) {\n phoneNumber.carrierCode = carrierCode;\n }\n // Phone number extensions are not supported by \"As You Type\" formatter.\n return phoneNumber;\n }\n\n /**\r\n * Returns `true` if the phone number is \"possible\".\r\n * Is just a shortcut for `PhoneNumber.isPossible()`.\r\n * @return {boolean}\r\n */\n }, {\n key: \"isPossible\",\n value: function isPossible() {\n var phoneNumber = this.getNumber();\n if (!phoneNumber) {\n return false;\n }\n return phoneNumber.isPossible();\n }\n\n /**\r\n * Returns `true` if the phone number is \"valid\".\r\n * Is just a shortcut for `PhoneNumber.isValid()`.\r\n * @return {boolean}\r\n */\n }, {\n key: \"isValid\",\n value: function isValid() {\n var phoneNumber = this.getNumber();\n if (!phoneNumber) {\n return false;\n }\n return phoneNumber.isValid();\n }\n\n /**\r\n * Checks if the phone number length is valid.\r\n * If it is, nothing is returned.\r\n * Otherwise, a rejection reason is returned.\r\n * @return {string?}\r\n */\n }, {\n key: \"validateLength\",\n value: function validateLength() {\n var _this$state4 = this.state,\n digits = _this$state4.digits,\n nationalSignificantNumber = _this$state4.nationalSignificantNumber;\n if (!digits) {\n return 'NOT_A_NUMBER';\n }\n if (!this.metadata.numberingPlan) {\n return 'INVALID_COUNTRY';\n }\n if (!nationalSignificantNumber) {\n return 'TOO_SHORT';\n }\n\n // `state.callingCode` and `state.country` are somewhat independent from one another\n // and there could be situations when one is defined but the other is not.\n // See the comment in `AsYouTypeState.js` for more info on when that is possible.\n // Here, it uses both: if `country` is defined then it will use that,\n // otherwise it will use `callingCode`.\n var result = checkNumberLength(nationalSignificantNumber, undefined, this.metadata);\n if (result !== 'IS_POSSIBLE') {\n return result;\n }\n }\n\n /**\r\n * @deprecated\r\n * This method is used in `react-phone-number-input/source/input-control.js`\r\n * in versions before `3.0.16`.\r\n */\n }, {\n key: \"getNationalNumber\",\n value: function getNationalNumber() {\n return this.state.nationalSignificantNumber;\n }\n\n /**\r\n * Returns the phone number characters entered by the user.\r\n * @return {string}\r\n */\n }, {\n key: \"getChars\",\n value: function getChars() {\n return (this.state.international ? '+' : '') + this.state.digits;\n }\n\n /**\r\n * Returns the template for the formatted phone number.\r\n * @return {string}\r\n */\n }, {\n key: \"getTemplate\",\n value: function getTemplate() {\n return this.formatter.getTemplate(this.state) || this.getNonFormattedTemplate() || '';\n }\n }]);\n}(); // In situations when multiple countries use the same calling code,\n// this function tells what exact country does a given national (significant) number belong to.\nexport { AsYouType as default };\nfunction getExactCountryForMultiCountryCallingCode(callingCode, nationalSignificantNumber, metadata) {\n var ambiguousCountries = metadata.getCountryCodesForCallingCode(callingCode);\n if (ambiguousCountries.length > 1) {\n return getCountryByNationalNumber(nationalSignificantNumber, ambiguousCountries, metadata.metadata);\n }\n}\n//# sourceMappingURL=AsYouType.js.map","import withMetadataArgument from './withMetadataArgument.js'\r\nimport { parsePhoneNumberWithError as _parsePhoneNumberWithError } from '../../core/index.js'\r\n\r\nexport function parsePhoneNumberWithError() {\r\n\treturn withMetadataArgument(_parsePhoneNumberWithError, arguments)\r\n}\r\n","import withMetadataArgument from './withMetadataArgument.js'\r\nimport { isValidPhoneNumber as _isValidPhoneNumber } from '../../core/index.js'\r\n\r\nexport function isValidPhoneNumber() {\r\n\treturn withMetadataArgument(_isValidPhoneNumber, arguments)\r\n}","// Importing from a \".js\" file is a workaround for Node.js \"ES Modules\"\r\n// importing system which is even uncapable of importing \"*.json\" files.\r\nimport metadata from '../../metadata.min.json.js'\r\n\r\nimport { AsYouType as _AsYouType } from '../../core/index.js'\r\n\r\nexport function AsYouType(country) {\r\n\treturn _AsYouType.call(this, country, metadata)\r\n}\r\n\r\nAsYouType.prototype = Object.create(_AsYouType.prototype, {})\r\nAsYouType.prototype.constructor = AsYouType","/**\n * A tiny, safe-by-default Markdown → HTML renderer for the chat widget.\n *\n * ## Why a hand-rolled renderer (and not markdown-it / snarkdown)?\n *\n * The widget renders **untrusted** text in two places: the assistant's reply\n * (LLM output, which can echo attacker-supplied content) and citation snippets\n * (raw scraped page chunks). Today both are written via `textContent`, so\n * `**bold**`, numbered lists, and `[links](url)` show up literally. We want\n * them rendered — without re-opening the XSS hole that `textContent` was\n * guarding against.\n *\n * markdown-it with `html:false` is safe-by-default but ships ~30 kB min into\n * what is an embeddable **global** bundle, where every kilobyte is on the host\n * page's critical path. snarkdown is ~1 kB but emits raw HTML, so it would\n * require bolting on a separate sanitizer. Instead, this renderer is\n * **safe-by-construction**:\n *\n * 1. It is a *tokenizer*, not an HTML passthrough. It only ever emits a\n * fixed allowlist of tags (`p`, `br`, `strong`, `em`, `ul`/`ol`/`li`,\n * `code`/`pre`, `a`, `blockquote`). There is no code path that copies a\n * tag out of the input — a literal `<script>` in the input is treated as\n * plain text.\n * 2. **Every** text run is HTML-escaped via {@link escapeHtml} before it\n * reaches the output. Raw `<`, `>`, `&`, `\"`, `'` can never become markup.\n * 3. **Images are dropped entirely** — `` renders as its alt text,\n * no `<img>` is ever produced (a scraped tracking pixel must not load).\n * 4. **Links** are gated through {@link safeHttpUrl}: only absolute `http(s)`\n * URLs become anchors (with `target=\"_blank\"` + a hardened `rel`);\n * `javascript:`/`data:`/relative/etc. fall back to plain (escaped) text.\n * 5. **Headings** (`#`..`######`) are *downgraded* to bold lines — a full\n * `<h1>` is far too large inside a chat bubble or citation card.\n *\n * The output is a string of HTML that is only ever assigned to `innerHTML` of\n * an element the caller controls; because of (1)–(4) it can only contain the\n * allowlisted, attribute-sanitized tags.\n *\n * Supported subset (deliberately small):\n * - Paragraphs (blank-line separated) and hard/soft line breaks\n * - `**bold**` / `__bold__`, `*italic*` / `_italic_`\n * - `` `inline code` `` and fenced ``` ```code blocks``` ```\n * - `- ` / `* ` / `+ ` unordered lists, `1.` ordered lists\n * - `> ` blockquotes\n * - `[text](http(s)://url)` links (images dropped to alt text)\n * - `#`..`######` headings → bold line\n */\n\n/** Escape the five HTML-significant characters so a text run can never be markup. */\nexport function escapeHtml(value: string): string {\n return value.replace(/[&<>\"']/g, (c) => {\n switch (c) {\n case '&':\n return '&';\n case '<':\n return '<';\n case '>':\n return '>';\n case '\"':\n return '"';\n default:\n return ''';\n }\n });\n}\n\n/**\n * Return `url` only if it is a valid absolute `http(s)` URL, else `null`.\n *\n * SECURITY: link targets here originate from untrusted content (LLM output /\n * scraped citation chunks). Allowing an arbitrary string as an `href` permits\n * `javascript:`/`data:`/`vbscript:` URLs that execute on click — a stored-XSS\n * vector. Only absolute http(s) links are rendered as anchors; anything else\n * falls back to plain text upstream.\n */\nexport function safeHttpUrl(url: string | undefined | null): string | null {\n if (!url) return null;\n try {\n const parsed = new URL(url);\n return parsed.protocol === 'http:' || parsed.protocol === 'https:' ? parsed.href : null;\n } catch {\n return null;\n }\n}\n\n// ───────────────────────────── Inline rendering ─────────────────────────────\n\n/**\n * Render the inline span grammar of a single line/segment to safe HTML.\n *\n * Order matters: code spans are extracted first (their contents are *not*\n * further parsed), then images are stripped to alt text, then links, then\n * emphasis. Every literal text run is escaped on the way out.\n */\nfunction renderInline(input: string): string {\n let out = '';\n let i = 0;\n const n = input.length;\n\n // Accumulate escaped literal text, flushing on each recognized token.\n let buf = '';\n const flush = () => {\n if (buf) {\n out += escapeHtml(buf);\n buf = '';\n }\n };\n\n while (i < n) {\n const ch = input[i]!;\n\n // Inline code: `...` — contents are literal (escaped), no nested parsing.\n if (ch === '`') {\n const end = input.indexOf('`', i + 1);\n if (end > i) {\n flush();\n out += `<code>${escapeHtml(input.slice(i + 1, end))}</code>`;\n i = end + 1;\n continue;\n }\n }\n\n // Image:  — DROPPED. Emit only the (escaped) alt text; never\n // produce an <img> (a scraped tracking pixel must not load).\n if (ch === '!' && input[i + 1] === '[') {\n const m = imageAt(input, i);\n if (m) {\n flush();\n out += renderInline(m.alt); // alt may itself contain emphasis\n i = m.end;\n continue;\n }\n }\n\n // Link: [text](href)\n if (ch === '[') {\n const m = linkAt(input, i);\n if (m) {\n flush();\n const safe = safeHttpUrl(m.href);\n const inner = renderInline(m.text);\n if (safe) {\n out += `<a href=\"${escapeHtml(safe)}\" target=\"_blank\" rel=\"noopener noreferrer nofollow\">${inner}</a>`;\n } else {\n // Unsafe scheme → render as plain (already-escaped) text, no anchor.\n out += inner;\n }\n i = m.end;\n continue;\n }\n }\n\n // Bold: **...** or __...__\n if ((ch === '*' && input[i + 1] === '*') || (ch === '_' && input[i + 1] === '_')) {\n const marker = ch + ch;\n const end = input.indexOf(marker, i + 2);\n if (end > i + 1) {\n flush();\n out += `<strong>${renderInline(input.slice(i + 2, end))}</strong>`;\n i = end + 2;\n continue;\n }\n }\n\n // Italic: *...* or _..._ (single marker, non-empty, not touching the other marker)\n if (ch === '*' || ch === '_') {\n const end = input.indexOf(ch, i + 1);\n if (end > i + 1 && input[i + 1] !== ch) {\n flush();\n out += `<em>${renderInline(input.slice(i + 1, end))}</em>`;\n i = end + 1;\n continue;\n }\n }\n\n buf += ch;\n i++;\n }\n\n flush();\n return out;\n}\n\n/** Parse a `[text](href)` link starting at `start` (`input[start] === '['`). */\nfunction linkAt(input: string, start: number): { text: string; href: string; end: number } | null {\n const close = matchBracket(input, start);\n if (close < 0 || input[close + 1] !== '(') return null;\n const paren = input.indexOf(')', close + 2);\n if (paren < 0) return null;\n const text = input.slice(start + 1, close);\n // href is the first whitespace-delimited token inside (...) — ignore any\n // markdown \"title\" portion; we never render titles.\n const href = input.slice(close + 2, paren).trim().split(/\\s+/)[0] ?? '';\n return { text, href, end: paren + 1 };\n}\n\n/** Parse a `` image starting at `start` (`input[start] === '!'`). */\nfunction imageAt(input: string, start: number): { alt: string; end: number } | null {\n const link = linkAt(input, start + 1);\n if (!link) return null;\n return { alt: link.text, end: link.end };\n}\n\n/** Find the matching `]` for a `[` at `open`, honoring one level of nesting. */\nfunction matchBracket(input: string, open: number): number {\n let depth = 0;\n for (let i = open; i < input.length; i++) {\n const c = input[i];\n if (c === '[') depth++;\n else if (c === ']') {\n depth--;\n if (depth === 0) return i;\n }\n }\n return -1;\n}\n\n// ───────────────────────────── Block rendering ──────────────────────────────\n\nconst UL_RE = /^\\s*[-*+]\\s+(.*)$/;\nconst OL_RE = /^\\s*\\d+[.)]\\s+(.*)$/;\nconst HEADING_RE = /^\\s{0,3}(#{1,6})\\s+(.*)$/;\nconst QUOTE_RE = /^\\s*>\\s?(.*)$/;\nconst FENCE_RE = /^\\s*(`{3,}|~{3,})\\s*(.*)$/;\n\n/**\n * Render a full Markdown string to safe HTML.\n *\n * @returns a string containing only the allowlisted tags described in the\n * module doc. Safe to assign to `innerHTML` of a caller-owned element.\n */\nexport function renderMarkdown(src: string): string {\n const lines = src.replace(/\\r\\n?/g, '\\n').split('\\n');\n const out: string[] = [];\n\n let i = 0;\n while (i < lines.length) {\n const line = lines[i]!;\n\n // Fenced code block: ```lang ... ```\n const fence = FENCE_RE.exec(line);\n if (fence) {\n const marker = fence[1]!;\n const body: string[] = [];\n i++;\n while (i < lines.length && !lines[i]!.trimStart().startsWith(marker)) {\n body.push(lines[i]!);\n i++;\n }\n if (i < lines.length) i++; // consume closing fence\n out.push(`<pre><code>${escapeHtml(body.join('\\n'))}</code></pre>`);\n continue;\n }\n\n // Blank line → paragraph boundary.\n if (line.trim() === '') {\n i++;\n continue;\n }\n\n // Heading → downgraded to a bold line (an <h1> is too big in a bubble).\n const heading = HEADING_RE.exec(line);\n if (heading) {\n out.push(`<p><strong>${renderInline(heading[2]!)}</strong></p>`);\n i++;\n continue;\n }\n\n // Unordered / ordered list — consume the contiguous run.\n if (UL_RE.test(line) || OL_RE.test(line)) {\n const ordered = OL_RE.test(line) && !UL_RE.test(line);\n const re = ordered ? OL_RE : UL_RE;\n const items: string[] = [];\n while (i < lines.length) {\n const m = re.exec(lines[i]!);\n if (!m) break;\n items.push(`<li>${renderInline(m[1]!)}</li>`);\n i++;\n }\n out.push(`<${ordered ? 'ol' : 'ul'}>${items.join('')}</${ordered ? 'ol' : 'ul'}>`);\n continue;\n }\n\n // Blockquote — consume the contiguous run.\n if (QUOTE_RE.test(line)) {\n const quoted: string[] = [];\n while (i < lines.length) {\n const m = QUOTE_RE.exec(lines[i]!);\n if (!m) break;\n quoted.push(m[1]!);\n i++;\n }\n out.push(`<blockquote>${renderInline(quoted.join('\\n')).replace(/\\n/g, '<br>')}</blockquote>`);\n continue;\n }\n\n // Paragraph — gather consecutive non-blank, non-block lines; soft breaks → <br>.\n const para: string[] = [];\n while (i < lines.length) {\n const l = lines[i]!;\n if (\n l.trim() === '' ||\n FENCE_RE.test(l) ||\n HEADING_RE.test(l) ||\n UL_RE.test(l) ||\n OL_RE.test(l) ||\n QUOTE_RE.test(l)\n ) {\n break;\n }\n para.push(l);\n i++;\n }\n out.push(`<p>${renderInline(para.join('\\n')).replace(/\\n/g, '<br>')}</p>`);\n }\n\n return out.join('');\n}\n\n// ───────────────────────── Citation-snippet cleanup ─────────────────────────\n\nconst SNIPPET_MAX = 260;\n\n/**\n * Clean a raw scraped citation snippet into a short, readable excerpt.\n *\n * Scraped chunks frequently begin with page boilerplate — a logo image wrapped\n * in a link, standalone nav, repeated whitespace — e.g.\n * `[](…) # Our Work We build…`. The source itself is already linked\n * from the citation card, so the snippet only needs to be a clean teaser.\n *\n * Steps:\n * 1. Strip a leading image / logo-link (`[](…)` or ``).\n * 2. Drop a leading standalone heading marker (`#`/`##`).\n * 3. Collapse all runs of whitespace to single spaces.\n * 4. Truncate to ~{@link SNIPPET_MAX} chars at a word boundary, adding `…`.\n *\n * The result is still rendered through {@link renderMarkdown} downstream, so any\n * remaining inline markup (bold/links) stays safe.\n */\nexport function cleanCitationSnippet(raw: string): string {\n let s = raw ?? '';\n\n // Repeatedly peel leading boilerplate tokens.\n let changed = true;\n while (changed) {\n changed = false;\n const before = s;\n // Leading linked image: [](href)\n s = s.replace(/^\\s*\\[!\\[[^\\]]*\\]\\([^)]*\\)\\]\\([^)]*\\)\\s*/, '');\n // Leading bare image: \n s = s.replace(/^\\s*!\\[[^\\]]*\\]\\([^)]*\\)\\s*/, '');\n // Leading heading marker(s): \"# \", \"## \" (keep the heading text)\n s = s.replace(/^\\s*#{1,6}\\s+/, '');\n if (s !== before) changed = true;\n }\n\n // Collapse whitespace.\n s = s.replace(/\\s+/g, ' ').trim();\n\n // Truncate at a word boundary.\n if (s.length > SNIPPET_MAX) {\n const cut = s.slice(0, SNIPPET_MAX);\n const lastSpace = cut.lastIndexOf(' ');\n s = (lastSpace > SNIPPET_MAX * 0.6 ? cut.slice(0, lastSpace) : cut).trimEnd() + '…';\n }\n\n return s;\n}\n","/**\n * Public configuration surface for the chat widget.\n *\n * A host page configures the widget either declaratively (HTML attributes on the\n * `<smooth-agent-chat>` element) or programmatically (passing this object to\n * {@link mountChatWidget} / `element.configure(...)`).\n */\nimport { safeHttpUrl } from './markdown.js';\n\nexport interface ChatWidgetTheme {\n /** Foreground text color for the widget chrome. */\n text?: string;\n /** Panel background color. */\n background?: string;\n /** Primary accent (launcher button, send button, outbound bubble). */\n primary?: string;\n /** Text color rendered on top of `primary`. */\n primaryText?: string;\n /** A secondary accent (used for subtle highlights). */\n secondary?: string;\n /** Inbound (assistant) chat bubble background. */\n assistantBubble?: string;\n /** Inbound (assistant) chat bubble text color. */\n assistantBubbleText?: string;\n /** Outbound (user) chat bubble background. Defaults to `primary`. */\n userBubble?: string;\n /** Outbound (user) chat bubble text color. Defaults to `primaryText`. */\n userBubbleText?: string;\n /** Border color for the panel and input. */\n border?: string;\n\n // ── Aliases for the dashboard's 10-color model (SmooAI agent widget config).\n // When provided, these take precedence over the canonical keys above, so a\n // config exported from the agent dashboard themes the widget directly.\n /** Alias for {@link assistantBubble}. */\n chatBubbleInbound?: string;\n /** Alias for {@link assistantBubbleText}. */\n chatBubbleInboundText?: string;\n /** Alias for {@link userBubble}. */\n chatBubbleOutbound?: string;\n /** Alias for {@link userBubbleText}. */\n chatBubbleOutboundText?: string;\n}\n\n/**\n * Layout mode for the widget.\n *\n * - `\"popover\"` (default) — the embeddable launcher bubble + floating panel.\n * - `\"fullpage\"` — no launcher; the chat fills its container/viewport with a\n * branded header, a scrollable message list, and an input bar. Ideal for a\n * dedicated support page (`/chat`, a docs site sidebar, an iframe, …).\n */\nexport type ChatWidgetMode = 'popover' | 'fullpage';\n\nexport interface ChatWidgetConfig {\n /**\n * smooth-operator WebSocket endpoint, e.g.\n * `ws://localhost:8787/ws` (local dev) or your deployed `wss://…/ws` URL.\n */\n endpoint: string;\n /**\n * Layout mode — `\"popover\"` (default, launcher + floating panel) or\n * `\"fullpage\"` (chat fills its container; no launcher). See {@link ChatWidgetMode}.\n */\n mode?: ChatWidgetMode;\n /** UUID of the agent to start a conversation session with. */\n agentId: string;\n /** Display name for the agent (header label). Defaults to \"Assistant\". */\n agentName?: string;\n /**\n * Brand logo shown in the full-page header avatar tile; falls back to the\n * Smooth icon. SECURITY: only absolute `http(s)` URLs are honored — any other\n * scheme (`javascript:`/`data:`/…) is ignored, so a hostile config can't\n * inject script.\n */\n logoUrl?: string;\n /** Optional display name for the user participant. */\n userName?: string;\n /** Optional email address for the user participant. */\n userEmail?: string;\n /** Optional phone number for the user participant (passed via session metadata). */\n userPhone?: string;\n /**\n * Optional pre-auth HMAC context. When the host page has a shared secret with\n * the agent, it can sign `{ userId, signature, timestamp }` so the chat-ws\n * wrapper's `/internal/*` identity routes (and the WS create path) verify the\n * caller without an OTP round-trip (ADR-046/ADR-048). Passed through verbatim.\n */\n authContext?: { userId: string; signature: string; timestamp: number };\n /** Placeholder text for the message input. */\n placeholder?: string;\n /** Greeting rendered when the conversation opens (before any messages). */\n greeting?: string;\n /** Message shown when the connection cannot be (re)established. */\n connectionErrorMessage?: string;\n /** Start the panel open instead of collapsed to the launcher. */\n startOpen?: boolean;\n /**\n * Hide the \"powered by smooth-operator\" branding in the header tag and the\n * composer footer. Defaults to `false` (branding shown). The `hide-branding`\n * HTML attribute maps to this.\n */\n hideBranding?: boolean;\n /**\n * Suggested starter prompts shown as clickable chips before the first message.\n * Clicking one sends it. Capped at 5 for layout.\n */\n examplePrompts?: string[];\n /**\n * Show mid-conversation suggested-reply chips (\"quick replies\") under the\n * latest assistant message when the agent returns follow-up suggestions.\n * Clicking one sends it. Defaults to `true` (shown unless explicitly `false`).\n */\n showSuggestedReplies?: boolean;\n /** Require the visitor's name before chatting. */\n requireName?: boolean;\n /** Require the visitor's email before chatting. */\n requireEmail?: boolean;\n /** Require the visitor's phone before chatting. */\n requirePhone?: boolean;\n /**\n * Show the phone field on the pre-chat form (optional unless {@link requirePhone}).\n * Defaults to `true` for this widget — phone rides the session metadata as\n * `userPhone` so the agent can follow up by SMS. Set `false` to hide it.\n */\n collectPhone?: boolean;\n /**\n * Show the email + SMS marketing-consent checkboxes on the pre-chat form.\n * Explicit opt-in, default UNCHECKED; a `consentAt` timestamp is stamped when\n * a box is ticked. Defaults to `true`. The consent record is threaded into the\n * session metadata (ADR-048).\n */\n collectConsent?: boolean;\n /**\n * Offer the cross-device \"Restore my chats\" affordance — an explicit link that\n * runs the identity-OTP → resolve → replay flow. Defaults to `true`.\n */\n allowChatRestore?: boolean;\n /**\n * Let visitors chat without providing any identity. When `true`, the\n * `require*` flags are ignored and the pre-chat form is skipped.\n */\n allowAnonymous?: boolean;\n /** Theme overrides. */\n theme?: ChatWidgetTheme;\n}\n\n/** The fully-resolved theme (canonical keys only — aliases are folded in). */\nexport type ResolvedTheme = Required<Omit<ChatWidgetTheme, 'chatBubbleInbound' | 'chatBubbleInboundText' | 'chatBubbleOutbound' | 'chatBubbleOutboundText'>>;\n\nexport type ResolvedConfig = Required<Omit<ChatWidgetConfig, 'theme' | 'userName' | 'userEmail' | 'userPhone' | 'authContext' | 'logoUrl'>> & {\n theme: ResolvedTheme;\n userName?: string;\n userEmail?: string;\n userPhone?: string;\n authContext?: { userId: string; signature: string; timestamp: number };\n /** Sanitized brand logo URL (`http(s)` only) or `undefined` — see {@link ChatWidgetConfig.logoUrl}. */\n logoUrl?: string;\n};\n\n/** Resolve a partial config against the built-in defaults. */\nexport function resolveConfig(config: ChatWidgetConfig): ResolvedConfig {\n const theme = config.theme ?? {};\n const primary = theme.primary ?? '#00a6a6';\n const primaryText = theme.primaryText ?? '#f8fafc';\n // Dashboard aliases win over canonical keys when present.\n const assistantBubble = theme.chatBubbleInbound ?? theme.assistantBubble ?? '#06134b';\n const assistantBubbleText = theme.chatBubbleInboundText ?? theme.assistantBubbleText ?? '#f8fafc';\n const userBubble = theme.chatBubbleOutbound ?? theme.userBubble ?? primary;\n const userBubbleText = theme.chatBubbleOutboundText ?? theme.userBubbleText ?? primaryText;\n return {\n endpoint: config.endpoint,\n mode: config.mode ?? 'popover',\n agentId: config.agentId,\n agentName: config.agentName ?? 'Assistant',\n // Only absolute http(s) URLs survive — anything else (javascript:/data:/\n // relative) is dropped so the header can never render a hostile logo src.\n logoUrl: safeHttpUrl(config.logoUrl) ?? undefined,\n userName: config.userName,\n userEmail: config.userEmail,\n userPhone: config.userPhone,\n authContext: config.authContext,\n placeholder: config.placeholder ?? 'Type a message…',\n greeting: config.greeting ?? 'Hi! How can I help you today?',\n connectionErrorMessage: config.connectionErrorMessage ?? \"We couldn't reach the chat. Please try again in a moment.\",\n startOpen: config.startOpen ?? false,\n hideBranding: config.hideBranding ?? false,\n examplePrompts: (config.examplePrompts ?? []).filter((p) => p.trim().length > 0).slice(0, 5),\n showSuggestedReplies: config.showSuggestedReplies ?? true,\n requireName: config.requireName ?? false,\n requireEmail: config.requireEmail ?? false,\n requirePhone: config.requirePhone ?? false,\n collectPhone: config.collectPhone ?? true,\n collectConsent: config.collectConsent ?? true,\n allowChatRestore: config.allowChatRestore ?? true,\n allowAnonymous: config.allowAnonymous ?? false,\n theme: {\n text: theme.text ?? '#f8fafc',\n background: theme.background ?? '#040d30',\n primary,\n primaryText,\n secondary: theme.secondary ?? '#ff6b6c',\n assistantBubble,\n assistantBubbleText,\n userBubble,\n userBubbleText,\n border: theme.border ?? 'rgba(255, 255, 255, 0.1)',\n },\n };\n}\n\n/**\n * Whether the pre-chat identity form should gate the conversation: at least one\n * field is required and anonymous chat is not allowed.\n */\nexport function needsUserInfo(resolved: ResolvedConfig): boolean {\n return !resolved.allowAnonymous && (resolved.requireName || resolved.requireEmail || resolved.requirePhone);\n}\n","/**\n * Transport abstraction for the client.\n *\n * The client is deliberately decoupled from any concrete WebSocket implementation\n * so it can be unit-tested with a mock and run on Node, the browser, or a custom\n * socket. A transport is anything that can send a string frame and surface\n * incoming string frames + lifecycle events.\n */\nconst WS_CONNECTING = 0;\nconst WS_OPEN = 1;\nconst WS_CLOSING = 2;\n/** Default connect timeout (ms) for the WebSocket transport. */\nconst DEFAULT_CONNECT_TIMEOUT = 30_000;\n/**\n * Default transport backed by a `WebSocket`-like object. By default it uses the\n * global `WebSocket`; pass a `factory` to inject one (e.g. the `ws` package on\n * Node, or a mock in tests).\n */\nexport class WebSocketTransport {\n socket = null;\n url;\n factory;\n connectTimeout;\n messageHandlers = new Set();\n closeHandlers = new Set();\n errorHandlers = new Set();\n constructor(url, factory, connectTimeout = DEFAULT_CONNECT_TIMEOUT) {\n this.url = url;\n this.connectTimeout = connectTimeout;\n if (factory) {\n this.factory = factory;\n }\n else {\n const G = globalThis;\n if (!G.WebSocket) {\n throw new Error('No global WebSocket available; pass a WebSocketFactory to WebSocketTransport.');\n }\n const Ctor = G.WebSocket;\n this.factory = (u) => new Ctor(u);\n }\n }\n get state() {\n if (!this.socket)\n return 'closed';\n switch (this.socket.readyState) {\n case WS_CONNECTING:\n return 'connecting';\n case WS_OPEN:\n return 'open';\n case WS_CLOSING:\n return 'closing';\n default:\n return 'closed';\n }\n }\n connect() {\n if (this.socket && this.socket.readyState === WS_OPEN)\n return Promise.resolve();\n // A prior socket that never reached OPEN (failed/half-open dial, or a closed\n // socket from a previous attempt) would otherwise be orphaned: its listeners\n // stay registered and keep dispatching into the shared handler sets, so a late\n // message/close from the dead socket double-fires. Close it and detach it\n // before dialing a fresh one. (WebSocketLike has no removeEventListener, so we\n // also guard every handler below with an identity check on `this.socket`.)\n if (this.socket && this.socket.readyState !== WS_OPEN) {\n const stale = this.socket;\n this.socket = null;\n try {\n stale.close();\n }\n catch {\n // ignore — best-effort teardown of a half-open socket\n }\n }\n return new Promise((resolve, reject) => {\n const socket = this.factory(this.url);\n this.socket = socket;\n let settled = false;\n const timer = this.connectTimeout > 0\n ? setTimeout(() => {\n if (settled)\n return;\n settled = true;\n // Tear down the half-open socket so it can't leak / fire later.\n if (this.socket === socket)\n this.socket = null;\n try {\n socket.close();\n }\n catch {\n // ignore\n }\n reject(new Error(`WebSocket connect to ${this.url} timed out after ${this.connectTimeout}ms`));\n }, this.connectTimeout)\n : undefined;\n socket.addEventListener('open', () => {\n // Ignore events from a socket we've already replaced/abandoned.\n if (this.socket !== socket)\n return;\n if (settled)\n return;\n settled = true;\n if (timer)\n clearTimeout(timer);\n resolve();\n });\n socket.addEventListener('error', (ev) => {\n if (this.socket !== socket)\n return;\n for (const h of this.errorHandlers)\n h(ev);\n if (!settled && this.state !== 'open') {\n settled = true;\n if (timer)\n clearTimeout(timer);\n if (this.socket === socket)\n this.socket = null;\n // Release the failed socket so it can't linger / fire later.\n try {\n socket.close();\n }\n catch {\n // ignore\n }\n reject(ev instanceof Error ? ev : new Error('WebSocket connection error'));\n }\n });\n socket.addEventListener('close', (ev) => {\n if (this.socket !== socket)\n return;\n if (timer)\n clearTimeout(timer);\n for (const h of this.closeHandlers)\n h({ code: ev.code, reason: ev.reason });\n });\n socket.addEventListener('message', (ev) => {\n if (this.socket !== socket)\n return;\n const data = typeof ev.data === 'string' ? ev.data : String(ev.data);\n for (const h of this.messageHandlers)\n h(data);\n });\n });\n }\n send(data) {\n if (!this.socket || this.socket.readyState !== WS_OPEN) {\n throw new Error(`Cannot send: transport is \"${this.state}\"`);\n }\n this.socket.send(data);\n }\n close(code, reason) {\n this.socket?.close(code, reason);\n }\n onMessage(handler) {\n this.messageHandlers.add(handler);\n return () => this.messageHandlers.delete(handler);\n }\n onClose(handler) {\n this.closeHandlers.add(handler);\n return () => this.closeHandlers.delete(handler);\n }\n onError(handler) {\n this.errorHandlers.add(handler);\n return () => this.errorHandlers.delete(handler);\n }\n}\n//# sourceMappingURL=transport.js.map","export * from './generated/types.js';\n// ───────────────────────────── Discriminators ──────────────────────────────\n/** Every client→server `action` discriminator value. */\nexport const ACTION_TYPES = [\n 'create_conversation_session',\n 'send_message',\n 'get_session',\n 'get_conversation_messages',\n 'confirm_tool_action',\n 'verify_otp',\n 'ping',\n];\n/** Every server→client `type` discriminator value. */\nexport const EVENT_TYPES = [\n 'immediate_response',\n 'eventual_response',\n 'stream_chunk',\n 'stream_token',\n 'keepalive',\n 'write_confirmation_required',\n 'otp_verification_required',\n 'otp_sent',\n 'otp_verified',\n 'otp_invalid',\n 'error',\n 'pong',\n];\n// ───────────────────────────── Type guards ─────────────────────────────────\n/** True if `frame` is a server event of the given `type`, narrowing accordingly. */\nexport function isEvent(frame, type) {\n return isServerEvent(frame) && frame.type === type;\n}\n/** True if `frame` looks like any server event (has a known `type` discriminator). */\nexport function isServerEvent(frame) {\n return (typeof frame === 'object' &&\n frame !== null &&\n 'type' in frame &&\n typeof frame.type === 'string' &&\n EVENT_TYPES.includes(frame.type));\n}\n/** True if `frame` looks like any client action (has a known `action` discriminator). */\nexport function isClientAction(frame) {\n return (typeof frame === 'object' &&\n frame !== null &&\n 'action' in frame &&\n typeof frame.action === 'string' &&\n ACTION_TYPES.includes(frame.action));\n}\n//# sourceMappingURL=types.js.map","/**\n * SmoothAgentClient — a minimal, idiomatic, transport-agnostic client for the\n * smooth-operator WebSocket protocol.\n *\n * Design goals\n * ------------\n * - **Transport-agnostic.** The client never touches a real socket directly; it\n * talks to an injectable {@link Transport}. The default ({@link WebSocketTransport})\n * uses the global `WebSocket`, but tests inject a mock and Node can inject `ws`.\n * - **Request/response correlation by `requestId`.** Every action gets a generated\n * `requestId`; the client routes incoming events back to the originating call.\n * - **Streaming as an async iterator.** `sendMessage` returns a {@link MessageTurn}\n * that is both awaitable (resolves with the terminal `eventual_response`) and\n * async-iterable (yields each `stream_token` / `stream_chunk` / HITL event in\n * order). This models the `stream_token`/`stream_chunk` → `eventual_response`\n * flow without forcing a callback style on the caller.\n * - **No live server required.** Correctness is fully unit-testable with a mock\n * transport (see `test/client.test.ts`).\n */\nimport { WebSocketTransport, } from './transport.js';\nimport { isServerEvent } from './types.js';\n/** Events that terminate a streaming turn (success or error). */\nconst TURN_TERMINAL = new Set(['eventual_response', 'error']);\n/** A timeout that yields no terminal event. */\nclass RequestTimeoutError extends Error {\n constructor(requestId, ms) {\n super(`Request ${requestId} timed out after ${ms}ms`);\n this.name = 'RequestTimeoutError';\n }\n}\n/**\n * A streaming turn that received no terminal `eventual_response` / `error` within the\n * configured {@link SmoothAgentClientOptions.turnTimeout}. The turn rejects with this\n * and its async iteration throws it, so a stuck server can never hang the caller.\n */\nexport class TurnTimeoutError extends Error {\n requestId;\n constructor(requestId, ms) {\n super(`Turn ${requestId} timed out after ${ms}ms without a terminal response`);\n this.name = 'TurnTimeoutError';\n this.requestId = requestId;\n }\n}\n/** A protocol-level error event surfaced as a throwable. */\nexport class ProtocolError extends Error {\n code;\n requestId;\n constructor(code, message, requestId) {\n super(message);\n this.name = 'ProtocolError';\n this.code = code;\n this.requestId = requestId;\n }\n}\n/**\n * A streaming message turn. Await it for the terminal {@link EventualResponse},\n * or async-iterate it to receive every intermediate event in arrival order.\n *\n * ```ts\n * const turn = client.sendMessage({ sessionId, message: 'hi' });\n * for await (const ev of turn) {\n * if (ev.type === 'stream_token') process.stdout.write(ev.token ?? '');\n * }\n * const final = await turn; // EventualResponse\n * ```\n */\nexport class MessageTurn {\n /** The requestId this turn is correlated on. */\n requestId;\n queue = [];\n waiter = null;\n done = false;\n finalEvent = null;\n error = null;\n settled;\n settle;\n fail;\n onClose;\n timeoutTimer;\n constructor(requestId, onClose, turnTimeout = 0) {\n this.requestId = requestId;\n this.onClose = onClose;\n this.settled = new Promise((resolve, reject) => {\n this.settle = resolve;\n this.fail = reject;\n });\n // Avoid unhandled-rejection noise if the caller only iterates and never awaits.\n this.settled.catch(() => { });\n // Bound the turn: a server that accepts the message but never emits a terminal\n // event must not hang the caller forever.\n if (turnTimeout > 0) {\n this.timeoutTimer = setTimeout(() => {\n this.finish(null, new TurnTimeoutError(this.requestId, turnTimeout));\n }, turnTimeout);\n }\n }\n /** Feed an event into the turn (called by the client's dispatcher). */\n push(event) {\n if (this.done)\n return;\n if (event.type === 'error') {\n const code = event.data?.error?.code ?? 'INTERNAL_ERROR';\n const message = event.data?.error?.message ?? 'Unknown protocol error';\n this.deliver(event);\n this.finish(null, new ProtocolError(code, message, this.requestId));\n return;\n }\n this.deliver(event);\n if (event.type === 'eventual_response') {\n this.finish(event, null);\n }\n }\n /** Force-close the turn (e.g. on disconnect) with an error. */\n abort(err) {\n if (this.done)\n return;\n this.finish(null, err);\n }\n deliver(event) {\n if (this.waiter) {\n const w = this.waiter;\n this.waiter = null;\n w.resolve({ value: event, done: false });\n }\n else {\n this.queue.push(event);\n }\n }\n finish(final, err) {\n if (this.done)\n return;\n this.done = true;\n this.finalEvent = final;\n this.error = err;\n if (this.timeoutTimer) {\n clearTimeout(this.timeoutTimer);\n this.timeoutTimer = undefined;\n }\n this.onClose();\n if (err)\n this.fail(err);\n else if (final)\n this.settle(final);\n // Release any pending iterator waiter now that the stream has ended. On error\n // the parked next() must *reject* (mirroring the queued-error path in next())\n // so a pure `for await` consumer sees the terminal error thrown instead of a\n // silent, indistinguishable `{ done: true }`.\n if (this.waiter) {\n const w = this.waiter;\n this.waiter = null;\n if (err) {\n w.reject(err);\n }\n else {\n w.resolve({ value: undefined, done: true });\n }\n }\n }\n [Symbol.asyncIterator]() {\n return {\n next: () => {\n if (this.queue.length > 0) {\n return Promise.resolve({ value: this.queue.shift(), done: false });\n }\n if (this.done) {\n if (this.error)\n return Promise.reject(this.error);\n return Promise.resolve({ value: undefined, done: true });\n }\n return new Promise((resolve, reject) => {\n this.waiter = { resolve, reject };\n });\n },\n };\n }\n // PromiseLike — `await turn` resolves with the EventualResponse.\n then(onfulfilled, onrejected) {\n return this.settled.then(onfulfilled, onrejected);\n }\n}\nexport class SmoothAgentClient {\n transport;\n generateRequestId;\n requestTimeout;\n turnTimeout;\n /** requestId → single-response waiter (create_session, get_session, ping, …). */\n pending = new Map();\n /** requestId → active streaming turn (send_message, and HITL resumes). */\n turns = new Map();\n /** Unsolicited-event listeners (keepalive, server-push). */\n listeners = new Set();\n unsubscribe = [];\n constructor(options) {\n this.transport =\n options.transport ??\n new WebSocketTransport(withConnectionToken(options.url, options.token), options.webSocketFactory);\n this.requestTimeout = options.requestTimeout ?? 30_000;\n this.turnTimeout = options.turnTimeout ?? 120_000;\n this.generateRequestId =\n options.generateRequestId ??\n (() => `req-${(globalThis.crypto?.randomUUID?.() ?? Math.random().toString(36).slice(2))}`);\n this.unsubscribe.push(this.transport.onMessage((data) => this.handleFrame(data)));\n this.unsubscribe.push(this.transport.onClose(() => this.failAll(new Error('Transport closed'))));\n }\n /** Open the underlying transport. */\n async connect() {\n await this.transport.connect();\n }\n /** Close the transport and reject all in-flight work. */\n disconnect(reason = 'client disconnect') {\n this.failAll(new Error(reason));\n for (const u of this.unsubscribe)\n u();\n this.unsubscribe = [];\n this.transport.close(1000, reason);\n }\n /** Subscribe to unsolicited / uncorrelated server events (e.g. keepalive). */\n onEvent(listener) {\n this.listeners.add(listener);\n return () => this.listeners.delete(listener);\n }\n // ───────────────────────────── Actions ─────────────────────────────────\n /** Start a new conversation session. Resolves with the session descriptor. */\n async createConversationSession(req) {\n const event = await this.request({ action: 'create_conversation_session', ...req });\n return extractImmediateData(event);\n }\n /** Fetch a session snapshot by ID. */\n async getSession(req) {\n const event = await this.request({ action: 'get_session', ...req });\n return extractImmediateData(event);\n }\n /** Fetch a page of conversation messages. */\n async getMessages(req) {\n const event = await this.request({ action: 'get_conversation_messages', ...req });\n return extractImmediateData(event);\n }\n /** Keepalive ping. Resolves with the server timestamp from the `pong` event. */\n async ping() {\n const event = await this.request({ action: 'ping' });\n if (event.type === 'pong')\n return event.timestamp ?? event.data?.timestamp ?? Date.now();\n return Date.now();\n }\n /**\n * Submit a user message and return a {@link MessageTurn}: await it for the\n * terminal `eventual_response`, or async-iterate it for the streaming events.\n */\n sendMessage(req) {\n const requestId = this.generateRequestId();\n const turn = new MessageTurn(requestId, () => this.turns.delete(requestId), this.turnTimeout);\n this.turns.set(requestId, turn);\n try {\n this.transport.send(JSON.stringify({ action: 'send_message', requestId, ...req }));\n }\n catch (err) {\n this.turns.delete(requestId);\n turn.abort(err);\n }\n return turn;\n }\n /**\n * Approve or reject a pending tool write, resuming the paused turn identified\n * by `requestId`. The resumed streaming events flow back into the original\n * {@link MessageTurn} for that `requestId`.\n */\n confirmToolAction(req) {\n this.transport.send(JSON.stringify({ action: 'confirm_tool_action', ...req }));\n }\n /**\n * Submit an OTP code, resuming the paused turn identified by `requestId`.\n * The resumed streaming events flow back into the original {@link MessageTurn}.\n */\n verifyOtp(req) {\n this.transport.send(JSON.stringify({ action: 'verify_otp', ...req }));\n }\n // ─────────────────────────── Internals ─────────────────────────────────\n /** Send an action that expects a single correlated response event. */\n request(action) {\n const requestId = action.requestId ?? this.generateRequestId();\n const frame = { ...action, requestId };\n return new Promise((resolve, reject) => {\n const timer = this.requestTimeout > 0\n ? setTimeout(() => {\n this.pending.delete(requestId);\n reject(new RequestTimeoutError(requestId, this.requestTimeout));\n }, this.requestTimeout)\n : undefined;\n this.pending.set(requestId, { resolve, reject, timer });\n try {\n this.transport.send(JSON.stringify(frame));\n }\n catch (err) {\n if (timer)\n clearTimeout(timer);\n this.pending.delete(requestId);\n reject(err);\n }\n });\n }\n /** Parse and route an incoming frame to the right consumer. */\n handleFrame(data) {\n let frame;\n try {\n frame = JSON.parse(data);\n }\n catch {\n return; // ignore malformed frames\n }\n if (!isServerEvent(frame))\n return;\n const event = frame;\n const requestId = event.requestId;\n // 1. Streaming turn? Route every related event into it.\n if (requestId && this.turns.has(requestId)) {\n this.turns.get(requestId).push(event);\n return;\n }\n // 2. Single-response request awaiting resolution?\n if (requestId && this.pending.has(requestId)) {\n const pending = this.pending.get(requestId);\n this.pending.delete(requestId);\n if (pending.timer)\n clearTimeout(pending.timer);\n if (event.type === 'error') {\n const code = event.data?.error?.code ?? 'INTERNAL_ERROR';\n const message = event.data?.error?.message ?? 'Unknown protocol error';\n pending.reject(new ProtocolError(code, message, requestId));\n }\n else {\n pending.resolve(event);\n }\n return;\n }\n // 3. Unsolicited / uncorrelated event (keepalive, server push).\n for (const l of this.listeners)\n l(event);\n }\n failAll(err) {\n for (const [, p] of this.pending) {\n if (p.timer)\n clearTimeout(p.timer);\n p.reject(err);\n }\n this.pending.clear();\n for (const [, turn] of this.turns)\n turn.abort(err);\n this.turns.clear();\n }\n}\n/**\n * Merge a connection auth `token` into a WebSocket URL as a `?token=` query param,\n * preserving any existing query string. Returns `url` unchanged when no token is\n * given, so the no-token path is byte-for-byte identical to before. Uses `URL` /\n * `URLSearchParams` so an existing `?foo=bar` becomes `?foo=bar&token=…` (and the\n * value is properly percent-encoded) rather than a naive `?`/`&` string-concat.\n *\n * Falls back to manual concatenation if `url` is not absolute (so `URL` can't parse\n * it) — e.g. a relative or mock URL used in tests.\n */\nfunction withConnectionToken(url, token) {\n if (!token)\n return url;\n try {\n const parsed = new URL(url);\n parsed.searchParams.set('token', token);\n return parsed.toString();\n }\n catch {\n const separator = url.includes('?') ? '&' : '?';\n return `${url}${separator}token=${encodeURIComponent(token)}`;\n }\n}\n/** Pull the typed `data` payload out of an `immediate_response` event. */\nfunction extractImmediateData(event) {\n if (event.type === 'immediate_response')\n return event.data;\n // Some servers may answer a non-streaming action with the payload elsewhere;\n // fall back to `data` if present.\n if ('data' in event && event.data && typeof event.data === 'object')\n return event.data;\n throw new ProtocolError('UNEXPECTED_EVENT', `Expected immediate_response, got \"${event.type}\"`, event.requestId);\n}\n//# sourceMappingURL=client.js.map","/**\n * Browser fingerprint — a stable, privacy-light identifier used by the\n * smooth-operator server to correlate an anonymous visitor's sessions across\n * page loads (and, server-side, to match an anonymous fingerprint to a known\n * CRM contact). It rides every `create_conversation_session` as\n * `browserFingerprint` (see ADR-048).\n *\n * ## Why not ThumbmarkJS\n *\n * The ADR floats ThumbmarkJS as the reference implementation. For an *embed*\n * that is injected onto arbitrary host pages, ThumbmarkJS is too heavy: its\n * full build pulls in extensive device-detection tables and async\n * component collection, adding tens of kilobytes (and async surface) to a\n * bundle whose whole selling point is staying out of the host page's\n * LCP/TBT budget. The fingerprint here is a few hundred bytes.\n *\n * ## What this is (and the tradeoff)\n *\n * The correlation that actually matters — \"is this the same browser as last\n * time?\" — is carried by a **persisted random UUID** (the `browserFingerprint`\n * field in the persisted store). That UUID is generated once and reused for\n * the life of the localStorage entry, so same-browser resume is exact and\n * deterministic. The signal hash below is a best-effort entropy *supplement*\n * mixed into that UUID's derivation seed on first generation — it gives the\n * server-side resolver a soft signal for the (rare) cross-storage case where\n * the UUID was cleared but the device is unchanged. It is intentionally NOT a\n * high-entropy device fingerprint: no canvas/WebGL/audio probes, no font\n * enumeration, nothing that reads as invasive tracking. The tradeoff is weaker\n * cross-storage matching in exchange for a tiny, transparent, no-network,\n * XSS-safe implementation. The server's resolver (SMOODEV-2129d) is the source\n * of truth for any fuzzy matching; the client just supplies a stable token.\n */\n\n/** Collect a small set of stable, non-invasive browser signals. */\nfunction collectSignals(): string {\n const parts: string[] = [];\n try {\n const nav = typeof navigator !== 'undefined' ? navigator : undefined;\n if (nav) {\n parts.push(`ua:${nav.userAgent ?? ''}`);\n parts.push(`lang:${nav.language ?? ''}`);\n parts.push(`langs:${Array.isArray(nav.languages) ? nav.languages.join(',') : ''}`);\n // `platform` is deprecated but still widely present and stable.\n parts.push(`plat:${(nav as Navigator & { platform?: string }).platform ?? ''}`);\n parts.push(`hc:${(nav as Navigator & { hardwareConcurrency?: number }).hardwareConcurrency ?? ''}`);\n parts.push(`dm:${(nav as Navigator & { deviceMemory?: number }).deviceMemory ?? ''}`);\n }\n if (typeof screen !== 'undefined') {\n parts.push(`scr:${screen.width}x${screen.height}x${screen.colorDepth}`);\n }\n if (typeof Intl !== 'undefined') {\n try {\n parts.push(`tz:${Intl.DateTimeFormat().resolvedOptions().timeZone ?? ''}`);\n } catch {\n /* resolvedOptions can throw in locked-down environments */\n }\n }\n parts.push(`tzo:${new Date().getTimezoneOffset()}`);\n } catch {\n /* a hostile/locked-down navigator must never break widget boot */\n }\n return parts.join('|');\n}\n\n/**\n * A small, fast, non-cryptographic string hash (FNV-1a, 32-bit) rendered as\n * an unsigned hex string. Stable across runs for the same input. Not used for\n * any security decision — only to derive a deterministic seed from the signal\n * string above.\n */\nfunction fnv1a(input: string): string {\n let h = 0x811c9dc5;\n for (let i = 0; i < input.length; i++) {\n h ^= input.charCodeAt(i);\n // 32-bit FNV prime multiply via shifts to stay in int range.\n h = Math.imul(h, 0x01000193);\n }\n // >>> 0 → unsigned; pad to 8 hex chars.\n return (h >>> 0).toString(16).padStart(8, '0');\n}\n\n/** Generate a UUID, preferring `crypto.randomUUID`, falling back to a v4-shaped string. */\nfunction generateUuid(): string {\n try {\n if (typeof crypto !== 'undefined' && typeof crypto.randomUUID === 'function') {\n return crypto.randomUUID();\n }\n } catch {\n /* fall through to the manual generator */\n }\n // RFC 4122 v4 shape from Math.random — only reached when crypto.randomUUID\n // is unavailable (very old engines). Sufficient for a correlation token.\n return 'xxxxxxxx-xxxx-4xxx-yxxx-xxxxxxxxxxxx'.replace(/[xy]/g, (c) => {\n const r = (Math.random() * 16) | 0;\n const v = c === 'x' ? r : (r & 0x3) | 0x8;\n return v.toString(16);\n });\n}\n\n/**\n * Compute a fresh fingerprint token: a stable random UUID, suffixed with the\n * FNV hash of the device signals so the server can recover a soft device\n * signal even if it only has the token. Called ONCE per browser (the result is\n * persisted and reused) — see {@link getOrCreateFingerprint}.\n */\nexport function computeFingerprint(): string {\n const signalHash = fnv1a(collectSignals());\n return `${generateUuid()}.${signalHash}`;\n}\n\n/**\n * Return the cached fingerprint if one was already computed for this browser,\n * otherwise compute + persist a new one via the provided accessors. The\n * persistence layer owns storage; this function owns the \"compute once\" policy.\n */\nexport function getOrCreateFingerprint(get: () => string | null, set: (fp: string) => void): string {\n const existing = get();\n if (existing) return existing;\n const fp = computeFingerprint();\n set(fp);\n return fp;\n}\n","const createStoreImpl = (createState) => {\n let state;\n const listeners = /* @__PURE__ */ new Set();\n const setState = (partial, replace) => {\n const nextState = typeof partial === \"function\" ? partial(state) : partial;\n if (!Object.is(nextState, state)) {\n const previousState = state;\n state = (replace != null ? replace : typeof nextState !== \"object\" || nextState === null) ? nextState : Object.assign({}, state, nextState);\n listeners.forEach((listener) => listener(state, previousState));\n }\n };\n const getState = () => state;\n const getInitialState = () => initialState;\n const subscribe = (listener) => {\n listeners.add(listener);\n return () => listeners.delete(listener);\n };\n const api = { setState, getState, getInitialState, subscribe };\n const initialState = state = createState(setState, getState, api);\n return api;\n};\nconst createStore = ((createState) => createState ? createStoreImpl(createState) : createStoreImpl);\n\nexport { createStore };\n","const reduxImpl = (reducer, initial) => (set, _get, api) => {\n api.dispatch = (action) => {\n set((state) => reducer(state, action), false, action);\n return action;\n };\n api.dispatchFromDevtools = true;\n return { dispatch: (...args) => api.dispatch(...args), ...initial };\n};\nconst redux = reduxImpl;\n\nconst shouldDispatchFromDevtools = (api) => !!api.dispatchFromDevtools && typeof api.dispatch === \"function\";\nconst trackedConnections = /* @__PURE__ */ new Map();\nconst getTrackedConnectionState = (name) => {\n const api = trackedConnections.get(name);\n if (!api) return {};\n return Object.fromEntries(\n Object.entries(api.stores).map(([key, api2]) => [key, api2.getState()])\n );\n};\nconst extractConnectionInformation = (store, extensionConnector, options) => {\n if (store === void 0) {\n return {\n type: \"untracked\",\n connection: extensionConnector.connect(options)\n };\n }\n const existingConnection = trackedConnections.get(options.name);\n if (existingConnection) {\n return { type: \"tracked\", store, ...existingConnection };\n }\n const newConnection = {\n connection: extensionConnector.connect(options),\n stores: {}\n };\n trackedConnections.set(options.name, newConnection);\n return { type: \"tracked\", store, ...newConnection };\n};\nconst removeStoreFromTrackedConnections = (name, store) => {\n if (store === void 0) return;\n const connectionInfo = trackedConnections.get(name);\n if (!connectionInfo) return;\n delete connectionInfo.stores[store];\n if (Object.keys(connectionInfo.stores).length === 0) {\n trackedConnections.delete(name);\n }\n};\nconst v8StackLineRe = /.+ (.+) .+/;\nconst geckoStackLineRe = /^([^@]+)@/;\nfunction findCallerName(stack) {\n var _a, _b, _c;\n if (!stack) return void 0;\n const traceLines = stack.split(\"\\n\");\n const apiSetStateLineIndex = traceLines.findIndex(\n (traceLine) => traceLine.includes(\"api.setState\")\n );\n if (apiSetStateLineIndex < 0) return void 0;\n const callerLine = ((_a = traceLines[apiSetStateLineIndex + 1]) == null ? void 0 : _a.trim()) || \"\";\n return ((_b = v8StackLineRe.exec(callerLine)) == null ? void 0 : _b[1]) || ((_c = geckoStackLineRe.exec(callerLine)) == null ? void 0 : _c[1]);\n}\nconst devtoolsImpl = (fn, devtoolsOptions = {}) => (set, get, api) => {\n const { enabled, anonymousActionType, store, ...options } = devtoolsOptions;\n let extensionConnector;\n try {\n extensionConnector = (enabled != null ? enabled : (import.meta.env ? import.meta.env.MODE : void 0) !== \"production\") && window.__REDUX_DEVTOOLS_EXTENSION__;\n } catch (e) {\n }\n if (!extensionConnector) {\n return fn(set, get, api);\n }\n const { connection, ...connectionInformation } = extractConnectionInformation(store, extensionConnector, options);\n let isRecording = true;\n api.setState = ((state, replace, nameOrAction) => {\n const r = set(state, replace);\n if (!isRecording) return r;\n const action = nameOrAction === void 0 ? {\n type: anonymousActionType || findCallerName(new Error().stack) || \"anonymous\"\n } : typeof nameOrAction === \"string\" ? { type: nameOrAction } : nameOrAction;\n if (store === void 0) {\n connection == null ? void 0 : connection.send(action, get());\n return r;\n }\n connection == null ? void 0 : connection.send(\n {\n ...action,\n type: `${store}/${action.type}`\n },\n {\n ...getTrackedConnectionState(options.name),\n [store]: api.getState()\n }\n );\n return r;\n });\n api.devtools = {\n cleanup: () => {\n if (connection && typeof connection.unsubscribe === \"function\") {\n connection.unsubscribe();\n }\n removeStoreFromTrackedConnections(options.name, store);\n }\n };\n const setStateFromDevtools = (...a) => {\n const originalIsRecording = isRecording;\n isRecording = false;\n set(...a);\n isRecording = originalIsRecording;\n };\n const initialState = fn(api.setState, get, api);\n if (connectionInformation.type === \"untracked\") {\n connection == null ? void 0 : connection.init(initialState);\n } else {\n connectionInformation.stores[connectionInformation.store] = api;\n connection == null ? void 0 : connection.init(\n Object.fromEntries(\n Object.entries(connectionInformation.stores).map(([key, store2]) => [\n key,\n key === connectionInformation.store ? initialState : store2.getState()\n ])\n )\n );\n }\n if (shouldDispatchFromDevtools(api)) {\n let didWarnAboutReservedActionType = false;\n const originalDispatch = api.dispatch;\n api.dispatch = (...args) => {\n if ((import.meta.env ? import.meta.env.MODE : void 0) !== \"production\" && args[0].type === \"__setState\" && !didWarnAboutReservedActionType) {\n console.warn(\n '[zustand devtools middleware] \"__setState\" action type is reserved to set state from the devtools. Avoid using it.'\n );\n didWarnAboutReservedActionType = true;\n }\n originalDispatch(...args);\n };\n }\n connection.subscribe((message) => {\n var _a;\n switch (message.type) {\n case \"ACTION\":\n if (typeof message.payload !== \"string\") {\n console.error(\n \"[zustand devtools middleware] Unsupported action format\"\n );\n return;\n }\n return parseJsonThen(\n message.payload,\n (action) => {\n if (action.type === \"__setState\") {\n if (store === void 0) {\n setStateFromDevtools(action.state);\n return;\n }\n if (Object.keys(action.state).length !== 1) {\n console.error(\n `\n [zustand devtools middleware] Unsupported __setState action format.\n When using 'store' option in devtools(), the 'state' should have only one key, which is a value of 'store' that was passed in devtools(),\n and value of this only key should be a state object. Example: { \"type\": \"__setState\", \"state\": { \"abc123Store\": { \"foo\": \"bar\" } } }\n `\n );\n }\n const stateFromDevtools = action.state[store];\n if (stateFromDevtools === void 0 || stateFromDevtools === null) {\n return;\n }\n if (JSON.stringify(api.getState()) !== JSON.stringify(stateFromDevtools)) {\n setStateFromDevtools(stateFromDevtools);\n }\n return;\n }\n if (shouldDispatchFromDevtools(api)) {\n api.dispatch(action);\n }\n }\n );\n case \"DISPATCH\":\n switch (message.payload.type) {\n case \"RESET\":\n setStateFromDevtools(initialState);\n if (store === void 0) {\n return connection == null ? void 0 : connection.init(api.getState());\n }\n return connection == null ? void 0 : connection.init(getTrackedConnectionState(options.name));\n case \"COMMIT\":\n if (store === void 0) {\n connection == null ? void 0 : connection.init(api.getState());\n return;\n }\n return connection == null ? void 0 : connection.init(getTrackedConnectionState(options.name));\n case \"ROLLBACK\":\n return parseJsonThen(message.state, (state) => {\n if (store === void 0) {\n setStateFromDevtools(state);\n connection == null ? void 0 : connection.init(api.getState());\n return;\n }\n setStateFromDevtools(state[store]);\n connection == null ? void 0 : connection.init(getTrackedConnectionState(options.name));\n });\n case \"JUMP_TO_STATE\":\n case \"JUMP_TO_ACTION\":\n return parseJsonThen(message.state, (state) => {\n if (store === void 0) {\n setStateFromDevtools(state);\n return;\n }\n if (JSON.stringify(api.getState()) !== JSON.stringify(state[store])) {\n setStateFromDevtools(state[store]);\n }\n });\n case \"IMPORT_STATE\": {\n const { nextLiftedState } = message.payload;\n const lastComputedState = (_a = nextLiftedState.computedStates.slice(-1)[0]) == null ? void 0 : _a.state;\n if (!lastComputedState) return;\n if (store === void 0) {\n setStateFromDevtools(lastComputedState);\n } else {\n setStateFromDevtools(lastComputedState[store]);\n }\n connection == null ? void 0 : connection.send(\n null,\n // FIXME no-any\n nextLiftedState\n );\n return;\n }\n case \"PAUSE_RECORDING\":\n return isRecording = !isRecording;\n }\n return;\n }\n });\n return initialState;\n};\nconst devtools = devtoolsImpl;\nconst parseJsonThen = (stringified, fn) => {\n let parsed;\n try {\n parsed = JSON.parse(stringified);\n } catch (e) {\n console.error(\n \"[zustand devtools middleware] Could not parse the received json\",\n e\n );\n }\n if (parsed !== void 0) fn(parsed);\n};\n\nconst subscribeWithSelectorImpl = (fn) => (set, get, api) => {\n const origSubscribe = api.subscribe;\n api.subscribe = ((selector, optListener, options) => {\n let listener = selector;\n if (optListener) {\n const equalityFn = (options == null ? void 0 : options.equalityFn) || Object.is;\n let currentSlice = selector(api.getState());\n listener = (state) => {\n const nextSlice = selector(state);\n if (!equalityFn(currentSlice, nextSlice)) {\n const previousSlice = currentSlice;\n optListener(currentSlice = nextSlice, previousSlice);\n }\n };\n if (options == null ? void 0 : options.fireImmediately) {\n optListener(currentSlice, currentSlice);\n }\n }\n return origSubscribe(listener);\n });\n const initialState = fn(set, get, api);\n return initialState;\n};\nconst subscribeWithSelector = subscribeWithSelectorImpl;\n\nfunction combine(initialState, create) {\n return (...args) => Object.assign({}, initialState, create(...args));\n}\n\nfunction createJSONStorage(getStorage, options) {\n let storage;\n try {\n storage = getStorage();\n } catch (e) {\n return;\n }\n const persistStorage = {\n getItem: (name) => {\n var _a;\n const parse = (str2) => {\n if (str2 === null) {\n return null;\n }\n return JSON.parse(str2, options == null ? void 0 : options.reviver);\n };\n const str = (_a = storage.getItem(name)) != null ? _a : null;\n if (str instanceof Promise) {\n return str.then(parse);\n }\n return parse(str);\n },\n setItem: (name, newValue) => storage.setItem(name, JSON.stringify(newValue, options == null ? void 0 : options.replacer)),\n removeItem: (name) => storage.removeItem(name)\n };\n return persistStorage;\n}\nconst toThenable = (fn) => (input) => {\n try {\n const result = fn(input);\n if (result instanceof Promise) {\n return result;\n }\n return {\n then(onFulfilled) {\n return toThenable(onFulfilled)(result);\n },\n catch(_onRejected) {\n return this;\n }\n };\n } catch (e) {\n return {\n then(_onFulfilled) {\n return this;\n },\n catch(onRejected) {\n return toThenable(onRejected)(e);\n }\n };\n }\n};\nconst persistImpl = (config, baseOptions) => (set, get, api) => {\n let options = {\n storage: createJSONStorage(() => window.localStorage),\n partialize: (state) => state,\n version: 0,\n merge: (persistedState, currentState) => ({\n ...currentState,\n ...persistedState\n }),\n ...baseOptions\n };\n let hasHydrated = false;\n let hydrationVersion = 0;\n const hydrationListeners = /* @__PURE__ */ new Set();\n const finishHydrationListeners = /* @__PURE__ */ new Set();\n let storage = options.storage;\n if (!storage) {\n return config(\n (...args) => {\n console.warn(\n `[zustand persist middleware] Unable to update item '${options.name}', the given storage is currently unavailable.`\n );\n set(...args);\n },\n get,\n api\n );\n }\n const setItem = () => {\n const state = options.partialize({ ...get() });\n return storage.setItem(options.name, {\n state,\n version: options.version\n });\n };\n const savedSetState = api.setState;\n api.setState = (state, replace) => {\n savedSetState(state, replace);\n return setItem();\n };\n const configResult = config(\n (...args) => {\n set(...args);\n return setItem();\n },\n get,\n api\n );\n api.getInitialState = () => configResult;\n let stateFromStorage;\n const hydrate = () => {\n var _a, _b;\n if (!storage) return;\n const currentVersion = ++hydrationVersion;\n hasHydrated = false;\n hydrationListeners.forEach((cb) => {\n var _a2;\n return cb((_a2 = get()) != null ? _a2 : configResult);\n });\n const postRehydrationCallback = ((_b = options.onRehydrateStorage) == null ? void 0 : _b.call(options, (_a = get()) != null ? _a : configResult)) || void 0;\n return toThenable(storage.getItem.bind(storage))(options.name).then((deserializedStorageValue) => {\n if (deserializedStorageValue) {\n if (typeof deserializedStorageValue.version === \"number\" && deserializedStorageValue.version !== options.version) {\n if (options.migrate) {\n const migration = options.migrate(\n deserializedStorageValue.state,\n deserializedStorageValue.version\n );\n if (migration instanceof Promise) {\n return migration.then((result) => [true, result]);\n }\n return [true, migration];\n }\n console.error(\n `State loaded from storage couldn't be migrated since no migrate function was provided`\n );\n } else {\n return [false, deserializedStorageValue.state];\n }\n }\n return [false, void 0];\n }).then((migrationResult) => {\n var _a2;\n if (currentVersion !== hydrationVersion) {\n return;\n }\n const [migrated, migratedState] = migrationResult;\n stateFromStorage = options.merge(\n migratedState,\n (_a2 = get()) != null ? _a2 : configResult\n );\n set(stateFromStorage, true);\n if (migrated) {\n return setItem();\n }\n }).then(() => {\n if (currentVersion !== hydrationVersion) {\n return;\n }\n postRehydrationCallback == null ? void 0 : postRehydrationCallback(get(), void 0);\n stateFromStorage = get();\n hasHydrated = true;\n finishHydrationListeners.forEach((cb) => cb(stateFromStorage));\n }).catch((e) => {\n if (currentVersion !== hydrationVersion) {\n return;\n }\n postRehydrationCallback == null ? void 0 : postRehydrationCallback(void 0, e);\n });\n };\n api.persist = {\n setOptions: (newOptions) => {\n options = {\n ...options,\n ...newOptions\n };\n if (newOptions.storage) {\n storage = newOptions.storage;\n }\n },\n clearStorage: () => {\n storage == null ? void 0 : storage.removeItem(options.name);\n },\n getOptions: () => options,\n rehydrate: () => hydrate(),\n hasHydrated: () => hasHydrated,\n onHydrate: (cb) => {\n hydrationListeners.add(cb);\n return () => {\n hydrationListeners.delete(cb);\n };\n },\n onFinishHydration: (cb) => {\n finishHydrationListeners.add(cb);\n return () => {\n finishHydrationListeners.delete(cb);\n };\n }\n };\n if (!options.skipHydration) {\n hydrate();\n }\n return stateFromStorage || configResult;\n};\nconst persist = persistImpl;\n\nfunction ssrSafe(config, isSSR = typeof window === \"undefined\") {\n return (set, get, api) => {\n if (!isSSR) {\n return config(set, get, api);\n }\n const ssrSet = () => {\n throw new Error(\"Cannot set state of Zustand store in SSR\");\n };\n api.setState = ssrSet;\n return config(ssrSet, get, api);\n };\n}\n\nexport { combine, createJSONStorage, devtools, persist, redux, subscribeWithSelector, ssrSafe as unstable_ssrSafe };\n","/**\n * Persisted widget state — the identity / consent / session-pointer client layer\n * (ADR-048, SMOODEV-2129e).\n *\n * Built on Zustand's framework-agnostic `vanilla` store + the `persist`\n * middleware (the user explicitly chose Zustand; it's ~1KB and has no React\n * dependency, so it works inside the web component). The store is keyed per\n * agent — localStorage key `smoo-chat-widget:<agentId>` — so two agents embedded\n * on the same origin don't clobber each other.\n *\n * ## What persists (and, deliberately, what does NOT)\n *\n * Only a **pointer** to the conversation plus the visitor's identity + marketing\n * consent + verified email + browser fingerprint. The transcript is **never**\n * persisted: the smooth-operator server is the source of truth and the widget\n * re-hydrates history via `getMessages` on resume. This keeps localStorage small\n * and avoids stale/divergent transcripts.\n *\n * `version` drives `persist.migrate` so future shape changes can upgrade old\n * blobs in place instead of silently dropping them.\n */\nimport { createStore, type StoreApi } from 'zustand/vanilla';\nimport { persist, type PersistStorage } from 'zustand/middleware';\n\n/** Current persisted-shape version. Bump when the shape below changes incompatibly. */\nexport const PERSIST_VERSION = 1 as const;\n\n/** Marketing-consent record captured at the pre-chat form. */\nexport interface ConsentState {\n emailOptIn: boolean;\n smsOptIn: boolean;\n /** Where the consent was captured. The widget always stamps `chat-widget-prechat`. */\n consentSource?: string;\n /** ISO 8601 timestamp stamped when the visitor ticked a consent box. */\n consentAt?: string;\n}\n\n/** Visitor identity collected from config or the pre-chat form. */\nexport interface IdentityState {\n name?: string;\n email?: string;\n phone?: string;\n}\n\n/**\n * The exact persisted shape (ADR-048 §d). Only the pointer + identity + consent\n * persist — never the transcript.\n */\nexport interface PersistedWidgetState {\n version: typeof PERSIST_VERSION;\n /** Pointer to the active conversation session; cleared on ended/404. */\n sessionId: string | null;\n identity: IdentityState;\n consent: ConsentState;\n /**\n * Email proven via OTP for the CURRENT session. Session-scoped: cleared on\n * `clearSession()` so it can't leak across visitors on a shared browser, and\n * only threaded into session metadata when {@link verifiedEmailSessionId}\n * matches the live session (i.e. on resume of the verified session) — never\n * auto-stamped onto a brand-new session.\n */\n verifiedEmail: string | null;\n /** The sessionId the {@link verifiedEmail} was proven against (binds the proof to one session). */\n verifiedEmailSessionId: string | null;\n /** Stable per-browser correlation token (see fingerprint.ts). */\n browserFingerprint: string | null;\n}\n\n/** Store actions layered on top of the persisted state. */\nexport interface WidgetStoreActions {\n setSessionId: (sessionId: string | null) => void;\n /** Merge identity fields (undefined values don't clobber existing ones). */\n mergeIdentity: (identity: IdentityState) => void;\n /** Replace consent wholesale (the pre-chat form computes the full record). */\n setConsent: (consent: ConsentState) => void;\n /** Record an OTP-proven email bound to a specific session. */\n setVerifiedEmail: (email: string | null, sessionId?: string | null) => void;\n setBrowserFingerprint: (fp: string) => void;\n /**\n * Clear the session pointer (and the session-scoped `verifiedEmail` proof) but\n * KEEP identity / consent / fingerprint — used when a persisted session has\n * ended or 404s so the next turn starts a fresh session for a known visitor.\n * `verifiedEmail` is deliberately cleared here: it is a per-session OTP proof,\n * not a durable identity, so it must NOT survive onto a new session (which on a\n * shared browser could be a different visitor).\n */\n clearSession: () => void;\n}\n\nexport type WidgetStore = PersistedWidgetState & WidgetStoreActions;\n\nconst EMPTY_CONSENT: ConsentState = { emailOptIn: false, smsOptIn: false };\n\nfunction initialPersisted(): PersistedWidgetState {\n return {\n version: PERSIST_VERSION,\n sessionId: null,\n identity: {},\n consent: { ...EMPTY_CONSENT },\n verifiedEmail: null,\n verifiedEmailSessionId: null,\n browserFingerprint: null,\n };\n}\n\n/** localStorage key for an agent's persisted widget state. */\nexport function storageKey(agentId: string): string {\n return `smoo-chat-widget:${agentId}`;\n}\n\n/**\n * An explicit in-memory (Map-backed) `PersistStorage`. Used as the fallback when\n * real localStorage is unavailable.\n *\n * IMPORTANT: we must NOT return `undefined` from {@link safeStorage} in that case.\n * zustand v5's `persist` treats a missing `storage` option by falling back to its\n * OWN `createJSONStorage(() => localStorage)` — i.e. it re-engages the very\n * localStorage the guard was trying to avoid (throwing again in privacy mode).\n * Handing it this no-op storage keeps the store working purely in memory and\n * guarantees the fallback can't touch real localStorage.\n */\nfunction memoryStorage(): PersistStorage<PersistedWidgetState> {\n const mem = new Map<string, string>();\n return {\n getItem: (name) => {\n const raw = mem.get(name);\n if (!raw) return null;\n try {\n return JSON.parse(raw) as ReturnType<PersistStorage<PersistedWidgetState>['getItem']>;\n } catch {\n return null;\n }\n },\n setItem: (name, value) => {\n mem.set(name, JSON.stringify(value));\n },\n removeItem: (name) => {\n mem.delete(name);\n },\n };\n}\n\n/**\n * A `persist` storage adapter that tolerates the *absence* of localStorage\n * (SSR, privacy-mode throwing on access, sandboxed iframes). When storage is\n * unavailable the store still works in-memory; nothing is persisted, but the\n * widget never throws on boot.\n */\nfunction safeStorage(): PersistStorage<PersistedWidgetState> {\n let ls: Storage | null = null;\n try {\n ls = typeof localStorage !== 'undefined' ? localStorage : null;\n // Probe: some environments expose localStorage but throw on access.\n if (ls) {\n const probe = '__smoo_probe__';\n ls.setItem(probe, '1');\n ls.removeItem(probe);\n }\n } catch {\n ls = null;\n }\n // Fall back to an explicit in-memory store — NEVER `undefined` (see memoryStorage).\n if (!ls) return memoryStorage();\n const storage = ls;\n return {\n getItem: (name) => {\n try {\n const raw = storage.getItem(name);\n return raw ? (JSON.parse(raw) as ReturnType<PersistStorage<PersistedWidgetState>['getItem']>) : null;\n } catch {\n return null;\n }\n },\n setItem: (name, value) => {\n try {\n storage.setItem(name, JSON.stringify(value));\n } catch {\n /* quota / privacy-mode write failures are non-fatal */\n }\n },\n removeItem: (name) => {\n try {\n storage.removeItem(name);\n } catch {\n /* non-fatal */\n }\n },\n };\n}\n\n/**\n * Migrate a persisted blob from an older `version` to the current shape. Today\n * v1 is the only version, so this just backfills any missing fields onto an\n * unknown old blob; future versions add `case` branches here.\n */\nfunction migrate(persisted: unknown): PersistedWidgetState {\n const base = initialPersisted();\n if (!persisted || typeof persisted !== 'object') return base;\n const p = persisted as Partial<PersistedWidgetState>;\n return {\n version: PERSIST_VERSION,\n sessionId: typeof p.sessionId === 'string' ? p.sessionId : null,\n identity: {\n name: typeof p.identity?.name === 'string' ? p.identity.name : undefined,\n email: typeof p.identity?.email === 'string' ? p.identity.email : undefined,\n phone: typeof p.identity?.phone === 'string' ? p.identity.phone : undefined,\n },\n consent: {\n emailOptIn: p.consent?.emailOptIn === true,\n smsOptIn: p.consent?.smsOptIn === true,\n consentSource: typeof p.consent?.consentSource === 'string' ? p.consent.consentSource : undefined,\n consentAt: typeof p.consent?.consentAt === 'string' ? p.consent.consentAt : undefined,\n },\n verifiedEmail: typeof p.verifiedEmail === 'string' ? p.verifiedEmail : null,\n verifiedEmailSessionId: typeof p.verifiedEmailSessionId === 'string' ? p.verifiedEmailSessionId : null,\n browserFingerprint: typeof p.browserFingerprint === 'string' ? p.browserFingerprint : null,\n };\n}\n\n/**\n * Create the per-agent persisted Zustand store. The `partialize` step ensures\n * only the persisted shape (never any future transient action/UI state) is\n * written to localStorage.\n */\nexport function createWidgetStore(agentId: string): StoreApi<WidgetStore> {\n return createStore<WidgetStore>()(\n persist(\n (set) => ({\n ...initialPersisted(),\n setSessionId: (sessionId) => set({ sessionId }),\n mergeIdentity: (identity) =>\n set((state) => ({\n identity: {\n ...state.identity,\n ...(identity.name !== undefined ? { name: identity.name } : {}),\n ...(identity.email !== undefined ? { email: identity.email } : {}),\n ...(identity.phone !== undefined ? { phone: identity.phone } : {}),\n },\n })),\n setConsent: (consent) => set({ consent: { ...consent } }),\n setVerifiedEmail: (verifiedEmail, sessionId) =>\n set((state) => ({\n verifiedEmail,\n // Bind the proof to the session it was verified against. When the\n // caller omits sessionId, fall back to the live pointer so the\n // proof is never left unbound.\n verifiedEmailSessionId: verifiedEmail === null ? null : (sessionId ?? state.sessionId),\n })),\n setBrowserFingerprint: (browserFingerprint) => set({ browserFingerprint }),\n // Drop the pointer AND the session-scoped OTP proof; keep durable identity.\n clearSession: () => set({ sessionId: null, verifiedEmail: null, verifiedEmailSessionId: null }),\n }),\n {\n name: storageKey(agentId),\n version: PERSIST_VERSION,\n storage: safeStorage(),\n migrate,\n // Persist ONLY the data shape — never the action functions.\n partialize: (state): PersistedWidgetState => ({\n version: PERSIST_VERSION,\n sessionId: state.sessionId,\n identity: state.identity,\n consent: state.consent,\n verifiedEmail: state.verifiedEmail,\n verifiedEmailSessionId: state.verifiedEmailSessionId,\n browserFingerprint: state.browserFingerprint,\n }),\n },\n ),\n );\n}\n","/**\n * ConversationController — the bridge between the widget UI and the\n * `@smooai/smooth-operator` protocol client.\n *\n * This is the piece that was rewired: the original smooai widget spoke to\n * `@smooai/realtime`; here every protocol action goes through {@link SmoothAgentClient}.\n * The wire shapes are identical (the protocol was lifted from `@smooai/realtime`),\n * so the swap is purely at the client-library boundary.\n *\n * Flow:\n * 1. `connect()` → opens the WebSocket transport and `create_conversation_session`\n * (or RESUMES a persisted session via `get_session`/`get_messages`).\n * 2. `send(text)` → `send_message`, streaming `stream_token` deltas into the\n * in-progress assistant message, then the terminal\n * `eventual_response`.\n *\n * 0.7.0 (SMOODEV-2129e) adds the identity / persistence / consent client layer:\n * - `browserFingerprint` computed once + sent on every `create_conversation_session`.\n * - identity + marketing consent threaded into the session `metadata`.\n * - same-session RESUME on load (no engine change — `get_session` + `get_messages`).\n * - returning-visitor RESUME via `POST /internal/resume-by-fingerprint`, and\n * cross-device \"restore my chats\" via the `POST /internal/identity/{request-otp,\n * verify-otp,resolve}` routes on the chat-ws wrapper. The engine (smooth-operator\n * 1.8.0) owns the `/ws` dispatch and REJECTS unknown verbs, so these are HTTP\n * `fetch()` calls (origin-allowlisted + optional authContext, per ADR-046/048) —\n * NOT WS frames.\n *\n * The controller is UI-agnostic: it emits typed events and the view renders them.\n */\nimport { type Citation, ProtocolError, type ServerEvent, SmoothAgentClient } from '@smooai/smooth-operator';\nimport type { StoreApi } from 'zustand/vanilla';\nimport type { ChatWidgetConfig } from './config.js';\nimport { getOrCreateFingerprint } from './fingerprint.js';\nimport { type ConsentState, createWidgetStore, type WidgetStore } from './persistence.js';\n\n/**\n * Derive the HTTP base for the chat-ws wrapper's `/internal/*` REST routes from\n * the WS endpoint: `wss://ai.smoo.ai/ws` → `https://ai.smoo.ai`. The engine\n * (smooth-operator 1.8.0) owns the `/ws` dispatch and REJECTS unknown verbs, so\n * the cross-device identity flow + fingerprint resume are HTTP POST routes on the\n * wrapper (origin-allowlisted + authContext, per ADR-046/ADR-048) — NOT WS frames.\n */\nexport function httpBaseFromWsEndpoint(endpoint: string): string | null {\n try {\n const u = new URL(endpoint);\n u.protocol = u.protocol === 'ws:' ? 'http:' : u.protocol === 'wss:' ? 'https:' : u.protocol;\n // The REST routes live at the host root (`/internal/*`), not under `/ws`.\n return `${u.protocol}//${u.host}`;\n } catch {\n // FAIL LOUD on a non-absolute endpoint. A relative fallback (e.g.\n // `string.replace`) would yield a relative base, and `fetch(\\`${base}/internal/...\\`)`\n // would then POST identity/OTP data to the HOST page origin (e.g. smoo.ai)\n // instead of the operator host (ai.smoo.ai) — leaking it to the wrong origin.\n // Returning null forces the controller into an error state and refuses the\n // `/internal/*` calls rather than mis-targeting them.\n return null;\n }\n}\n\nexport type { Citation };\n\nexport type Role = 'user' | 'assistant';\n\nexport interface ChatMessage {\n id: string;\n role: Role;\n /** Accumulated text (assistant messages grow as tokens stream in). */\n text: string;\n /** True while an assistant message is still streaming. */\n streaming: boolean;\n /**\n * Sources that grounded an assistant answer, when the terminal\n * `eventual_response` carried any. Optional + back-compatible: absent when\n * the turn used no knowledge sources (or for user messages). Read\n * defensively off the terminal event — see {@link extractCitations}.\n */\n citations?: Citation[];\n /**\n * Suggested follow-up replies (\"quick replies\") the agent offered on the\n * terminal `eventual_response`. Set ONLY on the finalized assistant message —\n * never mid-stream. Read defensively (see {@link extractSuggestions}); capped\n * at 4 for layout. Absent when the turn offered none.\n */\n suggestions?: string[];\n}\n\nexport type ConnectionStatus = 'idle' | 'connecting' | 'ready' | 'error' | 'closed';\n\n/**\n * A mid-turn pause that needs the visitor to act before the agent can continue:\n *\n * - `otp` — the agent requested OTP verification before an authenticated action.\n * Resume with {@link ConversationController.verifyOtp}.\n * - `confirm` — the agent wants to run a state-mutating tool and needs approval.\n * Resume with {@link ConversationController.confirmTool}.\n */\nexport type Interrupt =\n | {\n kind: 'otp';\n toolId?: string;\n actionDescription?: string;\n availableChannels: ('email' | 'sms')[];\n /** Set once the server confirms an OTP was dispatched. */\n sent?: { channel?: string; maskedDestination?: string };\n /** Set when a submitted code was rejected. */\n error?: string;\n attemptsRemaining?: number;\n }\n | { kind: 'confirm'; toolId?: string; actionDescription?: string };\n\nexport interface UserInfo {\n name?: string;\n email?: string;\n phone?: string;\n /** Marketing-consent opt-ins captured at the pre-chat form (ADR-048). */\n consent?: { emailOptIn: boolean; smsOptIn: boolean };\n}\n\n/** One conversation surfaced by `resolve_identity` for the cross-device picker. */\nexport interface RestorableConversation {\n conversationId: string;\n sessionId: string;\n lastActivityAt?: string;\n preview?: string;\n}\n\n/**\n * State machine for the cross-device \"restore my chats\" flow. Driven by the three\n * HTTP POST routes on the chat-ws wrapper — `/internal/identity/request-otp` →\n * `/internal/identity/verify-otp` → `/internal/identity/resolve` (ADR-048 §c).\n * The view renders a panel off this.\n */\nexport type IdentityRestore =\n | { phase: 'idle' }\n /** UI-local: the email-entry step before any request is sent. */\n | { phase: 'awaiting_email'; error?: string }\n | { phase: 'requesting'; email: string; channel: 'email' | 'sms' }\n | { phase: 'awaiting_code'; email: string; channel: 'email' | 'sms'; maskedDestination?: string; error?: string; attemptsRemaining?: number }\n | { phase: 'verifying'; email: string; channel: 'email' | 'sms' }\n | { phase: 'resolving'; email: string }\n | { phase: 'resolved'; email: string; conversations: RestorableConversation[] }\n | { phase: 'error'; message: string };\n\nexport interface ConversationEvents {\n /** Fired whenever the message list changes (append, token delta, finalize). */\n onMessages: (messages: ChatMessage[]) => void;\n /** Fired on connection-status transitions. */\n onStatus: (status: ConnectionStatus, detail?: string) => void;\n /** Fired when a turn pauses for OTP / tool-confirmation, and `null` when it clears. */\n onInterrupt?: (interrupt: Interrupt | null) => void;\n /** Fired on cross-device identity-restore state transitions. */\n onIdentityRestore?: (state: IdentityRestore) => void;\n}\n\n/** Pull the final assistant text out of an `eventual_response` data payload. */\nfunction extractFinalText(response: unknown): string | null {\n if (!response || typeof response !== 'object') return null;\n const r = response as { responseParts?: unknown };\n if (Array.isArray(r.responseParts)) {\n return r.responseParts.filter((p): p is string => typeof p === 'string').join('\\n\\n');\n }\n return null;\n}\n\n/**\n * Pull the grounding {@link Citation}s out of a terminal `eventual_response`.\n *\n * The protocol client types these (`eventual_response.data.data.citations`),\n * but they're optional and back-compatible — absent when the turn used no\n * knowledge sources. We read them defensively (tolerating their total absence,\n * non-array shapes, and missing fields) so a server that doesn't emit them, or\n * an older client, can't break rendering. Each citation always carries\n * `id`/`title`/`snippet`/`score`; `url` is present only for web-sourced docs.\n */\nfunction extractCitations(inner: unknown): Citation[] {\n if (!inner || typeof inner !== 'object') return [];\n const raw = (inner as { citations?: unknown }).citations;\n if (!Array.isArray(raw)) return [];\n const out: Citation[] = [];\n for (const c of raw) {\n if (!c || typeof c !== 'object') continue;\n const obj = c as Record<string, unknown>;\n const id = typeof obj.id === 'string' ? obj.id : '';\n const title = typeof obj.title === 'string' ? obj.title : id || 'Source';\n const snippet = typeof obj.snippet === 'string' ? obj.snippet : '';\n const url = typeof obj.url === 'string' && obj.url ? obj.url : undefined;\n const score = typeof obj.score === 'number' ? obj.score : 0;\n out.push({ id, title, snippet, score, url });\n }\n return out;\n}\n\n/**\n * Pull the suggested follow-up replies out of a terminal `eventual_response`'s\n * `response` object (`response.suggestedNextActions`). Optional + back-compatible\n * like citations — read defensively (tolerating absence, non-array shapes, and\n * non-string / blank entries) and capped at 4 so a chatty agent can't overflow\n * the composer chip row.\n */\nfunction extractSuggestions(response: unknown): string[] {\n if (!response || typeof response !== 'object') return [];\n const raw = (response as { suggestedNextActions?: unknown }).suggestedNextActions;\n if (!Array.isArray(raw)) return [];\n return raw.filter((s): s is string => typeof s === 'string' && s.trim().length > 0).slice(0, 4);\n}\n\n/** A `get_conversation_messages` row, narrowed defensively off the wire. */\ninterface WireMessage {\n id?: string;\n direction?: 'inbound' | 'outbound';\n content?: { text?: string };\n createdAt?: string;\n}\n\n/** Convert a server message row into a finalized {@link ChatMessage}. */\nfunction wireMessageToChat(m: WireMessage, idx: number): ChatMessage | null {\n const text = typeof m.content?.text === 'string' ? m.content.text : '';\n if (!text) return null;\n const role: Role = m.direction === 'outbound' ? 'assistant' : 'user';\n return { id: typeof m.id === 'string' ? m.id : `hist-${idx}`, role, text, streaming: false };\n}\n\nexport class ConversationController {\n private readonly config: ChatWidgetConfig;\n private readonly events: ConversationEvents;\n private readonly store: StoreApi<WidgetStore>;\n private client: SmoothAgentClient | null = null;\n private sessionId: string | null = null;\n private readonly messages: ChatMessage[] = [];\n private status: ConnectionStatus = 'idle';\n private seq = 0;\n /** requestId of the in-flight turn — used to resume OTP / tool confirmations. */\n private activeRequestId: string | null = null;\n private interrupt: Interrupt | null = null;\n private identityRestore: IdentityRestore = { phase: 'idle' };\n /**\n * True once the resume probe (persisted-pointer get_session OR the\n * `/internal/resume-by-fingerprint` POST) has run for this controller. Makes\n * `connect()` idempotent: re-entering after a transient `error` status (e.g. a\n * retried `send()`) creates a fresh session rather than re-running the resume\n * probe — which would fire another `resumeByFingerprint` POST and could adopt a\n * session we already decided not to resume.\n */\n private resumeAttempted = false;\n /**\n * HTTP base for the chat-ws wrapper's `/internal/*` REST routes. `null` when\n * the configured WS endpoint could not be parsed into an absolute origin — in\n * that case the `/internal/*` routes are refused (rather than mis-targeted at\n * the host page origin). See {@link httpBaseFromWsEndpoint}.\n */\n private readonly httpBase: string | null;\n\n constructor(config: ChatWidgetConfig, events: ConversationEvents, store?: StoreApi<WidgetStore>) {\n this.config = config;\n this.events = events;\n this.httpBase = httpBaseFromWsEndpoint(config.endpoint);\n if (this.httpBase === null) {\n // A non-absolute endpoint means the identity / resume `/internal/*` routes\n // have no safe target. Flag the controller in error so the UI surfaces it\n // and the routes refuse (see postInternal) rather than mis-targeting the\n // host page origin. Deferred to a microtask so listeners attached after\n // construction still observe the transition.\n queueMicrotask(() => this.setStatus('error', `Invalid chat endpoint: ${config.endpoint}`));\n }\n this.store = store ?? createWidgetStore(config.agentId);\n // Seed identity from config into the persisted store. `mergeIdentity` is\n // applied on EVERY construct, so a config-provided field always wins over\n // the persisted value (config is authoritative when present). Fields the\n // config does NOT provide keep their persisted value — those survive across\n // reloads; explicitly-configured ones are re-applied each load.\n const seed: { name?: string; email?: string; phone?: string } = {};\n if (config.userName) seed.name = config.userName;\n if (config.userEmail) seed.email = config.userEmail;\n if (config.userPhone) seed.phone = config.userPhone;\n if (Object.keys(seed).length > 0) this.store.getState().mergeIdentity(seed);\n }\n\n get connectionStatus(): ConnectionStatus {\n return this.status;\n }\n\n /** The persisted store, exposed so the view can read identity for the pre-chat gate. */\n getStore(): StoreApi<WidgetStore> {\n return this.store;\n }\n\n /** True when a persisted session pointer exists (drives the resume path). */\n hasPersistedSession(): boolean {\n return !!this.store.getState().sessionId;\n }\n\n /** True when persisted identity exists (lets the view skip the pre-chat form). */\n hasPersistedIdentity(): boolean {\n const id = this.store.getState().identity;\n return !!(id.name || id.email || id.phone);\n }\n\n /** Merge in visitor identity + consent (from the pre-chat form). Applied on next connect. */\n setUserInfo(info: UserInfo): void {\n const { name, email, phone, consent } = info;\n this.store.getState().mergeIdentity({ name, email, phone });\n if (consent) {\n const consentAt = consent.emailOptIn || consent.smsOptIn ? new Date().toISOString() : undefined;\n this.store.getState().setConsent({\n emailOptIn: consent.emailOptIn,\n smsOptIn: consent.smsOptIn,\n consentSource: 'chat-widget-prechat',\n consentAt,\n });\n }\n }\n\n private setInterrupt(interrupt: Interrupt | null): void {\n this.interrupt = interrupt;\n this.events.onInterrupt?.(interrupt);\n }\n\n private setIdentityRestore(state: IdentityRestore): void {\n this.identityRestore = state;\n this.events.onIdentityRestore?.(state);\n }\n\n get currentIdentityRestore(): IdentityRestore {\n return this.identityRestore;\n }\n\n /** Submit an OTP code to resume the paused turn. No-op if not awaiting OTP. */\n verifyOtp(code: string): void {\n if (!this.client || !this.sessionId || !this.activeRequestId || this.interrupt?.kind !== 'otp') return;\n this.client.verifyOtp({ sessionId: this.sessionId, requestId: this.activeRequestId, code });\n }\n\n /** Approve or reject a pending tool write to resume the paused turn. */\n confirmTool(approved: boolean): void {\n if (!this.client || !this.sessionId || !this.activeRequestId || this.interrupt?.kind !== 'confirm') return;\n this.client.confirmToolAction({ sessionId: this.sessionId, requestId: this.activeRequestId, approved });\n this.setInterrupt(null);\n }\n\n private nextId(prefix: string): string {\n this.seq += 1;\n return `${prefix}-${this.seq}-${Date.now().toString(36)}`;\n }\n\n private setStatus(status: ConnectionStatus, detail?: string): void {\n this.status = status;\n this.events.onStatus(status, detail);\n }\n\n private emitMessages(): void {\n // Hand out a shallow copy so the view can't mutate internal state.\n this.events.onMessages(this.messages.map((m) => ({ ...m })));\n }\n\n /** Compute (once) + return the persisted browser fingerprint. */\n private fingerprint(): string {\n const state = this.store.getState();\n return getOrCreateFingerprint(\n () => state.browserFingerprint,\n (fp) => this.store.getState().setBrowserFingerprint(fp),\n );\n }\n\n /**\n * Build the `metadata` payload threaded into `create_conversation_session`:\n * phone (no first-class engine field) and consent.\n *\n * NOTE: `verifiedEmail` is deliberately NOT stamped here. It is a per-session\n * OTP proof bound to the session it was verified against\n * (`verifiedEmailSessionId`), and the server only treats an actual OTP `verify`\n * as proof — metadata `verifiedEmail` is just a hint. Auto-stamping it onto\n * every brand-new `create_conversation_session` would mislabel a fresh\n * visitor's session with a prior (possibly different) visitor's email on a\n * shared browser. The verified email is only used when RESUMING the exact\n * session it was proven for — see {@link verifiedEmailForSession}.\n */\n private sessionMetadata(): Record<string, unknown> | undefined {\n const state = this.store.getState();\n const meta: Record<string, unknown> = {};\n if (state.identity.phone) meta.userPhone = state.identity.phone;\n const consent = state.consent;\n if (consent.emailOptIn || consent.smsOptIn || consent.consentAt) {\n const c: ConsentState = {\n emailOptIn: consent.emailOptIn,\n smsOptIn: consent.smsOptIn,\n consentSource: consent.consentSource ?? 'chat-widget-prechat',\n };\n if (consent.consentAt) c.consentAt = consent.consentAt;\n meta.consent = c;\n }\n return Object.keys(meta).length > 0 ? meta : undefined;\n }\n\n /**\n * The verified-email hint, but ONLY when the OTP proof is bound to the session\n * being resumed (`verifiedEmailSessionId === sessionId`). Returns null\n * otherwise so a stale/cross-visitor proof is never threaded onto a session it\n * wasn't proven for.\n */\n private verifiedEmailForSession(sessionId: string): string | null {\n const state = this.store.getState();\n if (state.verifiedEmail && state.verifiedEmailSessionId === sessionId) {\n return state.verifiedEmail;\n }\n return null;\n }\n\n /** Lazily open the WS client (default transport). Idempotent within a connect. */\n private async ensureClient(): Promise<void> {\n if (this.client) return;\n this.client = new SmoothAgentClient({ url: this.config.endpoint });\n await this.client.connect();\n }\n\n /**\n * Open the connection and either RESUME or create a session.\n *\n * 1. Persisted pointer (ADR-048 §b): `get_session` → if not `ended`, reuse +\n * hydrate from `get_messages` (newest-first, reversed). On ended/404 clear\n * ONLY the pointer (identity/consent survive).\n * 2. No persisted pointer: POST `/internal/resume-by-fingerprint` FIRST; if\n * `resumable`, adopt the returned session (the wrapper has primed the\n * operator registry), reuse the sessionId, and hydrate via get_session/\n * get_messages — rather than relying on createConversationSession to resume.\n * 3. Otherwise create a fresh session.\n */\n async connect(): Promise<void> {\n if (this.status === 'connecting' || this.status === 'ready') return;\n this.setStatus('connecting');\n try {\n await this.ensureClient();\n // The resume probe (persisted-pointer get_session OR the fingerprint\n // resume POST) runs AT MOST ONCE per controller lifecycle. Re-entering\n // connect() after a transient error (e.g. a retried send()) must not\n // re-run the probe — that would re-fire resumeByFingerprint and could\n // adopt a session we already chose not to resume. After the first\n // attempt, fall straight through to creating a fresh session.\n if (!this.resumeAttempted) {\n this.resumeAttempted = true;\n const persistedSessionId = this.store.getState().sessionId;\n if (persistedSessionId) {\n const resumed = await this.tryResume(persistedSessionId);\n if (resumed) {\n this.setStatus('ready');\n return;\n }\n // Resume failed (ended/404/gone) — clear the pointer, keep identity.\n this.store.getState().clearSession();\n } else {\n // Returning anonymous visitor with no stored pointer: ask the\n // wrapper to resolve a recent session for this fingerprint.\n const fpSessionId = await this.resumeByFingerprint();\n if (fpSessionId) {\n const resumed = await this.tryResume(fpSessionId);\n if (resumed) {\n this.store.getState().setSessionId(fpSessionId);\n this.setStatus('ready');\n return;\n }\n }\n }\n }\n await this.createSession();\n this.setStatus('ready');\n } catch (err) {\n this.setStatus('error', err instanceof Error ? err.message : String(err));\n throw err;\n }\n }\n\n // ─────────────────────── chat-ws `/internal/*` HTTP ─────────────────────────\n\n /**\n * Build the auth fields every `/internal/*` route shares: `agentId` (required\n * for the agent-policy lookup), `agentName` (used as the OTP email sender), and\n * the optional pre-auth `authContext` the host page may have configured. The\n * `Origin` header is sent automatically by the browser and checked server-side.\n */\n private authBody(): Record<string, unknown> {\n const body: Record<string, unknown> = { agentId: this.config.agentId };\n if (this.config.agentName) body.agentName = this.config.agentName;\n if (this.config.authContext) body.authContext = this.config.authContext;\n return body;\n }\n\n /** POST JSON to a `/internal/*` route; returns the parsed body (or throws). */\n private async postInternal(path: string, payload: Record<string, unknown>): Promise<Record<string, unknown>> {\n if (this.httpBase === null) {\n // No absolute origin could be derived from the WS endpoint — refuse the\n // call loudly rather than POST identity data to a relative (host-page) URL.\n throw new Error(`Cannot reach ${path}: the chat endpoint is not an absolute URL.`);\n }\n const res = await fetch(`${this.httpBase}${path}`, {\n method: 'POST',\n headers: { 'content-type': 'application/json' },\n // Auth is the `Origin` allowlist + the `authContext` body field — NOT\n // cookies. `credentials: 'include'` would force the server to reply with\n // `Access-Control-Allow-Credentials: true` AND a reflected origin (a\n // wildcard `*` is illegal with credentials), so a plain origin-allowlisted\n // CORS config would fail the preflight and break EVERY `/internal/*` call.\n // Omit credentials so the cross-origin POST works against an allowlist\n // that doesn't (and shouldn't need to) opt into credentialed CORS.\n credentials: 'omit',\n body: JSON.stringify({ ...this.authBody(), ...payload }),\n });\n let json: Record<string, unknown> = {};\n try {\n json = (await res.json()) as Record<string, unknown>;\n } catch {\n json = {};\n }\n if (!res.ok) {\n const err = json.error as { code?: string; message?: string } | undefined;\n throw new Error(err?.message ?? `${path} failed (${res.status})`);\n }\n return json;\n }\n\n /**\n * POST `/internal/resume-by-fingerprint`. Returns the resumable sessionId when\n * the wrapper found (and primed) a recent session for this fingerprint, else\n * null. Network/route failures are swallowed → null (fall through to create).\n */\n private async resumeByFingerprint(): Promise<string | null> {\n try {\n const json = await this.postInternal('/internal/resume-by-fingerprint', { browserFingerprint: this.fingerprint() });\n if (json.resumable === true && typeof json.sessionId === 'string') {\n return json.sessionId;\n }\n } catch {\n // Resume is best-effort; any failure just means a fresh session.\n }\n return null;\n }\n\n /** `create_conversation_session` with fingerprint + identity + consent metadata. */\n private async createSession(): Promise<void> {\n if (!this.client) throw new Error('Conversation is not connected');\n const state = this.store.getState();\n const metadata = this.sessionMetadata();\n const session = await this.client.createConversationSession({\n agentId: this.config.agentId,\n userName: state.identity.name,\n userEmail: state.identity.email,\n browserFingerprint: this.fingerprint(),\n ...(metadata ? { metadata } : {}),\n });\n this.sessionId = session.sessionId;\n this.store.getState().setSessionId(session.sessionId);\n }\n\n /**\n * Attempt to resume `sessionId`: returns true and hydrates the transcript when\n * the session is live, false when it has ended / can't be fetched.\n */\n private async tryResume(sessionId: string): Promise<boolean> {\n if (!this.client) return false;\n let snap: { status?: 'active' | 'idle' | 'ended' };\n try {\n snap = await this.client.getSession({ sessionId });\n } catch {\n return false; // 404 / SESSION_NOT_FOUND / network — start fresh.\n }\n if (snap.status === 'ended') return false;\n\n this.sessionId = sessionId;\n await this.hydrateHistory(sessionId);\n return true;\n }\n\n /** Page recent history (newest-first), reverse to chronological, and render. */\n private async hydrateHistory(sessionId: string): Promise<void> {\n if (!this.client) return;\n try {\n const page = await this.client.getMessages({ sessionId, limit: 50 });\n const rows = Array.isArray(page.messages) ? page.messages : [];\n // The server returns newest-first; reverse to chronological for the UI.\n const chronological = [...rows].reverse();\n const hydrated: ChatMessage[] = [];\n chronological.forEach((m, i) => {\n const chat = wireMessageToChat(m as WireMessage, i);\n if (chat) hydrated.push(chat);\n });\n this.messages.length = 0;\n this.messages.push(...hydrated);\n this.emitMessages();\n } catch {\n // History fetch is best-effort: a resumable session with no fetchable\n // history just shows an empty transcript rather than failing the resume.\n }\n }\n\n /**\n * Submit a user message. Appends the user bubble immediately, then streams the\n * assistant reply token-by-token, finalizing on `eventual_response`.\n */\n async send(text: string): Promise<void> {\n const trimmed = text.trim();\n if (!trimmed) return;\n if (!this.client || !this.sessionId || this.status !== 'ready') {\n await this.connect();\n }\n if (!this.client || !this.sessionId) {\n throw new Error('Conversation is not connected');\n }\n\n // 1. User bubble.\n this.messages.push({ id: this.nextId('u'), role: 'user', text: trimmed, streaming: false });\n\n // 2. Placeholder assistant bubble we grow as tokens arrive.\n const assistant: ChatMessage = { id: this.nextId('a'), role: 'assistant', text: '', streaming: true };\n this.messages.push(assistant);\n this.emitMessages();\n\n try {\n const turn = this.client.sendMessage({ sessionId: this.sessionId, message: trimmed, stream: true });\n this.activeRequestId = turn.requestId;\n\n for await (const event of turn) {\n if (event.type === 'stream_token') {\n const token = event.token ?? event.data?.token ?? '';\n if (token) {\n assistant.text += token;\n this.emitMessages();\n }\n } else {\n // OTP / tool-confirmation pauses surface here; the loop keeps\n // iterating once the visitor resumes via verifyOtp/confirmTool.\n this.handleTurnEvent(event);\n }\n }\n\n const final = await turn;\n const inner = final.data?.data;\n const finalText = extractFinalText(inner?.response);\n if (finalText && finalText.length > assistant.text.length) {\n assistant.text = finalText;\n }\n if (!assistant.text) {\n assistant.text = '(no response)';\n }\n // Attach grounding sources from the terminal event, when present.\n const citations = extractCitations(inner);\n if (citations.length > 0) {\n assistant.citations = citations;\n }\n // Suggested follow-up replies from the terminal event, when present.\n const suggestions = extractSuggestions(inner?.response);\n if (suggestions.length > 0) {\n assistant.suggestions = suggestions;\n }\n assistant.streaming = false;\n this.emitMessages();\n } catch (err) {\n assistant.streaming = false;\n const message =\n err instanceof ProtocolError\n ? `Error: ${err.message}`\n : (this.config.connectionErrorMessage ?? \"We couldn't reach the chat.\");\n assistant.text = assistant.text ? `${assistant.text}\\n\\n${message}` : message;\n this.emitMessages();\n this.setStatus('error', err instanceof Error ? err.message : String(err));\n } finally {\n this.activeRequestId = null;\n this.setInterrupt(null);\n }\n }\n\n /** Map a non-token turn event (OTP / tool-confirmation lifecycle) to interrupt state. */\n private handleTurnEvent(event: ServerEvent): void {\n const inner = ((event as { data?: { data?: Record<string, unknown> } }).data?.data ?? {}) as Record<string, unknown>;\n const str = (v: unknown): string | undefined => (typeof v === 'string' ? v : undefined);\n const num = (v: unknown): number | undefined => (typeof v === 'number' ? v : undefined);\n switch (event.type) {\n case 'otp_verification_required': {\n const channels: ('email' | 'sms')[] = Array.isArray(inner.availableChannels)\n ? inner.availableChannels.filter((c): c is 'email' | 'sms' => c === 'email' || c === 'sms')\n : ['email'];\n this.setInterrupt({\n kind: 'otp',\n toolId: str(inner.toolId),\n actionDescription: str(inner.actionDescription),\n availableChannels: channels.length > 0 ? channels : ['email'],\n });\n break;\n }\n case 'otp_sent':\n if (this.interrupt?.kind === 'otp') {\n this.setInterrupt({ ...this.interrupt, sent: { channel: str(inner.channel), maskedDestination: str(inner.maskedDestination) }, error: undefined });\n }\n break;\n case 'otp_verified':\n if (this.interrupt?.kind === 'otp') this.setInterrupt(null);\n break;\n case 'otp_invalid':\n if (this.interrupt?.kind === 'otp') {\n this.setInterrupt({ ...this.interrupt, error: str(inner.message) ?? 'That code was incorrect.', attemptsRemaining: num(inner.attemptsRemaining) });\n }\n break;\n case 'write_confirmation_required':\n this.setInterrupt({ kind: 'confirm', toolId: str(inner.toolId), actionDescription: str(inner.actionDescription) });\n break;\n default:\n break;\n }\n }\n\n // ─────────────────── Cross-device \"restore my chats\" (§c) ───────────────────\n //\n // Three HTTP POST routes on the chat-ws wrapper (the engine `/ws` dispatch\n // rejects unknown verbs): request-otp → verify-otp → resolve. ALL THREE are\n // session-scoped — they require a live `sessionId` (a uuid). request-otp\n // establishes the session itself (idempotent connect) before sending, so the\n // whole flow shares one session and verify-otp can't hit \"No active session\"\n // even if the email was submitted before the initial connect() resolved.\n\n /**\n * Begin the cross-device restore: POST `/internal/identity/request-otp` for\n * `email` over `channel`. The view collects the email via an explicit affordance.\n */\n async requestIdentityOtp(email: string, channel: 'email' | 'sms' = 'email'): Promise<void> {\n const trimmed = email.trim();\n if (!trimmed) return;\n this.setIdentityRestore({ phase: 'requesting', email: trimmed, channel });\n // request-otp must be SESSION-CONSISTENT with verify-otp (which hard-requires\n // a sessionId). If the restore affordance fired request-otp before connect()\n // resolved, there'd be no sessionId here and verify-otp would later error\n // \"No active session.\" Establish a session first (idempotent connect), then\n // require it — so the whole request → verify flow shares one live session.\n if (!this.sessionId) {\n try {\n await this.connect();\n } catch {\n /* fall through: handled by the sessionId check below */\n }\n }\n if (!this.sessionId) {\n this.setIdentityRestore({ phase: 'error', message: 'No active session to verify against.' });\n return;\n }\n try {\n const json = await this.postInternal('/internal/identity/request-otp', {\n sessionId: this.sessionId,\n email: trimmed,\n channel,\n });\n const masked = typeof json.maskedDestination === 'string' ? json.maskedDestination : undefined;\n this.setIdentityRestore({ phase: 'awaiting_code', email: trimmed, channel, maskedDestination: masked });\n } catch (err) {\n this.setIdentityRestore({ phase: 'error', message: err instanceof Error ? err.message : 'Could not send a verification code.' });\n }\n }\n\n /** Submit the code: POST `/internal/identity/verify-otp`, then resolve on success. */\n async verifyIdentityOtp(code: string): Promise<void> {\n const state = this.identityRestore;\n const trimmed = code.trim();\n if (!trimmed || state.phase !== 'awaiting_code') return;\n const { email, channel } = state;\n if (!this.sessionId) {\n this.setIdentityRestore({ phase: 'error', message: 'No active session to verify against.' });\n return;\n }\n this.setIdentityRestore({ phase: 'verifying', email, channel });\n try {\n const json = await this.postInternal('/internal/identity/verify-otp', { sessionId: this.sessionId, email, code: trimmed });\n if (json.event === 'otp_verified') {\n // Bind the OTP proof to the session it was verified against, so it\n // can't leak onto a different visitor's session on a shared browser.\n this.store.getState().setVerifiedEmail(email, this.sessionId);\n await this.resolveIdentity(email);\n } else if (json.event === 'otp_invalid') {\n const remaining = typeof json.attemptsRemaining === 'number' ? json.attemptsRemaining : undefined;\n this.setIdentityRestore({ phase: 'awaiting_code', email, channel, error: 'That code was incorrect.', attemptsRemaining: remaining });\n } else {\n this.setIdentityRestore({ phase: 'error', message: 'Verification failed.' });\n }\n } catch (err) {\n this.setIdentityRestore({ phase: 'error', message: err instanceof Error ? err.message : 'Verification failed.' });\n }\n }\n\n /** Resolve the verified identity → restorable conversations via POST `/internal/identity/resolve`. */\n private async resolveIdentity(email: string): Promise<void> {\n if (!this.sessionId) return;\n this.setIdentityRestore({ phase: 'resolving', email });\n try {\n const json = await this.postInternal('/internal/identity/resolve', { sessionId: this.sessionId, email });\n if (json.resolved !== true) {\n this.setIdentityRestore({ phase: 'resolved', email, conversations: [] });\n return;\n }\n const raw = json.conversations;\n const conversations: RestorableConversation[] = Array.isArray(raw)\n ? raw\n .map((c): RestorableConversation | null => {\n if (!c || typeof c !== 'object') return null;\n const o = c as Record<string, unknown>;\n const conversationId = typeof o.conversationId === 'string' ? o.conversationId : '';\n const sessionId = typeof o.sessionId === 'string' ? o.sessionId : '';\n if (!sessionId) return null;\n return {\n conversationId,\n sessionId,\n lastActivityAt: typeof o.lastActivityAt === 'string' ? o.lastActivityAt : undefined,\n preview: typeof o.preview === 'string' ? o.preview : undefined,\n };\n })\n .filter((c): c is RestorableConversation => c !== null)\n : [];\n this.setIdentityRestore({ phase: 'resolved', email, conversations });\n } catch (err) {\n this.setIdentityRestore({ phase: 'error', message: err instanceof Error ? err.message : 'Could not load your chats.' });\n }\n }\n\n /**\n * Replay a chosen restorable conversation: point the live session at its\n * sessionId, hydrate its transcript (get_session + get_messages), and persist\n * the new pointer so the next `sendMessage` continues it.\n */\n async restoreConversation(sessionId: string): Promise<void> {\n if (!this.client) await this.ensureClient();\n // Capture the OTP proof bound to the CURRENT live session BEFORE tryResume\n // repoints this.sessionId to the restored one. The visitor proved ownership\n // of this email in this very flow, so the proof legitimately follows the\n // conversation they chose to restore.\n const proven = this.sessionId ? this.verifiedEmailForSession(this.sessionId) : null;\n const resumed = await this.tryResume(sessionId);\n if (resumed) {\n this.store.getState().setSessionId(sessionId);\n // Rebind the proof to the restored session (keeps verifiedEmail\n // session-scoped, just now to the session it's actually used on). Only a\n // proof from the just-verified session follows — never an unrelated stale one.\n if (proven) this.store.getState().setVerifiedEmail(proven, sessionId);\n this.setIdentityRestore({ phase: 'idle' });\n this.setStatus('ready');\n } else {\n this.setIdentityRestore({ phase: 'error', message: 'That conversation is no longer available.' });\n }\n }\n\n /** Dismiss the cross-device restore panel. */\n cancelIdentityRestore(): void {\n this.setIdentityRestore({ phase: 'idle' });\n }\n\n /** Tear down the underlying client. */\n disconnect(): void {\n this.client?.disconnect('widget closed');\n this.client = null;\n this.sessionId = null;\n this.activeRequestId = null;\n // A full teardown ends the controller lifecycle: a subsequent connect() is a\n // genuine re-open and may resume again, so re-arm the resume probe.\n this.resumeAttempted = false;\n this.setInterrupt(null);\n this.setStatus('closed');\n }\n}\n","/**\n * The Smooth logo + icon, inlined as SVG strings so the full-page header can\n * render them without a separate network fetch (the IIFE bundle is\n * self-contained).\n *\n * GENERATED from `assets/smooth-logo.svg` / `assets/smooth-icon.svg` — do not\n * edit by hand. Regenerate with:\n * node -e 'const fs=require(\"fs\");process.stdout.write(JSON.stringify(fs.readFileSync(\"assets/smooth-icon.svg\",\"utf8\")))'\n */\n/* eslint-disable */\nexport const SMOOTH_LOGO_SVG = \"<?xml version=\\\"1.0\\\" encoding=\\\"UTF-8\\\"?>\\n<svg id=\\\"Layer_1\\\" data-name=\\\"Layer 1\\\" xmlns=\\\"http://www.w3.org/2000/svg\\\" xmlns:xlink=\\\"http://www.w3.org/1999/xlink\\\" viewBox=\\\"0 0 550 135\\\">\\n <defs>\\n <style>\\n .cls-1 {\\n fill: url(#linear-gradient-3);\\n }\\n\\n .cls-2 {\\n fill: url(#linear-gradient-2);\\n }\\n\\n .cls-3 {\\n fill: url(#linear-gradient);\\n fill-rule: evenodd;\\n }\\n </style>\\n <linearGradient id=\\\"linear-gradient\\\" x1=\\\"115.59\\\" y1=\\\"112.81\\\" x2=\\\"25.08\\\" y2=\\\"22.3\\\" gradientUnits=\\\"userSpaceOnUse\\\">\\n <stop offset=\\\".3\\\" stop-color=\\\"#f49f0a\\\"/>\\n <stop offset=\\\".79\\\" stop-color=\\\"#fb7a4d\\\"/>\\n <stop offset=\\\"1\\\" stop-color=\\\"#ff6b6c\\\"/>\\n </linearGradient>\\n <linearGradient id=\\\"linear-gradient-2\\\" x1=\\\"360.91\\\" y1=\\\"152.01\\\" x2=\\\"202.32\\\" y2=\\\"-6.59\\\" xlink:href=\\\"#linear-gradient\\\"/>\\n <linearGradient id=\\\"linear-gradient-3\\\" x1=\\\"443.91\\\" y1=\\\"30.15\\\" x2=\\\"531.36\\\" y2=\\\"117.59\\\" gradientUnits=\\\"userSpaceOnUse\\\">\\n <stop offset=\\\".43\\\" stop-color=\\\"#00a6a6\\\"/>\\n <stop offset=\\\"1\\\" stop-color=\\\"#1238dd\\\"/>\\n </linearGradient>\\n </defs>\\n <path class=\\\"cls-3\\\" d=\\\"M48.28,14.96c-12.39,5.21-22.54,14.64-28.65,26.61-6.12,11.97-7.8,25.72-4.77,38.81,3.04,13.09,10.6,24.69,21.36,32.75,10.76,8.06,24.02,12.05,37.44,11.28,13.42-.77,26.13-6.26,35.9-15.5,9.76-9.24,15.95-21.63,17.46-34.99,1.51-13.36-1.74-26.82-9.19-38.01-1.07-1.61-.64-3.78.97-4.85,1.61-1.07,3.78-.64,4.85.97,8.36,12.56,12.02,27.68,10.32,42.67-1.7,15-8.64,28.91-19.61,39.28-10.96,10.37-25.24,16.54-40.31,17.4-15.07.87-29.96-3.62-42.04-12.66-12.08-9.05-20.58-22.07-23.99-36.77-3.41-14.7-1.51-30.14,5.35-43.58,6.87-13.44,18.26-24.02,32.17-29.87,13.91-5.85,29.44-6.6,43.85-2.11,1.85.57,2.88,2.54,2.3,4.38-.57,1.85-2.54,2.88-4.38,2.3-12.83-4-26.67-3.33-39.06,1.88ZM111.39,19.75c0,2.07-1.68,3.75-3.75,3.75s-3.75-1.68-3.75-3.75,1.68-3.75,3.75-3.75,3.75,1.68,3.75,3.75ZM64.64,59.93c0,1.91,2.39,2.56,7.69,3.88,3.89.97,6.6,2.18,8.15,3.63,1.53,1.45,2.29,3.53,2.29,6.25,0,3.57-1.03,6.26-3.11,8.08-2.07,1.82-5.09,2.73-9.09,2.73h-9.6c-1.97,0-3.57-1.6-3.59-3.57-.01-1.99,1.6-3.61,3.59-3.61h9.41c3.15-.12,4.79-.95,4.91-2.47,0-1.3-1.03-2.21-3.07-2.73-6.91-1.72-11.11-3.44-12.6-5.15-1.48-1.71-2.23-3.77-2.23-6.19,0-6.59,3.2-9.85,9.59-9.8h10.77c1.99,0,3.6,1.61,3.6,3.59s-1.61,3.59-3.6,3.59h-9.69c-1.83,0-3.43.06-3.43,1.77Z\\\"/>\\n <path class=\\\"cls-2\\\" d=\\\"M205.52,48.44h-8.86c-.44-3.75-2.23-6.65-5.38-8.72-3.16-2.07-7.03-3.1-11.6-3.1h0c-3.35,0-6.27.54-8.78,1.62-2.49,1.09-4.44,2.59-5.84,4.48-1.39,1.89-2.08,4.05-2.08,6.46h0c0,2.01.49,3.75,1.46,5.2.97,1.44,2.22,2.63,3.74,3.58,1.53.95,3.13,1.72,4.8,2.32,1.68.6,3.22,1.09,4.62,1.46h0l7.68,2.06c1.97.52,4.17,1.23,6.6,2.14,2.43.92,4.75,2.16,6.98,3.72,2.23,1.56,4.07,3.56,5.52,6,1.45,2.44,2.18,5.43,2.18,8.98h0c0,4.08-1.07,7.77-3.2,11.08-2.12,3.29-5.22,5.91-9.3,7.86-4.08,1.95-9.02,2.92-14.82,2.92h0c-5.43,0-10.11-.87-14.06-2.62-3.95-1.75-7.05-4.19-9.3-7.32-2.25-3.12-3.53-6.75-3.84-10.88h9.46c.25,2.85,1.22,5.21,2.9,7.06,1.69,1.87,3.83,3.25,6.42,4.14,2.6.89,5.41,1.34,8.42,1.34h0c3.49,0,6.63-.57,9.4-1.72,2.79-1.13,4.99-2.73,6.62-4.8,1.63-2.05,2.44-4.46,2.44-7.22h0c0-2.51-.7-4.55-2.1-6.12-1.41-1.57-3.26-2.85-5.54-3.84-2.29-.99-4.77-1.85-7.44-2.58h0l-9.3-2.66c-5.91-1.71-10.59-4.13-14.04-7.28-3.44-3.16-5.16-7.29-5.16-12.38h0c0-4.23,1.15-7.93,3.46-11.1,2.29-3.16,5.39-5.62,9.3-7.38,3.91-1.76,8.27-2.64,13.08-2.64h0c4.88,0,9.21.87,13,2.6,3.8,1.73,6.81,4.11,9.04,7.12,2.23,3,3.4,6.41,3.52,10.22h0ZM229.16,105.18h-8.72v-56.74h8.42v8.86h.74c1.19-3.03,3.1-5.38,5.74-7.06,2.63-1.69,5.79-2.54,9.48-2.54h0c3.75,0,6.87.85,9.36,2.54,2.51,1.68,4.46,4.03,5.86,7.06h.58c1.45-2.92,3.63-5.25,6.54-7,2.91-1.73,6.39-2.6,10.46-2.6h0c5.07,0,9.21,1.58,12.44,4.74,3.23,3.17,4.84,8.09,4.84,14.76h0v37.98h-8.72v-37.98c0-4.19-1.14-7.18-3.42-8.98-2.29-1.79-4.99-2.68-8.1-2.68h0c-3.99,0-7.07,1.2-9.26,3.6-2.2,2.4-3.3,5.43-3.3,9.1h0v36.94h-8.86v-38.86c0-3.23-1.05-5.83-3.14-7.82-2.09-1.97-4.79-2.96-8.08-2.96h0c-2.27,0-4.38.6-6.34,1.8-1.96,1.21-3.53,2.88-4.72,5-1.2,2.13-1.8,4.59-1.8,7.38h0v35.46ZM333.9,106.36h0c-5.12,0-9.61-1.22-13.46-3.66-3.85-2.44-6.86-5.85-9.02-10.24-2.15-4.37-3.22-9.49-3.22-15.36h0c0-5.91,1.07-11.07,3.22-15.48,2.16-4.4,5.17-7.82,9.02-10.26,3.85-2.44,8.34-3.66,13.46-3.66h0c5.12,0,9.61,1.22,13.46,3.66,3.85,2.44,6.86,5.86,9.02,10.26,2.15,4.41,3.22,9.57,3.22,15.48h0c0,5.87-1.07,10.99-3.22,15.36-2.16,4.39-5.17,7.8-9.02,10.24-3.85,2.44-8.34,3.66-13.46,3.66ZM333.9,98.52h0c3.89,0,7.09-.99,9.6-2.98,2.52-2,4.38-4.63,5.58-7.88,1.21-3.25,1.82-6.77,1.82-10.56h0c0-3.79-.61-7.32-1.82-10.6-1.2-3.27-3.06-5.91-5.58-7.94-2.51-2.01-5.71-3.02-9.6-3.02h0c-3.89,0-7.09,1.01-9.6,3.02-2.51,2.03-4.37,4.67-5.58,7.94-1.2,3.28-1.8,6.81-1.8,10.6h0c0,3.79.6,7.31,1.8,10.56,1.21,3.25,3.07,5.88,5.58,7.88,2.51,1.99,5.71,2.98,9.6,2.98ZM395.94,106.36h0c-5.12,0-9.61-1.22-13.46-3.66-3.85-2.44-6.85-5.85-9-10.24-2.16-4.37-3.24-9.49-3.24-15.36h0c0-5.91,1.08-11.07,3.24-15.48,2.15-4.4,5.15-7.82,9-10.26,3.85-2.44,8.34-3.66,13.46-3.66h0c5.12,0,9.61,1.22,13.46,3.66,3.85,2.44,6.86,5.86,9.02,10.26,2.16,4.41,3.24,9.57,3.24,15.48h0c0,5.87-1.08,10.99-3.24,15.36-2.16,4.39-5.17,7.8-9.02,10.24-3.85,2.44-8.34,3.66-13.46,3.66ZM395.94,98.52h0c3.89,0,7.09-.99,9.6-2.98,2.52-2,4.38-4.63,5.58-7.88,1.21-3.25,1.82-6.77,1.82-10.56h0c0-3.79-.61-7.32-1.82-10.6-1.2-3.27-3.06-5.91-5.58-7.94-2.51-2.01-5.71-3.02-9.6-3.02h0c-3.88,0-7.08,1.01-9.6,3.02-2.51,2.03-4.37,4.67-5.58,7.94-1.2,3.28-1.8,6.81-1.8,10.6h0c0,3.79.6,7.31,1.8,10.56,1.21,3.25,3.07,5.88,5.58,7.88,2.52,1.99,5.72,2.98,9.6,2.98Z\\\"/>\\n <path class=\\\"cls-1\\\" d=\\\"M467.88,48.02v13.28h-35.79v-13.28h35.79ZM439.68,34.38h17.89v53.42c0,1.5.36,2.62,1.08,3.36.72.74,1.88,1.1,3.49,1.1.62,0,1.48-.07,2.59-.21,1.11-.14,1.91-.27,2.38-.41l2.31,13.02c-2.02.58-3.97.97-5.84,1.18-1.88.21-3.66.31-5.33.31-6.08,0-10.7-1.43-13.84-4.28-3.15-2.85-4.72-7.01-4.72-12.48v-55.01ZM506.59,72.63v32.71h-17.89V28.95h17.53v33.53h-1.13c1.4-4.55,3.6-8.21,6.59-11,2.99-2.79,7.01-4.18,12.07-4.18,4,0,7.48.89,10.46,2.67,2.97,1.78,5.28,4.29,6.92,7.54,1.64,3.25,2.46,7.02,2.46,11.33v36.5h-17.89v-33.02c0-3.21-.82-5.73-2.46-7.56-1.64-1.83-3.93-2.74-6.87-2.74-1.92,0-3.62.42-5.1,1.26-1.49.84-2.64,2.04-3.46,3.61-.82,1.57-1.23,3.49-1.23,5.74Z\\\"/>\\n</svg>\";\n\n/** The square Smooth icon (the stylized `th` glyph) — used as the default full-page header avatar. */\nexport const SMOOTH_ICON_SVG = \"<?xml version=\\\"1.0\\\" encoding=\\\"UTF-8\\\"?>\\n<svg id=\\\"Layer_1\\\" data-name=\\\"Layer 1\\\" xmlns=\\\"http://www.w3.org/2000/svg\\\" xmlns:xlink=\\\"http://www.w3.org/1999/xlink\\\" viewBox=\\\"0 0 150 150\\\">\\n <defs>\\n <style>\\n .cls-1 {\\n fill: url(#linear-gradient);\\n }\\n </style>\\n <linearGradient id=\\\"linear-gradient\\\" x1=\\\"31.06\\\" y1=\\\"37.6\\\" x2=\\\"118.5\\\" y2=\\\"125.04\\\" gradientUnits=\\\"userSpaceOnUse\\\">\\n <stop offset=\\\".43\\\" stop-color=\\\"#00a6a6\\\"/>\\n <stop offset=\\\"1\\\" stop-color=\\\"#1238dd\\\"/>\\n </linearGradient>\\n </defs>\\n <path class=\\\"cls-1\\\" d=\\\"M55.03,55.47v13.28H19.24v-13.28h35.79ZM26.83,41.83h17.89v53.42c0,1.5.36,2.62,1.08,3.36.72.74,1.88,1.1,3.49,1.1.62,0,1.48-.07,2.59-.21,1.11-.14,1.91-.27,2.38-.41l2.31,13.02c-2.02.58-3.97.97-5.84,1.18-1.88.21-3.66.31-5.33.31-6.08,0-10.7-1.43-13.84-4.28-3.15-2.85-4.72-7.01-4.72-12.48v-55.01ZM93.74,80.08v32.71h-17.89V36.39h17.53v33.53h-1.13c1.4-4.55,3.6-8.21,6.59-11,2.99-2.79,7.01-4.18,12.07-4.18,4,0,7.48.89,10.46,2.67,2.97,1.78,5.28,4.29,6.92,7.54,1.64,3.25,2.46,7.02,2.46,11.33v36.5h-17.89v-33.02c0-3.21-.82-5.73-2.46-7.56-1.64-1.83-3.93-2.74-6.87-2.74-1.92,0-3.62.42-5.1,1.26-1.49.84-2.64,2.04-3.46,3.61-.82,1.57-1.23,3.49-1.23,5.74Z\\\"/>\\n</svg>\";\n","import type { ChatWidgetMode, ResolvedTheme } from './config.js';\n\n/**\n * Render the widget's scoped stylesheet — the \"Aurora Glass\" design system.\n *\n * Every brand value is injected as a CSS custom property on `:host` so a host\n * page can override colors per-instance and the rules below stay static. Two\n * extra tokens are *derived in CSS* from the brand vars so they adapt to any\n * theme (light or dark) without the caller supplying them:\n *\n * --sac-primary-2 a darker shade of `primary`, used as the second stop of the\n * launcher / send / user-bubble gradients (depth without a\n * second brand input).\n * --sac-surface-2 a faint wash derived from `text`, used for inset chrome\n * (composer field, close button, source cards). On a dark\n * panel it reads as a light overlay; on a light panel, dark.\n *\n * Deliberately framework-light: no Tailwind, no runtime CSS-in-JS — just a string\n * the web component drops into its shadow root. Modern color features\n * (`color-mix`) are used intentionally; the widget targets evergreen browsers.\n *\n * `mode` switches host positioning + panel sizing between the floating popover\n * (default) and the full-page layout (fills its container/viewport).\n */\nexport function buildStyles(theme: ResolvedTheme, mode: ChatWidgetMode = 'popover'): string {\n return `\n:host {\n --sac-text: ${theme.text};\n --sac-bg: ${theme.background};\n --sac-primary: ${theme.primary};\n --sac-primary-text: ${theme.primaryText};\n --sac-assistant-bubble: ${theme.assistantBubble};\n --sac-assistant-bubble-text: ${theme.assistantBubbleText};\n --sac-user-bubble: ${theme.userBubble};\n --sac-user-bubble-text: ${theme.userBubbleText};\n --sac-border: ${theme.border};\n\n /* Derived tokens — adapt to any brand color without a second input. */\n --sac-primary-2: color-mix(in srgb, var(--sac-primary) 78%, #000 22%);\n --sac-surface-2: color-mix(in srgb, var(--sac-text) 5%, transparent);\n --sac-radius: 22px;\n --sac-ease: cubic-bezier(.16, 1, .3, 1);\n\n ${\n mode === 'fullpage'\n ? `/* Full-page: fill the host's box (sized by its container, else the viewport). */\n display: flex;\n flex-direction: column;\n position: relative;\n width: 100%;\n height: 100%;`\n : `/* Popover: float in the bottom-right corner. */\n position: fixed;\n bottom: 24px;\n right: 24px;\n z-index: 2147483000;`\n }\n font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Helvetica, Arial, sans-serif;\n -webkit-font-smoothing: antialiased;\n}\n${\n mode === 'fullpage'\n ? `\n/* Viewport fallback — the element sets this attribute only when the host's\n container gives it no resolved height (e.g. mounted straight into an\n auto-height <body>). A sized container always wins, so an embed inside a\n fixed-height box never overflows it (composer stays visible). */\n:host([data-viewport-fallback]) { min-height: 100dvh; }\n/* The render wrapper passes the host's box down to the panel via flex. */\n.wrap {\n flex: 1;\n display: flex;\n flex-direction: column;\n min-height: 0;\n}\n`\n : ''\n}\n* { box-sizing: border-box; }\n\n/* ───────────────────────────── Launcher ───────────────────────────── */\n.launcher {\n position: relative;\n width: 62px;\n height: 62px;\n border-radius: 50%;\n border: none;\n cursor: pointer;\n padding: 0;\n background: radial-gradient(120% 120% at 30% 20%,\n color-mix(in srgb, var(--sac-primary) 78%, #fff 22%) 0%,\n var(--sac-primary) 42%,\n var(--sac-primary-2) 130%);\n color: var(--sac-primary-text);\n display: flex;\n align-items: center;\n justify-content: center;\n box-shadow:\n 0 1px 0 rgba(255, 255, 255, .25) inset,\n 0 10px 24px -6px color-mix(in srgb, var(--sac-primary) 55%, transparent),\n 0 18px 50px -12px rgba(0, 0, 0, .6);\n transition: transform .45s var(--sac-ease), box-shadow .45s var(--sac-ease), opacity .3s ease;\n isolation: isolate;\n}\n/* Breathing presence ring. */\n.launcher::before {\n content: '';\n position: absolute;\n inset: -6px;\n border-radius: 50%;\n z-index: -1;\n background: radial-gradient(closest-side, color-mix(in srgb, var(--sac-primary) 45%, transparent), transparent 75%);\n animation: sac-breathe 3.4s ease-in-out infinite;\n}\n@keyframes sac-breathe { 0%, 100% { transform: scale(1); opacity: .55 } 50% { transform: scale(1.28); opacity: 0 } }\n.launcher:hover {\n transform: translateY(-3px) scale(1.06);\n box-shadow:\n 0 1px 0 rgba(255, 255, 255, .3) inset,\n 0 16px 30px -6px color-mix(in srgb, var(--sac-primary) 60%, transparent),\n 0 26px 60px -14px rgba(0, 0, 0, .7);\n}\n.launcher:active { transform: translateY(-1px) scale(.98); }\n.launcher .ico { width: 27px; height: 27px; display: block; transition: transform .4s var(--sac-ease); }\n.launcher:hover .ico { transform: rotate(-6deg) scale(1.04); }\n.launcher.hidden { opacity: 0; transform: scale(.4) translateY(10px); pointer-events: none; }\n\n/* ─────────────────────────────── Panel ────────────────────────────── */\n.panel {\n width: 390px;\n max-width: calc(100vw - 40px);\n height: 600px;\n max-height: calc(100vh - 56px);\n display: flex;\n flex-direction: column;\n overflow: hidden;\n border-radius: var(--sac-radius);\n background: linear-gradient(180deg, color-mix(in srgb, var(--sac-bg) 92%, #fff 8%) 0%, var(--sac-bg) 22%);\n color: var(--sac-text);\n border: 1px solid color-mix(in srgb, var(--sac-border) 80%, transparent);\n box-shadow:\n 0 0 0 1px rgba(255, 255, 255, .03) inset,\n 0 40px 80px -24px rgba(0, 0, 0, .65),\n 0 16px 40px -20px rgba(0, 0, 0, .5);\n transform-origin: bottom right;\n animation: sac-panel-in .5s var(--sac-ease) both;\n position: relative;\n}\n@keyframes sac-panel-in { from { opacity: 0; transform: translateY(16px) scale(.92) } to { opacity: 1; transform: none } }\n.panel.hidden { display: none; }\n/* Ambient brand glow bleeding from the top of the panel. */\n.panel::before {\n content: '';\n position: absolute;\n left: 0; right: 0; top: 0;\n height: 140px;\n pointer-events: none;\n background: radial-gradient(120% 100% at 50% 0%, color-mix(in srgb, var(--sac-primary) 22%, transparent), transparent 70%);\n}\n/* Full-page: the panel becomes the whole surface — it follows the host's box\n (via the .wrap flex chain), never a hardcoded viewport unit. */\n.panel.fullpage {\n width: 100%;\n flex: 1;\n height: auto;\n min-height: 0;\n max-width: none;\n max-height: none;\n border: none;\n border-radius: 0;\n box-shadow: none;\n animation: none;\n}\n\n/* ─────────────────────────────── Header ───────────────────────────── */\n.header {\n position: relative;\n display: flex;\n align-items: center;\n gap: 12px;\n padding: 16px 16px 14px;\n}\n.avatar {\n width: 40px;\n height: 40px;\n border-radius: 13px;\n flex: none;\n background: linear-gradient(140deg, var(--sac-primary), var(--sac-primary-2));\n display: flex;\n align-items: center;\n justify-content: center;\n color: var(--sac-primary-text);\n box-shadow:\n 0 6px 16px -6px color-mix(in srgb, var(--sac-primary) 60%, transparent),\n 0 1px 0 rgba(255, 255, 255, .25) inset;\n}\n.avatar svg { width: 22px; height: 22px; }\n.avatar .logo-wrap { display: flex; align-items: center; justify-content: center; width: 100%; height: 100%; }\n.avatar .logo { height: 22px; width: auto; display: block; }\n.avatar .logo-img { max-width: 100%; max-height: 100%; width: auto; height: auto; object-fit: contain; display: block; border-radius: 9px; }\n.meta { min-width: 0; flex: 1; display: flex; flex-direction: column; gap: 2px; }\n.title { font-weight: 650; font-size: 15.5px; letter-spacing: -.01em; line-height: 1.1; }\n.status {\n display: flex;\n align-items: center;\n gap: 6px;\n font-size: 12px;\n color: color-mix(in srgb, var(--sac-text) 62%, transparent);\n}\n.dot {\n width: 7px; height: 7px;\n border-radius: 50%;\n flex: none;\n background: #34d399;\n color: #34d399;\n box-shadow: 0 0 0 0 rgba(52, 211, 153, .6);\n animation: sac-pulse 2.4s ease-out infinite;\n}\n.dot.connecting { background: #fbbf24; color: #fbbf24; animation: sac-pulse 1.1s ease-out infinite; }\n.dot.error { background: #f87171; color: #f87171; animation: none; }\n.dot.off { background: #94a3b8; color: #94a3b8; animation: none; }\n@keyframes sac-pulse {\n 0% { box-shadow: 0 0 0 0 color-mix(in srgb, currentColor 55%, transparent) }\n 70% { box-shadow: 0 0 0 6px transparent }\n 100% { box-shadow: 0 0 0 0 transparent }\n}\n.close {\n margin-left: auto;\n width: 32px; height: 32px;\n border-radius: 10px;\n border: none;\n cursor: pointer;\n background: var(--sac-surface-2);\n color: inherit;\n display: flex;\n align-items: center;\n justify-content: center;\n transition: background .2s ease, transform .2s ease;\n}\n.close:hover { background: color-mix(in srgb, var(--sac-text) 12%, transparent); transform: translateY(1px); }\n.close svg { width: 16px; height: 16px; opacity: .8; }\n.powered { margin-left: auto; font-size: 10.5px; letter-spacing: .02em; opacity: .6; color: inherit; text-decoration: none; }\n.powered:hover { opacity: .85; text-decoration: underline; }\n.header-sep { height: 1px; margin: 0 16px; background: linear-gradient(90deg, transparent, var(--sac-border), transparent); }\n\n/* Full-page header: taller, logo-led, no close. */\n.panel.fullpage .header { padding: 18px 22px; }\n.panel.fullpage .avatar { width: 44px; height: 44px; }\n.panel.fullpage .avatar .logo { height: 26px; }\n.panel.fullpage .avatar svg { width: 28px; height: 28px; }\n\n/* ────────────────────────────── Messages ──────────────────────────── */\n.messages {\n flex: 1;\n overflow-y: auto;\n padding: 18px 16px 8px;\n display: flex;\n flex-direction: column;\n gap: 12px;\n scroll-behavior: smooth;\n}\n.messages::-webkit-scrollbar { width: 8px; }\n.messages::-webkit-scrollbar-thumb {\n background: color-mix(in srgb, var(--sac-text) 14%, transparent);\n border-radius: 99px;\n border: 2px solid transparent;\n background-clip: padding-box;\n}\n.messages::-webkit-scrollbar-thumb:hover {\n background: color-mix(in srgb, var(--sac-text) 24%, transparent);\n background-clip: padding-box;\n}\n\n.row {\n display: flex;\n gap: 9px;\n max-width: 88%;\n animation: sac-msg-in .42s var(--sac-ease) both;\n}\n@keyframes sac-msg-in { from { opacity: 0; transform: translateY(8px) } to { opacity: 1; transform: none } }\n.row.user { align-self: flex-end; flex-direction: row-reverse; }\n.row.assistant { align-self: flex-start; }\n.mini {\n width: 26px; height: 26px;\n border-radius: 9px;\n flex: none;\n align-self: flex-end;\n background: linear-gradient(140deg, var(--sac-primary), var(--sac-primary-2));\n display: flex;\n align-items: center;\n justify-content: center;\n color: var(--sac-primary-text);\n}\n.mini svg { width: 15px; height: 15px; }\n\n.bubble {\n padding: 11px 14px;\n border-radius: 16px;\n font-size: 14px;\n line-height: 1.5;\n white-space: pre-wrap;\n word-break: break-word;\n position: relative;\n}\n.bubble.assistant {\n background: linear-gradient(180deg, color-mix(in srgb, var(--sac-assistant-bubble) 86%, #fff 5%), var(--sac-assistant-bubble));\n color: var(--sac-assistant-bubble-text);\n border: 1px solid color-mix(in srgb, var(--sac-text) 8%, transparent);\n border-bottom-left-radius: 5px;\n box-shadow: 0 2px 8px -4px rgba(0, 0, 0, .4);\n}\n.bubble.user {\n background: linear-gradient(165deg,\n color-mix(in srgb, var(--sac-user-bubble) 88%, #fff 12%),\n var(--sac-user-bubble) 60%,\n color-mix(in srgb, var(--sac-user-bubble) 80%, var(--sac-primary-2) 20%));\n color: var(--sac-user-bubble-text);\n border-bottom-right-radius: 5px;\n box-shadow: 0 6px 16px -8px color-mix(in srgb, var(--sac-primary) 50%, transparent);\n}\n.bubble.greeting {\n background: transparent;\n border: 1px dashed color-mix(in srgb, var(--sac-text) 14%, transparent);\n color: color-mix(in srgb, var(--sac-text) 80%, transparent);\n box-shadow: none;\n}\n\n/* Typing indicator (assistant bubble with no text yet). */\n.bubble.typing { display: flex; gap: 4px; padding: 14px 15px; }\n.bubble.typing i {\n width: 7px; height: 7px;\n border-radius: 50%;\n background: color-mix(in srgb, var(--sac-assistant-bubble-text) 55%, transparent);\n animation: sac-typing 1.3s ease-in-out infinite;\n}\n.bubble.typing i:nth-child(2) { animation-delay: .18s; }\n.bubble.typing i:nth-child(3) { animation-delay: .36s; }\n@keyframes sac-typing { 0%, 60%, 100% { transform: translateY(0); opacity: .4 } 30% { transform: translateY(-5px); opacity: 1 } }\n\n.cursor::after {\n content: '';\n display: inline-block;\n width: 2px; height: 1.05em;\n margin-left: 2px;\n vertical-align: -2px;\n border-radius: 2px;\n background: currentColor;\n animation: sac-blink 1s steps(2, start) infinite;\n}\n@keyframes sac-blink { to { opacity: 0 } }\n\n/* ─────────────── Rendered markdown (assistant bubbles / snippets) ─────────── */\n/* The renderer (markdown.ts) emits a small allowlisted set of tags; these rules\n keep them legible inside the tight Aurora-Glass bubble + citation card. */\n/* Block-level markdown drives its own spacing/wrapping, so opt out of the\n bubble's pre-wrap (which would otherwise add stray blank lines). */\n.bubble.md { white-space: normal; }\n.md > :first-child { margin-top: 0; }\n.md > :last-child { margin-bottom: 0; }\n.md p { margin: 0 0 8px; }\n.md ul, .md ol { margin: 6px 0 8px; padding-left: 20px; }\n.md li { margin: 2px 0; }\n.md li::marker { color: color-mix(in srgb, var(--sac-primary) 75%, transparent); }\n.md a {\n color: color-mix(in srgb, var(--sac-primary) 92%, #fff);\n text-decoration: underline;\n text-underline-offset: 2px;\n word-break: break-word;\n}\n.md a:hover { text-decoration: none; }\n.md strong { font-weight: 700; }\n.md em { font-style: italic; }\n.md code {\n font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;\n font-size: .9em;\n padding: 1px 5px;\n border-radius: 5px;\n background: color-mix(in srgb, var(--sac-text) 10%, transparent);\n}\n.md pre {\n margin: 6px 0 8px;\n padding: 9px 11px;\n border-radius: 9px;\n overflow-x: auto;\n background: color-mix(in srgb, var(--sac-text) 9%, transparent);\n border: 1px solid color-mix(in srgb, var(--sac-text) 8%, transparent);\n}\n.md pre code { padding: 0; background: none; font-size: 12px; line-height: 1.45; }\n.md blockquote {\n margin: 6px 0;\n padding: 2px 0 2px 11px;\n border-left: 2px solid color-mix(in srgb, var(--sac-primary) 55%, transparent);\n color: color-mix(in srgb, var(--sac-text) 78%, transparent);\n}\n\n/* Full-page: center the conversation in a readable column. */\n.panel.fullpage .messages { padding: 26px 20px; }\n.panel.fullpage .row { max-width: 760px; width: 100%; margin-left: auto; margin-right: auto; }\n.panel.fullpage .row.user { max-width: 80%; margin-right: 0; }\n\n/* ───────────────── Sources (grounding citations) ──────────────────── */\n.sources {\n align-self: flex-start;\n max-width: 88%;\n margin: -4px 0 0 35px;\n}\n.panel.fullpage .sources { max-width: 760px; width: 100%; margin-left: auto; margin-right: auto; }\n.sources summary {\n cursor: pointer;\n list-style: none;\n display: inline-flex;\n align-items: center;\n gap: 7px;\n font-size: 12px;\n font-weight: 600;\n color: color-mix(in srgb, var(--sac-text) 70%, transparent);\n padding: 5px 0;\n user-select: none;\n}\n.sources summary::-webkit-details-marker { display: none; }\n.sources .chev { transition: transform .2s var(--sac-ease); flex: none; }\n.sources details[open] .chev { transform: rotate(90deg); }\n.sources .count {\n background: color-mix(in srgb, var(--sac-primary) 18%, transparent);\n color: color-mix(in srgb, var(--sac-primary) 92%, #fff);\n font-size: 10.5px;\n font-weight: 700;\n padding: 1px 7px;\n border-radius: 99px;\n}\n.sources ol { list-style: none; margin: 6px 0 2px; padding: 0; display: flex; flex-direction: column; gap: 7px; }\n.sources li {\n background: var(--sac-surface-2);\n border: 1px solid color-mix(in srgb, var(--sac-border) 70%, transparent);\n border-left: 2px solid var(--sac-primary);\n border-radius: 9px;\n padding: 8px 10px;\n}\n.sources .src-title {\n color: color-mix(in srgb, var(--sac-primary) 92%, #fff);\n font-weight: 600;\n font-size: 12.5px;\n text-decoration: none;\n word-break: break-word;\n}\n.sources a.src-title:hover { text-decoration: underline; }\n.sources span.src-title { color: var(--sac-text); opacity: .95; }\n.sources .src-snippet {\n display: block;\n margin-top: 3px;\n font-size: 11.5px;\n line-height: 1.45;\n color: color-mix(in srgb, var(--sac-text) 55%, transparent);\n white-space: normal;\n}\n\n/* ────────────────────────────── Composer ──────────────────────────── */\n.composer-wrap { padding: 12px 14px calc(12px + env(safe-area-inset-bottom)); }\n.composer {\n display: flex;\n align-items: flex-end;\n gap: 8px;\n padding: 7px 7px 7px 14px;\n border-radius: 18px;\n background: var(--sac-surface-2);\n border: 1px solid color-mix(in srgb, var(--sac-border) 80%, transparent);\n transition: border-color .25s ease, box-shadow .25s ease, background .25s ease;\n}\n.composer:focus-within {\n border-color: color-mix(in srgb, var(--sac-primary) 60%, transparent);\n box-shadow: 0 0 0 4px color-mix(in srgb, var(--sac-primary) 14%, transparent);\n}\n.composer textarea {\n flex: 1;\n resize: none;\n border: none;\n background: transparent;\n color: var(--sac-text);\n font-family: inherit;\n font-size: 14px;\n line-height: 1.45;\n max-height: 120px;\n padding: 6px 0;\n outline: none;\n}\n.composer textarea::placeholder { color: color-mix(in srgb, var(--sac-text) 42%, transparent); }\n.send {\n width: 38px; height: 38px;\n flex: none;\n border: none;\n border-radius: 13px;\n cursor: pointer;\n display: flex;\n align-items: center;\n justify-content: center;\n background: linear-gradient(150deg, var(--sac-primary), var(--sac-primary-2));\n color: var(--sac-primary-text);\n box-shadow:\n 0 6px 14px -6px color-mix(in srgb, var(--sac-primary) 65%, transparent),\n 0 1px 0 rgba(255, 255, 255, .25) inset;\n transition: transform .2s var(--sac-ease), box-shadow .2s var(--sac-ease), opacity .2s ease;\n}\n.send svg { width: 18px; height: 18px; }\n.send:hover { transform: translateY(-1px) scale(1.05); }\n.send:active { transform: scale(.94); }\n.send:disabled { opacity: .4; cursor: default; transform: none; box-shadow: none; }\n.footer {\n text-align: center;\n margin-top: 9px;\n font-size: 10.5px;\n letter-spacing: .04em;\n color: color-mix(in srgb, var(--sac-text) 38%, transparent);\n}\n.footer b { font-weight: 600; color: color-mix(in srgb, var(--sac-text) 55%, transparent); }\n.footer a { color: inherit; text-decoration: none; }\n.footer a:hover { text-decoration: underline; }\n\n/* ─────────────────── Pre-chat identity form ───────────────────────── */\n.prechat { flex: 1; display: flex; flex-direction: column; justify-content: center; gap: 18px; padding: 22px 20px; }\n.pc-head { text-align: center; }\n.pc-title { font-size: 17px; font-weight: 650; letter-spacing: -.01em; }\n.pc-sub { margin-top: 4px; font-size: 13px; color: color-mix(in srgb, var(--sac-text) 60%, transparent); }\n.pc-form { display: flex; flex-direction: column; gap: 12px; }\n.pc-field { display: flex; flex-direction: column; gap: 5px; }\n.pc-field span { font-size: 12px; font-weight: 600; color: color-mix(in srgb, var(--sac-text) 70%, transparent); }\n.pc-field input {\n border: 1px solid color-mix(in srgb, var(--sac-border) 80%, transparent);\n background: var(--sac-surface-2);\n color: var(--sac-text);\n border-radius: 12px;\n padding: 11px 13px;\n font-family: inherit;\n font-size: 14px;\n outline: none;\n transition: border-color .2s ease, box-shadow .2s ease;\n}\n.pc-field input::placeholder { color: color-mix(in srgb, var(--sac-text) 42%, transparent); }\n.pc-field input:focus {\n border-color: color-mix(in srgb, var(--sac-primary) 60%, transparent);\n box-shadow: 0 0 0 4px color-mix(in srgb, var(--sac-primary) 14%, transparent);\n}\n/* Inline phone validity — subtle, themed. Empty stays neutral (optional field). */\n.pc-field.valid input {\n border-color: color-mix(in srgb, var(--sac-primary) 55%, #2faa6a 45%);\n}\n.pc-field.invalid input {\n border-color: color-mix(in srgb, #e2566b 62%, var(--sac-border) 38%);\n}\n.pc-field.invalid input:focus {\n box-shadow: 0 0 0 4px color-mix(in srgb, #e2566b 16%, transparent);\n}\n.pc-field .pc-hint {\n min-height: 13px;\n margin-top: 1px;\n font-size: 11.5px;\n font-weight: 500;\n line-height: 1.2;\n color: color-mix(in srgb, #e2566b 78%, var(--sac-text) 22%);\n}\n.pc-submit {\n margin-top: 4px;\n border: none;\n border-radius: 13px;\n padding: 12px;\n cursor: pointer;\n background: linear-gradient(150deg, var(--sac-primary), var(--sac-primary-2));\n color: var(--sac-primary-text);\n font-weight: 650;\n font-size: 14px;\n box-shadow: 0 6px 14px -6px color-mix(in srgb, var(--sac-primary) 65%, transparent), 0 1px 0 rgba(255, 255, 255, .25) inset;\n transition: transform .2s var(--sac-ease);\n}\n.pc-submit:hover { transform: translateY(-1px); }\n.pc-submit:active { transform: scale(.98); }\n.pc-consents { display: flex; flex-direction: column; gap: 9px; margin-top: 2px; }\n.pc-consent { display: flex; align-items: flex-start; gap: 9px; cursor: pointer; }\n.pc-consent input {\n margin-top: 2px;\n width: 16px;\n height: 16px;\n flex: 0 0 auto;\n accent-color: var(--sac-primary);\n cursor: pointer;\n}\n.pc-consent span { font-size: 12px; line-height: 1.4; color: color-mix(in srgb, var(--sac-text) 72%, transparent); }\n\n/* ─────────────────── Starter-prompt chips ─────────────────────────── */\n.prompts { display: flex; flex-wrap: wrap; gap: 8px; margin: 2px 0 2px 35px; }\n.panel.fullpage .prompts { margin-left: auto; margin-right: auto; max-width: 760px; width: 100%; }\n.chip {\n border: 1px solid color-mix(in srgb, var(--sac-border) 80%, transparent);\n background: var(--sac-surface-2);\n color: var(--sac-text);\n border-radius: 999px;\n padding: 8px 13px;\n font-family: inherit;\n font-size: 12.5px;\n cursor: pointer;\n text-align: left;\n transition: border-color .2s ease, background .2s ease, transform .2s ease;\n}\n.chip:hover {\n border-color: color-mix(in srgb, var(--sac-primary) 50%, transparent);\n background: color-mix(in srgb, var(--sac-primary) 10%, var(--sac-surface-2));\n transform: translateY(-1px);\n}\n\n/* ───────────── Mid-conversation suggested-reply chips ─────────────── */\n.reply-suggestions { padding: 0 14px 4px; }\n.reply-suggestions:empty { display: none; }\n\n/* ─────────────── OTP / tool-confirmation interrupt ────────────────── */\n.interrupt { padding: 0 14px; }\n.int-card {\n border: 1px solid color-mix(in srgb, var(--sac-primary) 35%, var(--sac-border));\n background: color-mix(in srgb, var(--sac-primary) 8%, var(--sac-surface-2));\n border-radius: 14px;\n padding: 12px 13px;\n animation: sac-msg-in .3s var(--sac-ease) both;\n}\n.int-head { display: flex; align-items: center; gap: 8px; }\n.int-ico { display: flex; color: var(--sac-primary); }\n.int-ico svg { width: 17px; height: 17px; }\n.int-title { font-size: 13.5px; font-weight: 650; }\n.int-desc { margin-top: 5px; font-size: 12.5px; line-height: 1.45; color: color-mix(in srgb, var(--sac-text) 80%, transparent); }\n.int-sent { margin-top: 6px; font-size: 11.5px; color: color-mix(in srgb, var(--sac-text) 60%, transparent); }\n.int-row { display: flex; gap: 8px; margin-top: 10px; }\n.int-input {\n flex: 1;\n min-width: 0;\n border: 1px solid color-mix(in srgb, var(--sac-border) 80%, transparent);\n background: var(--sac-bg);\n color: var(--sac-text);\n border-radius: 10px;\n padding: 9px 11px;\n font-family: inherit;\n font-size: 14px;\n letter-spacing: .14em;\n outline: none;\n transition: border-color .2s ease, box-shadow .2s ease;\n}\n.int-input:focus {\n border-color: color-mix(in srgb, var(--sac-primary) 60%, transparent);\n box-shadow: 0 0 0 4px color-mix(in srgb, var(--sac-primary) 14%, transparent);\n}\n.int-btn {\n border: 1px solid color-mix(in srgb, var(--sac-border) 80%, transparent);\n background: var(--sac-surface-2);\n color: var(--sac-text);\n border-radius: 10px;\n padding: 9px 14px;\n font-family: inherit;\n font-size: 13px;\n font-weight: 600;\n cursor: pointer;\n transition: transform .2s var(--sac-ease), background .2s ease, border-color .2s ease;\n}\n.int-btn:hover { transform: translateY(-1px); }\n.int-btn.primary {\n border: none;\n background: linear-gradient(150deg, var(--sac-primary), var(--sac-primary-2));\n color: var(--sac-primary-text);\n box-shadow: 0 6px 14px -6px color-mix(in srgb, var(--sac-primary) 65%, transparent);\n}\n.int-row .int-btn { flex: 1; }\n.int-row .int-input + .int-btn { flex: 0 0 auto; }\n.int-error { margin-top: 8px; font-size: 12px; color: #f87171; }\n.int-card { position: relative; }\n.int-close {\n position: absolute;\n top: 8px;\n right: 9px;\n border: none;\n background: transparent;\n color: color-mix(in srgb, var(--sac-text) 55%, transparent);\n font-size: 18px;\n line-height: 1;\n cursor: pointer;\n padding: 2px 4px;\n border-radius: 6px;\n transition: color .2s ease, background .2s ease;\n}\n.int-close:hover { color: var(--sac-text); background: color-mix(in srgb, var(--sac-text) 8%, transparent); }\n\n/* ─────────────── Cross-device \"Restore my chats\" ──────────────────── */\n.restore-link {\n border: none;\n background: none;\n padding: 0;\n font: inherit;\n font-size: 10.5px;\n letter-spacing: .04em;\n color: color-mix(in srgb, var(--sac-primary) 80%, var(--sac-text));\n cursor: pointer;\n text-decoration: underline;\n text-underline-offset: 2px;\n}\n.restore-link:hover { color: var(--sac-primary); }\n.restore-list { display: flex; flex-direction: column; gap: 7px; margin-top: 9px; }\n.restore-item {\n display: flex;\n align-items: center;\n justify-content: space-between;\n gap: 10px;\n text-align: left;\n border: 1px solid color-mix(in srgb, var(--sac-border) 80%, transparent);\n background: var(--sac-bg);\n color: var(--sac-text);\n border-radius: 10px;\n padding: 9px 11px;\n font-family: inherit;\n font-size: 12.5px;\n cursor: pointer;\n transition: border-color .2s ease, background .2s ease, transform .2s ease;\n}\n.restore-item:hover {\n border-color: color-mix(in srgb, var(--sac-primary) 50%, transparent);\n background: color-mix(in srgb, var(--sac-primary) 8%, var(--sac-bg));\n transform: translateY(-1px);\n}\n.restore-preview { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }\n.restore-when { flex: 0 0 auto; font-size: 11px; color: color-mix(in srgb, var(--sac-text) 55%, transparent); }\n\n.hidden { display: none !important; }\n\n@media (prefers-reduced-motion: reduce) {\n .launcher::before, .dot, .bubble.typing i { animation: none !important; }\n .panel, .row, .launcher, .send, .close { animation: none !important; transition: none !important; }\n}\n`;\n}\n","/**\n * `<smooth-agent-chat>` — a framework-light embeddable chat web component.\n *\n * A clean, dependency-light web component that preserves a familiar embedding\n * model — a launcher + popover panel, declarative HTML attributes, and a\n * programmatic API — while talking to the `@smooai/smooth-operator` protocol\n * client. The visual layer is the \"Aurora Glass\" design system (see\n * {@link buildStyles}): a spring launcher with a live presence pulse, a\n * glass-depth panel, a gradient brand avatar + status dot, an animated typing\n * indicator, message rise-in, refined source cards, and an icon composer. Every\n * color is driven by `--sac-*` custom properties so a host's brand flows through.\n *\n * Embedding model:\n * <smooth-agent-chat endpoint=\"ws://localhost:8787/ws\" agent-id=\"…\"></smooth-agent-chat>\n * or programmatically via {@link mountChatWidget}.\n */\nimport { AsYouType, isValidPhoneNumber, parsePhoneNumber } from 'libphonenumber-js/min';\nimport type { ChatWidgetConfig, ChatWidgetMode, ChatWidgetTheme } from './config.js';\nimport { needsUserInfo, resolveConfig } from './config.js';\nimport { type ChatMessage, type Citation, type ConnectionStatus, ConversationController, type IdentityRestore, type Interrupt } from './conversation.js';\nimport { SMOOTH_ICON_SVG } from './logo.js';\nimport { cleanCitationSnippet, escapeHtml, renderMarkdown, safeHttpUrl } from './markdown.js';\nimport { buildStyles } from './styles.js';\n\nexport const ELEMENT_TAG = 'smooth-agent-chat';\n\n/**\n * Default region for phone parsing/formatting on the pre-chat form. The widget\n * is US-first; the backend does the authoritative E.164 normalization (SMOODEV-2153),\n * so this only governs the as-you-type display + the inline validity hint and the\n * best-effort E.164 we send when the number already parses as valid.\n */\nconst PHONE_DEFAULT_REGION = 'US' as const;\n\n/**\n * Best-effort E.164 for an as-typed phone number. Returns the canonical\n * `+1…` form when the value parses to a valid number in {@link PHONE_DEFAULT_REGION},\n * otherwise `null` (caller falls back to sending the raw value — the backend\n * re-parses and normalizes/nulls authoritatively).\n */\nfunction phoneToE164(value: string): string | null {\n const v = value.trim();\n if (!v) return null;\n try {\n if (!isValidPhoneNumber(v, PHONE_DEFAULT_REGION)) return null;\n return parsePhoneNumber(v, PHONE_DEFAULT_REGION).number;\n } catch {\n return null;\n }\n}\n\n/** Public smooth-operator repo — the \"powered by\" header tag + footer link here. */\nconst SMOOTH_OPERATOR_URL = 'https://github.com/SmooAI/smooth-operator';\n\nconst OBSERVED = ['endpoint', 'agent-id', 'agent-name', 'logo-url', 'placeholder', 'greeting', 'start-open', 'mode', 'hide-branding'] as const;\n\n/**\n * Inline SVG icons (static, trusted strings — never interpolated with user data).\n * Kept here so the IIFE bundle is self-contained: no icon-font or network fetch.\n */\nconst ICON = {\n /** Launcher — a speech bubble carrying a spark (chat + AI). */\n spark: `<svg class=\"ico\" viewBox=\"0 0 24 24\" fill=\"none\" xmlns=\"http://www.w3.org/2000/svg\"><path d=\"M12 3.5c-4.7 0-8.5 3.2-8.5 7.2 0 2.2 1.2 4.2 3 5.5v3.3l3.2-1.7c.7.1 1.5.2 2.3.2 4.7 0 8.5-3.2 8.5-7.3S16.7 3.5 12 3.5Z\" fill=\"currentColor\" opacity=\".22\"/><path d=\"M13.4 7.2 9 12.6h2.6l-1 4.2 4.4-5.4h-2.6l1-4.2Z\" fill=\"currentColor\"/></svg>`,\n /** Small assistant avatar used beside each assistant message. */\n bot: `<svg viewBox=\"0 0 24 24\" fill=\"none\" xmlns=\"http://www.w3.org/2000/svg\"><rect x=\"4.5\" y=\"7.5\" width=\"15\" height=\"11\" rx=\"3.5\" stroke=\"currentColor\" stroke-width=\"1.6\"/><path d=\"M12 4.5v3M8.5 12.2h.01M15.5 12.2h.01\" stroke=\"currentColor\" stroke-width=\"1.8\" stroke-linecap=\"round\"/><path d=\"M9.5 15.4c.7.6 1.5.9 2.5.9s1.8-.3 2.5-.9\" stroke=\"currentColor\" stroke-width=\"1.5\" stroke-linecap=\"round\"/></svg>`,\n /** Close (collapse panel) — a downward chevron. */\n close: `<svg viewBox=\"0 0 24 24\" fill=\"none\" xmlns=\"http://www.w3.org/2000/svg\"><path d=\"m7 10 5 5 5-5\" stroke=\"currentColor\" stroke-width=\"1.8\" stroke-linecap=\"round\" stroke-linejoin=\"round\"/></svg>`,\n /** Send — an upward arrow. */\n send: `<svg viewBox=\"0 0 24 24\" fill=\"none\" xmlns=\"http://www.w3.org/2000/svg\"><path d=\"M12 19V6M12 6l-5.5 5.5M12 6l5.5 5.5\" stroke=\"currentColor\" stroke-width=\"1.9\" stroke-linecap=\"round\" stroke-linejoin=\"round\"/></svg>`,\n /** Sources disclosure caret. */\n chev: `<svg width=\"11\" height=\"11\" viewBox=\"0 0 24 24\" fill=\"none\"><path d=\"m9 6 6 6-6 6\" stroke=\"currentColor\" stroke-width=\"2.2\" stroke-linecap=\"round\" stroke-linejoin=\"round\"/></svg>`,\n /** OTP interrupt — a padlock. */\n lock: `<svg viewBox=\"0 0 24 24\" fill=\"none\" xmlns=\"http://www.w3.org/2000/svg\"><rect x=\"5\" y=\"10.5\" width=\"14\" height=\"9.5\" rx=\"2.2\" stroke=\"currentColor\" stroke-width=\"1.7\"/><path d=\"M8 10.5V8a4 4 0 0 1 8 0v2.5\" stroke=\"currentColor\" stroke-width=\"1.7\"/></svg>`,\n /** Tool-confirmation interrupt — a shield. */\n shield: `<svg viewBox=\"0 0 24 24\" fill=\"none\" xmlns=\"http://www.w3.org/2000/svg\"><path d=\"M12 3 5 6v5c0 4.4 3 7.2 7 8.5 4-1.3 7-4.1 7-8.5V6l-7-3Z\" stroke=\"currentColor\" stroke-width=\"1.7\" stroke-linejoin=\"round\"/><path d=\"m9 11.5 2 2 4-4\" stroke=\"currentColor\" stroke-width=\"1.7\" stroke-linecap=\"round\" stroke-linejoin=\"round\"/></svg>`,\n} as const;\n\n// `safeHttpUrl` / `escapeHtml` live in `./markdown.js` (the markdown renderer\n// needs them too); re-exported here for back-compat with existing importers.\nexport { escapeHtml, safeHttpUrl } from './markdown.js';\n\nexport class SmoothAgentChatElement extends HTMLElement {\n static get observedAttributes(): readonly string[] {\n return OBSERVED;\n }\n\n private readonly root: ShadowRoot;\n private controller: ConversationController | null = null;\n private overrides: Partial<ChatWidgetConfig> = {};\n private open = false;\n private messages: ChatMessage[] = [];\n private status: ConnectionStatus = 'idle';\n private mounted = false;\n /** True once the visitor has cleared the pre-chat identity gate (or it's not needed). */\n private userInfoSatisfied = false;\n /** True after the visitor has sent their first message (hides starter chips). */\n private hasSent = false;\n /** Starter prompts shown as chips in the empty state. */\n private examplePrompts: string[] = [];\n /** Whether mid-conversation suggested-reply chips are shown (config). */\n private showSuggestedReplies = true;\n /** Resolved greeting text, cached so async (rAF) renders can reuse it. */\n private greeting = '';\n /** Current mid-turn interrupt (OTP / tool-confirmation), or null. */\n private interrupt: Interrupt | null = null;\n private interruptEl: HTMLElement | null = null;\n /** Cross-device \"restore my chats\" flow state (ADR-048 §c). */\n private identityRestore: IdentityRestore = { phase: 'idle' };\n /** Whether the cross-device restore affordance is offered (config). */\n private allowChatRestore = true;\n /** True while the pre-chat identity gate is showing (blocks premature connect). */\n private gating = false;\n\n // Cached DOM refs (populated in render()).\n private panelEl: HTMLElement | null = null;\n private launcherEl: HTMLElement | null = null;\n private messagesEl: HTMLElement | null = null;\n private statusEl: HTMLElement | null = null;\n private dotEl: HTMLElement | null = null;\n private inputEl: HTMLTextAreaElement | null = null;\n private sendBtn: HTMLButtonElement | null = null;\n private suggestionsEl: HTMLElement | null = null;\n\n // ── Smooth streaming reveal ──\n // Tokens arrive in variable-size bursts at uneven rates, so revealing text in\n // lockstep with arrival looks jerky. Instead we buffer the full target text\n // and reveal it via a requestAnimationFrame \"typewriter\" at an adaptive rate\n // (chars/frame scales with the pending backlog so it never falls behind the\n // network). State below tracks the single in-flight streaming bubble.\n /** The live streaming assistant bubble whose textContent the rAF loop drives. */\n private streamBubbleEl: HTMLElement | null = null;\n /** Message id the reveal is bound to (guards against stale frames after rebuilds). */\n private streamMsgId: string | null = null;\n /** Full buffered target text for the streaming message (grows as tokens arrive). */\n private streamTarget = '';\n /** How many chars of {@link streamTarget} are currently shown. */\n private displayedLength = 0;\n private rafId = 0;\n\n constructor() {\n super();\n this.root = this.attachShadow({ mode: 'open' });\n }\n\n connectedCallback(): void {\n this.mounted = true;\n this.render();\n }\n\n disconnectedCallback(): void {\n this.mounted = false;\n this.resetReveal();\n this.controller?.disconnect();\n this.controller = null;\n }\n\n attributeChangedCallback(): void {\n if (this.mounted) this.render();\n }\n\n /**\n * Programmatically merge config overrides (endpoint, agentId, theme, …). Values\n * set here take precedence over HTML attributes. Re-renders the widget.\n */\n configure(config: Partial<ChatWidgetConfig>): void {\n this.overrides = { ...this.overrides, ...config };\n if (config.theme) {\n this.overrides.theme = { ...(this.overrides.theme ?? {}), ...config.theme };\n }\n if (this.mounted) this.render();\n }\n\n /** Open the chat panel. */\n openChat(): void {\n this.open = true;\n this.syncOpenState();\n // Don't connect while the pre-chat identity gate is unsatisfied — connecting\n // here would create a session BEFORE the visitor submits their name/email/\n // consent, sending an empty identity. The form's submit handler connects.\n if (!this.gating) void this.controller?.connect().catch(() => {});\n }\n\n /** Collapse the chat panel back to the launcher. */\n closeChat(): void {\n this.open = false;\n this.syncOpenState();\n }\n\n // ─────────────────────────── Config resolution ─────────────────────────────\n\n private readConfig(): ChatWidgetConfig | null {\n const endpoint = this.overrides.endpoint ?? this.getAttribute('endpoint') ?? '';\n const agentId = this.overrides.agentId ?? this.getAttribute('agent-id') ?? '';\n if (!endpoint || !agentId) return null;\n\n const theme: ChatWidgetTheme | undefined = this.overrides.theme;\n const modeAttr = this.getAttribute('mode');\n const mode: ChatWidgetMode = this.overrides.mode ?? (modeAttr === 'fullpage' ? 'fullpage' : modeAttr === 'popover' ? 'popover' : undefined) ?? 'popover';\n return {\n endpoint,\n mode,\n agentId,\n agentName: this.overrides.agentName ?? this.getAttribute('agent-name') ?? undefined,\n logoUrl: this.overrides.logoUrl ?? this.getAttribute('logo-url') ?? undefined,\n userName: this.overrides.userName,\n userEmail: this.overrides.userEmail,\n userPhone: this.overrides.userPhone,\n authContext: this.overrides.authContext,\n placeholder: this.overrides.placeholder ?? this.getAttribute('placeholder') ?? undefined,\n greeting: this.overrides.greeting ?? this.getAttribute('greeting') ?? undefined,\n connectionErrorMessage: this.overrides.connectionErrorMessage,\n startOpen: this.overrides.startOpen ?? this.hasAttribute('start-open'),\n hideBranding: this.overrides.hideBranding ?? this.hasAttribute('hide-branding'),\n examplePrompts: this.overrides.examplePrompts,\n showSuggestedReplies: this.overrides.showSuggestedReplies,\n requireName: this.overrides.requireName,\n requireEmail: this.overrides.requireEmail,\n requirePhone: this.overrides.requirePhone,\n collectPhone: this.overrides.collectPhone,\n collectConsent: this.overrides.collectConsent,\n allowChatRestore: this.overrides.allowChatRestore,\n allowAnonymous: this.overrides.allowAnonymous,\n theme,\n };\n }\n\n // ───────────────────────────────── Render ──────────────────────────────────\n\n private render(): void {\n const config = this.readConfig();\n if (!config) {\n this.root.innerHTML = '';\n return;\n }\n const resolved = resolveConfig(config);\n\n this.allowChatRestore = resolved.allowChatRestore;\n\n // (Re)create the controller only when there isn't one yet. Attribute churn\n // (e.g. theme tweaks) re-renders the view without dropping the session.\n if (!this.controller) {\n this.controller = new ConversationController(config, {\n onMessages: (messages) => {\n this.handleMessages(messages, resolved.greeting);\n },\n onStatus: (status) => {\n this.status = status;\n this.renderStatus();\n this.renderComposerState();\n },\n onInterrupt: (interrupt) => {\n this.interrupt = interrupt;\n this.renderInterrupt();\n // Suggestion chips are hidden while an interrupt overlay is up.\n this.renderSuggestions();\n },\n onIdentityRestore: (state) => {\n this.identityRestore = state;\n this.renderInterrupt();\n // The restore overlay reuses the interrupt slot — hide chips too.\n this.renderSuggestions();\n },\n });\n if (resolved.startOpen) this.open = true;\n // Returning visitor: a persisted session or identity lets us skip the\n // pre-chat gate and resume straight into the conversation (ADR-048 §b).\n if (this.controller.hasPersistedSession() || this.controller.hasPersistedIdentity()) {\n this.userInfoSatisfied = true;\n }\n }\n\n const fullpage = resolved.mode === 'fullpage';\n // Full-page mode is always \"open\" — it fills its container and has no\n // launcher to toggle.\n if (fullpage) this.open = true;\n\n const style = document.createElement('style');\n style.textContent = buildStyles(resolved.theme, resolved.mode);\n\n // Header: in full-page mode lead with the brand logo in the avatar tile\n // and a subtle \"powered by\" tag; in popover mode show a brand-colored\n // monogram avatar + a compact close (collapse) button. The logo defaults\n // to the square Smooth icon, but a host page can override it with\n // `logoUrl` (already sanitized to http(s)-only by resolveConfig; escaped\n // here so it can't break out of the src attribute).\n const monogram = escapeHtml((resolved.agentName.trim().charAt(0) || 'A').toUpperCase());\n const headerLogo = resolved.logoUrl\n ? `<img src=\"${escapeHtml(resolved.logoUrl)}\" alt=\"\" class=\"logo-img\" />`\n : SMOOTH_ICON_SVG;\n const header = fullpage\n ? `<div class=\"header\">\n <div class=\"avatar\"><span class=\"logo-wrap\">${headerLogo}</span></div>\n <div class=\"meta\">\n <span class=\"title\">${escapeHtml(resolved.agentName)}</span>\n <span class=\"status\"><span class=\"dot off\"></span><span class=\"status-text\"></span></span>\n </div>\n ${\n resolved.hideBranding\n ? ''\n : `<a class=\"powered\" href=\"${SMOOTH_OPERATOR_URL}\" target=\"_blank\" rel=\"noopener noreferrer\">powered by smooth-operator</a>`\n }\n </div>`\n : `<div class=\"header\">\n <div class=\"avatar\">${monogram}</div>\n <div class=\"meta\">\n <span class=\"title\">${escapeHtml(resolved.agentName)}</span>\n <span class=\"status\"><span class=\"dot off\"></span><span class=\"status-text\"></span></span>\n </div>\n <button class=\"close\" aria-label=\"Close chat\">${ICON.close}</button>\n </div>`;\n\n // Remember starter prompts + greeting for the empty-state chips / async renders.\n this.examplePrompts = resolved.examplePrompts;\n this.showSuggestedReplies = resolved.showSuggestedReplies;\n this.greeting = resolved.greeting;\n\n // Gate the conversation behind a pre-chat identity form when required.\n const gating = needsUserInfo(resolved) && !this.userInfoSatisfied;\n this.gating = gating;\n // Phone is collected by default (optional unless requirePhone). Consent\n // checkboxes default to shown, explicit + unchecked (ADR-048 §a/§3).\n const showPhone = resolved.requirePhone || resolved.collectPhone;\n const field = (name: string, type: string, label: string, autocomplete: string, required: boolean, hint = false) =>\n `<label class=\"pc-field\"><span>${escapeHtml(label)}</span><input name=\"${name}\" type=\"${type}\" autocomplete=\"${autocomplete}\"${required ? ' required' : ''} />${\n hint ? '<span class=\"pc-hint\" aria-live=\"polite\"></span>' : ''\n }</label>`;\n const consentBox = (name: string, label: string) =>\n `<label class=\"pc-consent\"><input name=\"${name}\" type=\"checkbox\" /><span>${escapeHtml(label)}</span></label>`;\n const consentHtml = resolved.collectConsent\n ? `<div class=\"pc-consents\">\n ${consentBox('emailOptIn', 'Email me product news and offers.')}\n ${consentBox('smsOptIn', 'Text me updates by SMS. Message/data rates may apply.')}\n </div>`\n : '';\n const prechatHtml = `\n <div class=\"prechat\">\n <div class=\"pc-head\">\n <div class=\"pc-title\">Before we chat</div>\n <div class=\"pc-sub\">A couple details so ${escapeHtml(resolved.agentName)} can help.</div>\n </div>\n <form class=\"pc-form\" novalidate>\n ${resolved.requireName ? field('name', 'text', 'Name', 'name', true) : ''}\n ${resolved.requireEmail ? field('email', 'email', 'Email', 'email', true) : ''}\n ${showPhone ? field('phone', 'tel', 'Phone', 'tel', resolved.requirePhone, true) : ''}\n ${consentHtml}\n <button type=\"submit\" class=\"pc-submit\">Start chat</button>\n </form>\n </div>`;\n // Footer: optional \"powered by\" branding (hidden by hide-branding) and an\n // optional \"Restore my chats\" affordance. The \" · \" separator only appears\n // when both are present, and the footer is omitted entirely when neither is.\n const brandingHtml = resolved.hideBranding\n ? ''\n : `<a href=\"${SMOOTH_OPERATOR_URL}\" target=\"_blank\" rel=\"noopener noreferrer\">powered by <b>smooth‑operator</b></a>`;\n const restoreBtn = this.allowChatRestore ? `<button type=\"button\" class=\"restore-link\">Restore my chats</button>` : '';\n const footerInner = [brandingHtml, restoreBtn].filter(Boolean).join(' · ');\n const footerHtml = footerInner ? `<div class=\"footer\">${footerInner}</div>` : '';\n const chatHtml = `\n <div class=\"messages\"></div>\n <div class=\"reply-suggestions\"></div>\n <div class=\"interrupt hidden\"></div>\n <div class=\"composer-wrap\">\n <div class=\"composer\">\n <textarea rows=\"1\" placeholder=\"${escapeHtml(resolved.placeholder)}\"></textarea>\n <button class=\"send\" type=\"button\" aria-label=\"Send message\">${ICON.send}</button>\n </div>\n ${footerHtml}\n </div>`;\n\n const container = document.createElement('div');\n container.className = 'wrap';\n container.innerHTML = `\n ${fullpage ? '' : `<button class=\"launcher\" part=\"launcher\" aria-label=\"Open chat\">${ICON.spark}</button>`}\n <div class=\"panel${fullpage ? ' fullpage' : ' hidden'}\" part=\"panel\" role=\"${fullpage ? 'region' : 'dialog'}\" aria-label=\"${escapeHtml(resolved.agentName)} chat\">\n ${header}\n <div class=\"header-sep\"></div>\n ${gating ? prechatHtml : chatHtml}\n </div>\n `;\n\n // Tag the logo <svg> so styles can size it (the inlined SVG has its own id).\n const logoSvg = container.querySelector('.logo-wrap svg');\n if (logoSvg) logoSvg.setAttribute('class', 'logo');\n\n // A full DOM rebuild invalidates any cached streaming-bubble ref; cancel\n // the in-flight reveal loop so renderMessages can re-bind cleanly.\n this.resetReveal();\n this.root.replaceChildren(style, container);\n\n this.launcherEl = container.querySelector('.launcher');\n this.panelEl = container.querySelector('.panel');\n this.messagesEl = container.querySelector('.messages');\n this.statusEl = container.querySelector('.status-text');\n this.dotEl = container.querySelector('.dot');\n this.inputEl = container.querySelector('textarea');\n this.sendBtn = container.querySelector('.send');\n this.interruptEl = container.querySelector('.interrupt');\n this.suggestionsEl = container.querySelector('.reply-suggestions');\n\n this.launcherEl?.addEventListener('click', () => this.openChat());\n container.querySelector('.close')?.addEventListener('click', () => this.closeChat());\n this.sendBtn?.addEventListener('click', () => this.submit());\n this.inputEl?.addEventListener('input', () => this.autosize());\n this.inputEl?.addEventListener('keydown', (ev) => {\n if (ev.key === 'Enter' && !ev.shiftKey) {\n ev.preventDefault();\n this.submit();\n }\n });\n\n const pcForm = container.querySelector('.pc-form');\n pcForm?.addEventListener('submit', (ev) => {\n ev.preventDefault();\n this.handlePrechatSubmit(pcForm as HTMLFormElement);\n });\n\n // Live phone formatting + validity hint (libphonenumber-js, US default).\n // The implicit <label>, type=\"tel\", and autocomplete=\"tel\" from field()\n // are preserved — autofill keeps working — and we also reformat on\n // `change` so a browser-autofilled value gets formatted/validated too.\n this.wirePhoneField(pcForm as HTMLFormElement | null);\n\n // Cross-device \"Restore my chats\": open the panel + start the email entry.\n // AWAIT connect() before showing the email step so a `sessionId` exists by\n // the time the visitor submits — otherwise request-otp could go out with no\n // session and verify-otp would then hard-error \"No active session.\" The\n // request-otp/verify-otp paths in the controller also require a session, so\n // gating here keeps the affordance race-free.\n container.querySelector('.restore-link')?.addEventListener('click', () => {\n void (async () => {\n this.identityRestore = { phase: 'awaiting_email' };\n this.renderInterrupt();\n // Establish a live session before the email entry can fire request-otp.\n await this.controller?.connect().catch(() => {});\n })();\n });\n\n // Full-page mode sizes to the host's box; fall back to the viewport only\n // when the container gives the host no height.\n if (fullpage) this.syncViewportFallback();\n\n // Full-page mode connects eagerly (there's no launcher click to trigger it) —\n // but only once any identity gate is cleared.\n if (fullpage && !gating) void this.controller?.connect().catch(() => {});\n\n this.syncOpenState();\n if (!gating) this.renderMessages();\n this.renderStatus();\n this.renderComposerState();\n this.renderInterrupt();\n }\n\n /**\n * Render (or clear) the mid-turn interrupt overlay above the composer:\n * an OTP code prompt or a tool-write confirmation. Server-supplied text is\n * set via `textContent` (never innerHTML); only static icons use innerHTML.\n */\n private renderInterrupt(): void {\n const el = this.interruptEl;\n if (!el) return;\n el.replaceChildren();\n const it = this.interrupt;\n if (!it) {\n // No mid-turn interrupt — but the cross-device restore flow may be\n // active, which reuses this same overlay slot.\n if (this.identityRestore.phase !== 'idle') {\n el.classList.remove('hidden');\n el.appendChild(this.buildRestoreCard());\n return;\n }\n el.classList.add('hidden');\n return;\n }\n el.classList.remove('hidden');\n\n const card = document.createElement('div');\n card.className = 'int-card';\n\n const head = document.createElement('div');\n head.className = 'int-head';\n const ico = document.createElement('span');\n ico.className = 'int-ico';\n ico.innerHTML = it.kind === 'otp' ? ICON.lock : ICON.shield; // static, trusted\n const title = document.createElement('span');\n title.className = 'int-title';\n title.textContent = it.kind === 'otp' ? 'Verification required' : 'Confirm this action';\n head.append(ico, title);\n card.appendChild(head);\n\n if (it.actionDescription) {\n const desc = document.createElement('div');\n desc.className = 'int-desc';\n desc.textContent = it.actionDescription;\n card.appendChild(desc);\n }\n\n if (it.kind === 'otp') {\n if (it.sent?.maskedDestination) {\n const sent = document.createElement('div');\n sent.className = 'int-sent';\n sent.textContent = `Code sent to ${it.sent.maskedDestination}${it.sent.channel ? ` via ${it.sent.channel}` : ''}.`;\n card.appendChild(sent);\n }\n const row = document.createElement('div');\n row.className = 'int-row';\n const input = document.createElement('input');\n input.className = 'int-input';\n input.type = 'text';\n input.inputMode = 'numeric';\n input.autocomplete = 'one-time-code';\n input.placeholder = 'Enter code';\n const submit = () => {\n const code = input.value.trim();\n if (code) this.controller?.verifyOtp(code);\n };\n input.addEventListener('keydown', (ev) => {\n if (ev.key === 'Enter') {\n ev.preventDefault();\n submit();\n }\n });\n const verify = document.createElement('button');\n verify.className = 'int-btn primary';\n verify.type = 'button';\n verify.textContent = 'Verify';\n verify.addEventListener('click', submit);\n row.append(input, verify);\n card.appendChild(row);\n if (it.error) {\n const err = document.createElement('div');\n err.className = 'int-error';\n err.textContent = it.attemptsRemaining != null ? `${it.error} (${it.attemptsRemaining} left)` : it.error;\n card.appendChild(err);\n }\n queueMicrotask(() => input.focus());\n } else {\n const row = document.createElement('div');\n row.className = 'int-row';\n const decline = document.createElement('button');\n decline.className = 'int-btn';\n decline.type = 'button';\n decline.textContent = 'Decline';\n decline.addEventListener('click', () => this.controller?.confirmTool(false));\n const approve = document.createElement('button');\n approve.className = 'int-btn primary';\n approve.type = 'button';\n approve.textContent = 'Approve';\n approve.addEventListener('click', () => this.controller?.confirmTool(true));\n row.append(decline, approve);\n card.appendChild(row);\n }\n\n el.appendChild(card);\n }\n\n /**\n * Build the cross-device \"Restore my chats\" card (ADR-048 §c). Reuses the\n * same overlay slot + visual language as the OTP interrupt. All server-supplied\n * strings (masked destination, conversation previews) are set via `textContent`\n * — never innerHTML — so they can't inject markup; only the static lock icon\n * uses innerHTML.\n */\n private buildRestoreCard(): HTMLElement {\n const state = this.identityRestore;\n const card = document.createElement('div');\n card.className = 'int-card';\n\n const head = document.createElement('div');\n head.className = 'int-head';\n const ico = document.createElement('span');\n ico.className = 'int-ico';\n ico.innerHTML = ICON.lock; // static, trusted\n const title = document.createElement('span');\n title.className = 'int-title';\n title.textContent = 'Restore your chats';\n head.append(ico, title);\n card.appendChild(head);\n\n const close = document.createElement('button');\n close.className = 'int-close';\n close.type = 'button';\n close.setAttribute('aria-label', 'Cancel');\n close.textContent = '×';\n close.addEventListener('click', () => {\n this.controller?.cancelIdentityRestore();\n this.identityRestore = { phase: 'idle' };\n this.renderInterrupt();\n });\n card.appendChild(close);\n\n if (state.phase === 'awaiting_email') {\n const desc = document.createElement('div');\n desc.className = 'int-desc';\n desc.textContent = \"Enter your email and we'll send a code to find your previous chats.\";\n card.appendChild(desc);\n\n const row = document.createElement('div');\n row.className = 'int-row';\n const input = document.createElement('input');\n input.className = 'int-input';\n input.type = 'email';\n input.autocomplete = 'email';\n input.placeholder = 'you@example.com';\n const go = () => {\n const email = input.value.trim();\n if (email) void this.controller?.requestIdentityOtp(email, 'email');\n };\n input.addEventListener('keydown', (ev) => {\n if (ev.key === 'Enter') {\n ev.preventDefault();\n go();\n }\n });\n const send = document.createElement('button');\n send.className = 'int-btn primary';\n send.type = 'button';\n send.textContent = 'Send code';\n send.addEventListener('click', go);\n row.append(input, send);\n card.appendChild(row);\n if (state.error) {\n const err = document.createElement('div');\n err.className = 'int-error';\n err.textContent = state.error;\n card.appendChild(err);\n }\n queueMicrotask(() => input.focus());\n } else if (state.phase === 'requesting' || state.phase === 'verifying' || state.phase === 'resolving') {\n const msg = document.createElement('div');\n msg.className = 'int-sent';\n msg.textContent = state.phase === 'requesting' ? 'Sending a code…' : state.phase === 'verifying' ? 'Verifying…' : 'Finding your chats…';\n card.appendChild(msg);\n } else if (state.phase === 'awaiting_code') {\n if (state.maskedDestination) {\n const sent = document.createElement('div');\n sent.className = 'int-sent';\n sent.textContent = `Code sent to ${state.maskedDestination}.`;\n card.appendChild(sent);\n }\n const row = document.createElement('div');\n row.className = 'int-row';\n const input = document.createElement('input');\n input.className = 'int-input';\n input.type = 'text';\n input.inputMode = 'numeric';\n input.autocomplete = 'one-time-code';\n input.placeholder = 'Enter code';\n const submit = () => {\n const code = input.value.trim();\n if (code) void this.controller?.verifyIdentityOtp(code);\n };\n input.addEventListener('keydown', (ev) => {\n if (ev.key === 'Enter') {\n ev.preventDefault();\n submit();\n }\n });\n const verify = document.createElement('button');\n verify.className = 'int-btn primary';\n verify.type = 'button';\n verify.textContent = 'Verify';\n verify.addEventListener('click', submit);\n row.append(input, verify);\n card.appendChild(row);\n if (state.error) {\n const err = document.createElement('div');\n err.className = 'int-error';\n err.textContent = state.attemptsRemaining != null ? `${state.error} (${state.attemptsRemaining} left)` : state.error;\n card.appendChild(err);\n }\n queueMicrotask(() => input.focus());\n } else if (state.phase === 'resolved') {\n if (state.conversations.length === 0) {\n const none = document.createElement('div');\n none.className = 'int-desc';\n none.textContent = 'No previous chats found for that email.';\n card.appendChild(none);\n } else {\n const pick = document.createElement('div');\n pick.className = 'int-desc';\n pick.textContent = 'Pick a conversation to continue:';\n card.appendChild(pick);\n const list = document.createElement('div');\n list.className = 'restore-list';\n for (const conv of state.conversations) {\n const btn = document.createElement('button');\n btn.type = 'button';\n btn.className = 'restore-item';\n const preview = document.createElement('span');\n preview.className = 'restore-preview';\n preview.textContent = conv.preview || 'Conversation';\n btn.appendChild(preview);\n if (conv.lastActivityAt) {\n const when = document.createElement('span');\n when.className = 'restore-when';\n when.textContent = this.formatWhen(conv.lastActivityAt);\n btn.appendChild(when);\n }\n btn.addEventListener('click', () => {\n void this.controller?.restoreConversation(conv.sessionId);\n });\n list.appendChild(btn);\n }\n card.appendChild(list);\n }\n } else if (state.phase === 'error') {\n const err = document.createElement('div');\n err.className = 'int-error';\n err.textContent = state.message;\n card.appendChild(err);\n }\n\n return card;\n }\n\n /** Format an ISO timestamp as a short, locale-aware label (best-effort). */\n private formatWhen(iso: string): string {\n const d = new Date(iso);\n if (Number.isNaN(d.getTime())) return '';\n try {\n return d.toLocaleDateString(undefined, { month: 'short', day: 'numeric' });\n } catch {\n return '';\n }\n }\n\n /**\n * Wire as-you-type formatting + an inline validity hint onto the pre-chat\n * phone input (libphonenumber-js, US default region). Autofill is preserved:\n * the input keeps its `type=\"tel\"` + `autocomplete=\"tel\"` + implicit <label>,\n * and we also reformat on `change` so a browser-autofilled value gets\n * formatted/validated too.\n *\n * As-you-type caret note: `AsYouType` reformats the entire string, which\n * moves the caret to the end on a mid-string edit. To avoid fighting the\n * user, we only rewrite the value when the caret is at the end (the typical\n * append-a-digit case) and never on a deletion — so backspacing the\n * formatting characters works naturally.\n */\n private wirePhoneField(form: HTMLFormElement | null): void {\n const input = form?.querySelector('input[name=\"phone\"]') as HTMLInputElement | null;\n if (!input) return;\n const hint = input.parentElement?.querySelector('.pc-hint') as HTMLElement | null;\n\n const updateHint = () => {\n const v = input.value.trim();\n const field = input.closest('.pc-field');\n if (!v) {\n // Empty is neutral — the field is optional unless requirePhone.\n field?.classList.remove('valid', 'invalid');\n if (hint) hint.textContent = '';\n return;\n }\n const ok = isValidPhoneNumber(v, PHONE_DEFAULT_REGION);\n field?.classList.toggle('valid', ok);\n field?.classList.toggle('invalid', !ok);\n if (hint) hint.textContent = ok ? '' : 'Enter a valid phone number';\n };\n\n const reformat = () => {\n const atEnd = input.selectionStart === input.value.length && input.selectionEnd === input.value.length;\n // Only reformat when appending at the end; never fight a mid-string\n // edit or a deletion (see the caret note above).\n if (atEnd) {\n const formatted = new AsYouType(PHONE_DEFAULT_REGION).input(input.value);\n // Avoid clobbering when the user is deleting: only grow/normalize,\n // not when the formatter would re-add a character they just removed.\n if (formatted.length >= input.value.length) {\n input.value = formatted;\n }\n }\n updateHint();\n };\n\n input.addEventListener('input', (ev) => {\n const ie = ev as InputEvent;\n // Don't reformat while deleting — let the user clear characters freely.\n if (typeof ie.inputType === 'string' && ie.inputType.startsWith('delete')) {\n updateHint();\n return;\n }\n reformat();\n });\n // Browser autofill / paste-then-blur lands here; format + validate it too.\n input.addEventListener('change', reformat);\n }\n\n /** Collect identity + consent from the pre-chat form, then drop into the chat view. */\n private handlePrechatSubmit(form: HTMLFormElement): void {\n if (!form.reportValidity()) return;\n const data = new FormData(form);\n const val = (k: string) => ((data.get(k) as string | null)?.trim() || undefined);\n const checked = (k: string) => data.get(k) === 'on';\n\n // Phone: when required, block on an invalid number and surface the hint.\n // When optional, allow submit — the backend normalizes/nulls authoritatively.\n const rawPhone = val('phone');\n const phoneInput = form.querySelector('input[name=\"phone\"]') as HTMLInputElement | null;\n if (rawPhone && phoneInput && !isValidPhoneNumber(rawPhone, PHONE_DEFAULT_REGION)) {\n const required = phoneInput.hasAttribute('required');\n const field = phoneInput.closest('.pc-field');\n field?.classList.add('invalid');\n const hint = field?.querySelector('.pc-hint');\n if (hint) hint.textContent = 'Enter a valid phone number';\n if (required) {\n phoneInput.focus();\n return;\n }\n }\n // Prefer canonical E.164 when it parses; fall back to the raw value\n // otherwise (the backend re-parses + normalizes either way).\n const phone = rawPhone ? (phoneToE164(rawPhone) ?? rawPhone) : undefined;\n\n this.controller?.setUserInfo({\n name: val('name'),\n email: val('email'),\n phone,\n consent: { emailOptIn: checked('emailOptIn'), smsOptIn: checked('smsOptIn') },\n });\n this.userInfoSatisfied = true;\n this.render();\n void this.controller?.connect().catch(() => {});\n }\n\n /** Send a starter prompt (from a chip click). */\n private submitPrompt(text: string): void {\n if (!this.inputEl) return;\n this.inputEl.value = text;\n this.submit();\n }\n\n private syncOpenState(): void {\n // In full-page mode the panel always fills the host; nothing to toggle.\n if (this.panelEl?.classList.contains('fullpage')) {\n this.inputEl?.focus();\n return;\n }\n this.panelEl?.classList.toggle('hidden', !this.open);\n this.launcherEl?.classList.toggle('hidden', this.open);\n if (this.open) this.inputEl?.focus();\n }\n\n /** Grow the textarea with its content, up to the CSS max-height. */\n private autosize(): void {\n const ta = this.inputEl;\n if (!ta) return;\n ta.style.height = 'auto';\n ta.style.height = `${ta.scrollHeight}px`;\n }\n\n /**\n * Receive a new message snapshot from the controller and update the view.\n *\n * `onMessages` fires on *every* `stream_token` delta. Rebuilding the whole\n * list each frame is wasteful and fights the smooth reveal, so we take the\n * cheap path when the only change is the trailing streaming assistant message\n * growing: just bump the reveal *target* (the rAF loop drains it). Any\n * structural change (new message, finalize, citations) triggers a full\n * rebuild via {@link renderMessages}.\n */\n private handleMessages(messages: ChatMessage[], greeting: string): void {\n this.greeting = greeting;\n const prev = this.messages;\n const last = messages[messages.length - 1];\n const prevLast = prev[prev.length - 1];\n\n const structural =\n messages.length !== prev.length ||\n !last ||\n !prevLast ||\n last.id !== prevLast.id ||\n last.role !== prevLast.role ||\n // finalize transition (streaming → done) needs the markdown render + sources\n last.streaming !== prevLast.streaming ||\n // first token after the typing indicator needs the bubble swapped in\n (!!last.streaming && !prevLast.text && !!last.text);\n\n this.messages = messages;\n\n if (!structural && last && last.streaming && last.id === this.streamMsgId) {\n // Fast path: the streaming tail just grew. Bump the reveal target and\n // let the rAF loop catch up — no DOM rebuild, no per-token reflow.\n this.streamTarget = last.text;\n this.ensureRevealLoop();\n return;\n }\n\n this.renderMessages();\n }\n\n private renderMessages(): void {\n if (!this.messagesEl) return;\n this.resetReveal();\n this.messagesEl.replaceChildren();\n\n const greeting = this.greeting;\n if (this.messages.length === 0 && greeting) {\n this.messagesEl.appendChild(this.buildRow('assistant', this.greetingBubble(greeting)));\n }\n\n // Starter-prompt chips: shown until the visitor sends their first message.\n if (!this.hasSent && this.messages.length === 0 && this.examplePrompts.length > 0) {\n const chips = document.createElement('div');\n chips.className = 'prompts';\n for (const prompt of this.examplePrompts) {\n const chip = document.createElement('button');\n chip.type = 'button';\n chip.className = 'chip';\n chip.textContent = prompt;\n chip.addEventListener('click', () => this.submitPrompt(prompt));\n chips.appendChild(chip);\n }\n this.messagesEl.appendChild(chips);\n }\n\n for (const msg of this.messages) {\n const bubble = document.createElement('div');\n bubble.className = `bubble ${msg.role}`;\n if (msg.role === 'assistant' && msg.streaming && !msg.text) {\n // No text yet → animated typing indicator.\n bubble.classList.add('typing');\n bubble.append(this.typingDot(), this.typingDot(), this.typingDot());\n } else if (msg.streaming) {\n // Mid-stream: partial/unclosed markdown renders ugly (half-open\n // `**`, dangling `[`), so keep plain text + the blinking cursor.\n // The text is revealed gradually by the rAF typewriter; seed the\n // bubble with whatever is already displayed and bind the reveal.\n bubble.classList.add('cursor');\n this.bindReveal(msg, bubble);\n } else if (msg.role === 'assistant') {\n // Final assistant turn → render the sanitized markdown subset.\n // `renderMarkdown` escapes all text, drops images, gates links to\n // http(s), and only emits an allowlisted set of tags, so this\n // `innerHTML` cannot inject markup (see markdown.ts).\n bubble.classList.add('md');\n bubble.innerHTML = renderMarkdown(msg.text);\n } else {\n // User bubbles stay plain text.\n bubble.textContent = msg.text;\n }\n this.messagesEl.appendChild(this.buildRow(msg.role, bubble));\n\n // Render a \"Sources (N)\" section under any assistant message whose\n // terminal eventual_response carried citations.\n if (msg.role === 'assistant' && !msg.streaming && msg.citations && msg.citations.length > 0) {\n this.messagesEl.appendChild(this.renderSources(msg.citations));\n }\n }\n this.scrollToBottom(true);\n this.renderSuggestions();\n }\n\n /**\n * Render (or clear) the mid-conversation suggested-reply chips under the\n * composer. Shown ONLY when: the feature is enabled, no interrupt / restore\n * overlay is active (those reuse the slot above the composer), and the LATEST\n * message is a finalized assistant turn that carried suggestions. A new turn\n * (agent or the visitor typing) appends messages, so the latest is no longer\n * that assistant message and the chips clear on the next render. Chips reuse\n * the empty-state `.prompts`/`.chip` styling and send via the same path.\n */\n private renderSuggestions(): void {\n const el = this.suggestionsEl;\n if (!el) return;\n el.replaceChildren();\n if (!this.showSuggestedReplies) return;\n // Hidden while an OTP / tool-confirmation / restore overlay is active.\n if (this.interrupt || this.identityRestore.phase !== 'idle') return;\n const last = this.messages[this.messages.length - 1];\n if (!last || last.role !== 'assistant' || last.streaming || !last.suggestions || last.suggestions.length === 0) return;\n\n const chips = document.createElement('div');\n chips.className = 'prompts';\n for (const suggestion of last.suggestions) {\n const chip = document.createElement('button');\n chip.type = 'button';\n chip.className = 'chip';\n chip.textContent = suggestion;\n chip.addEventListener('click', () => this.submitPrompt(suggestion));\n chips.appendChild(chip);\n }\n el.appendChild(chips);\n }\n\n // ─────────────────────── Smooth streaming reveal ───────────────────────────\n\n /** True when the host/user prefers reduced motion (snap, no typewriter). */\n private prefersReducedMotion(): boolean {\n return typeof matchMedia === 'function' && matchMedia('(prefers-reduced-motion: reduce)').matches;\n }\n\n /**\n * Bind the rAF typewriter to a freshly built streaming bubble. Preserves the\n * already-revealed prefix across rebuilds (so a structural rebuild mid-stream\n * doesn't restart the reveal from zero), then resumes the loop.\n */\n private bindReveal(msg: ChatMessage, bubble: HTMLElement): void {\n const carryOver = msg.id === this.streamMsgId ? Math.min(this.displayedLength, msg.text.length) : 0;\n this.streamBubbleEl = bubble;\n this.streamMsgId = msg.id;\n this.streamTarget = msg.text;\n this.displayedLength = carryOver;\n\n if (this.prefersReducedMotion()) {\n // No animation: show everything immediately.\n this.displayedLength = msg.text.length;\n bubble.textContent = msg.text;\n return;\n }\n bubble.textContent = msg.text.slice(0, this.displayedLength);\n this.ensureRevealLoop();\n }\n\n /** Start the rAF loop if it isn't already running. */\n private ensureRevealLoop(): void {\n if (this.prefersReducedMotion() || typeof requestAnimationFrame !== 'function') {\n // No animation (reduced-motion or no rAF): snap to the full buffer.\n this.snapReveal();\n return;\n }\n if (this.rafId) return; // already running\n this.rafId = requestAnimationFrame(() => this.tickReveal());\n }\n\n /**\n * One animation frame of the reveal. Advances `displayedLength` toward the\n * buffered target at an ADAPTIVE rate — the deeper the backlog, the more\n * chars per frame — so the reveal stays smooth yet never falls behind the\n * network. Updates ONLY the bound bubble's textContent (no list rebuild).\n */\n private tickReveal(): void {\n this.rafId = 0;\n const bubble = this.streamBubbleEl;\n if (!bubble) return;\n\n const target = this.streamTarget;\n const remaining = target.length - this.displayedLength;\n\n if (remaining <= 0) {\n // Caught up to everything buffered so far → idle. A later token bump\n // (handleMessages → ensureRevealLoop) restarts the loop; the finalize\n // structural rebuild snaps to the full markdown render.\n return;\n }\n\n // Adaptive speed: ~1/8 of the backlog per frame (≈ catch up over a few\n // frames), clamped to a readable floor so short bursts still animate and\n // an aggressive ceiling so a deep buffer drains fast. At ~60fps this\n // comfortably outruns the wire — the reveal is steady, never bursty.\n const step = Math.max(2, Math.min(remaining, Math.ceil(remaining / 8)));\n this.displayedLength = Math.min(target.length, this.displayedLength + step);\n bubble.textContent = target.slice(0, this.displayedLength);\n this.scrollToBottom(false);\n\n this.rafId = requestAnimationFrame(() => this.tickReveal());\n }\n\n /** Snap the bound bubble to the full buffered text immediately (reduced-motion / no-rAF). */\n private snapReveal(): void {\n if (this.streamBubbleEl) {\n this.displayedLength = this.streamTarget.length;\n this.streamBubbleEl.textContent = this.streamTarget;\n }\n }\n\n /**\n * Full-page sizing probe: decide whether the host's container gives it a\n * real box. With the `.wrap` flex chain hidden, `height: 100%` of a SIZED\n * container still resolves (clientHeight > 0), while an auto-height parent\n * (e.g. mounted straight into `<body>`) collapses to ~0. Only the latter\n * gets `data-viewport-fallback`, whose CSS applies `min-height: 100dvh` —\n * so an embed inside a fixed-height box never overflows it (the composer\n * stays visible), and a bare full-page route still fills the viewport.\n */\n private syncViewportFallback(): void {\n const wrap = this.shadowRoot?.querySelector<HTMLElement>('.wrap');\n if (!wrap) return;\n const prev = wrap.style.display;\n wrap.style.display = 'none';\n const heightless = this.clientHeight < 8;\n wrap.style.display = prev;\n this.toggleAttribute('data-viewport-fallback', heightless);\n }\n\n /** Cancel any in-flight reveal loop and clear its state (called on full rebuild). */\n private resetReveal(): void {\n if (this.rafId && typeof cancelAnimationFrame === 'function') cancelAnimationFrame(this.rafId);\n this.rafId = 0;\n this.streamBubbleEl = null;\n // streamMsgId/displayedLength are intentionally kept so bindReveal can\n // carry the revealed prefix across a structural rebuild of the same msg;\n // they're reset when a different message binds.\n }\n\n /**\n * Auto-scroll the message list to the bottom — but don't fight a visitor who\n * has scrolled up to read history. When `force` (a structural rebuild) we\n * always pin to bottom; during the streaming reveal we only follow if the\n * viewport is already near the bottom.\n */\n private scrollToBottom(force: boolean): void {\n const el = this.messagesEl;\n if (!el) return;\n if (force) {\n el.scrollTop = el.scrollHeight;\n return;\n }\n const nearBottom = el.scrollHeight - el.scrollTop - el.clientHeight < 80;\n if (nearBottom) el.scrollTop = el.scrollHeight;\n }\n\n /** Wrap a bubble in a `.row`, prefixing assistant rows with a mini avatar. */\n private buildRow(role: 'user' | 'assistant', bubble: HTMLElement): HTMLElement {\n const row = document.createElement('div');\n row.className = `row ${role}`;\n if (role === 'assistant') {\n const mini = document.createElement('div');\n mini.className = 'mini';\n mini.innerHTML = ICON.bot; // static, trusted\n row.appendChild(mini);\n }\n row.appendChild(bubble);\n return row;\n }\n\n private greetingBubble(greeting: string): HTMLElement {\n const b = document.createElement('div');\n b.className = 'bubble assistant greeting';\n b.textContent = greeting;\n return b;\n }\n\n private typingDot(): HTMLElement {\n return document.createElement('i');\n }\n\n /**\n * Build the collapsible \"Sources (N)\" block for an assistant message's\n * citations. Title/snippet are set via `textContent` (never innerHTML) so\n * citation text can't inject markup; only the static chevron + numeric count\n * use innerHTML.\n */\n private renderSources(citations: Citation[]): HTMLElement {\n const wrap = document.createElement('div');\n wrap.className = 'sources';\n wrap.setAttribute('part', 'sources');\n\n const details = document.createElement('details');\n details.open = true;\n\n const summary = document.createElement('summary');\n const chev = document.createElement('span');\n chev.className = 'chev';\n chev.innerHTML = ICON.chev; // static, trusted\n const label = document.createElement('span');\n label.textContent = 'Sources';\n const count = document.createElement('span');\n count.className = 'count';\n count.textContent = String(citations.length);\n summary.append(chev, label, count);\n details.appendChild(summary);\n\n const list = document.createElement('ol');\n for (const c of citations) {\n const li = document.createElement('li');\n\n let titleEl: HTMLElement;\n // SECURITY: only absolute http(s) URLs may become a link href. A\n // citation URL comes from indexed content (web/GitHub connectors), so\n // an attacker-influenceable doc could carry `javascript:`/`data:`/\n // `vbscript:` — assigning those to `a.href` is a one-click XSS. Anything\n // that isn't a valid absolute http(s) URL renders as plain text.\n const safeUrl = safeHttpUrl(c.url);\n if (safeUrl) {\n const a = document.createElement('a');\n a.className = 'src-title';\n a.href = safeUrl;\n a.target = '_blank';\n a.rel = 'noopener noreferrer nofollow';\n titleEl = a;\n } else {\n titleEl = document.createElement('span');\n titleEl.className = 'src-title';\n }\n titleEl.textContent = c.title || c.id || 'Source';\n li.appendChild(titleEl);\n\n if (c.snippet) {\n // The snippet is the raw scraped chunk — often led by page\n // boilerplate (logo link, nav, whitespace). Trim it to a clean\n // excerpt, then render the sanitized markdown subset. Both steps\n // escape text + drop images/unsafe links (see markdown.ts), so\n // this `innerHTML` is safe.\n const cleaned = cleanCitationSnippet(c.snippet);\n if (cleaned) {\n const snip = document.createElement('span');\n snip.className = 'src-snippet md';\n snip.innerHTML = renderMarkdown(cleaned);\n li.appendChild(snip);\n }\n }\n list.appendChild(li);\n }\n details.appendChild(list);\n wrap.appendChild(details);\n return wrap;\n }\n\n private renderStatus(): void {\n const label: Record<ConnectionStatus, string> = {\n idle: '',\n connecting: 'Connecting…',\n ready: 'Online',\n error: 'Connection issue',\n closed: 'Disconnected',\n };\n if (this.statusEl) this.statusEl.textContent = label[this.status];\n if (this.dotEl) {\n // ready → green (no modifier); connecting → amber; error → red; else grey.\n const mod = this.status === 'ready' ? '' : this.status === 'connecting' ? ' connecting' : this.status === 'error' ? ' error' : ' off';\n this.dotEl.className = `dot${mod}`;\n }\n }\n\n private renderComposerState(): void {\n const busy = this.status === 'connecting';\n if (this.sendBtn) this.sendBtn.disabled = busy;\n if (this.inputEl) this.inputEl.disabled = busy;\n }\n\n private submit(): void {\n if (!this.inputEl || !this.controller) return;\n const text = this.inputEl.value;\n if (!text.trim()) return;\n this.inputEl.value = '';\n this.hasSent = true;\n this.autosize();\n void this.controller.send(text);\n }\n}\n\n/** Register the custom element once. Safe to call multiple times. */\nexport function defineChatWidget(): void {\n if (typeof customElements !== 'undefined' && !customElements.get(ELEMENT_TAG)) {\n customElements.define(ELEMENT_TAG, SmoothAgentChatElement);\n }\n}\n\n/**\n * Programmatically create, configure, and append a widget to the page.\n * Returns the element so the host can drive `openChat()` / `closeChat()`.\n */\nexport function mountChatWidget(config: ChatWidgetConfig, target: HTMLElement = document.body): SmoothAgentChatElement {\n defineChatWidget();\n const el = document.createElement(ELEMENT_TAG) as SmoothAgentChatElement;\n el.configure(config);\n target.appendChild(el);\n return el;\n}\n\n/**\n * Ergonomic helper for the full-page layout: mounts a `<smooth-agent-chat>` in\n * `mode: \"fullpage\"` (no launcher — the chat fills its container/viewport with a\n * Smooth-branded header, a scrollable message list, and an input bar) and\n * returns the element.\n *\n * `target` defaults to `document.body`; pass a sized container to embed the\n * full-page chat inside a layout region (e.g. a `/chat` route shell or an\n * iframe). The `mode` is forced to `\"fullpage\"` regardless of the passed config.\n *\n * ```ts\n * mountFullPageChat({ endpoint: 'wss://…/ws', agentId: '…', agentName: 'Support' });\n * ```\n */\nexport function mountFullPageChat(config: Omit<ChatWidgetConfig, 'mode'>, target: HTMLElement = document.body): SmoothAgentChatElement {\n return mountChatWidget({ ...config, mode: 'fullpage' }, target);\n}\n","/**\n * Standalone IIFE entry. Bundled (with the protocol client inlined) into\n * `dist/chat-widget.global.js` for a plain `<script src=\"…\">` embed.\n *\n * On load it:\n * - registers the `<smooth-agent-chat>` custom element, and\n * - exposes the programmatic API on the IIFE global `SmoothAgentChat`\n * (`window.SmoothAgentChat.mount({ endpoint, agentId })`).\n *\n * A host page can then either drop the element in markup:\n * <smooth-agent-chat endpoint=\"wss://…/ws\" agent-id=\"…\"></smooth-agent-chat>\n * or mount it programmatically:\n * SmoothAgentChat.mount({ endpoint: 'wss://…/ws', agentId: '…' });\n */\nimport type { ChatWidgetConfig } from './config.js';\nimport { defineChatWidget, mountChatWidget, mountFullPageChat, SmoothAgentChatElement } from './element.js';\n\ndefineChatWidget();\n\nexport { defineChatWidget, mountChatWidget, mountFullPageChat, SmoothAgentChatElement };\n\n/** Convenience alias matching the global API surface (`SmoothAgentChat.mount`). */\nexport function mount(config: ChatWidgetConfig, target?: HTMLElement): SmoothAgentChatElement {\n return mountChatWidget(config, target);\n}\n\n/**\n * Full-page convenience alias (`SmoothAgentChat.mountFullPage`): mounts the chat\n * in `mode: \"fullpage\"` so it fills its container/viewport with no launcher.\n */\nexport function mountFullPage(config: Omit<ChatWidgetConfig, 'mode'>, target?: HTMLElement): SmoothAgentChatElement {\n return mountFullPageChat(config, target);\n}\n"],"x_google_ignoreList":[0,1,2,3,4,5,6,7,8,9,10,11,12,13,14,15,16,17,18,19,20,21,22,23,24,25,26,27,28,29,30,31,32,33,34,35,36,37,38,39,40,41,42,43,44,45,46,47,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AK,SAAS,KAAK,QAAQ,WAAW;EAC9C;EAEA,SAAuB;GACnB,IAAI,CAAC,KAAK,WAAW,CAAC,KAAK,YAAY;GACvC,MAAM,OAAO,KAAK,QAAQ;GAC1B,IAAI,CAAC,KAAK,KAAK,GAAG;GAClB,KAAK,QAAQ,QAAQ;GACrB,KAAK,UAAU;GACf,KAAK,SAAS;GACd,KAAU,WAAW,KAAK,IAAI;EAClC;CACJ;;CAGA,SAAgB,mBAAyB;EACrC,IAAI,OAAO,mBAAmB,eAAe,CAAC,eAAe,IAAA,mBAAe,GACxE,eAAe,OAAO,aAAa,sBAAsB;CAEjE;;;;;CAMA,SAAgB,gBAAgB,QAA0B,SAAsB,SAAS,MAA8B;EACnH,iBAAiB;EACjB,MAAM,KAAK,SAAS,cAAc,WAAW;EAC7C,GAAG,UAAU,MAAM;EACnB,OAAO,YAAY,EAAE;EACrB,OAAO;CACX;;;;;;;;;;;;;;;CAgBA,SAAgB,kBAAkB,QAAwC,SAAsB,SAAS,MAA8B;EACnI,OAAO,gBAAgB;GAAE,GAAG;GAAQ,MAAM;EAAW,GAAG,MAAM;CAClE;;;CC3uCA,iBAAiB;;CAKjB,SAAgB,MAAM,QAA0B,QAA8C;EAC1F,OAAO,gBAAgB,QAAQ,MAAM;CACzC;;;;;CAMA,SAAgB,cAAc,QAAwC,QAA8C;EAChH,OAAO,kBAAkB,QAAQ,MAAM;CAC3C"}
|
|
1
|
+
{"version":3,"file":"chat-widget.global.js","names":["metadata","_typeof","_defineProperties","_toPropertyKey","_createClass","_toPrimitive","_classCallCheck","_typeof","_classCallCheck","_defineProperties","_toPropertyKey","_createClass","_toPrimitive","compare","_createForOfIteratorHelperLoose","_unsupportedIterableToArray","_arrayLikeToArray","_createForOfIteratorHelperLoose","_unsupportedIterableToArray","_arrayLikeToArray","_createForOfIteratorHelperLoose","_unsupportedIterableToArray","_arrayLikeToArray","_createForOfIteratorHelperLoose","_unsupportedIterableToArray","_arrayLikeToArray","USE_NON_GEOGRAPHIC_COUNTRY_CODE","_createForOfIteratorHelperLoose","_unsupportedIterableToArray","_arrayLikeToArray","USE_NON_GEOGRAPHIC_COUNTRY_CODE","formatNationalNumber","_typeof","ownKeys","_objectSpread","_defineProperty","_toPropertyKey","_classCallCheck","_defineProperties","_createClass","_toPrimitive","isPossibleNumber","USE_NON_GEOGRAPHIC_COUNTRY_CODE","parsePhoneNumber","_typeof","ownKeys","_objectSpread","_defineProperty","_toPropertyKey","_toPrimitive","parsePhoneNumberWithError","_typeof","ownKeys","_objectSpread","_defineProperty","_toPropertyKey","_toPrimitive","_slicedToArray","_arrayWithHoles","_iterableToArrayLimit","_unsupportedIterableToArray","_nonIterableRest","_arrayLikeToArray","parsePhoneNumberWithError","parsePhoneNumberWithError_","_typeof","ownKeys","_objectSpread","_defineProperty","_toPropertyKey","_toPrimitive","parsePhoneNumberWithError","_typeof","_defineProperty","_toPropertyKey","_toPrimitive","isValidPhoneNumber","_typeof","_classCallCheck","_defineProperties","_toPropertyKey","_createClass","_toPrimitive","_createForOfIteratorHelperLoose","_unsupportedIterableToArray","_arrayLikeToArray","_typeof","_classCallCheck","_defineProperties","_toPropertyKey","_createClass","_toPrimitive","_createForOfIteratorHelperLoose","_unsupportedIterableToArray","_arrayLikeToArray","_typeof","_classCallCheck","_defineProperties","_toPropertyKey","_createClass","_toPrimitive","_typeof","_unsupportedIterableToArray","_arrayLikeToArray","_classCallCheck","_defineProperties","_toPropertyKey","_createClass","_toPrimitive","_typeof","_slicedToArray","_arrayWithHoles","_iterableToArrayLimit","_unsupportedIterableToArray","_nonIterableRest","_arrayLikeToArray","_classCallCheck","_defineProperties","_toPropertyKey","_createClass","_toPrimitive","extractCountryCallingCode","_extractCountryCallingCode","_typeof","AsYouType","_parsePhoneNumberWithError","_isValidPhoneNumber","_AsYouType","metadata","parsePhoneNumber"],"sources":["../node_modules/.pnpm/libphonenumber-js@1.13.7/node_modules/libphonenumber-js/metadata.min.json.js","../node_modules/.pnpm/libphonenumber-js@1.13.7/node_modules/libphonenumber-js/min/exports/withMetadataArgument.js","../node_modules/.pnpm/libphonenumber-js@1.13.7/node_modules/libphonenumber-js/es6/constants.js","../node_modules/.pnpm/libphonenumber-js@1.13.7/node_modules/libphonenumber-js/es6/ParseError.js","../node_modules/.pnpm/libphonenumber-js@1.13.7/node_modules/libphonenumber-js/es6/tools/semver-compare.js","../node_modules/.pnpm/libphonenumber-js@1.13.7/node_modules/libphonenumber-js/es6/helpers/isObject.js","../node_modules/.pnpm/libphonenumber-js@1.13.7/node_modules/libphonenumber-js/es6/helpers/isCallingCode.js","../node_modules/.pnpm/libphonenumber-js@1.13.7/node_modules/libphonenumber-js/es6/metadata.js","../node_modules/.pnpm/libphonenumber-js@1.13.7/node_modules/libphonenumber-js/es6/helpers/extension/createExtensionPattern.js","../node_modules/.pnpm/libphonenumber-js@1.13.7/node_modules/libphonenumber-js/es6/helpers/isViablePhoneNumber.js","../node_modules/.pnpm/libphonenumber-js@1.13.7/node_modules/libphonenumber-js/es6/helpers/extension/extractExtension.js","../node_modules/.pnpm/libphonenumber-js@1.13.7/node_modules/libphonenumber-js/es6/helpers/parseDigits.js","../node_modules/.pnpm/libphonenumber-js@1.13.7/node_modules/libphonenumber-js/es6/parseIncompletePhoneNumber.js","../node_modules/.pnpm/libphonenumber-js@1.13.7/node_modules/libphonenumber-js/es6/helpers/mergeArrays.js","../node_modules/.pnpm/libphonenumber-js@1.13.7/node_modules/libphonenumber-js/es6/helpers/checkNumberLength.js","../node_modules/.pnpm/libphonenumber-js@1.13.7/node_modules/libphonenumber-js/es6/isPossible.js","../node_modules/.pnpm/libphonenumber-js@1.13.7/node_modules/libphonenumber-js/es6/helpers/matchesEntirely.js","../node_modules/.pnpm/libphonenumber-js@1.13.7/node_modules/libphonenumber-js/es6/helpers/getNumberType.js","../node_modules/.pnpm/libphonenumber-js@1.13.7/node_modules/libphonenumber-js/es6/isValid.js","../node_modules/.pnpm/libphonenumber-js@1.13.7/node_modules/libphonenumber-js/es6/helpers/isCountryCode.js","../node_modules/.pnpm/libphonenumber-js@1.13.7/node_modules/libphonenumber-js/es6/helpers/getCountryAndCallingCodeFromOneOfThem.js","../node_modules/.pnpm/libphonenumber-js@1.13.7/node_modules/libphonenumber-js/es6/helpers/getPossibleCountriesForNumber.js","../node_modules/.pnpm/libphonenumber-js@1.13.7/node_modules/libphonenumber-js/es6/helpers/stripIddPrefix.js","../node_modules/.pnpm/libphonenumber-js@1.13.7/node_modules/libphonenumber-js/es6/helpers/extractNationalNumberFromPossiblyIncompleteNumber.js","../node_modules/.pnpm/libphonenumber-js@1.13.7/node_modules/libphonenumber-js/es6/helpers/getCountryByNationalNumber.js","../node_modules/.pnpm/libphonenumber-js@1.13.7/node_modules/libphonenumber-js/es6/helpers/getCountryByCallingCode.js","../node_modules/.pnpm/libphonenumber-js@1.13.7/node_modules/libphonenumber-js/es6/helpers/extractNationalNumber.js","../node_modules/.pnpm/libphonenumber-js@1.13.7/node_modules/libphonenumber-js/es6/helpers/extractCountryCallingCodeFromInternationalNumberWithoutPlusSign.js","../node_modules/.pnpm/libphonenumber-js@1.13.7/node_modules/libphonenumber-js/es6/helpers/extractCountryCallingCode.js","../node_modules/.pnpm/libphonenumber-js@1.13.7/node_modules/libphonenumber-js/es6/helpers/applyInternationalSeparatorStyle.js","../node_modules/.pnpm/libphonenumber-js@1.13.7/node_modules/libphonenumber-js/es6/helpers/formatNationalNumberUsingFormat.js","../node_modules/.pnpm/libphonenumber-js@1.13.7/node_modules/libphonenumber-js/es6/helpers/getIddPrefix.js","../node_modules/.pnpm/libphonenumber-js@1.13.7/node_modules/libphonenumber-js/es6/helpers/RFC3966.js","../node_modules/.pnpm/libphonenumber-js@1.13.7/node_modules/libphonenumber-js/es6/format.js","../node_modules/.pnpm/libphonenumber-js@1.13.7/node_modules/libphonenumber-js/es6/PhoneNumber.js","../node_modules/.pnpm/libphonenumber-js@1.13.7/node_modules/libphonenumber-js/es6/helpers/extractPhoneContext.js","../node_modules/.pnpm/libphonenumber-js@1.13.7/node_modules/libphonenumber-js/es6/helpers/extractFormattedPhoneNumberFromPossibleRfc3966NumberUri.js","../node_modules/.pnpm/libphonenumber-js@1.13.7/node_modules/libphonenumber-js/es6/parse.js","../node_modules/.pnpm/libphonenumber-js@1.13.7/node_modules/libphonenumber-js/es6/parsePhoneNumberWithError_.js","../node_modules/.pnpm/libphonenumber-js@1.13.7/node_modules/libphonenumber-js/es6/normalizeArguments.js","../node_modules/.pnpm/libphonenumber-js@1.13.7/node_modules/libphonenumber-js/es6/parsePhoneNumberWithError.js","../node_modules/.pnpm/libphonenumber-js@1.13.7/node_modules/libphonenumber-js/es6/parsePhoneNumber_.js","../node_modules/.pnpm/libphonenumber-js@1.13.7/node_modules/libphonenumber-js/es6/isValidPhoneNumber.js","../node_modules/.pnpm/libphonenumber-js@1.13.7/node_modules/libphonenumber-js/es6/AsYouTypeState.js","../node_modules/.pnpm/libphonenumber-js@1.13.7/node_modules/libphonenumber-js/es6/AsYouTypeFormatter.util.js","../node_modules/.pnpm/libphonenumber-js@1.13.7/node_modules/libphonenumber-js/es6/AsYouTypeFormatter.complete.js","../node_modules/.pnpm/libphonenumber-js@1.13.7/node_modules/libphonenumber-js/es6/AsYouTypeFormatter.PatternParser.js","../node_modules/.pnpm/libphonenumber-js@1.13.7/node_modules/libphonenumber-js/es6/AsYouTypeFormatter.PatternMatcher.js","../node_modules/.pnpm/libphonenumber-js@1.13.7/node_modules/libphonenumber-js/es6/AsYouTypeFormatter.js","../node_modules/.pnpm/libphonenumber-js@1.13.7/node_modules/libphonenumber-js/es6/AsYouTypeParser.js","../node_modules/.pnpm/libphonenumber-js@1.13.7/node_modules/libphonenumber-js/es6/AsYouType.js","../node_modules/.pnpm/libphonenumber-js@1.13.7/node_modules/libphonenumber-js/min/exports/parsePhoneNumberWithError.js","../node_modules/.pnpm/libphonenumber-js@1.13.7/node_modules/libphonenumber-js/min/exports/isValidPhoneNumber.js","../node_modules/.pnpm/libphonenumber-js@1.13.7/node_modules/libphonenumber-js/min/exports/AsYouType.js","../src/markdown.ts","../src/config.ts","../node_modules/.pnpm/@smooai+smooth-operator@1.21.1/node_modules/@smooai/smooth-operator/dist/transport.js","../node_modules/.pnpm/@smooai+smooth-operator@1.21.1/node_modules/@smooai/smooth-operator/dist/types.js","../node_modules/.pnpm/@smooai+smooth-operator@1.21.1/node_modules/@smooai/smooth-operator/dist/client.js","../src/fingerprint.ts","../node_modules/.pnpm/zustand@5.0.14/node_modules/zustand/esm/vanilla.mjs","../node_modules/.pnpm/zustand@5.0.14/node_modules/zustand/esm/middleware.mjs","../src/persistence.ts","../src/conversation.ts","../src/logo.ts","../src/styles.ts","../src/element.ts","../src/standalone.ts"],"sourcesContent":["// This file is a workaround for a bug in web browsers' \"native\"\n// ES6 importing system which is uncapable of importing \"*.json\" files.\n// https://github.com/catamphetamine/libphonenumber-js/issues/239\nexport default {\"version\":4,\"country_calling_codes\":{\"1\":[\"US\",\"AG\",\"AI\",\"AS\",\"BB\",\"BM\",\"BS\",\"CA\",\"DM\",\"DO\",\"GD\",\"GU\",\"JM\",\"KN\",\"KY\",\"LC\",\"MP\",\"MS\",\"PR\",\"SX\",\"TC\",\"TT\",\"VC\",\"VG\",\"VI\"],\"7\":[\"RU\",\"KZ\"],\"20\":[\"EG\"],\"27\":[\"ZA\"],\"30\":[\"GR\"],\"31\":[\"NL\"],\"32\":[\"BE\"],\"33\":[\"FR\"],\"34\":[\"ES\"],\"36\":[\"HU\"],\"39\":[\"IT\",\"VA\"],\"40\":[\"RO\"],\"41\":[\"CH\"],\"43\":[\"AT\"],\"44\":[\"GB\",\"GG\",\"IM\",\"JE\"],\"45\":[\"DK\"],\"46\":[\"SE\"],\"47\":[\"NO\",\"SJ\"],\"48\":[\"PL\"],\"49\":[\"DE\"],\"51\":[\"PE\"],\"52\":[\"MX\"],\"53\":[\"CU\"],\"54\":[\"AR\"],\"55\":[\"BR\"],\"56\":[\"CL\"],\"57\":[\"CO\"],\"58\":[\"VE\"],\"60\":[\"MY\"],\"61\":[\"AU\",\"CC\",\"CX\"],\"62\":[\"ID\"],\"63\":[\"PH\"],\"64\":[\"NZ\"],\"65\":[\"SG\"],\"66\":[\"TH\"],\"81\":[\"JP\"],\"82\":[\"KR\"],\"84\":[\"VN\"],\"86\":[\"CN\"],\"90\":[\"TR\"],\"91\":[\"IN\"],\"92\":[\"PK\"],\"93\":[\"AF\"],\"94\":[\"LK\"],\"95\":[\"MM\"],\"98\":[\"IR\"],\"211\":[\"SS\"],\"212\":[\"MA\",\"EH\"],\"213\":[\"DZ\"],\"216\":[\"TN\"],\"218\":[\"LY\"],\"220\":[\"GM\"],\"221\":[\"SN\"],\"222\":[\"MR\"],\"223\":[\"ML\"],\"224\":[\"GN\"],\"225\":[\"CI\"],\"226\":[\"BF\"],\"227\":[\"NE\"],\"228\":[\"TG\"],\"229\":[\"BJ\"],\"230\":[\"MU\"],\"231\":[\"LR\"],\"232\":[\"SL\"],\"233\":[\"GH\"],\"234\":[\"NG\"],\"235\":[\"TD\"],\"236\":[\"CF\"],\"237\":[\"CM\"],\"238\":[\"CV\"],\"239\":[\"ST\"],\"240\":[\"GQ\"],\"241\":[\"GA\"],\"242\":[\"CG\"],\"243\":[\"CD\"],\"244\":[\"AO\"],\"245\":[\"GW\"],\"246\":[\"IO\"],\"247\":[\"AC\"],\"248\":[\"SC\"],\"249\":[\"SD\"],\"250\":[\"RW\"],\"251\":[\"ET\"],\"252\":[\"SO\"],\"253\":[\"DJ\"],\"254\":[\"KE\"],\"255\":[\"TZ\"],\"256\":[\"UG\"],\"257\":[\"BI\"],\"258\":[\"MZ\"],\"260\":[\"ZM\"],\"261\":[\"MG\"],\"262\":[\"RE\",\"YT\"],\"263\":[\"ZW\"],\"264\":[\"NA\"],\"265\":[\"MW\"],\"266\":[\"LS\"],\"267\":[\"BW\"],\"268\":[\"SZ\"],\"269\":[\"KM\"],\"290\":[\"SH\",\"TA\"],\"291\":[\"ER\"],\"297\":[\"AW\"],\"298\":[\"FO\"],\"299\":[\"GL\"],\"350\":[\"GI\"],\"351\":[\"PT\"],\"352\":[\"LU\"],\"353\":[\"IE\"],\"354\":[\"IS\"],\"355\":[\"AL\"],\"356\":[\"MT\"],\"357\":[\"CY\"],\"358\":[\"FI\",\"AX\"],\"359\":[\"BG\"],\"370\":[\"LT\"],\"371\":[\"LV\"],\"372\":[\"EE\"],\"373\":[\"MD\"],\"374\":[\"AM\"],\"375\":[\"BY\"],\"376\":[\"AD\"],\"377\":[\"MC\"],\"378\":[\"SM\"],\"380\":[\"UA\"],\"381\":[\"RS\"],\"382\":[\"ME\"],\"383\":[\"XK\"],\"385\":[\"HR\"],\"386\":[\"SI\"],\"387\":[\"BA\"],\"389\":[\"MK\"],\"420\":[\"CZ\"],\"421\":[\"SK\"],\"423\":[\"LI\"],\"500\":[\"FK\"],\"501\":[\"BZ\"],\"502\":[\"GT\"],\"503\":[\"SV\"],\"504\":[\"HN\"],\"505\":[\"NI\"],\"506\":[\"CR\"],\"507\":[\"PA\"],\"508\":[\"PM\"],\"509\":[\"HT\"],\"590\":[\"GP\",\"BL\",\"MF\"],\"591\":[\"BO\"],\"592\":[\"GY\"],\"593\":[\"EC\"],\"594\":[\"GF\"],\"595\":[\"PY\"],\"596\":[\"MQ\"],\"597\":[\"SR\"],\"598\":[\"UY\"],\"599\":[\"CW\",\"BQ\"],\"670\":[\"TL\"],\"672\":[\"NF\"],\"673\":[\"BN\"],\"674\":[\"NR\"],\"675\":[\"PG\"],\"676\":[\"TO\"],\"677\":[\"SB\"],\"678\":[\"VU\"],\"679\":[\"FJ\"],\"680\":[\"PW\"],\"681\":[\"WF\"],\"682\":[\"CK\"],\"683\":[\"NU\"],\"685\":[\"WS\"],\"686\":[\"KI\"],\"687\":[\"NC\"],\"688\":[\"TV\"],\"689\":[\"PF\"],\"690\":[\"TK\"],\"691\":[\"FM\"],\"692\":[\"MH\"],\"850\":[\"KP\"],\"852\":[\"HK\"],\"853\":[\"MO\"],\"855\":[\"KH\"],\"856\":[\"LA\"],\"880\":[\"BD\"],\"886\":[\"TW\"],\"960\":[\"MV\"],\"961\":[\"LB\"],\"962\":[\"JO\"],\"963\":[\"SY\"],\"964\":[\"IQ\"],\"965\":[\"KW\"],\"966\":[\"SA\"],\"967\":[\"YE\"],\"968\":[\"OM\"],\"970\":[\"PS\"],\"971\":[\"AE\"],\"972\":[\"IL\"],\"973\":[\"BH\"],\"974\":[\"QA\"],\"975\":[\"BT\"],\"976\":[\"MN\"],\"977\":[\"NP\"],\"992\":[\"TJ\"],\"993\":[\"TM\"],\"994\":[\"AZ\"],\"995\":[\"GE\"],\"996\":[\"KG\"],\"998\":[\"UZ\"]},\"countries\":{\"AC\":[\"247\",\"00\",\"(?:[01589]\\\\d|[46])\\\\d{4}\",[5,6]],\"AD\":[\"376\",\"00\",\"(?:1|6\\\\d)\\\\d{7}|[135-9]\\\\d{5}\",[6,8,9],[[\"(\\\\d{3})(\\\\d{3})\",\"$1 $2\",[\"[135-9]\"]],[\"(\\\\d{4})(\\\\d{4})\",\"$1 $2\",[\"1\"]],[\"(\\\\d{3})(\\\\d{3})(\\\\d{3})\",\"$1 $2 $3\",[\"6\"]]]],\"AE\":[\"971\",\"00\",\"(?:[4-7]\\\\d|9[0-689])\\\\d{7}|800\\\\d{2,9}|[2-4679]\\\\d{7}\",[5,6,7,8,9,10,11,12],[[\"(\\\\d{3})(\\\\d{2,9})\",\"$1 $2\",[\"60|8\"]],[\"(\\\\d)(\\\\d{3})(\\\\d{4})\",\"$1 $2 $3\",[\"[236]|[479][2-8]\"],\"0$1\"],[\"(\\\\d{3})(\\\\d)(\\\\d{5})\",\"$1 $2 $3\",[\"[479]\"]],[\"(\\\\d{2})(\\\\d{3})(\\\\d{4})\",\"$1 $2 $3\",[\"5\"],\"0$1\"]],\"0\"],\"AF\":[\"93\",\"00\",\"[2-7]\\\\d{8}\",[9],[[\"(\\\\d{2})(\\\\d{3})(\\\\d{4})\",\"$1 $2 $3\",[\"[2-7]\"],\"0$1\"]],\"0\"],\"AG\":[\"1\",\"011\",\"(?:268|[58]\\\\d\\\\d|900)\\\\d{7}\",[10],0,\"1\",0,\"([457]\\\\d{6})$|1\",\"268$1\",0,\"268\"],\"AI\":[\"1\",\"011\",\"(?:264|[58]\\\\d\\\\d|900)\\\\d{7}\",[10],0,\"1\",0,\"([2457]\\\\d{6})$|1\",\"264$1\",0,\"264\"],\"AL\":[\"355\",\"00\",\"(?:700\\\\d\\\\d|900)\\\\d{3}|8\\\\d{5,7}|(?:[2-5]|6\\\\d)\\\\d{7}\",[6,7,8,9],[[\"(\\\\d{3})(\\\\d{3,4})\",\"$1 $2\",[\"80|9\"],\"0$1\"],[\"(\\\\d)(\\\\d{3})(\\\\d{4})\",\"$1 $2 $3\",[\"4[2-6]\"],\"0$1\"],[\"(\\\\d{2})(\\\\d{3})(\\\\d{3})\",\"$1 $2 $3\",[\"[2358][2-5]|4\"],\"0$1\"],[\"(\\\\d{3})(\\\\d{5})\",\"$1 $2\",[\"[23578]\"],\"0$1\"],[\"(\\\\d{2})(\\\\d{3})(\\\\d{4})\",\"$1 $2 $3\",[\"6\"],\"0$1\"]],\"0\"],\"AM\":[\"374\",\"00\",\"(?:[1-489]\\\\d|55|60|77)\\\\d{6}\",[8],[[\"(\\\\d{3})(\\\\d{2})(\\\\d{3})\",\"$1 $2 $3\",[\"[89]0\"],\"0 $1\"],[\"(\\\\d{3})(\\\\d{5})\",\"$1 $2\",[\"2|3[12]\"],\"(0$1)\"],[\"(\\\\d{2})(\\\\d{6})\",\"$1 $2\",[\"1|47\"],\"(0$1)\"],[\"(\\\\d{2})(\\\\d{6})\",\"$1 $2\",[\"[3-9]\"],\"0$1\"]],\"0\"],\"AO\":[\"244\",\"00\",\"[29]\\\\d{8}\",[9],[[\"(\\\\d{3})(\\\\d{3})(\\\\d{3})\",\"$1 $2 $3\",[\"[29]\"]]]],\"AR\":[\"54\",\"00\",\"(?:11|[89]\\\\d\\\\d)\\\\d{8}|[2368]\\\\d{9}\",[10,11],[[\"(\\\\d{4})(\\\\d{2})(\\\\d{4})\",\"$1 $2-$3\",[\"2(?:2[024-9]|3[0-59]|47|6[245]|9[02-8])|3(?:3[28]|4[03-9]|5[2-46-8]|7[1-578]|8[2-9])\",\"2(?:[23]02|6(?:[25]|4[6-8])|9(?:[02356]|4[02568]|72|8[23]))|3(?:3[28]|4(?:[04679]|3[5-8]|5[4-68]|8[2379])|5(?:[2467]|3[237]|8[2-5])|7[1-578]|8(?:[2469]|3[2578]|5[4-8]|7[36-8]|8[5-8]))|2(?:2[24-9]|3[1-59]|47)\",\"2(?:[23]02|6(?:[25]|4(?:64|[78]))|9(?:[02356]|4(?:[0268]|5[2-6])|72|8[23]))|3(?:3[28]|4(?:[04679]|3[78]|5(?:4[46]|8)|8[2379])|5(?:[2467]|3[237]|8[23])|7[1-578]|8(?:[2469]|3[278]|5[56][46]|86[3-6]))|2(?:2[24-9]|3[1-59]|47)|38(?:[58][78]|7[378])|3(?:4[35][56]|58[45]|8(?:[38]5|54|76))[4-6]\",\"2(?:[23]02|6(?:[25]|4(?:64|[78]))|9(?:[02356]|4(?:[0268]|5[2-6])|72|8[23]))|3(?:3[28]|4(?:[04679]|3(?:5(?:4[0-25689]|[56])|[78])|58|8[2379])|5(?:[2467]|3[237]|8(?:[23]|4(?:[45]|60)|5(?:4[0-39]|5|64)))|7[1-578]|8(?:[2469]|3[278]|54(?:4|5[13-7]|6[89])|86[3-6]))|2(?:2[24-9]|3[1-59]|47)|38(?:[58][78]|7[378])|3(?:454|85[56])[46]|3(?:4(?:36|5[56])|8(?:[38]5|76))[4-6]\"],\"0$1\",1],[\"(\\\\d{2})(\\\\d{4})(\\\\d{4})\",\"$1 $2-$3\",[\"1\"],\"0$1\",1],[\"(\\\\d{3})(\\\\d{3})(\\\\d{4})\",\"$1-$2-$3\",[\"[68]\"],\"0$1\"],[\"(\\\\d{3})(\\\\d{3})(\\\\d{4})\",\"$1 $2-$3\",[\"[23]\"],\"0$1\",1],[\"(\\\\d)(\\\\d{4})(\\\\d{2})(\\\\d{4})\",\"$2 15-$3-$4\",[\"9(?:2[2-469]|3[3-578])\",\"9(?:2(?:2[024-9]|3[0-59]|47|6[245]|9[02-8])|3(?:3[28]|4[03-9]|5[2-46-8]|7[1-578]|8[2-9]))\",\"9(?:2(?:[23]02|6(?:[25]|4[6-8])|9(?:[02356]|4[02568]|72|8[23]))|3(?:3[28]|4(?:[04679]|3[5-8]|5[4-68]|8[2379])|5(?:[2467]|3[237]|8[2-5])|7[1-578]|8(?:[2469]|3[2578]|5[4-8]|7[36-8]|8[5-8])))|92(?:2[24-9]|3[1-59]|47)\",\"9(?:2(?:[23]02|6(?:[25]|4(?:64|[78]))|9(?:[02356]|4(?:[0268]|5[2-6])|72|8[23]))|3(?:3[28]|4(?:[04679]|3[78]|5(?:4[46]|8)|8[2379])|5(?:[2467]|3[237]|8[23])|7[1-578]|8(?:[2469]|3[278]|5(?:[56][46]|[78])|7[378]|8(?:6[3-6]|[78]))))|92(?:2[24-9]|3[1-59]|47)|93(?:4[35][56]|58[45]|8(?:[38]5|54|76))[4-6]\",\"9(?:2(?:[23]02|6(?:[25]|4(?:64|[78]))|9(?:[02356]|4(?:[0268]|5[2-6])|72|8[23]))|3(?:3[28]|4(?:[04679]|3(?:5(?:4[0-25689]|[56])|[78])|5(?:4[46]|8)|8[2379])|5(?:[2467]|3[237]|8(?:[23]|4(?:[45]|60)|5(?:4[0-39]|5|64)))|7[1-578]|8(?:[2469]|3[278]|5(?:4(?:4|5[13-7]|6[89])|[56][46]|[78])|7[378]|8(?:6[3-6]|[78]))))|92(?:2[24-9]|3[1-59]|47)|93(?:4(?:36|5[56])|8(?:[38]5|76))[4-6]\"],\"0$1\",0,\"$1 $2 $3-$4\"],[\"(\\\\d)(\\\\d{2})(\\\\d{4})(\\\\d{4})\",\"$2 15-$3-$4\",[\"91\"],\"0$1\",0,\"$1 $2 $3-$4\"],[\"(\\\\d{3})(\\\\d{3})(\\\\d{5})\",\"$1-$2-$3\",[\"8\"],\"0$1\"],[\"(\\\\d)(\\\\d{3})(\\\\d{3})(\\\\d{4})\",\"$2 15-$3-$4\",[\"9\"],\"0$1\",0,\"$1 $2 $3-$4\"]],\"0\",0,\"0?(?:(11|2(?:2(?:02?|[13]|2[13-79]|4[1-6]|5[2457]|6[124-8]|7[1-4]|8[13-6]|9[1267])|3(?:02?|1[467]|2[03-6]|3[13-8]|[49][2-6]|5[2-8]|[67])|4(?:7[3-578]|9)|6(?:[0136]|2[24-6]|4[6-8]?|5[15-8])|80|9(?:0[1-3]|[19]|2\\\\d|3[1-6]|4[02568]?|5[2-4]|6[2-46]|72?|8[23]?))|3(?:3(?:2[79]|6|8[2578])|4(?:0[0-24-9]|[12]|3[5-8]?|4[24-7]|5[4-68]?|6[02-9]|7[126]|8[2379]?|9[1-36-8])|5(?:1|2[1245]|3[237]?|4[1-46-9]|6[2-4]|7[1-6]|8[2-5]?)|6[24]|7(?:[069]|1[1568]|2[15]|3[145]|4[13]|5[14-8]|7[2-57]|8[126])|8(?:[01]|2[15-7]|3[2578]?|4[13-6]|5[4-8]?|6[1-357-9]|7[36-8]?|8[5-8]?|9[124])))15)?\",\"9$1\"],\"AS\":[\"1\",\"011\",\"(?:[58]\\\\d\\\\d|684|900)\\\\d{7}\",[10],0,\"1\",0,\"([267]\\\\d{6})$|1\",\"684$1\",0,\"684\"],\"AT\":[\"43\",\"00\",\"1\\\\d{3,12}|2\\\\d{6,12}|43(?:(?:0\\\\d|5[02-9])\\\\d{3,9}|2\\\\d{4,5}|[3467]\\\\d{4}|8\\\\d{4,6}|9\\\\d{4,7})|5\\\\d{4,12}|8\\\\d{7,12}|9\\\\d{8,12}|(?:[367]\\\\d|4[0-24-9])\\\\d{4,11}\",[4,5,6,7,8,9,10,11,12,13],[[\"(\\\\d)(\\\\d{3,12})\",\"$1 $2\",[\"1(?:11|[2-9])\"],\"0$1\"],[\"(\\\\d{3})(\\\\d{2})\",\"$1 $2\",[\"517\"],\"0$1\"],[\"(\\\\d{2})(\\\\d{3,5})\",\"$1 $2\",[\"5[079]\"],\"0$1\"],[\"(\\\\d{3})(\\\\d{3,10})\",\"$1 $2\",[\"(?:31|4)6|51|6(?:48|5[0-3579]|[6-9])|7(?:20|32|8)|[89]\",\"(?:31|4)6|51|6(?:485|5[0-3579]|[6-9])|7(?:20|32|8)|[89]\"],\"0$1\"],[\"(\\\\d{4})(\\\\d{3,9})\",\"$1 $2\",[\"[2-467]|5[2-6]\"],\"0$1\"],[\"(\\\\d{2})(\\\\d{3})(\\\\d{3,4})\",\"$1 $2 $3\",[\"5\"],\"0$1\"],[\"(\\\\d{2})(\\\\d{4})(\\\\d{4,7})\",\"$1 $2 $3\",[\"5\"],\"0$1\"]],\"0\"],\"AU\":[\"61\",\"001[14-689]|14(?:1[14]|34|4[17]|[56]6|7[47]|88)0011\",\"1(?:[0-79]\\\\d{7}(?:\\\\d(?:\\\\d{2})?)?|8[0-24-9]\\\\d{7})|[2-478]\\\\d{8}|1\\\\d{4,7}\",[5,6,7,8,9,10,12],[[\"(\\\\d{2})(\\\\d{3,4})\",\"$1 $2\",[\"16\"],\"0$1\"],[\"(\\\\d{2})(\\\\d{3})(\\\\d{2,4})\",\"$1 $2 $3\",[\"16\"],\"0$1\"],[\"(\\\\d{3})(\\\\d{3})(\\\\d{3})\",\"$1 $2 $3\",[\"14|4\"],\"0$1\"],[\"(\\\\d)(\\\\d{4})(\\\\d{4})\",\"$1 $2 $3\",[\"[2378]\"],\"(0$1)\"],[\"(\\\\d{4})(\\\\d{3})(\\\\d{3})\",\"$1 $2 $3\",[\"1(?:30|[89])\"]]],\"0\",0,\"(183[12])|0\",0,0,0,[[\"(?:(?:241|349)0\\\\d\\\\d|8(?:51(?:0(?:0[03-9]|[12479]\\\\d|3[2-9]|5[0-8]|6[1-9]|8[0-7])|1(?:[0235689]\\\\d|1[0-69]|4[0-589]|7[0-47-9])|2(?:0[0-79]|[18][13579]|2[14-9]|3[0-46-9]|[4-6]\\\\d|7[89]|9[0-4])|[34]\\\\d\\\\d)|91(?:(?:[0-58]\\\\d|6[0135-9])\\\\d|7(?:0[0-24-9]|[1-9]\\\\d)|9(?:[0-46-9]\\\\d|5[0-79]))))\\\\d{3}|(?:2(?:[0-26-9]\\\\d|3[0-8]|4[02-9]|5[0135-9])|3(?:[0-3589]\\\\d|4[0-578]|6[1-9]|7[0-35-9])|7(?:[013-57-9]\\\\d|2[0-8])|8(?:55|6[0-8]|[78]\\\\d|9[02-9]))\\\\d{6}\",[9]],[\"4(?:79[01]|83[0-36-9]|95[0-3])\\\\d{5}|4(?:[0-36]\\\\d|4[047-9]|[58][0-24-9]|7[02-8]|9[0-47-9])\\\\d{6}\",[9]],[\"180(?:0\\\\d{3}|2)\\\\d{3}\",[7,10]],[\"190[0-26]\\\\d{6}\",[10]],0,0,0,[\"163\\\\d{2,6}\",[5,6,7,8,9]],[\"14(?:5(?:1[0458]|[23][458])|71\\\\d)\\\\d{4}\",[9]],[\"13(?:00\\\\d{6}(?:\\\\d{2})?|45[0-4]\\\\d{3})|13\\\\d{4}\",[6,8,10,12]]],\"0011\"],\"AW\":[\"297\",\"00\",\"(?:[25-79]\\\\d\\\\d|800)\\\\d{4}\",[7],[[\"(\\\\d{3})(\\\\d{4})\",\"$1 $2\",[\"[25-9]\"]]]],\"AX\":[\"358\",\"00|99(?:[01469]|5(?:[14]1|3[23]|5[59]|77|88|9[09]))\",\"2\\\\d{4,9}|35\\\\d{4,5}|(?:60\\\\d\\\\d|800)\\\\d{4,6}|7\\\\d{5,11}|(?:[14]\\\\d|3[0-46-9]|50)\\\\d{4,8}\",[5,6,7,8,9,10,11,12],0,\"0\",0,0,0,0,\"18\",0,\"00\"],\"AZ\":[\"994\",\"00\",\"365\\\\d{6}|(?:[124579]\\\\d|60|88)\\\\d{7}\",[9],[[\"(\\\\d{3})(\\\\d{2})(\\\\d{2})(\\\\d{2})\",\"$1 $2 $3 $4\",[\"90\"],\"0$1\"],[\"(\\\\d{2})(\\\\d{3})(\\\\d{2})(\\\\d{2})\",\"$1 $2 $3 $4\",[\"1[28]|2|365|46\",\"1[28]|2|365[45]|46\",\"1[28]|2|365(?:4|5[02])|46\"],\"(0$1)\"],[\"(\\\\d{2})(\\\\d{3})(\\\\d{2})(\\\\d{2})\",\"$1 $2 $3 $4\",[\"[13-9]\"],\"0$1\"]],\"0\"],\"BA\":[\"387\",\"00\",\"6\\\\d{8}|(?:[35689]\\\\d|49|70)\\\\d{6}\",[8,9],[[\"(\\\\d{2})(\\\\d{3})(\\\\d{3})\",\"$1 $2 $3\",[\"6[1-3]|[7-9]\"],\"0$1\"],[\"(\\\\d{2})(\\\\d{3})(\\\\d{3})\",\"$1 $2-$3\",[\"[3-5]|6[56]\"],\"0$1\"],[\"(\\\\d{2})(\\\\d{2})(\\\\d{2})(\\\\d{3})\",\"$1 $2 $3 $4\",[\"6\"],\"0$1\"]],\"0\"],\"BB\":[\"1\",\"011\",\"(?:246|[58]\\\\d\\\\d|900)\\\\d{7}\",[10],0,\"1\",0,\"([2-9]\\\\d{6})$|1\",\"246$1\",0,\"246\"],\"BD\":[\"880\",\"00\",\"[1-469]\\\\d{9}|8[0-79]\\\\d{7,8}|[2-79]\\\\d{8}|[2-9]\\\\d{7}|[3-9]\\\\d{6}|[57-9]\\\\d{5}\",[6,7,8,9,10],[[\"(\\\\d{2})(\\\\d{4,6})\",\"$1-$2\",[\"31[5-8]|[459]1\"],\"0$1\"],[\"(\\\\d{3})(\\\\d{3,7})\",\"$1-$2\",[\"3(?:[67]|8[013-9])|4(?:6[168]|7|[89][18])|5(?:6[128]|9)|6(?:[15]|28|4[14])|7[2-589]|8(?:0[014-9]|[12])|9[358]|(?:3[2-5]|4[235]|5[2-578]|6[0389]|76|8[3-7]|9[24])1|(?:44|66)[01346-9]\"],\"0$1\"],[\"(\\\\d{4})(\\\\d{3,6})\",\"$1-$2\",[\"[13-9]|2[23]\"],\"0$1\"],[\"(\\\\d)(\\\\d{7,8})\",\"$1-$2\",[\"2\"],\"0$1\"]],\"0\"],\"BE\":[\"32\",\"00\",\"4\\\\d{8}|[1-9]\\\\d{7}\",[8,9],[[\"(\\\\d{3})(\\\\d{2})(\\\\d{3})\",\"$1 $2 $3\",[\"(?:80|9)0\"],\"0$1\"],[\"(\\\\d)(\\\\d{3})(\\\\d{2})(\\\\d{2})\",\"$1 $2 $3 $4\",[\"[239]|4[23]\"],\"0$1\"],[\"(\\\\d{2})(\\\\d{2})(\\\\d{2})(\\\\d{2})\",\"$1 $2 $3 $4\",[\"[15-8]\"],\"0$1\"],[\"(\\\\d{3})(\\\\d{2})(\\\\d{2})(\\\\d{2})\",\"$1 $2 $3 $4\",[\"4\"],\"0$1\"]],\"0\"],\"BF\":[\"226\",\"00\",\"[024-7]\\\\d{7}\",[8],[[\"(\\\\d{2})(\\\\d{2})(\\\\d{2})(\\\\d{2})\",\"$1 $2 $3 $4\",[\"[024-7]\"]]]],\"BG\":[\"359\",\"00\",\"00800\\\\d{7}|[2-7]\\\\d{6,7}|[89]\\\\d{6,8}|2\\\\d{5}\",[6,7,8,9,12],[[\"(\\\\d)(\\\\d)(\\\\d{2})(\\\\d{2})\",\"$1 $2 $3 $4\",[\"2\"],\"0$1\"],[\"(\\\\d{3})(\\\\d{4})\",\"$1 $2\",[\"43[1-6]|70[1-9]\"],\"0$1\"],[\"(\\\\d)(\\\\d{3})(\\\\d{3,4})\",\"$1 $2 $3\",[\"2\"],\"0$1\"],[\"(\\\\d{2})(\\\\d{3})(\\\\d{2,3})\",\"$1 $2 $3\",[\"[356]|4[124-7]|7[1-9]|8[1-6]|9[1-7]\"],\"0$1\"],[\"(\\\\d{3})(\\\\d{2})(\\\\d{3})\",\"$1 $2 $3\",[\"(?:70|8)0\"],\"0$1\"],[\"(\\\\d{3})(\\\\d{3})(\\\\d{2})\",\"$1 $2 $3\",[\"43[1-7]|7\"],\"0$1\"],[\"(\\\\d{2})(\\\\d{3})(\\\\d{3,4})\",\"$1 $2 $3\",[\"[48]|9[08]\"],\"0$1\"],[\"(\\\\d{3})(\\\\d{3})(\\\\d{3})\",\"$1 $2 $3\",[\"9\"],\"0$1\"]],\"0\"],\"BH\":[\"973\",\"00\",\"[136-9]\\\\d{7}\",[8],[[\"(\\\\d{4})(\\\\d{4})\",\"$1 $2\",[\"[13679]|8[02-4679]\"]]]],\"BI\":[\"257\",\"00\",\"(?:[267]\\\\d|31)\\\\d{6}\",[8],[[\"(\\\\d{2})(\\\\d{2})(\\\\d{2})(\\\\d{2})\",\"$1 $2 $3 $4\",[\"[2367]\"]]]],\"BJ\":[\"229\",\"00\",\"(?:01\\\\d|8)\\\\d{7}\",[8,10],[[\"(\\\\d{2})(\\\\d{2})(\\\\d{2})(\\\\d{2})\",\"$1 $2 $3 $4\",[\"8\"]],[\"(\\\\d{2})(\\\\d{2})(\\\\d{2})(\\\\d{2})(\\\\d{2})\",\"$1 $2 $3 $4 $5\",[\"0\"]]]],\"BL\":[\"590\",\"00\",\"7090\\\\d{5}|(?:[56]9|[89]\\\\d)\\\\d{7}\",[9],0,\"0\",0,0,0,0,0,[[\"(?:59(?:0(?:2[7-9]|3[3-7]|5[12]|87)|87\\\\d)|80[6-9]\\\\d\\\\d)\\\\d{4}\"],[\"(?:69(?:0\\\\d\\\\d|1(?:2[2-9]|3[0-5]))|7090[0-4])\\\\d{4}\"],[\"80[0-5]\\\\d{6}\"],[\"8[129]\\\\d{7}\"],0,0,0,0,[\"9(?:(?:39[5-7]|76[018])\\\\d|475[0-6])\\\\d{4}\"]]],\"BM\":[\"1\",\"011\",\"(?:441|[58]\\\\d\\\\d|900)\\\\d{7}\",[10],0,\"1\",0,\"([2-9]\\\\d{6})$|1\",\"441$1\",0,\"441\"],\"BN\":[\"673\",\"00\",\"[2-578]\\\\d{6}\",[7],[[\"(\\\\d{3})(\\\\d{4})\",\"$1 $2\",[\"[2-578]\"]]]],\"BO\":[\"591\",\"00(?:1\\\\d)?\",\"(?:[2-7]\\\\d\\\\d|8001)\\\\d{5}\",[8,9],[[\"(\\\\d)(\\\\d{7})\",\"$1 $2\",[\"[23]|4[46]|50\"]],[\"(\\\\d{8})\",\"$1\",[\"[5-7]\"]],[\"(\\\\d{3})(\\\\d{2})(\\\\d{4})\",\"$1 $2 $3\",[\"8\"]]],\"0\",0,\"0(1\\\\d)?\"],\"BQ\":[\"599\",\"00\",\"(?:[34]1|7\\\\d)\\\\d{5}\",[7],0,0,0,0,0,0,\"[347]\"],\"BR\":[\"55\",\"00(?:1[245]|2[1-35]|31|4[13]|[56]5|99)\",\"[1-467]\\\\d{9,10}|55[0-46-9]\\\\d{8}|[34]\\\\d{7}|55\\\\d{7,8}|(?:5[0-46-9]|[89]\\\\d)\\\\d{7,9}\",[8,9,10,11],[[\"(\\\\d{4})(\\\\d{4})\",\"$1-$2\",[\"300|4(?:0[02]|37|86)\",\"300|4(?:0(?:0|20)|370|864)\"]],[\"(\\\\d{3})(\\\\d{2,3})(\\\\d{4})\",\"$1 $2 $3\",[\"(?:[358]|90)0\"],\"0$1\"],[\"(\\\\d{2})(\\\\d{4})(\\\\d{4})\",\"$1 $2-$3\",[\"(?:[14689][1-9]|2[12478]|3[1-578]|5[13-5]|7[13-579])[2-57]\"],\"($1)\"],[\"(\\\\d{2})(\\\\d{5})(\\\\d{4})\",\"$1 $2-$3\",[\"[16][1-9]|[2-57-9]\"],\"($1)\"]],\"0\",0,\"(?:0|90)(?:(1[245]|2[1-35]|31|4[13]|[56]5|99)(\\\\d{10,11}))?\",\"$2\"],\"BS\":[\"1\",\"011\",\"(?:242|[58]\\\\d\\\\d|900)\\\\d{7}\",[10],0,\"1\",0,\"([3-8]\\\\d{6})$|1\",\"242$1\",0,\"242\"],\"BT\":[\"975\",\"00\",\"[178]\\\\d{7}|[2-8]\\\\d{6}\",[7,8],[[\"(\\\\d)(\\\\d{3})(\\\\d{3})\",\"$1 $2 $3\",[\"[2-6]|7[246]|8[2-4]\"]],[\"(\\\\d{2})(\\\\d{2})(\\\\d{2})(\\\\d{2})\",\"$1 $2 $3 $4\",[\"1[67]|[78]\"]]]],\"BW\":[\"267\",\"00\",\"(?:0800|(?:[37]|800)\\\\d)\\\\d{6}|(?:[2-6]\\\\d|90)\\\\d{5}\",[7,8,10],[[\"(\\\\d{2})(\\\\d{5})\",\"$1 $2\",[\"90\"]],[\"(\\\\d{3})(\\\\d{4})\",\"$1 $2\",[\"[24-6]|3[15-9]\"]],[\"(\\\\d{2})(\\\\d{3})(\\\\d{3})\",\"$1 $2 $3\",[\"[37]\"]],[\"(\\\\d{4})(\\\\d{3})(\\\\d{3})\",\"$1 $2 $3\",[\"0\"]],[\"(\\\\d{3})(\\\\d{4})(\\\\d{3})\",\"$1 $2 $3\",[\"8\"]]]],\"BY\":[\"375\",\"810\",\"(?:[12]\\\\d|33|44|902)\\\\d{7}|8(?:0[0-79]\\\\d{5,7}|[1-7]\\\\d{9})|8(?:1[0-489]|[5-79]\\\\d)\\\\d{7}|8[1-79]\\\\d{6,7}|8[0-79]\\\\d{5}|8\\\\d{5}\",[6,7,8,9,10,11],[[\"(\\\\d{3})(\\\\d{3})\",\"$1 $2\",[\"800\"],\"8 $1\"],[\"(\\\\d{3})(\\\\d{2})(\\\\d{2,4})\",\"$1 $2 $3\",[\"800\"],\"8 $1\"],[\"(\\\\d{4})(\\\\d{2})(\\\\d{3})\",\"$1 $2-$3\",[\"1(?:5[169]|6[3-5]|7[179])|2(?:1[35]|2[34]|3[3-5])\",\"1(?:5[169]|6(?:3[1-3]|4|5[125])|7(?:1[3-9]|7[0-24-6]|9[2-7]))|2(?:1[35]|2[34]|3[3-5])\"],\"8 0$1\"],[\"(\\\\d{3})(\\\\d{2})(\\\\d{2})(\\\\d{2})\",\"$1 $2-$3-$4\",[\"1(?:[56]|7[467])|2[1-3]\"],\"8 0$1\"],[\"(\\\\d{2})(\\\\d{3})(\\\\d{2})(\\\\d{2})\",\"$1 $2-$3-$4\",[\"[1-4]\"],\"8 0$1\"],[\"(\\\\d{3})(\\\\d{3,4})(\\\\d{4})\",\"$1 $2 $3\",[\"[89]\"],\"8 $1\"]],\"8\",0,\"0|80?\",0,0,0,0,\"8~10\"],\"BZ\":[\"501\",\"00\",\"(?:0800\\\\d|[2-8])\\\\d{6}\",[7,11],[[\"(\\\\d{3})(\\\\d{4})\",\"$1-$2\",[\"[2-8]\"]],[\"(\\\\d)(\\\\d{3})(\\\\d{4})(\\\\d{3})\",\"$1-$2-$3-$4\",[\"0\"]]]],\"CA\":[\"1\",\"011\",\"[2-9]\\\\d{9}|3\\\\d{6}\",[7,10],0,\"1\",0,0,0,0,0,[[\"(?:2(?:04|[23]6|[48]9|5[07]|63)|3(?:06|43|54|6[578]|82)|4(?:03|1[68]|[26]8|3[178]|50|74)|5(?:06|1[49]|48|79|8[147])|6(?:04|[18]3|39|47|72)|7(?:0[59]|42|53|78|8[02])|8(?:[06]7|19|25|7[39])|9(?:0[25]|42))[2-9]\\\\d{6}\",[10]],[\"\",[10]],[\"8(?:00|33|44|55|66|77|88)[2-9]\\\\d{6}\",[10]],[\"900[2-9]\\\\d{6}\",[10]],[\"52(?:3(?:[2-46-9][02-9]\\\\d|5(?:[02-46-9]\\\\d|5[0-46-9]))|4(?:[2-478][02-9]\\\\d|5(?:[034]\\\\d|2[024-9]|5[0-46-9])|6(?:0[1-9]|[2-9]\\\\d)|9(?:[05-9]\\\\d|2[0-5]|49)))\\\\d{4}|52[34][2-9]1[02-9]\\\\d{4}|(?:5(?:2[125-9]|3[23]|44|66|77|88)|6(?:22|33))[2-9]\\\\d{6}\",[10]],0,[\"310\\\\d{4}\",[7]],0,[\"600[2-9]\\\\d{6}\",[10]]]],\"CC\":[\"61\",\"001[14-689]|14(?:1[14]|34|4[17]|[56]6|7[47]|88)0011\",\"1(?:[0-79]\\\\d{8}(?:\\\\d{2})?|8[0-24-9]\\\\d{7})|[148]\\\\d{8}|1\\\\d{5,7}\",[6,7,8,9,10,12],0,\"0\",0,\"([59]\\\\d{7})$|0\",\"8$1\",0,0,[[\"8(?:51(?:0(?:02|31|60|89)|1(?:18|76)|223)|91(?:0(?:1[0-2]|29)|1(?:[28]2|50|79)|2(?:10|64)|3(?:[06]8|22)|4[29]8|62\\\\d|70[23]|959))\\\\d{3}\",[9]],[\"4(?:79[01]|83[0-36-9]|95[0-3])\\\\d{5}|4(?:[0-36]\\\\d|4[047-9]|[58][0-24-9]|7[02-8]|9[0-47-9])\\\\d{6}\",[9]],[\"180(?:0\\\\d{3}|2)\\\\d{3}\",[7,10]],[\"190[0-26]\\\\d{6}\",[10]],0,0,0,0,[\"14(?:5(?:1[0458]|[23][458])|71\\\\d)\\\\d{4}\",[9]],[\"13(?:00\\\\d{6}(?:\\\\d{2})?|45[0-4]\\\\d{3})|13\\\\d{4}\",[6,8,10,12]]],\"0011\"],\"CD\":[\"243\",\"00\",\"(?:(?:[189]|5\\\\d)\\\\d|2)\\\\d{7}|[1-68]\\\\d{6}\",[7,8,9,10],[[\"(\\\\d{2})(\\\\d{2})(\\\\d{3})\",\"$1 $2 $3\",[\"88\"],\"0$1\"],[\"(\\\\d{2})(\\\\d{5})\",\"$1 $2\",[\"[1-6]\"],\"0$1\"],[\"(\\\\d{2})(\\\\d{2})(\\\\d{4})\",\"$1 $2 $3\",[\"2\"],\"0$1\"],[\"(\\\\d{2})(\\\\d{3})(\\\\d{4})\",\"$1 $2 $3\",[\"1\"],\"0$1\"],[\"(\\\\d{3})(\\\\d{3})(\\\\d{3})\",\"$1 $2 $3\",[\"[89]\"],\"0$1\"],[\"(\\\\d{2})(\\\\d{2})(\\\\d{3})(\\\\d{3})\",\"$1 $2 $3 $4\",[\"5\"],\"0$1\"]],\"0\"],\"CF\":[\"236\",\"00\",\"8776\\\\d{4}|(?:[27]\\\\d|61)\\\\d{6}\",[8],[[\"(\\\\d{2})(\\\\d{2})(\\\\d{2})(\\\\d{2})\",\"$1 $2 $3 $4\",[\"[26-8]\"]]]],\"CG\":[\"242\",\"00\",\"222\\\\d{6}|(?:0\\\\d|80)\\\\d{7}\",[9],[[\"(\\\\d)(\\\\d{4})(\\\\d{4})\",\"$1 $2 $3\",[\"8\"]],[\"(\\\\d{2})(\\\\d{3})(\\\\d{4})\",\"$1 $2 $3\",[\"[02]\"]]]],\"CH\":[\"41\",\"00\",\"8\\\\d{11}|[2-9]\\\\d{8}\",[9,12],[[\"(\\\\d{3})(\\\\d{3})(\\\\d{3})\",\"$1 $2 $3\",[\"8[047]|90\"],\"0$1\"],[\"(\\\\d{2})(\\\\d{3})(\\\\d{2})(\\\\d{2})\",\"$1 $2 $3 $4\",[\"[2-79]|81\"],\"0$1\"],[\"(\\\\d{3})(\\\\d{2})(\\\\d{3})(\\\\d{2})(\\\\d{2})\",\"$1 $2 $3 $4 $5\",[\"8\"],\"0$1\"]],\"0\"],\"CI\":[\"225\",\"00\",\"[02]\\\\d{9}\",[10],[[\"(\\\\d{2})(\\\\d{2})(\\\\d)(\\\\d{5})\",\"$1 $2 $3 $4\",[\"2\"]],[\"(\\\\d{2})(\\\\d{2})(\\\\d{2})(\\\\d{4})\",\"$1 $2 $3 $4\",[\"0\"]]]],\"CK\":[\"682\",\"00\",\"[2-578]\\\\d{4}\",[5],[[\"(\\\\d{2})(\\\\d{3})\",\"$1 $2\",[\"[2-578]\"]]]],\"CL\":[\"56\",\"(?:0|1(?:1[0-69]|2[02-5]|5[13-58]|69|7[0167]|8[018]))0\",\"12300\\\\d{6}|6\\\\d{9,10}|[2-9]\\\\d{8}\",[9,10,11],[[\"(\\\\d{5})(\\\\d{4})\",\"$1 $2\",[\"219\",\"2196\"],\"($1)\"],[\"(\\\\d{3})(\\\\d{3})(\\\\d{3})\",\"$1 $2 $3\",[\"60|809\"]],[\"(\\\\d{2})(\\\\d{3})(\\\\d{4})\",\"$1 $2 $3\",[\"44\"]],[\"(\\\\d)(\\\\d{4})(\\\\d{4})\",\"$1 $2 $3\",[\"2[1-36]\"],\"($1)\"],[\"(\\\\d)(\\\\d{4})(\\\\d{4})\",\"$1 $2 $3\",[\"9(?:10|[2-9])\"]],[\"(\\\\d{2})(\\\\d{3})(\\\\d{4})\",\"$1 $2 $3\",[\"3[2-5]|[47]|5[1-3578]|6[13-57]|8(?:0[1-8]|[1-9])\"],\"($1)\"],[\"(\\\\d{3})(\\\\d{3})(\\\\d{3,4})\",\"$1 $2 $3\",[\"60|8\"]],[\"(\\\\d{4})(\\\\d{3})(\\\\d{4})\",\"$1 $2 $3\",[\"1\"]],[\"(\\\\d{3})(\\\\d{3})(\\\\d{2})(\\\\d{3})\",\"$1 $2 $3 $4\",[\"60\"]]]],\"CM\":[\"237\",\"00\",\"[26]\\\\d{8}|88\\\\d{6,7}\",[8,9],[[\"(\\\\d{2})(\\\\d{2})(\\\\d{2})(\\\\d{2})\",\"$1 $2 $3 $4\",[\"88\"]],[\"(\\\\d)(\\\\d{2})(\\\\d{2})(\\\\d{2})(\\\\d{2})\",\"$1 $2 $3 $4 $5\",[\"[26]|88\"]]]],\"CN\":[\"86\",\"00|1(?:[12]\\\\d|79)\\\\d\\\\d00\",\"(?:(?:1[03-689]|2\\\\d)\\\\d\\\\d|6)\\\\d{8}|1\\\\d{10}|[126]\\\\d{6}(?:\\\\d(?:\\\\d{2})?)?|86\\\\d{5,6}|(?:[3-579]\\\\d|8[0-57-9])\\\\d{5,9}\",[7,8,9,10,11,12],[[\"(\\\\d{2})(\\\\d{5,6})\",\"$1 $2\",[\"(?:10|2[0-57-9])[19]|3(?:[157]|35|49|9[1-68])|4(?:1[124-9]|2[179]|6[47-9]|7|8[23])|5(?:[1357]|2[37]|4[36]|6[1-46]|80)|6(?:3[1-5]|6[0238]|9[12])|7(?:01|[1579]|2[248]|3[014-9]|4[3-6]|6[023689])|8(?:07|1[236-8]|2[5-7]|[37]|8[36-8]|9[1-8])|9(?:0[1-3689]|1[1-79]|3|4[13]|5[1-5]|7[0-79]|9[0-35-9])|(?:4[35]|59|85)[1-9]\",\"(?:10|2[0-57-9])(?:1[02]|9[56])|8078|(?:3(?:[157]\\\\d|35|49|9[1-68])|4(?:1[124-9]|2[179]|[35][1-9]|6[47-9]|7\\\\d|8[23])|5(?:[1357]\\\\d|2[37]|4[36]|6[1-46]|80|9[1-9])|6(?:3[1-5]|6[0238]|9[12])|7(?:01|[1579]\\\\d|2[248]|3[014-9]|4[3-6]|6[023689])|8(?:1[236-8]|2[5-7]|[37]\\\\d|5[1-9]|8[36-8]|9[1-8])|9(?:0[1-3689]|1[1-79]|3\\\\d|4[13]|5[1-5]|7[0-79]|9[0-35-9]))1\",\"10(?:1(?:0|23)|9[56])|2[0-57-9](?:1(?:00|23)|9[56])|80781|(?:3(?:[157]\\\\d|35|49|9[1-68])|4(?:1[124-9]|2[179]|[35][1-9]|6[47-9]|7\\\\d|8[23])|5(?:[1357]\\\\d|2[37]|4[36]|6[1-46]|80|9[1-9])|6(?:3[1-5]|6[0238]|9[12])|7(?:01|[1579]\\\\d|2[248]|3[014-9]|4[3-6]|6[023689])|8(?:1[236-8]|2[5-7]|[37]\\\\d|5[1-9]|8[36-8]|9[1-8])|9(?:0[1-3689]|1[1-79]|3\\\\d|4[13]|5[1-5]|7[0-79]|9[0-35-9]))12\",\"10(?:1(?:0|23)|9[56])|2[0-57-9](?:1(?:00|23)|9[56])|807812|(?:3(?:[157]\\\\d|35|49|9[1-68])|4(?:1[124-9]|2[179]|[35][1-9]|6[47-9]|7\\\\d|8[23])|5(?:[1357]\\\\d|2[37]|4[36]|6[1-46]|80|9[1-9])|6(?:3[1-5]|6[0238]|9[12])|7(?:01|[1579]\\\\d|2[248]|3[014-9]|4[3-6]|6[023689])|8(?:1[236-8]|2[5-7]|[37]\\\\d|5[1-9]|8[36-8]|9[1-8])|9(?:0[1-3689]|1[1-79]|3\\\\d|4[13]|5[1-5]|7[0-79]|9[0-35-9]))123\",\"10(?:1(?:0|23)|9[56])|2[0-57-9](?:1(?:00|23)|9[56])|(?:3(?:[157]\\\\d|35|49|9[1-68])|4(?:1[124-9]|2[179]|[35][1-9]|6[47-9]|7\\\\d|8[23])|5(?:[1357]\\\\d|2[37]|4[36]|6[1-46]|80|9[1-9])|6(?:3[1-5]|6[0238]|9[12])|7(?:01|[1579]\\\\d|2[248]|3[014-9]|4[3-6]|6[023689])|8(?:078|1[236-8]|2[5-7]|[37]\\\\d|5[1-9]|8[36-8]|9[1-8])|9(?:0[1-3689]|1[1-79]|3\\\\d|4[13]|5[1-5]|7[0-79]|9[0-35-9]))123\"],\"0$1\"],[\"(\\\\d{3})(\\\\d{5,6})\",\"$1 $2\",[\"3(?:[157]|35|49|9[1-68])|4(?:[17]|2[179]|6[47-9]|8[23])|5(?:[1357]|2[37]|4[36]|6[1-46]|80)|6(?:3[1-5]|6[0238]|9[12])|7(?:01|[1579]|2[248]|3[014-9]|4[3-6]|6[023689])|8(?:1[236-8]|2[5-7]|[37]|8[36-8]|9[1-8])|9(?:0[1-3689]|1[1-79]|[379]|4[13]|5[1-5])|(?:4[35]|59|85)[1-9]\",\"(?:3(?:[157]\\\\d|35|49|9[1-68])|4(?:[17]\\\\d|2[179]|[35][1-9]|6[47-9]|8[23])|5(?:[1357]\\\\d|2[37]|4[36]|6[1-46]|80|9[1-9])|6(?:3[1-5]|6[0238]|9[12])|7(?:01|[1579]\\\\d|2[248]|3[014-9]|4[3-6]|6[023689])|8(?:1[236-8]|2[5-7]|[37]\\\\d|5[1-9]|8[36-8]|9[1-8])|9(?:0[1-3689]|1[1-79]|[379]\\\\d|4[13]|5[1-5]))[19]\",\"85[23](?:10|95)|(?:3(?:[157]\\\\d|35|49|9[1-68])|4(?:[17]\\\\d|2[179]|[35][1-9]|6[47-9]|8[23])|5(?:[1357]\\\\d|2[37]|4[36]|6[1-46]|80|9[1-9])|6(?:3[1-5]|6[0238]|9[12])|7(?:01|[1579]\\\\d|2[248]|3[014-9]|4[3-6]|6[023689])|8(?:1[236-8]|2[5-7]|[37]\\\\d|5[14-9]|8[36-8]|9[1-8])|9(?:0[1-3689]|1[1-79]|[379]\\\\d|4[13]|5[1-5]))(?:10|9[56])\",\"85[23](?:100|95)|(?:3(?:[157]\\\\d|35|49|9[1-68])|4(?:[17]\\\\d|2[179]|[35][1-9]|6[47-9]|8[23])|5(?:[1357]\\\\d|2[37]|4[36]|6[1-46]|80|9[1-9])|6(?:3[1-5]|6[0238]|9[12])|7(?:01|[1579]\\\\d|2[248]|3[014-9]|4[3-6]|6[023689])|8(?:1[236-8]|2[5-7]|[37]\\\\d|5[14-9]|8[36-8]|9[1-8])|9(?:0[1-3689]|1[1-79]|[379]\\\\d|4[13]|5[1-5]))(?:100|9[56])\"],\"0$1\"],[\"(\\\\d{3})(\\\\d{3})(\\\\d{4})\",\"$1 $2 $3\",[\"(?:4|80)0\"]],[\"(\\\\d{2})(\\\\d{4})(\\\\d{4})\",\"$1 $2 $3\",[\"10|2(?:[02-57-9]|1[1-9])\",\"10|2(?:[02-57-9]|1[1-9])\",\"10[0-79]|2(?:[02-57-9]|1[1-79])|(?:10|21)8(?:0[1-9]|[1-9])\"],\"0$1\",1],[\"(\\\\d{3})(\\\\d{3})(\\\\d{4})\",\"$1 $2 $3\",[\"3(?:[3-59]|7[02-68])|4(?:[26-8]|3[3-9]|5[2-9])|5(?:3[03-9]|[468]|7[028]|9[2-46-9])|6|7(?:[0-247]|3[04-9]|5[0-4689]|6[2368])|8(?:[1-358]|9[1-7])|9(?:[013479]|5[1-5])|(?:[34]1|55|79|87)[02-9]\"],\"0$1\",1],[\"(\\\\d{3})(\\\\d{7,8})\",\"$1 $2\",[\"9\"]],[\"(\\\\d{4})(\\\\d{3})(\\\\d{4})\",\"$1 $2 $3\",[\"80\"],\"0$1\",1],[\"(\\\\d{3})(\\\\d{4})(\\\\d{4})\",\"$1 $2 $3\",[\"[3-578]\"],\"0$1\",1],[\"(\\\\d{3})(\\\\d{4})(\\\\d{4})\",\"$1 $2 $3\",[\"1[3-9]\"]],[\"(\\\\d{2})(\\\\d{3})(\\\\d{3})(\\\\d{4})\",\"$1 $2 $3 $4\",[\"[12]\"],\"0$1\",1]],\"0\",0,\"(1(?:[12]\\\\d|79)\\\\d\\\\d)|0\",0,0,0,0,\"00\"],\"CO\":[\"57\",\"00(?:4(?:[14]4|56)|[579])\",\"(?:46|60\\\\d\\\\d)\\\\d{6}|(?:1\\\\d|[39])\\\\d{9}\",[8,10,11],[[\"(\\\\d{4})(\\\\d{4})\",\"$1 $2\",[\"46\"]],[\"(\\\\d{3})(\\\\d{7})\",\"$1 $2\",[\"6|90\"],\"($1)\"],[\"(\\\\d{3})(\\\\d{7})\",\"$1 $2\",[\"3[0-357]|9[14]\"]],[\"(\\\\d)(\\\\d{3})(\\\\d{7})\",\"$1-$2-$3\",[\"1\"],\"0$1\",0,\"$1 $2 $3\"]],\"0\",0,\"0([3579]|4(?:[14]4|56))?\"],\"CR\":[\"506\",\"00\",\"(?:8\\\\d|90)\\\\d{8}|(?:[24-8]\\\\d{3}|3005)\\\\d{4}\",[8,10],[[\"(\\\\d{4})(\\\\d{4})\",\"$1 $2\",[\"[2-7]|8[3-9]\"]],[\"(\\\\d{3})(\\\\d{3})(\\\\d{4})\",\"$1-$2-$3\",[\"[89]\"]]],0,0,\"(19(?:0[0-2468]|1[09]|20|66|77|99))\"],\"CU\":[\"53\",\"119\",\"(?:[2-7]|8\\\\d\\\\d)\\\\d{7}|[2-47]\\\\d{6}|[34]\\\\d{5}\",[6,7,8,10],[[\"(\\\\d{2})(\\\\d{4,6})\",\"$1 $2\",[\"2[1-4]|[34]\"],\"(0$1)\"],[\"(\\\\d)(\\\\d{6,7})\",\"$1 $2\",[\"7\"],\"(0$1)\"],[\"(\\\\d)(\\\\d{7})\",\"$1 $2\",[\"[56]\"],\"0$1\"],[\"(\\\\d{3})(\\\\d{7})\",\"$1 $2\",[\"8\"],\"0$1\"]],\"0\"],\"CV\":[\"238\",\"0\",\"(?:[2-59]\\\\d\\\\d|800)\\\\d{4}\",[7],[[\"(\\\\d{3})(\\\\d{2})(\\\\d{2})\",\"$1 $2 $3\",[\"[2-589]\"]]]],\"CW\":[\"599\",\"00\",\"(?:[34]1|60|(?:7|9\\\\d)\\\\d)\\\\d{5}\",[7,8],[[\"(\\\\d{3})(\\\\d{4})\",\"$1 $2\",[\"[3467]\"]],[\"(\\\\d)(\\\\d{3})(\\\\d{4})\",\"$1 $2 $3\",[\"9[4-8]\"]]],0,0,0,0,0,\"[69]\"],\"CX\":[\"61\",\"001[14-689]|14(?:1[14]|34|4[17]|[56]6|7[47]|88)0011\",\"1(?:[0-79]\\\\d{8}(?:\\\\d{2})?|8[0-24-9]\\\\d{7})|[148]\\\\d{8}|1\\\\d{5,7}\",[6,7,8,9,10,12],0,\"0\",0,\"([59]\\\\d{7})$|0\",\"8$1\",0,0,[[\"8(?:51(?:0(?:01|30|59|88)|1(?:17|46|75)|2(?:22|35))|91(?:00[6-9]|1(?:[28]1|49|78)|2(?:09|63)|3(?:12|26|75)|4(?:56|97)|64\\\\d|7(?:0[01]|1[0-2])|958))\\\\d{3}\",[9]],[\"4(?:79[01]|83[0-36-9]|95[0-3])\\\\d{5}|4(?:[0-36]\\\\d|4[047-9]|[58][0-24-9]|7[02-8]|9[0-47-9])\\\\d{6}\",[9]],[\"180(?:0\\\\d{3}|2)\\\\d{3}\",[7,10]],[\"190[0-26]\\\\d{6}\",[10]],0,0,0,0,[\"14(?:5(?:1[0458]|[23][458])|71\\\\d)\\\\d{4}\",[9]],[\"13(?:00\\\\d{6}(?:\\\\d{2})?|45[0-4]\\\\d{3})|13\\\\d{4}\",[6,8,10,12]]],\"0011\"],\"CY\":[\"357\",\"00\",\"(?:[279]\\\\d|[58]0)\\\\d{6}\",[8],[[\"(\\\\d{2})(\\\\d{6})\",\"$1 $2\",[\"[257-9]\"]]]],\"CZ\":[\"420\",\"00\",\"(?:[2-578]\\\\d|60)\\\\d{7}|9\\\\d{8,11}\",[9,10,11,12],[[\"(\\\\d{3})(\\\\d{3})(\\\\d{3})\",\"$1 $2 $3\",[\"[2-8]|9[015-7]\"]],[\"(\\\\d{2})(\\\\d{3})(\\\\d{3})(\\\\d{2})\",\"$1 $2 $3 $4\",[\"96\"]],[\"(\\\\d{2})(\\\\d{3})(\\\\d{3})(\\\\d{3})\",\"$1 $2 $3 $4\",[\"9\"]],[\"(\\\\d{3})(\\\\d{3})(\\\\d{3})(\\\\d{3})\",\"$1 $2 $3 $4\",[\"9\"]]]],\"DE\":[\"49\",\"00\",\"[2579]\\\\d{5,14}|49(?:[34]0|69|8\\\\d)\\\\d\\\\d?|49(?:37|49|60|7[089]|9\\\\d)\\\\d{1,3}|49(?:2[024-9]|3[2-689]|7[1-7])\\\\d{1,8}|(?:1|[368]\\\\d|4[0-8])\\\\d{3,13}|49(?:[015]\\\\d|2[13]|31|[46][1-8])\\\\d{1,9}\",[4,5,6,7,8,9,10,11,12,13,14,15],[[\"(\\\\d{2})(\\\\d{3,13})\",\"$1 $2\",[\"3[02]|40|[68]9\"],\"0$1\"],[\"(\\\\d{3})(\\\\d{3,12})\",\"$1 $2\",[\"2(?:0[1-389]|1[124]|2[18]|3[14])|3(?:[35-9][15]|4[015])|906|(?:2[4-9]|4[2-9]|[579][1-9]|[68][1-8])1\",\"2(?:0[1-389]|12[0-8])|3(?:[35-9][15]|4[015])|906|2(?:[13][14]|2[18])|(?:2[4-9]|4[2-9]|[579][1-9]|[68][1-8])1\"],\"0$1\"],[\"(\\\\d{4})(\\\\d{2,11})\",\"$1 $2\",[\"[24-6]|3(?:[3569][02-46-9]|4[2-4679]|7[2-467]|8[2-46-8])|70[2-8]|8(?:0[2-9]|[1-8])|90[7-9]|[79][1-9]\",\"[24-6]|3(?:3(?:0[1-467]|2[127-9]|3[124578]|7[1257-9]|8[1256]|9[145])|4(?:2[135]|4[13578]|9[1346])|5(?:0[14]|2[1-3589]|6[1-4]|7[13468]|8[13568])|6(?:2[1-489]|3[124-6]|6[13]|7[12579]|8[1-356]|9[135])|7(?:2[1-7]|4[145]|6[1-5]|7[1-4])|8(?:21|3[1468]|6|7[1467]|8[136])|9(?:0[12479]|2[1358]|4[134679]|6[1-9]|7[136]|8[147]|9[1468]))|70[2-8]|8(?:0[2-9]|[1-8])|90[7-9]|[79][1-9]|3[68]4[1347]|3(?:47|60)[1356]|3(?:3[46]|46|5[49])[1246]|3[4579]3[1357]\"],\"0$1\"],[\"(\\\\d{3})(\\\\d{4})\",\"$1 $2\",[\"138\"],\"0$1\"],[\"(\\\\d{5})(\\\\d{2,10})\",\"$1 $2\",[\"3\"],\"0$1\"],[\"(\\\\d{3})(\\\\d{5,11})\",\"$1 $2\",[\"181\"],\"0$1\"],[\"(\\\\d{3})(\\\\d)(\\\\d{4,10})\",\"$1 $2 $3\",[\"1(?:3|80)|9\"],\"0$1\"],[\"(\\\\d{3})(\\\\d{7,8})\",\"$1 $2\",[\"1[67]\"],\"0$1\"],[\"(\\\\d{3})(\\\\d{7,12})\",\"$1 $2\",[\"8\"],\"0$1\"],[\"(\\\\d{5})(\\\\d{6})\",\"$1 $2\",[\"185\",\"1850\",\"18500\"],\"0$1\"],[\"(\\\\d{3})(\\\\d{4})(\\\\d{4})\",\"$1 $2 $3\",[\"7\"],\"0$1\"],[\"(\\\\d{4})(\\\\d{7})\",\"$1 $2\",[\"18[68]\"],\"0$1\"],[\"(\\\\d{4})(\\\\d{7})\",\"$1 $2\",[\"15[1279]\"],\"0$1\"],[\"(\\\\d{5})(\\\\d{6})\",\"$1 $2\",[\"15[03568]\",\"15(?:[0568]|3[13])\"],\"0$1\"],[\"(\\\\d{3})(\\\\d{8})\",\"$1 $2\",[\"18\"],\"0$1\"],[\"(\\\\d{3})(\\\\d{2})(\\\\d{7,8})\",\"$1 $2 $3\",[\"1(?:6[023]|7)\"],\"0$1\"],[\"(\\\\d{4})(\\\\d{2})(\\\\d{7})\",\"$1 $2 $3\",[\"15[279]\"],\"0$1\"],[\"(\\\\d{3})(\\\\d{2})(\\\\d{8})\",\"$1 $2 $3\",[\"15\"],\"0$1\"]],\"0\"],\"DJ\":[\"253\",\"00\",\"(?:2\\\\d|77)\\\\d{6}\",[8],[[\"(\\\\d{2})(\\\\d{2})(\\\\d{2})(\\\\d{2})\",\"$1 $2 $3 $4\",[\"[27]\"]]]],\"DK\":[\"45\",\"00\",\"[2-9]\\\\d{7}\",[8],[[\"(\\\\d{2})(\\\\d{2})(\\\\d{2})(\\\\d{2})\",\"$1 $2 $3 $4\",[\"[2-9]\"]]]],\"DM\":[\"1\",\"011\",\"(?:[58]\\\\d\\\\d|767|900)\\\\d{7}\",[10],0,\"1\",0,\"([2-7]\\\\d{6})$|1\",\"767$1\",0,\"767\"],\"DO\":[\"1\",\"011\",\"(?:[58]\\\\d\\\\d|900)\\\\d{7}\",[10],0,\"1\",0,0,0,0,\"8001|8[024]9\"],\"DZ\":[\"213\",\"00\",\"(?:[1-4]|[5-79]\\\\d|80)\\\\d{7}\",[8,9],[[\"(\\\\d{2})(\\\\d{2})(\\\\d{2})(\\\\d{2})\",\"$1 $2 $3 $4\",[\"[1-4]\"],\"0$1\"],[\"(\\\\d{2})(\\\\d{3})(\\\\d{2})(\\\\d{2})\",\"$1 $2 $3 $4\",[\"9\"],\"0$1\"],[\"(\\\\d{3})(\\\\d{2})(\\\\d{2})(\\\\d{2})\",\"$1 $2 $3 $4\",[\"[5-8]\"],\"0$1\"]],\"0\"],\"EC\":[\"593\",\"00\",\"1\\\\d{9,10}|(?:[2-7]|9\\\\d)\\\\d{7}\",[8,9,10,11],[[\"(\\\\d)(\\\\d{3})(\\\\d{4})\",\"$1 $2-$3\",[\"[2-7]\"],\"(0$1)\",0,\"$1-$2-$3\"],[\"(\\\\d{2})(\\\\d{3})(\\\\d{4})\",\"$1 $2 $3\",[\"9\"],\"0$1\"],[\"(\\\\d{4})(\\\\d{3})(\\\\d{3,4})\",\"$1 $2 $3\",[\"1\"]]],\"0\"],\"EE\":[\"372\",\"00\",\"8\\\\d{9}|[4578]\\\\d{7}|(?:[3-8]\\\\d|90)\\\\d{5}\",[7,8,10],[[\"(\\\\d{3})(\\\\d{4})\",\"$1 $2\",[\"[369]|4[3-8]|5(?:[0-2]|5[0-478]|6[45])|7[1-9]|88\",\"[369]|4[3-8]|5(?:[02]|1(?:[0-8]|95)|5[0-478]|6(?:4[0-4]|5[1-589]))|7[1-9]|88\"]],[\"(\\\\d{4})(\\\\d{3,4})\",\"$1 $2\",[\"[45]|8(?:00|[1-49])\",\"[45]|8(?:00[1-9]|[1-49])\"]],[\"(\\\\d{2})(\\\\d{2})(\\\\d{4})\",\"$1 $2 $3\",[\"7\"]],[\"(\\\\d{4})(\\\\d{3})(\\\\d{3})\",\"$1 $2 $3\",[\"8\"]]]],\"EG\":[\"20\",\"00\",\"[189]\\\\d{8,9}|[24-6]\\\\d{8}|[135]\\\\d{7}\",[8,9,10],[[\"(\\\\d)(\\\\d{7,8})\",\"$1 $2\",[\"[23]\"],\"0$1\"],[\"(\\\\d{2})(\\\\d{6,7})\",\"$1 $2\",[\"1[35]|[4-6]|8[2468]|9[235-7]\"],\"0$1\"],[\"(\\\\d{3})(\\\\d{3})(\\\\d{4})\",\"$1 $2 $3\",[\"[89]\"],\"0$1\"],[\"(\\\\d{2})(\\\\d{8})\",\"$1 $2\",[\"1\"],\"0$1\"]],\"0\"],\"EH\":[\"212\",\"00\",\"[5-8]\\\\d{8}\",[9],0,\"0\",0,0,0,0,0,[[\"528[89]\\\\d{5}\"],[\"(?:6(?:[0-79]\\\\d|8[0-247-9])|7(?:[016-8]\\\\d|2[0-8]|5[0-5]))\\\\d{6}\"],[\"80[0-7]\\\\d{6}\"],[\"89\\\\d{7}\"],0,0,0,0,[\"(?:592(?:4[0-2]|93)|80[89]\\\\d\\\\d)\\\\d{4}\"]]],\"ER\":[\"291\",\"00\",\"[178]\\\\d{6}\",[7],[[\"(\\\\d)(\\\\d{3})(\\\\d{3})\",\"$1 $2 $3\",[\"[178]\"],\"0$1\"]],\"0\"],\"ES\":[\"34\",\"00\",\"[5-9]\\\\d{8}\",[9],[[\"(\\\\d{3})(\\\\d{3})(\\\\d{3})\",\"$1 $2 $3\",[\"[89]00\"]],[\"(\\\\d{3})(\\\\d{2})(\\\\d{2})(\\\\d{2})\",\"$1 $2 $3 $4\",[\"[5-9]\"]]]],\"ET\":[\"251\",\"00\",\"(?:11|[2-57-9]\\\\d)\\\\d{7}\",[9],[[\"(\\\\d{2})(\\\\d{3})(\\\\d{4})\",\"$1 $2 $3\",[\"[1-57-9]\"],\"0$1\"]],\"0\"],\"FI\":[\"358\",\"00|99(?:[01469]|5(?:[14]1|3[23]|5[59]|77|88|9[09]))\",\"[1-35689]\\\\d{4}|7\\\\d{10,11}|(?:[124-7]\\\\d|3[0-46-9])\\\\d{8}|[1-9]\\\\d{5,8}\",[5,6,7,8,9,10,11,12],[[\"(\\\\d{5})\",\"$1\",[\"20[2-59]\"],\"0$1\"],[\"(\\\\d{3})(\\\\d{3,7})\",\"$1 $2\",[\"(?:[1-3]0|[68])0|70[07-9]\"],\"0$1\"],[\"(\\\\d{2})(\\\\d{4,8})\",\"$1 $2\",[\"[14]|2[09]|50|7[135]\"],\"0$1\"],[\"(\\\\d{2})(\\\\d{6,10})\",\"$1 $2\",[\"7\"],\"0$1\"],[\"(\\\\d)(\\\\d{4,9})\",\"$1 $2\",[\"(?:19|[2568])[1-8]|3(?:0[1-9]|[1-9])|9\"],\"0$1\"]],\"0\",0,0,0,0,\"1[03-79]|[2-9]\",0,\"00\"],\"FJ\":[\"679\",\"0(?:0|52)\",\"45\\\\d{5}|(?:0800\\\\d|[235-9])\\\\d{6}\",[7,11],[[\"(\\\\d{3})(\\\\d{4})\",\"$1 $2\",[\"[235-9]|45\"]],[\"(\\\\d{4})(\\\\d{3})(\\\\d{4})\",\"$1 $2 $3\",[\"0\"]]],0,0,0,0,0,0,0,\"00\"],\"FK\":[\"500\",\"00\",\"[2-7]\\\\d{4}\",[5]],\"FM\":[\"691\",\"00\",\"(?:[39]\\\\d\\\\d|820)\\\\d{4}\",[7],[[\"(\\\\d{3})(\\\\d{4})\",\"$1 $2\",[\"[389]\"]]]],\"FO\":[\"298\",\"00\",\"[2-9]\\\\d{5}\",[6],[[\"(\\\\d{6})\",\"$1\",[\"[2-9]\"]]],0,0,\"(10(?:01|[12]0|88))\"],\"FR\":[\"33\",\"00\",\"[1-9]\\\\d{8}\",[9],[[\"(\\\\d{3})(\\\\d{2})(\\\\d{2})(\\\\d{2})\",\"$1 $2 $3 $4\",[\"8\"],\"0 $1\"],[\"(\\\\d)(\\\\d{2})(\\\\d{2})(\\\\d{2})(\\\\d{2})\",\"$1 $2 $3 $4 $5\",[\"[1-79]\"],\"0$1\"]],\"0\"],\"GA\":[\"241\",\"00\",\"(?:[067]\\\\d|11)\\\\d{6}|[2-7]\\\\d{6}\",[7,8],[[\"(\\\\d)(\\\\d{2})(\\\\d{2})(\\\\d{2})\",\"$1 $2 $3 $4\",[\"[2-7]\"],\"0$1\"],[\"(\\\\d{2})(\\\\d{2})(\\\\d{2})(\\\\d{2})\",\"$1 $2 $3 $4\",[\"0\"]],[\"(\\\\d{2})(\\\\d{2})(\\\\d{2})(\\\\d{2})\",\"$1 $2 $3 $4\",[\"11|[67]\"],\"0$1\"]],0,0,\"0(11\\\\d{6}|60\\\\d{6}|61\\\\d{6}|6[256]\\\\d{6}|7[467]\\\\d{6})\",\"$1\"],\"GB\":[\"44\",\"00\",\"[1-357-9]\\\\d{9}|[18]\\\\d{8}|8\\\\d{6}\",[7,9,10],[[\"(\\\\d{3})(\\\\d{4})\",\"$1 $2\",[\"800\",\"8001\",\"80011\",\"800111\",\"8001111\"],\"0$1\"],[\"(\\\\d{3})(\\\\d{2})(\\\\d{2})\",\"$1 $2 $3\",[\"845\",\"8454\",\"84546\",\"845464\"],\"0$1\"],[\"(\\\\d{3})(\\\\d{6})\",\"$1 $2\",[\"800\"],\"0$1\"],[\"(\\\\d{5})(\\\\d{4,5})\",\"$1 $2\",[\"1(?:38|5[23]|69|76|94)\",\"1(?:(?:38|69)7|5(?:24|39)|768|946)\",\"1(?:3873|5(?:242|39[4-6])|(?:697|768)[347]|9467)\"],\"0$1\"],[\"(\\\\d{4})(\\\\d{5,6})\",\"$1 $2\",[\"1(?:[2-69][02-9]|[78])\"],\"0$1\"],[\"(\\\\d{2})(\\\\d{4})(\\\\d{4})\",\"$1 $2 $3\",[\"[25]|7(?:0|6[02-9])\",\"[25]|7(?:0|6(?:[03-9]|2[356]))\"],\"0$1\"],[\"(\\\\d{4})(\\\\d{6})\",\"$1 $2\",[\"7\"],\"0$1\"],[\"(\\\\d{3})(\\\\d{3})(\\\\d{4})\",\"$1 $2 $3\",[\"[1389]\"],\"0$1\"]],\"0\",0,\"0|180020\",0,0,0,[[\"(?:1(?:1(?:3(?:[0-58]\\\\d\\\\d|73[0-5])|4(?:(?:[0-5]\\\\d|70)\\\\d|69[7-9])|(?:(?:5[0-26-9]|[78][0-49])\\\\d|6(?:[0-4]\\\\d|5[01]))\\\\d)|(?:2(?:(?:0[024-9]|2[3-9]|3[3-79]|4[1-689]|[58][02-9]|6[0-47-9]|7[013-9]|9\\\\d)\\\\d|1(?:[0-7]\\\\d|8[0-3]))|(?:3(?:0\\\\d|1[0-8]|[25][02-9]|3[02-579]|[468][0-46-9]|7[1-35-79]|9[2-578])|4(?:0[03-9]|[137]\\\\d|[28][02-57-9]|4[02-69]|5[0-8]|[69][0-79])|5(?:0[1-35-9]|[16]\\\\d|2[024-9]|3[015689]|4[02-9]|5[03-9]|7[0-35-9]|8[0-468]|9[0-57-9])|6(?:0[034689]|1\\\\d|2[0-35689]|[38][013-9]|4[1-467]|5[0-69]|6[13-9]|7[0-8]|9[0-24578])|7(?:0[0246-9]|2\\\\d|3[0236-8]|4[03-9]|5[0-46-9]|6[013-9]|7[0-35-9]|8[024-9]|9[02-9])|8(?:0[35-9]|2[1-57-9]|3[02-578]|4[0-578]|5[124-9]|6[2-69]|7\\\\d|8[02-9]|9[02569])|9(?:0[02-589]|[18]\\\\d|2[02-689]|3[1-57-9]|4[2-9]|5[0-579]|6[2-47-9]|7[0-24578]|9[2-57]))\\\\d)\\\\d)|2(?:0[013478]|3[0189]|4[017]|8[0-46-9]|9[0-2])\\\\d{3})\\\\d{4}|1(?:2(?:0(?:46[1-4]|87[2-9])|545[1-79]|76(?:2\\\\d|3[1-8]|6[1-6])|9(?:7(?:2[0-4]|3[2-5])|8(?:2[2-8]|7[0-47-9]|8[3-5])))|3(?:6(?:38[2-5]|47[23])|8(?:47[04-9]|64[0157-9]))|4(?:044[1-7]|20(?:2[23]|8\\\\d)|6(?:0(?:30|5[2-57]|6[1-8]|7[2-8])|140)|8(?:052|87[1-3]))|5(?:2(?:4(?:3[2-79]|6\\\\d)|76\\\\d)|6(?:26[06-9]|686))|6(?:06(?:4\\\\d|7[4-79])|295[5-7]|35[34]\\\\d|47(?:24|61)|59(?:5[08]|6[67]|74)|9(?:55[0-4]|77[23]))|7(?:26(?:6[13-9]|7[0-7])|(?:442|688)\\\\d|50(?:2[0-3]|[3-68]2|76))|8(?:27[56]\\\\d|37(?:5[2-5]|8[239])|843[2-58])|9(?:0(?:0(?:6[1-8]|85)|52\\\\d)|3583|4(?:66[1-8]|9(?:2[01]|81))|63(?:23|3[1-4])|9561))\\\\d{3}\",[9,10]],[\"7(?:457[0-57-9]|700[01]|911[028])\\\\d{5}|7(?:[1-3]\\\\d\\\\d|4(?:[0-46-9]\\\\d|5[0-689])|5(?:0[0-8]|[13-9]\\\\d|2[0-35-9])|7(?:0[1-9]|[1-7]\\\\d|8[02-9]|9[0-689])|8(?:[014-9]\\\\d|[23][0-8])|9(?:[024-9]\\\\d|1[02-9]|3[0-689]))\\\\d{6}\",[10]],[\"80[08]\\\\d{7}|800\\\\d{6}|8001111\"],[\"(?:8(?:4[2-5]|7[0-3])|9(?:[01]\\\\d|8[2-49]))\\\\d{7}|845464\\\\d\",[7,10]],[\"70\\\\d{8}\",[10]],0,[\"(?:3[0347]|55)\\\\d{8}\",[10]],[\"76(?:464|652)\\\\d{5}|76(?:0[0-28]|2[356]|34|4[01347]|5[49]|6[0-369]|77|8[14]|9[139])\\\\d{6}\",[10]],[\"56\\\\d{8}\",[10]]],0,\" x\"],\"GD\":[\"1\",\"011\",\"(?:473|[58]\\\\d\\\\d|900)\\\\d{7}\",[10],0,\"1\",0,\"([2-9]\\\\d{6})$|1\",\"473$1\",0,\"473\"],\"GE\":[\"995\",\"00\",\"(?:[3-57]\\\\d\\\\d|800)\\\\d{6}\",[9],[[\"(\\\\d{3})(\\\\d{3})(\\\\d{3})\",\"$1 $2 $3\",[\"70\"],\"0$1\"],[\"(\\\\d{2})(\\\\d{3})(\\\\d{2})(\\\\d{2})\",\"$1 $2 $3 $4\",[\"32\"],\"0$1\"],[\"(\\\\d{3})(\\\\d{2})(\\\\d{2})(\\\\d{2})\",\"$1 $2 $3 $4\",[\"[57]\"]],[\"(\\\\d{3})(\\\\d{2})(\\\\d{2})(\\\\d{2})\",\"$1 $2 $3 $4\",[\"[348]\"],\"0$1\"]],\"0\"],\"GF\":[\"594\",\"00\",\"(?:694\\\\d|7093)\\\\d{5}|(?:59|[89]\\\\d)\\\\d{7}\",[9],[[\"(\\\\d{3})(\\\\d{2})(\\\\d{2})(\\\\d{2})\",\"$1 $2 $3 $4\",[\"[5-7]|80[6-9]|9[47]\"],\"0$1\"],[\"(\\\\d{3})(\\\\d{2})(\\\\d{2})(\\\\d{2})\",\"$1 $2 $3 $4\",[\"[89]\"],\"0$1\"]],\"0\"],\"GG\":[\"44\",\"00\",\"(?:1481|[357-9]\\\\d{3})\\\\d{6}|8\\\\d{6}(?:\\\\d{2})?\",[7,9,10],0,\"0\",0,\"([25-9]\\\\d{5})$|0|180020\",\"1481$1\",0,0,[[\"1481[25-9]\\\\d{5}\",[10]],[\"7(?:(?:781|839)\\\\d|911[17])\\\\d{5}\",[10]],[\"80[08]\\\\d{7}|800\\\\d{6}|8001111\"],[\"(?:8(?:4[2-5]|7[0-3])|9(?:[01]\\\\d|8[0-3]))\\\\d{7}|845464\\\\d\",[7,10]],[\"70\\\\d{8}\",[10]],0,[\"(?:3[0347]|55)\\\\d{8}\",[10]],[\"76(?:464|652)\\\\d{5}|76(?:0[0-28]|2[356]|34|4[01347]|5[49]|6[0-369]|77|8[14]|9[139])\\\\d{6}\",[10]],[\"56\\\\d{8}\",[10]]]],\"GH\":[\"233\",\"00\",\"[235]\\\\d{8}|800\\\\d{5,6}\",[8,9],[[\"(\\\\d{3})(\\\\d{5})\",\"$1 $2\",[\"8\"],\"0$1\"],[\"(\\\\d{2})(\\\\d{3})(\\\\d{4})\",\"$1 $2 $3\",[\"[2358]\"],\"0$1\"]],\"0\"],\"GI\":[\"350\",\"00\",\"(?:[25]\\\\d|60)\\\\d{6}\",[8],[[\"(\\\\d{3})(\\\\d{5})\",\"$1 $2\",[\"2\"]]]],\"GL\":[\"299\",\"00\",\"(?:19|[2-689]\\\\d|70)\\\\d{4}\",[6],[[\"(\\\\d{2})(\\\\d{2})(\\\\d{2})\",\"$1 $2 $3\",[\"19|[2-9]\"]]]],\"GM\":[\"220\",\"00\",\"[2-9]\\\\d{6}\",[7],[[\"(\\\\d{3})(\\\\d{4})\",\"$1 $2\",[\"[2-9]\"]]]],\"GN\":[\"224\",\"00\",\"722\\\\d{6}|(?:3|6\\\\d)\\\\d{7}\",[8,9],[[\"(\\\\d{2})(\\\\d{2})(\\\\d{2})(\\\\d{2})\",\"$1 $2 $3 $4\",[\"3\"]],[\"(\\\\d{3})(\\\\d{2})(\\\\d{2})(\\\\d{2})\",\"$1 $2 $3 $4\",[\"[67]\"]]]],\"GP\":[\"590\",\"00\",\"7090\\\\d{5}|(?:[56]9|[89]\\\\d)\\\\d{7}\",[9],[[\"(\\\\d{3})(\\\\d{2})(\\\\d{2})(\\\\d{2})\",\"$1 $2 $3 $4\",[\"[5-79]|80[6-9]\"],\"0$1\"],[\"(\\\\d{3})(\\\\d{2})(\\\\d{2})(\\\\d{2})\",\"$1 $2 $3 $4\",[\"8\"],\"0$1\"]],\"0\",0,0,0,0,0,[[\"(?:59(?:0(?:0[1-68]|[14][0-24-9]|2[0-68]|3[1-9]|5[3-579]|[68][0-689]|7[08]|9\\\\d)|87\\\\d)|80[6-9]\\\\d\\\\d)\\\\d{4}\"],[\"(?:69(?:0\\\\d\\\\d|1(?:2[2-9]|3[0-5]))|7090[0-4])\\\\d{4}\"],[\"80[0-5]\\\\d{6}\"],[\"8[129]\\\\d{7}\"],0,0,0,0,[\"9(?:(?:39[5-7]|76[018])\\\\d|475[0-6])\\\\d{4}\"]]],\"GQ\":[\"240\",\"00\",\"222\\\\d{6}|(?:3\\\\d|55|[89]0)\\\\d{7}\",[9],[[\"(\\\\d{3})(\\\\d{3})(\\\\d{3})\",\"$1 $2 $3\",[\"[235]\"]],[\"(\\\\d{3})(\\\\d{6})\",\"$1 $2\",[\"[89]\"]]]],\"GR\":[\"30\",\"00\",\"5005000\\\\d{3}|8\\\\d{9,11}|(?:[269]\\\\d|70)\\\\d{8}\",[10,11,12],[[\"(\\\\d{2})(\\\\d{4})(\\\\d{4})\",\"$1 $2 $3\",[\"21|7\"]],[\"(\\\\d{4})(\\\\d{6})\",\"$1 $2\",[\"2(?:2|3[2-57-9]|4[2-469]|5[2-59]|6[2-9]|7[2-69]|8[2-49])|5\"]],[\"(\\\\d{3})(\\\\d{3})(\\\\d{4})\",\"$1 $2 $3\",[\"[2689]\"]],[\"(\\\\d{3})(\\\\d{3,4})(\\\\d{5})\",\"$1 $2 $3\",[\"8\"]]]],\"GT\":[\"502\",\"00\",\"80\\\\d{6}|(?:1\\\\d{3}|[2-7])\\\\d{7}\",[8,11],[[\"(\\\\d{4})(\\\\d{4})\",\"$1 $2\",[\"[2-8]\"]],[\"(\\\\d{4})(\\\\d{3})(\\\\d{4})\",\"$1 $2 $3\",[\"1\"]]]],\"GU\":[\"1\",\"011\",\"(?:[58]\\\\d\\\\d|671|900)\\\\d{7}\",[10],0,\"1\",0,\"([2-9]\\\\d{6})$|1\",\"671$1\",0,\"671\"],\"GW\":[\"245\",\"00\",\"[49]\\\\d{8}|4\\\\d{6}\",[7,9],[[\"(\\\\d{3})(\\\\d{4})\",\"$1 $2\",[\"40\"]],[\"(\\\\d{3})(\\\\d{3})(\\\\d{3})\",\"$1 $2 $3\",[\"[49]\"]]]],\"GY\":[\"592\",\"001\",\"(?:[2-8]\\\\d{3}|9008)\\\\d{3}\",[7],[[\"(\\\\d{3})(\\\\d{4})\",\"$1 $2\",[\"[2-9]\"]]]],\"HK\":[\"852\",\"00(?:30|5[09]|[126-9]?)\",\"8[0-46-9]\\\\d{6,7}|9\\\\d{4,7}|(?:[2-7]|9\\\\d{3})\\\\d{7}\",[5,6,7,8,9,11],[[\"(\\\\d{3})(\\\\d{2,5})\",\"$1 $2\",[\"900\",\"9003\"]],[\"(\\\\d{4})(\\\\d{4})\",\"$1 $2\",[\"[2-7]|8[1-4]|9(?:0[1-9]|[1-8])\"]],[\"(\\\\d{3})(\\\\d{3})(\\\\d{3})\",\"$1 $2 $3\",[\"8\"]],[\"(\\\\d{3})(\\\\d{2})(\\\\d{3})(\\\\d{3})\",\"$1 $2 $3 $4\",[\"9\"]]],0,0,0,0,0,0,0,\"00\"],\"HN\":[\"504\",\"00\",\"8\\\\d{10}|[237-9]\\\\d{7}\",[8,11],[[\"(\\\\d{4})(\\\\d{4})\",\"$1-$2\",[\"[237-9]\"]]]],\"HR\":[\"385\",\"00\",\"[2-69]\\\\d{8}|80\\\\d{5,7}|[1-79]\\\\d{7}|6\\\\d{6}\",[7,8,9],[[\"(\\\\d{2})(\\\\d{2})(\\\\d{3})\",\"$1 $2 $3\",[\"6[01]\"],\"0$1\"],[\"(\\\\d{3})(\\\\d{2})(\\\\d{2,3})\",\"$1 $2 $3\",[\"8\"],\"0$1\"],[\"(\\\\d)(\\\\d{4})(\\\\d{3})\",\"$1 $2 $3\",[\"1\"],\"0$1\"],[\"(\\\\d{2})(\\\\d{3})(\\\\d{3,4})\",\"$1 $2 $3\",[\"6|7[245]\"],\"0$1\"],[\"(\\\\d{2})(\\\\d{3})(\\\\d{3,4})\",\"$1 $2 $3\",[\"9\"],\"0$1\"],[\"(\\\\d{2})(\\\\d{3})(\\\\d{3,4})\",\"$1 $2 $3\",[\"[2-57]\"],\"0$1\"],[\"(\\\\d{3})(\\\\d{3})(\\\\d{3})\",\"$1 $2 $3\",[\"8\"],\"0$1\"]],\"0\"],\"HT\":[\"509\",\"00\",\"[2-589]\\\\d{7}\",[8],[[\"(\\\\d{2})(\\\\d{2})(\\\\d{4})\",\"$1 $2 $3\",[\"[2-589]\"]]]],\"HU\":[\"36\",\"00\",\"[235-7]\\\\d{8}|[1-9]\\\\d{7}\",[8,9],[[\"(\\\\d)(\\\\d{3})(\\\\d{4})\",\"$1 $2 $3\",[\"1\"],\"(06 $1)\"],[\"(\\\\d{2})(\\\\d{3})(\\\\d{3})\",\"$1 $2 $3\",[\"[27][2-9]|3[2-7]|4[24-9]|5[2-79]|6|8[2-57-9]|9[2-69]\"],\"(06 $1)\"],[\"(\\\\d{2})(\\\\d{3})(\\\\d{3,4})\",\"$1 $2 $3\",[\"[2-9]\"],\"06 $1\"]],\"06\"],\"ID\":[\"62\",\"00[89]\",\"00[1-9]\\\\d{9,14}|(?:[1-36]|8\\\\d{5})\\\\d{6}|00\\\\d{9}|[1-9]\\\\d{8,10}|[2-9]\\\\d{7}\",[7,8,9,10,11,12,13,14,15,16,17],[[\"(\\\\d)(\\\\d{3})(\\\\d{3})\",\"$1 $2 $3\",[\"15\"]],[\"(\\\\d{2})(\\\\d{5,9})\",\"$1 $2\",[\"2[124]|[36]1\"],\"(0$1)\"],[\"(\\\\d{3})(\\\\d{5,7})\",\"$1 $2\",[\"800\"],\"0$1\"],[\"(\\\\d{3})(\\\\d{5,8})\",\"$1 $2\",[\"[2-79]\"],\"(0$1)\"],[\"(\\\\d{3})(\\\\d{3,4})(\\\\d{3})\",\"$1-$2-$3\",[\"8[1-35-9]\"],\"0$1\"],[\"(\\\\d{3})(\\\\d{6,8})\",\"$1 $2\",[\"1\"],\"0$1\"],[\"(\\\\d{3})(\\\\d{3})(\\\\d{4})\",\"$1 $2 $3\",[\"804\"],\"0$1\"],[\"(\\\\d{3})(\\\\d)(\\\\d{3})(\\\\d{3})\",\"$1 $2 $3 $4\",[\"80\"],\"0$1\"],[\"(\\\\d{3})(\\\\d{4})(\\\\d{4,5})\",\"$1-$2-$3\",[\"8\"],\"0$1\"]],\"0\"],\"IE\":[\"353\",\"00\",\"(?:1\\\\d|[2569])\\\\d{6,8}|4\\\\d{6,9}|7\\\\d{8}|8\\\\d{8,9}\",[7,8,9,10],[[\"(\\\\d{2})(\\\\d{5})\",\"$1 $2\",[\"2[24-9]|47|58|6[237-9]|9[35-9]\"],\"(0$1)\"],[\"(\\\\d{3})(\\\\d{5})\",\"$1 $2\",[\"[45]0\"],\"(0$1)\"],[\"(\\\\d)(\\\\d{3,4})(\\\\d{4})\",\"$1 $2 $3\",[\"1\"],\"(0$1)\"],[\"(\\\\d{2})(\\\\d{3})(\\\\d{3,4})\",\"$1 $2 $3\",[\"[2569]|4[1-69]|7[14]\"],\"(0$1)\"],[\"(\\\\d{3})(\\\\d{3})(\\\\d{3})\",\"$1 $2 $3\",[\"70\"],\"0$1\"],[\"(\\\\d{3})(\\\\d{3})(\\\\d{3})\",\"$1 $2 $3\",[\"81\"],\"(0$1)\"],[\"(\\\\d{2})(\\\\d{3})(\\\\d{4})\",\"$1 $2 $3\",[\"[78]\"],\"0$1\"],[\"(\\\\d{4})(\\\\d{3})(\\\\d{3})\",\"$1 $2 $3\",[\"1\"]],[\"(\\\\d{2})(\\\\d{4})(\\\\d{4})\",\"$1 $2 $3\",[\"4\"],\"(0$1)\"],[\"(\\\\d{2})(\\\\d)(\\\\d{3})(\\\\d{4})\",\"$1 $2 $3 $4\",[\"8\"],\"0$1\"]],\"0\"],\"IL\":[\"972\",\"0(?:0|1[2-9])\",\"1\\\\d{6}(?:\\\\d{3,5})?|[57]\\\\d{8}|[1-489]\\\\d{7}\",[7,8,9,10,11,12],[[\"(\\\\d{4})(\\\\d{3})\",\"$1-$2\",[\"125\"]],[\"(\\\\d{4})(\\\\d{2})(\\\\d{2})\",\"$1-$2-$3\",[\"121\"]],[\"(\\\\d)(\\\\d{3})(\\\\d{4})\",\"$1-$2-$3\",[\"[2-489]\"],\"0$1\"],[\"(\\\\d{2})(\\\\d{3})(\\\\d{4})\",\"$1-$2-$3\",[\"[57]\"],\"0$1\"],[\"(\\\\d{4})(\\\\d{3})(\\\\d{3})\",\"$1-$2-$3\",[\"12\"]],[\"(\\\\d{4})(\\\\d{6})\",\"$1-$2\",[\"159\"]],[\"(\\\\d)(\\\\d{3})(\\\\d{3})(\\\\d{3})\",\"$1-$2-$3-$4\",[\"1[7-9]\"]],[\"(\\\\d{3})(\\\\d{1,2})(\\\\d{3})(\\\\d{4})\",\"$1-$2 $3-$4\",[\"15\"]]],\"0\"],\"IM\":[\"44\",\"00\",\"1624\\\\d{6}|(?:[3578]\\\\d|90)\\\\d{8}\",[10],0,\"0\",0,\"([25-8]\\\\d{5})$|0|180020\",\"1624$1\",0,\"74576|(?:16|7[56])24\"],\"IN\":[\"91\",\"00\",\"(?:000800|[2-9]\\\\d\\\\d)\\\\d{7}|1\\\\d{7,12}\",[8,9,10,11,12,13],[[\"(\\\\d{8})\",\"$1\",[\"5(?:0|2[23]|3[03]|[67]1|88)\",\"5(?:0|2(?:21|3)|3(?:0|3[23])|616|717|888)\",\"5(?:0|2(?:21|3)|3(?:0|3[23])|616|717|8888)\"],0,1],[\"(\\\\d{4})(\\\\d{4,5})\",\"$1 $2\",[\"180\",\"1800\"],0,1],[\"(\\\\d{3})(\\\\d{3})(\\\\d{4})\",\"$1 $2 $3\",[\"140\"],0,1],[\"(\\\\d{2})(\\\\d{4})(\\\\d{4})\",\"$1 $2 $3\",[\"11|2[02]|33|4[04]|79[1-7]|80[2-46]\",\"11|2[02]|33|4[04]|79(?:[1-6]|7[19])|80(?:[2-4]|6[0-589])\",\"11|2[02]|33|4[04]|79(?:[124-6]|3(?:[02-9]|1[0-24-9])|7(?:1|9[1-6]))|80(?:[2-4]|6[0-589])\"],\"0$1\",1],[\"(\\\\d{3})(\\\\d{3})(\\\\d{4})\",\"$1 $2 $3\",[\"1(?:2[0-249]|3[0-25]|4[145]|[68]|7[1257])|2(?:1[257]|3[013]|4[01]|5[0137]|6[0158]|78|8[1568])|3(?:26|4[1-3]|5[34]|6[01489]|7[02-46]|8[159])|4(?:1[36]|2[1-47]|5[12]|6[0-26-9]|7[0-24-9]|8[013-57]|9[014-7])|5(?:1[025]|22|[36][25]|4[28]|5[12]|[78]1)|6(?:12|[2-4]1|5[17]|6[13]|80)|7(?:12|3[134]|61|88)|8(?:16|2[014]|3[126]|6[136]|7[078]|8[34]|91)|(?:43|59|75)[15]|(?:1[59]|29|67)[14]\",\"1(?:2[0-24]|3[0-25]|4[145]|[59][14]|6[1-9]|7[1257]|8[1-57-9])|2(?:1[257]|3[013]|4[01]|5[0137]|6[058]|78|8[1568]|9[14])|3(?:26|4[1-3]|5[34]|6[01489]|7[02-46]|8[159])|4(?:1[36]|2[1-47]|3[15]|5[12]|6[0-26-9]|7[0-24-9]|8[013-57]|9[014-7])|5(?:1[025]|22|[36][25]|4[28]|[578]1|9[15])|674|7(?:(?:3[34]|5[15])[2-6]|61[346]|88[0-8])|8(?:70[2-6]|84[235-7]|91[3-7])|(?:1(?:29|60|8[06])|261|552|6(?:12|[2-47]1|5[17]|6[13]|80)|7(?:12|31)|8(?:16|2[014]|3[126]|6[136]|7[78]|83))[2-7]\",\"1(?:2[0-24]|3[0-25]|4[145]|[59][14]|6[1-9]|7[1257]|8[1-57-9])|2(?:1[257]|3[013]|4[01]|5[0137]|6[058]|78|8[1568]|9[14])|3(?:26|4[1-3]|5[34]|6[01489]|7[02-46]|8[159])|4(?:1[36]|2[1-47]|3[15]|5[12]|6[0-26-9]|7[0-24-9]|8[013-57]|9[014-7])|5(?:1[025]|22|[36][25]|4[28]|[578]1|9[15])|6(?:12(?:[2-6]|7[0-8])|74[2-7])|7(?:3171|5[15][2-6]|61[346]|88(?:[2-7]|82))|8(?:70[2-6]|84(?:[2356]|7[19])|91(?:[3-6]|7[19]))|73[134][2-6]|8(?:16|2[014]|3[126]|6[136]|7[78]|83)(?:[2-6]|7[19])|(?:1(?:29|60|8[06])|261|552|6(?:[2-4]1|5[17]|6[13]|7(?:1|4[0189])|80)|7(?:12|88[01]))[2-7]\"],\"0$1\",1],[\"(\\\\d{4})(\\\\d{3})(\\\\d{3})\",\"$1 $2 $3\",[\"1(?:[2-479]|5[0235-9])|[2-5]|6(?:1[1358]|2[2457-9]|3[2-5]|4[235-7]|5[2-689]|6[24578]|7[235689]|8[1-6])|7(?:1[013-9]|3[129]|5[29]|6[02-5]|70)|807\",\"1(?:[2-479]|5[0235-9])|[2-5]|6(?:1[1358]|2(?:[2457]|84|95)|3(?:[2-4]|55)|4[235-7]|5[2-689]|6[24578]|7(?:[23569]|8[0-57-9])|8[1-6])|7(?:1(?:[013-8]|9[6-9])|3(?:17|2[0-49]|9[2-57])|5(?:2[1-3]|9[0-6])|6(?:0[5689]|2[5-9]|3[02-8]|4|5[0-367])|70[13-7])|807[19]\",\"1(?:[2-479]|5(?:[0236-9]|5[013-9]))|[2-5]|6(?:2(?:84|95)|355|8(?:28[235-7]|3))|73179|807(?:1|9[1-3])|(?:1552|6(?:(?:1[1358]|2[2457]|3[2-4]|4[235-7]|5[2-689]|6[24578])\\\\d|7(?:[23569]\\\\d|8[0-57-9])|8(?:[14-6]\\\\d|2[0-79]))|7(?:1(?:[013-8]\\\\d|9[6-9])|3(?:2[0-49]|9[2-57])|5(?:2[1-3]|9[0-6])|6(?:0[5689]|2[5-9]|3[02-8]|4\\\\d|5[0-367])|70[13-7]))[2-7]\"],\"0$1\",1],[\"(\\\\d{5})(\\\\d{5})\",\"$1 $2\",[\"16|[6-9]\"],\"0$1\",1],[\"(\\\\d{4})(\\\\d{2,4})(\\\\d{4})\",\"$1 $2 $3\",[\"18[06]\",\"18[06]0\"],0,1],[\"(\\\\d{4})(\\\\d{3})(\\\\d{3})(\\\\d{3})\",\"$1 $2 $3 $4\",[\"18\"],0,1]],\"0\"],\"IO\":[\"246\",\"00\",\"3\\\\d{6}\",[7],[[\"(\\\\d{3})(\\\\d{4})\",\"$1 $2\",[\"3\"]]]],\"IQ\":[\"964\",\"00\",\"(?:1|7\\\\d\\\\d)\\\\d{7}|[2-6]\\\\d{7,8}\",[8,9,10],[[\"(\\\\d)(\\\\d{3})(\\\\d{4})\",\"$1 $2 $3\",[\"1\"],\"0$1\"],[\"(\\\\d{2})(\\\\d{3})(\\\\d{3,4})\",\"$1 $2 $3\",[\"[2-6]\"],\"0$1\"],[\"(\\\\d{3})(\\\\d{3})(\\\\d{4})\",\"$1 $2 $3\",[\"7\"],\"0$1\"]],\"0\"],\"IR\":[\"98\",\"00\",\"[1-9]\\\\d{9}|(?:[1-8]\\\\d\\\\d|9)\\\\d{3,4}\",[4,5,6,7,10],[[\"(\\\\d{4,5})\",\"$1\",[\"96\"],\"0$1\"],[\"(\\\\d{2})(\\\\d{4,5})\",\"$1 $2\",[\"(?:1[137]|2[13-68]|3[1458]|4[145]|5[1468]|6[16]|7[1467]|8[13467])[12689]\"],\"0$1\"],[\"(\\\\d{3})(\\\\d{3})(\\\\d{3,4})\",\"$1 $2 $3\",[\"9\"],\"0$1\"],[\"(\\\\d{2})(\\\\d{4})(\\\\d{4})\",\"$1 $2 $3\",[\"[1-8]\"],\"0$1\"]],\"0\"],\"IS\":[\"354\",\"00|1(?:0(?:01|[12]0)|100)\",\"(?:38\\\\d|[4-9])\\\\d{6}\",[7,9],[[\"(\\\\d{3})(\\\\d{4})\",\"$1 $2\",[\"[4-9]\"]],[\"(\\\\d{3})(\\\\d{3})(\\\\d{3})\",\"$1 $2 $3\",[\"3\"]]],0,0,0,0,0,0,0,\"00\"],\"IT\":[\"39\",\"00\",\"0\\\\d{5,11}|1\\\\d{8,10}|3(?:[0-8]\\\\d{7,10}|9\\\\d{7,8})|(?:43|55|70)\\\\d{8}|8\\\\d{5}(?:\\\\d{2,4})?\",[6,7,8,9,10,11,12],[[\"(\\\\d{2})(\\\\d{4,6})\",\"$1 $2\",[\"0[26]\"]],[\"(\\\\d{3})(\\\\d{3,6})\",\"$1 $2\",[\"0[13-57-9][0159]|8(?:03|4[17]|9[2-5])\",\"0[13-57-9][0159]|8(?:03|4[17]|9(?:2|3[04]|[45][0-4]))\"]],[\"(\\\\d{4})(\\\\d{2,6})\",\"$1 $2\",[\"0(?:[13-579][2-46-8]|8[236-8])\"]],[\"(\\\\d{4})(\\\\d{4})\",\"$1 $2\",[\"894\"]],[\"(\\\\d{2})(\\\\d{3,4})(\\\\d{4})\",\"$1 $2 $3\",[\"0[26]|5\"]],[\"(\\\\d{3})(\\\\d{3})(\\\\d{3,4})\",\"$1 $2 $3\",[\"1(?:44|[679])|[378]|43\"]],[\"(\\\\d{3})(\\\\d{3,4})(\\\\d{4})\",\"$1 $2 $3\",[\"0[13-57-9][0159]|14\"]],[\"(\\\\d{2})(\\\\d{4})(\\\\d{5})\",\"$1 $2 $3\",[\"0[26]\"]],[\"(\\\\d{4})(\\\\d{3})(\\\\d{4})\",\"$1 $2 $3\",[\"0\"]],[\"(\\\\d{3})(\\\\d{4})(\\\\d{4,5})\",\"$1 $2 $3\",[\"[03]\"]]],0,0,0,0,0,0,[[\"0(?:669[0-79]\\\\d{1,6}|831\\\\d{2,8})|0(?:1(?:[0159]\\\\d|[27][1-5]|31|4[1-4]|6[1356]|8[2-57])|2\\\\d\\\\d|3(?:[0159]\\\\d|2[1-4]|3[12]|[48][1-6]|6[2-59]|7[1-7])|4(?:[0159]\\\\d|[23][1-9]|4[245]|6[1-5]|7[1-4]|81)|5(?:[0159]\\\\d|2[1-5]|3[2-6]|4[1-79]|6[4-6]|7[1-578]|8[3-8])|6(?:[0-57-9]\\\\d|6[0-8])|7(?:[0159]\\\\d|2[12]|3[1-7]|4[2-46]|6[13569]|7[13-6]|8[1-59])|8(?:[0159]\\\\d|2[3-578]|3[2356]|[6-8][1-5])|9(?:[0159]\\\\d|[238][1-5]|4[12]|6[1-8]|7[1-6]))\\\\d{2,7}\"],[\"3[2-9]\\\\d{7,8}|(?:31|43)\\\\d{8}\",[9,10]],[\"80(?:0\\\\d{3}|3)\\\\d{3}\",[6,9]],[\"(?:0878\\\\d{3}|89(?:2\\\\d|3[04]|4(?:[0-4]|[5-9]\\\\d\\\\d)|5[0-4]))\\\\d\\\\d|(?:1(?:44|6[346])|89(?:38|5[5-9]|9))\\\\d{6}\",[6,8,9,10]],[\"1(?:78\\\\d|99)\\\\d{6}\",[9,10]],[\"3[2-8]\\\\d{9,10}\",[11,12]],0,0,[\"55\\\\d{8}\",[10]],[\"84(?:[08]\\\\d{3}|[17])\\\\d{3}\",[6,9]]]],\"JE\":[\"44\",\"00\",\"1534\\\\d{6}|(?:[3578]\\\\d|90)\\\\d{8}\",[10],0,\"0\",0,\"([0-24-8]\\\\d{5})$|0|180020\",\"1534$1\",0,0,[[\"1534[0-24-8]\\\\d{5}\"],[\"7(?:(?:(?:50|82)9|937)\\\\d|7(?:00[378]|97\\\\d))\\\\d{5}\"],[\"80(?:07(?:35|81)|8901)\\\\d{4}\"],[\"(?:8(?:4(?:4(?:4(?:05|42|69)|703)|5(?:041|800))|7(?:0002|1206))|90(?:066[59]|1810|71(?:07|55)))\\\\d{4}\"],[\"701511\\\\d{4}\"],0,[\"(?:3(?:0(?:07(?:35|81)|8901)|3\\\\d{4}|4(?:4(?:4(?:05|42|69)|703)|5(?:041|800))|7(?:0002|1206))|55\\\\d{4})\\\\d{4}\"],[\"76(?:464|652)\\\\d{5}|76(?:0[0-28]|2[356]|34|4[01347]|5[49]|6[0-369]|77|8[14]|9[139])\\\\d{6}\"],[\"56\\\\d{8}\"]]],\"JM\":[\"1\",\"011\",\"(?:[58]\\\\d\\\\d|658|900)\\\\d{7}\",[10],0,\"1\",0,0,0,0,\"658|876\"],\"JO\":[\"962\",\"00\",\"(?:(?:[2689]|7\\\\d)\\\\d|32|427|53)\\\\d{6}\",[8,9],[[\"(\\\\d)(\\\\d{3})(\\\\d{4})\",\"$1 $2 $3\",[\"[2356]|87\"],\"(0$1)\"],[\"(\\\\d{3})(\\\\d{5,6})\",\"$1 $2\",[\"[89]\"],\"0$1\"],[\"(\\\\d{2})(\\\\d{7})\",\"$1 $2\",[\"70\"],\"0$1\"],[\"(\\\\d)(\\\\d{4})(\\\\d{4})\",\"$1 $2 $3\",[\"[47]\"],\"0$1\"]],\"0\"],\"JP\":[\"81\",\"010\",\"00[1-9]\\\\d{6,14}|[25-9]\\\\d{9}|(?:00|[1-9]\\\\d\\\\d)\\\\d{6}\",[8,9,10,11,12,13,14,15,16,17],[[\"(\\\\d{3})(\\\\d{3})(\\\\d{3})\",\"$1-$2-$3\",[\"(?:12|57|99)0\"],\"0$1\"],[\"(\\\\d{4})(\\\\d)(\\\\d{4})\",\"$1-$2-$3\",[\"1(?:26|3[79]|4[56]|5[4-68]|6[3-5])|499|5(?:76|97)|746|8(?:3[89]|47|51)|9(?:80|9[16])\",\"1(?:267|3(?:7[247]|9[278])|466|5(?:47|58|64)|6(?:3[245]|48|5[4-68]))|499[2468]|5(?:76|97)9|7468|8(?:3(?:8[7-9]|96)|477|51[2-9])|9(?:802|9(?:1[23]|69))|1(?:45|58)[67]\",\"1(?:267|3(?:7[247]|9[278])|466|5(?:47|58|64)|6(?:3[245]|48|5[4-68]))|499[2468]|5(?:769|979[2-69])|7468|8(?:3(?:8[7-9]|96[2457-9])|477|51[2-9])|9(?:802|9(?:1[23]|69))|1(?:45|58)[67]\"],\"0$1\"],[\"(\\\\d{2})(\\\\d{3})(\\\\d{4})\",\"$1-$2-$3\",[\"60\"],\"0$1\"],[\"(\\\\d)(\\\\d{4})(\\\\d{4})\",\"$1-$2-$3\",[\"3|4(?:2[09]|7[01])|6[1-9]\",\"3|4(?:2(?:0|9[02-69])|7(?:0[019]|1))|6[1-9]\"],\"0$1\"],[\"(\\\\d{2})(\\\\d{3})(\\\\d{4})\",\"$1-$2-$3\",[\"1(?:1|5[45]|77|88|9[69])|2(?:2[1-37]|3[0-269]|4[59]|5|6[24]|7[1-358]|8[1369]|9[0-38])|4(?:[28][1-9]|3[0-57]|[45]|6[248]|7[2-579]|9[29])|5(?:2|3[0459]|4[0-369]|5[29]|8[02389]|9[0-389])|7(?:2[02-46-9]|34|[58]|6[0249]|7[57]|9[2-6])|8(?:2[124589]|3[26-9]|49|51|6|7[0-468]|8[68]|9[019])|9(?:[23][1-9]|4[15]|5[138]|6[1-3]|7[156]|8[189]|9[1-489])\",\"1(?:1|5(?:4[018]|5[017])|77|88|9[69])|2(?:2(?:[127]|3[014-9])|3[0-269]|4[59]|5(?:[1-3]|5[0-69]|9[19])|62|7(?:[1-35]|8[0189])|8(?:[16]|3[0134]|9[0-5])|9(?:[028]|17))|4(?:2(?:[13-79]|8[014-6])|3[0-57]|[45]|6[248]|7[2-47]|8[1-9]|9[29])|5(?:2|3(?:[045]|9[0-8])|4[0-369]|5[29]|8[02389]|9[0-3])|7(?:2[02-46-9]|34|[58]|6[0249]|7[57]|9(?:[23]|4[0-59]|5[01569]|6[0167]))|8(?:2(?:[1258]|4[0-39]|9[0-2469])|3(?:[29]|60)|49|51|6(?:[0-24]|36|5[0-3589]|7[23]|9[01459])|7[0-468]|8[68])|9(?:[23][1-9]|4[15]|5[138]|6[1-3]|7[156]|8[189]|9(?:[1289]|3[34]|4[0178]))|(?:264|837)[016-9]|2(?:57|93)[015-9]|(?:25[0468]|422|838)[01]|(?:47[59]|59[89]|8(?:6[68]|9))[019]\",\"1(?:1|5(?:4[018]|5[017])|77|88|9[69])|2(?:2[127]|3[0-269]|4[59]|5(?:[1-3]|5[0-69]|9(?:17|99))|6(?:2|4[016-9])|7(?:[1-35]|8[0189])|8(?:[16]|3[0134]|9[0-5])|9(?:[028]|17))|4(?:2(?:[13-79]|8[014-6])|3[0-57]|[45]|6[248]|7[2-47]|9[29])|5(?:2|3(?:[045]|9(?:[0-58]|6[4-9]|7[0-35689]))|4[0-369]|5[29]|8[02389]|9[0-3])|7(?:2[02-46-9]|34|[58]|6[0249]|7[57]|9(?:[23]|4[0-59]|5[01569]|6[0167]))|8(?:2(?:[1258]|4[0-39]|9[0169])|3(?:[29]|60|7(?:[017-9]|6[6-8]))|49|51|6(?:[0-24]|36[2-57-9]|5(?:[0-389]|5[23])|6(?:[01]|9[178])|7(?:2[2-468]|3[78])|9[0145])|7[0-468]|8[68])|9(?:4[15]|5[138]|7[156]|8[189]|9(?:[1289]|3(?:31|4[357])|4[0178]))|(?:8294|96)[1-3]|2(?:57|93)[015-9]|(?:223|8699)[014-9]|(?:25[0468]|422|838)[01]|(?:48|8292|9[23])[1-9]|(?:47[59]|59[89]|8(?:68|9))[019]\"],\"0$1\"],[\"(\\\\d{3})(\\\\d{2})(\\\\d{4})\",\"$1-$2-$3\",[\"[14]|[289][2-9]|5[3-9]|7[2-4679]\"],\"0$1\"],[\"(\\\\d{3})(\\\\d{3})(\\\\d{4})\",\"$1-$2-$3\",[\"800\"],\"0$1\"],[\"(\\\\d{2})(\\\\d{4})(\\\\d{4})\",\"$1-$2-$3\",[\"[25-9]\"],\"0$1\"]],\"0\",0,\"(000[2569]\\\\d{4,6})$|(?:(?:003768)0?)|0\",\"$1\"],\"KE\":[\"254\",\"000\",\"(?:[17]\\\\d\\\\d|900)\\\\d{6}|(?:2|80)0\\\\d{6,7}|[4-6]\\\\d{6,8}\",[7,8,9,10],[[\"(\\\\d{2})(\\\\d{5,7})\",\"$1 $2\",[\"[24-6]\"],\"0$1\"],[\"(\\\\d{3})(\\\\d{6})\",\"$1 $2\",[\"[17]\"],\"0$1\"],[\"(\\\\d{3})(\\\\d{3})(\\\\d{3,4})\",\"$1 $2 $3\",[\"[89]\"],\"0$1\"]],\"0\"],\"KG\":[\"996\",\"00\",\"8\\\\d{9}|[235-9]\\\\d{8}\",[9,10],[[\"(\\\\d{4})(\\\\d{5})\",\"$1 $2\",[\"3(?:1[346]|[24-79])\"],\"0$1\"],[\"(\\\\d{3})(\\\\d{3})(\\\\d{3})\",\"$1 $2 $3\",[\"[235-79]|88\"],\"0$1\"],[\"(\\\\d{3})(\\\\d{3})(\\\\d)(\\\\d{2,3})\",\"$1 $2 $3 $4\",[\"8\"],\"0$1\"]],\"0\"],\"KH\":[\"855\",\"00[14-9]\",\"1\\\\d{9}|[1-9]\\\\d{7,8}\",[8,9,10],[[\"(\\\\d{2})(\\\\d{3})(\\\\d{3,4})\",\"$1 $2 $3\",[\"[1-9]\"],\"0$1\"],[\"(\\\\d{4})(\\\\d{3})(\\\\d{3})\",\"$1 $2 $3\",[\"1\"]]],\"0\"],\"KI\":[\"686\",\"00\",\"(?:[37]\\\\d|6[0-79])\\\\d{6}|(?:[2-48]\\\\d|50)\\\\d{3}\",[5,8],0,\"0\"],\"KM\":[\"269\",\"00\",\"[3478]\\\\d{6}\",[7],[[\"(\\\\d{3})(\\\\d{2})(\\\\d{2})\",\"$1 $2 $3\",[\"[3478]\"]]]],\"KN\":[\"1\",\"011\",\"(?:[58]\\\\d\\\\d|900)\\\\d{7}\",[10],0,\"1\",0,\"([2-7]\\\\d{6})$|1\",\"869$1\",0,\"869\"],\"KP\":[\"850\",\"00|99\",\"85\\\\d{6}|(?:19\\\\d|[2-7])\\\\d{7}\",[8,10],[[\"(\\\\d{2})(\\\\d{3})(\\\\d{3})\",\"$1 $2 $3\",[\"8\"],\"0$1\"],[\"(\\\\d)(\\\\d{3})(\\\\d{4})\",\"$1 $2 $3\",[\"[2-7]\"],\"0$1\"],[\"(\\\\d{3})(\\\\d{3})(\\\\d{4})\",\"$1 $2 $3\",[\"1\"],\"0$1\"]],\"0\"],\"KR\":[\"82\",\"00(?:[125689]|3(?:[46]5|91)|7(?:00|27|3|55|6[126]))\",\"00[1-9]\\\\d{8,11}|(?:[12]|5\\\\d{3})\\\\d{7}|[13-6]\\\\d{9}|(?:[1-6]\\\\d|80)\\\\d{7}|[3-6]\\\\d{4,5}|(?:00|7)0\\\\d{8}\",[5,6,8,9,10,11,12,13,14],[[\"(\\\\d{2})(\\\\d{3,4})\",\"$1-$2\",[\"(?:3[1-3]|[46][1-4]|5[1-5])1\"],\"0$1\"],[\"(\\\\d{4})(\\\\d{4})\",\"$1-$2\",[\"1\"]],[\"(\\\\d)(\\\\d{3,4})(\\\\d{4})\",\"$1-$2-$3\",[\"2\"],\"0$1\"],[\"(\\\\d{2})(\\\\d{3})(\\\\d{4})\",\"$1-$2-$3\",[\"[36]0|8\"],\"0$1\"],[\"(\\\\d{2})(\\\\d{3,4})(\\\\d{4})\",\"$1-$2-$3\",[\"[1346]|5[1-5]\"],\"0$1\"],[\"(\\\\d{2})(\\\\d{4})(\\\\d{4})\",\"$1-$2-$3\",[\"[57]\"],\"0$1\"],[\"(\\\\d{2})(\\\\d{5})(\\\\d{4})\",\"$1-$2-$3\",[\"5\"],\"0$1\"]],\"0\",0,\"0(8(?:[1-46-8]|5\\\\d\\\\d))?\"],\"KW\":[\"965\",\"00\",\"18\\\\d{5}|(?:[2569]\\\\d|41)\\\\d{6}\",[7,8],[[\"(\\\\d{4})(\\\\d{3,4})\",\"$1 $2\",[\"[169]|2(?:[235]|4[1-35-9])|52\"]],[\"(\\\\d{3})(\\\\d{5})\",\"$1 $2\",[\"[245]\"]]]],\"KY\":[\"1\",\"011\",\"(?:345|[58]\\\\d\\\\d|900)\\\\d{7}\",[10],0,\"1\",0,\"([2-9]\\\\d{6})$|1\",\"345$1\",0,\"345\"],\"KZ\":[\"7\",\"810\",\"8\\\\d{13}|[78]\\\\d{9}\",[10,14],0,\"8\",0,0,0,0,\"7\",0,\"8~10\"],\"LA\":[\"856\",\"00\",\"[23]\\\\d{9}|3\\\\d{8}|(?:[235-8]\\\\d|41)\\\\d{6}\",[8,9,10],[[\"(\\\\d{2})(\\\\d{3})(\\\\d{3})\",\"$1 $2 $3\",[\"2[13]|3[14]|[4-8]\"],\"0$1\"],[\"(\\\\d{2})(\\\\d{2})(\\\\d{2})(\\\\d{3})\",\"$1 $2 $3 $4\",[\"3\"],\"0$1\"],[\"(\\\\d{2})(\\\\d{2})(\\\\d{3})(\\\\d{3})\",\"$1 $2 $3 $4\",[\"[23]\"],\"0$1\"]],\"0\"],\"LB\":[\"961\",\"00\",\"[27-9]\\\\d{7}|[13-9]\\\\d{6}\",[7,8],[[\"(\\\\d)(\\\\d{3})(\\\\d{3})\",\"$1 $2 $3\",[\"[13-69]|7(?:[2-57]|62|8[0-6]|9[04-9])|8[02-9]\"],\"0$1\"],[\"(\\\\d{2})(\\\\d{3})(\\\\d{3})\",\"$1 $2 $3\",[\"[27-9]\"]]],\"0\"],\"LC\":[\"1\",\"011\",\"(?:[58]\\\\d\\\\d|758|900)\\\\d{7}\",[10],0,\"1\",0,\"([2-8]\\\\d{6})$|1\",\"758$1\",0,\"758\"],\"LI\":[\"423\",\"00\",\"[68]\\\\d{8}|(?:[2378]\\\\d|90)\\\\d{5}\",[7,9],[[\"(\\\\d{3})(\\\\d{2})(\\\\d{2})\",\"$1 $2 $3\",[\"[2379]|8(?:0[09]|7)\",\"[2379]|8(?:0(?:02|9)|7)\"]],[\"(\\\\d{3})(\\\\d{3})(\\\\d{3})\",\"$1 $2 $3\",[\"8\"]],[\"(\\\\d{2})(\\\\d{3})(\\\\d{4})\",\"$1 $2 $3\",[\"69\"]],[\"(\\\\d{3})(\\\\d{3})(\\\\d{3})\",\"$1 $2 $3\",[\"6\"]]],\"0\",0,\"(1001)|0\"],\"LK\":[\"94\",\"00\",\"[1-9]\\\\d{8}\",[9],[[\"(\\\\d{2})(\\\\d{3})(\\\\d{4})\",\"$1 $2 $3\",[\"7\"],\"0$1\"],[\"(\\\\d{3})(\\\\d{3})(\\\\d{3})\",\"$1 $2 $3\",[\"[1-689]\"],\"0$1\"]],\"0\"],\"LR\":[\"231\",\"00\",\"(?:[2457]\\\\d|33|88)\\\\d{7}|(?:2\\\\d|[4-6])\\\\d{6}\",[7,8,9],[[\"(\\\\d)(\\\\d{3})(\\\\d{3})\",\"$1 $2 $3\",[\"4[67]|[56]\"],\"0$1\"],[\"(\\\\d{2})(\\\\d{3})(\\\\d{3})\",\"$1 $2 $3\",[\"2\"],\"0$1\"],[\"(\\\\d{2})(\\\\d{3})(\\\\d{4})\",\"$1 $2 $3\",[\"[2-578]\"],\"0$1\"]],\"0\"],\"LS\":[\"266\",\"00\",\"(?:[256]\\\\d\\\\d|800)\\\\d{5}\",[8],[[\"(\\\\d{4})(\\\\d{4})\",\"$1 $2\",[\"[2568]\"]]]],\"LT\":[\"370\",\"00\",\"(?:[3469]\\\\d|52|[78]0)\\\\d{6}\",[8],[[\"(\\\\d)(\\\\d{3})(\\\\d{4})\",\"$1 $2 $3\",[\"52[0-7]\"],\"(0-$1)\",1],[\"(\\\\d{3})(\\\\d{2})(\\\\d{3})\",\"$1 $2 $3\",[\"[7-9]\"],\"0 $1\",1],[\"(\\\\d{2})(\\\\d{6})\",\"$1 $2\",[\"37|4(?:[15]|6[1-8])\"],\"(0-$1)\",1],[\"(\\\\d{3})(\\\\d{5})\",\"$1 $2\",[\"[3-6]\"],\"(0-$1)\",1]],\"0\",0,\"[08]\"],\"LU\":[\"352\",\"00\",\"35[013-9]\\\\d{4,8}|6\\\\d{8}|35\\\\d{2,4}|(?:[2457-9]\\\\d|3[0-46-9])\\\\d{2,9}\",[4,5,6,7,8,9,10,11],[[\"(\\\\d{2})(\\\\d{3})\",\"$1 $2\",[\"2(?:0[2-689]|[2-9])|[3-57]|8(?:0[2-9]|[13-9])|9(?:0[89]|[2-579])\"]],[\"(\\\\d{2})(\\\\d{2})(\\\\d{2})\",\"$1 $2 $3\",[\"2(?:0[2-689]|[2-9])|[3-57]|8(?:0[2-9]|[13-9])|9(?:0[89]|[2-579])\"]],[\"(\\\\d{2})(\\\\d{2})(\\\\d{3})\",\"$1 $2 $3\",[\"20[2-689]\"]],[\"(\\\\d{2})(\\\\d{2})(\\\\d{2})(\\\\d{1,2})\",\"$1 $2 $3 $4\",[\"20\"]],[\"(\\\\d{2})(\\\\d{2})(\\\\d{2})(\\\\d{1,5})\",\"$1 $2 $3 $4\",[\"[3-57]|8[13-9]|9(?:0[89]|[2-579])|(?:2|80)[2-9]\"]],[\"(\\\\d{3})(\\\\d{2})(\\\\d{3})\",\"$1 $2 $3\",[\"80[01]|90[015]\"]],[\"(\\\\d{2})(\\\\d{2})(\\\\d{2})(\\\\d{3})\",\"$1 $2 $3 $4\",[\"20\"]],[\"(\\\\d{3})(\\\\d{3})(\\\\d{3})\",\"$1 $2 $3\",[\"6\"]],[\"(\\\\d{2})(\\\\d{2})(\\\\d{2})(\\\\d{2})(\\\\d{1,2})\",\"$1 $2 $3 $4 $5\",[\"20\"]]],0,0,\"(15(?:0[06]|1[12]|[35]5|4[04]|6[26]|77|88|99)\\\\d)\"],\"LV\":[\"371\",\"00\",\"(?:[268]\\\\d|78|90)\\\\d{6}\",[8],[[\"(\\\\d{2})(\\\\d{3})(\\\\d{3})\",\"$1 $2 $3\",[\"[2679]|8[01]\"]]]],\"LY\":[\"218\",\"00\",\"[2-9]\\\\d{8}\",[9],[[\"(\\\\d{2})(\\\\d{7})\",\"$1-$2\",[\"[2-9]\"],\"0$1\"]],\"0\"],\"MA\":[\"212\",\"00\",\"[5-8]\\\\d{8}\",[9],[[\"(\\\\d{4})(\\\\d{5})\",\"$1-$2\",[\"892\"],\"0$1\"],[\"(\\\\d{2})(\\\\d{7})\",\"$1-$2\",[\"8(?:0[0-7]|9)\"],\"0$1\"],[\"(\\\\d)(\\\\d{2})(\\\\d{2})(\\\\d{2})(\\\\d{2})\",\"$1 $2 $3 $4 $5\",[\"[5-8]\"],\"0$1\"]],\"0\",0,0,0,0,\"[5-8]\"],\"MC\":[\"377\",\"00\",\"(?:[3489]|[67]\\\\d)\\\\d{7}\",[8,9],[[\"(\\\\d{2})(\\\\d{3})(\\\\d{3})\",\"$1 $2 $3\",[\"4\"],\"0$1\"],[\"(\\\\d{2})(\\\\d{2})(\\\\d{2})(\\\\d{2})\",\"$1 $2 $3 $4\",[\"[389]\"]],[\"(\\\\d)(\\\\d{2})(\\\\d{2})(\\\\d{2})(\\\\d{2})\",\"$1 $2 $3 $4 $5\",[\"[67]\"],\"0$1\"]],\"0\"],\"MD\":[\"373\",\"00\",\"(?:[235-7]\\\\d|[89]0)\\\\d{6}\",[8],[[\"(\\\\d{3})(\\\\d{5})\",\"$1 $2\",[\"[89]\"],\"0$1\"],[\"(\\\\d{2})(\\\\d{3})(\\\\d{3})\",\"$1 $2 $3\",[\"22|3\"],\"0$1\"],[\"(\\\\d{3})(\\\\d{2})(\\\\d{3})\",\"$1 $2 $3\",[\"[25-7]\"],\"0$1\"]],\"0\"],\"ME\":[\"382\",\"00\",\"(?:20|[3-79]\\\\d)\\\\d{6}|80\\\\d{6,7}\",[8,9],[[\"(\\\\d{2})(\\\\d{3})(\\\\d{3,4})\",\"$1 $2 $3\",[\"[2-9]\"],\"0$1\"]],\"0\"],\"MF\":[\"590\",\"00\",\"7090\\\\d{5}|(?:[56]9|[89]\\\\d)\\\\d{7}\",[9],0,\"0\",0,0,0,0,0,[[\"(?:59(?:0(?:0[079]|[14]3|[27][79]|3[03-7]|5[0-268]|87)|87\\\\d)|80[6-9]\\\\d\\\\d)\\\\d{4}\"],[\"(?:69(?:0\\\\d\\\\d|1(?:2[2-9]|3[0-5]))|7090[0-4])\\\\d{4}\"],[\"80[0-5]\\\\d{6}\"],[\"8[129]\\\\d{7}\"],0,0,0,0,[\"9(?:(?:39[5-7]|76[018])\\\\d|475[0-6])\\\\d{4}\"]]],\"MG\":[\"261\",\"00\",\"[23]\\\\d{8}\",[9],[[\"(\\\\d{2})(\\\\d{2})(\\\\d{3})(\\\\d{2})\",\"$1 $2 $3 $4\",[\"[23]\"],\"0$1\"]],\"0\",0,\"([24-9]\\\\d{6})$|0\",\"20$1\"],\"MH\":[\"692\",\"011\",\"329\\\\d{4}|(?:[256]\\\\d|45)\\\\d{5}\",[7],[[\"(\\\\d{3})(\\\\d{4})\",\"$1-$2\",[\"[2-6]\"]]],\"1\"],\"MK\":[\"389\",\"00\",\"[2-578]\\\\d{7}\",[8],[[\"(\\\\d)(\\\\d{3})(\\\\d{4})\",\"$1 $2 $3\",[\"2|34[47]|4(?:[37]7|5[47]|64)\"],\"0$1\"],[\"(\\\\d{2})(\\\\d{3})(\\\\d{3})\",\"$1 $2 $3\",[\"[347]\"],\"0$1\"],[\"(\\\\d{3})(\\\\d)(\\\\d{2})(\\\\d{2})\",\"$1 $2 $3 $4\",[\"[58]\"],\"0$1\"]],\"0\"],\"ML\":[\"223\",\"00\",\"[24-9]\\\\d{7}\",[8],[[\"(\\\\d{2})(\\\\d{2})(\\\\d{2})(\\\\d{2})\",\"$1 $2 $3 $4\",[\"[24-9]\"]]]],\"MM\":[\"95\",\"00\",\"1\\\\d{5,7}|95\\\\d{6}|(?:[4-7]|9[0-46-9])\\\\d{6,8}|(?:2|8\\\\d)\\\\d{5,8}\",[6,7,8,9,10],[[\"(\\\\d)(\\\\d{2})(\\\\d{3})\",\"$1 $2 $3\",[\"16|2\"],\"0$1\"],[\"(\\\\d{2})(\\\\d{2})(\\\\d{3})\",\"$1 $2 $3\",[\"4(?:[2-46]|5[3-5])|5|6(?:[1-689]|7[235-7])|7(?:[0-4]|5[2-7])|8[1-5]|(?:60|86)[23]\"],\"0$1\"],[\"(\\\\d)(\\\\d{3})(\\\\d{3,4})\",\"$1 $2 $3\",[\"[12]|452|678|86\",\"[12]|452|6788|86\"],\"0$1\"],[\"(\\\\d{2})(\\\\d{3})(\\\\d{3,4})\",\"$1 $2 $3\",[\"[4-7]|8[1-35]\"],\"0$1\"],[\"(\\\\d)(\\\\d{3})(\\\\d{4,6})\",\"$1 $2 $3\",[\"9(?:2[0-4]|[35-9]|4[137-9])\"],\"0$1\"],[\"(\\\\d)(\\\\d{4})(\\\\d{4})\",\"$1 $2 $3\",[\"2\"],\"0$1\"],[\"(\\\\d{3})(\\\\d{3})(\\\\d{4})\",\"$1 $2 $3\",[\"8\"],\"0$1\"],[\"(\\\\d)(\\\\d{3})(\\\\d{3})(\\\\d{3})\",\"$1 $2 $3 $4\",[\"92\"],\"0$1\"],[\"(\\\\d)(\\\\d{5})(\\\\d{4})\",\"$1 $2 $3\",[\"9\"],\"0$1\"]],\"0\"],\"MN\":[\"976\",\"001\",\"[12]\\\\d{7,9}|[5-9]\\\\d{7}\",[8,9,10],[[\"(\\\\d{2})(\\\\d{2})(\\\\d{4})\",\"$1 $2 $3\",[\"11|2[16]\"],\"0$1\"],[\"(\\\\d{4})(\\\\d{4})\",\"$1 $2\",[\"[5-9]\"]],[\"(\\\\d{3})(\\\\d{5,6})\",\"$1 $2\",[\"[12]2[1-3]\"],\"0$1\"],[\"(\\\\d{4})(\\\\d{5,6})\",\"$1 $2\",[\"[12](?:27|3[2-8]|4[2-68]|5[1-4689])\",\"[12](?:27|3[2-8]|4[2-68]|5[1-4689])[0-3]\"],\"0$1\"],[\"(\\\\d{5})(\\\\d{4,5})\",\"$1 $2\",[\"[12]\"],\"0$1\"]],\"0\"],\"MO\":[\"853\",\"00\",\"0800\\\\d{3}|(?:28|[68]\\\\d)\\\\d{6}\",[7,8],[[\"(\\\\d{4})(\\\\d{3})\",\"$1 $2\",[\"0\"]],[\"(\\\\d{4})(\\\\d{4})\",\"$1 $2\",[\"[268]\"]]]],\"MP\":[\"1\",\"011\",\"[58]\\\\d{9}|(?:67|90)0\\\\d{7}\",[10],0,\"1\",0,\"([2-9]\\\\d{6})$|1\",\"670$1\",0,\"670\"],\"MQ\":[\"596\",\"00\",\"7091\\\\d{5}|(?:[56]9|[89]\\\\d)\\\\d{7}\",[9],[[\"(\\\\d{3})(\\\\d{2})(\\\\d{2})(\\\\d{2})\",\"$1 $2 $3 $4\",[\"[5-79]|8(?:0[6-9]|[36])\"],\"0$1\"],[\"(\\\\d{3})(\\\\d{2})(\\\\d{2})(\\\\d{2})\",\"$1 $2 $3 $4\",[\"8\"],\"0$1\"]],\"0\"],\"MR\":[\"222\",\"00\",\"(?:[2-4]\\\\d\\\\d|800)\\\\d{5}\",[8],[[\"(\\\\d{2})(\\\\d{2})(\\\\d{2})(\\\\d{2})\",\"$1 $2 $3 $4\",[\"[2-48]\"]]]],\"MS\":[\"1\",\"011\",\"(?:[58]\\\\d\\\\d|664|900)\\\\d{7}\",[10],0,\"1\",0,\"([34]\\\\d{6})$|1\",\"664$1\",0,\"664\"],\"MT\":[\"356\",\"00\",\"3550\\\\d{4}|(?:[2579]\\\\d\\\\d|800)\\\\d{5}\",[8],[[\"(\\\\d{4})(\\\\d{4})\",\"$1 $2\",[\"[2357-9]\"]]]],\"MU\":[\"230\",\"0(?:0|[24-7]0|3[03])\",\"(?:[57]|8\\\\d\\\\d)\\\\d{7}|[2-468]\\\\d{6}\",[7,8,10],[[\"(\\\\d{3})(\\\\d{4})\",\"$1 $2\",[\"[2-46]|8[013]\"]],[\"(\\\\d{4})(\\\\d{4})\",\"$1 $2\",[\"[57]\"]],[\"(\\\\d{5})(\\\\d{5})\",\"$1 $2\",[\"8\"]]],0,0,0,0,0,0,0,\"020\"],\"MV\":[\"960\",\"0(?:0|19)\",\"(?:800|9[0-57-9]\\\\d)\\\\d{7}|[34679]\\\\d{6}\",[7,10],[[\"(\\\\d{3})(\\\\d{4})\",\"$1-$2\",[\"[34679]\"]],[\"(\\\\d{3})(\\\\d{3})(\\\\d{4})\",\"$1 $2 $3\",[\"[89]\"]]],0,0,0,0,0,0,0,\"00\"],\"MW\":[\"265\",\"00\",\"(?:[1289]\\\\d|31|77)\\\\d{7}|1\\\\d{6}\",[7,9],[[\"(\\\\d)(\\\\d{3})(\\\\d{3})\",\"$1 $2 $3\",[\"1[2-9]\"],\"0$1\"],[\"(\\\\d{3})(\\\\d{2})(\\\\d{2})(\\\\d{2})\",\"$1 $2 $3 $4\",[\"[1-37-9]\"],\"0$1\"]],\"0\"],\"MX\":[\"52\",\"0[09]\",\"[2-9]\\\\d{9}\",[10],[[\"(\\\\d{2})(\\\\d{4})(\\\\d{4})\",\"$1 $2 $3\",[\"33|5[56]|81\"]],[\"(\\\\d{3})(\\\\d{3})(\\\\d{4})\",\"$1 $2 $3\",[\"[2-9]\"]]],0,0,0,0,0,0,0,\"00\"],\"MY\":[\"60\",\"00\",\"1\\\\d{8,9}|(?:3\\\\d|[4-9])\\\\d{7}\",[8,9,10],[[\"(\\\\d)(\\\\d{3})(\\\\d{4})\",\"$1-$2 $3\",[\"[4-79]\"],\"0$1\"],[\"(\\\\d{2})(\\\\d{3})(\\\\d{3,4})\",\"$1-$2 $3\",[\"1(?:[02469]|[378][1-9]|53)|8\",\"1(?:[02469]|[37][1-9]|53|8(?:[1-46-9]|5[7-9]))|8\"],\"0$1\"],[\"(\\\\d)(\\\\d{4})(\\\\d{4})\",\"$1-$2 $3\",[\"3\"],\"0$1\"],[\"(\\\\d)(\\\\d{3})(\\\\d{2})(\\\\d{4})\",\"$1-$2-$3-$4\",[\"1(?:[367]|80)\"]],[\"(\\\\d{3})(\\\\d{3})(\\\\d{4})\",\"$1-$2 $3\",[\"15\"],\"0$1\"],[\"(\\\\d{2})(\\\\d{4})(\\\\d{4})\",\"$1-$2 $3\",[\"1\"],\"0$1\"]],\"0\"],\"MZ\":[\"258\",\"00\",\"(?:2|8\\\\d)\\\\d{7}\",[8,9],[[\"(\\\\d{2})(\\\\d{3})(\\\\d{3,4})\",\"$1 $2 $3\",[\"2|8[2-79]\"]],[\"(\\\\d{3})(\\\\d{3})(\\\\d{3})\",\"$1 $2 $3\",[\"8\"]]]],\"NA\":[\"264\",\"00\",\"[68]\\\\d{7,8}\",[8,9],[[\"(\\\\d{2})(\\\\d{3})(\\\\d{3})\",\"$1 $2 $3\",[\"88\"],\"0$1\"],[\"(\\\\d{2})(\\\\d{3})(\\\\d{3,4})\",\"$1 $2 $3\",[\"6\"],\"0$1\"],[\"(\\\\d{3})(\\\\d{3})(\\\\d{3})\",\"$1 $2 $3\",[\"87\"],\"0$1\"],[\"(\\\\d{2})(\\\\d{3})(\\\\d{4})\",\"$1 $2 $3\",[\"8\"],\"0$1\"]],\"0\"],\"NC\":[\"687\",\"00\",\"(?:050|[2-57-9]\\\\d\\\\d)\\\\d{3}\",[6],[[\"(\\\\d{2})(\\\\d{2})(\\\\d{2})\",\"$1.$2.$3\",[\"[02-57-9]\"]]]],\"NE\":[\"227\",\"00\",\"[027-9]\\\\d{7}\",[8],[[\"(\\\\d{2})(\\\\d{3})(\\\\d{3})\",\"$1 $2 $3\",[\"08\"]],[\"(\\\\d{2})(\\\\d{2})(\\\\d{2})(\\\\d{2})\",\"$1 $2 $3 $4\",[\"[089]|2[013]|7[0467]\"]]]],\"NF\":[\"672\",\"00\",\"[13]\\\\d{5}\",[6],[[\"(\\\\d{2})(\\\\d{4})\",\"$1 $2\",[\"1[0-3]\"]],[\"(\\\\d)(\\\\d{5})\",\"$1 $2\",[\"[13]\"]]],0,0,\"([0-258]\\\\d{4})$\",\"3$1\"],\"NG\":[\"234\",\"009\",\"(?:20|9\\\\d)\\\\d{8}|[78]\\\\d{9,13}\",[10,11,12,13,14],[[\"(\\\\d{3})(\\\\d{3})(\\\\d{3,4})\",\"$1 $2 $3\",[\"[7-9]\"],\"0$1\"],[\"(\\\\d{3})(\\\\d{3})(\\\\d{4})\",\"$1 $2 $3\",[\"20[129]\"],\"0$1\"],[\"(\\\\d{4})(\\\\d{2})(\\\\d{4})\",\"$1 $2 $3\",[\"2\"],\"0$1\"],[\"(\\\\d{3})(\\\\d{4})(\\\\d{4,5})\",\"$1 $2 $3\",[\"[78]\"],\"0$1\"],[\"(\\\\d{3})(\\\\d{5})(\\\\d{5,6})\",\"$1 $2 $3\",[\"[78]\"],\"0$1\"]],\"0\"],\"NI\":[\"505\",\"00\",\"(?:1800|[25-8]\\\\d{3})\\\\d{4}\",[8],[[\"(\\\\d{4})(\\\\d{4})\",\"$1 $2\",[\"[125-8]\"]]]],\"NL\":[\"31\",\"00\",\"(?:[124-7]\\\\d\\\\d|3(?:[02-9]\\\\d|1[0-8]))\\\\d{6}|8\\\\d{6,9}|9\\\\d{6,10}|1\\\\d{4,5}\",[5,6,7,8,9,10,11],[[\"(\\\\d{3})(\\\\d{4,7})\",\"$1 $2\",[\"[89]0\"],\"0$1\"],[\"(\\\\d{2})(\\\\d{7})\",\"$1 $2\",[\"66\"],\"0$1\"],[\"(\\\\d)(\\\\d{8})\",\"$1 $2\",[\"6\"],\"0$1\"],[\"(\\\\d{3})(\\\\d{3})(\\\\d{3})\",\"$1 $2 $3\",[\"1[16-8]|2[259]|3[124]|4[17-9]|5[124679]\"],\"0$1\"],[\"(\\\\d{2})(\\\\d{3})(\\\\d{4})\",\"$1 $2 $3\",[\"[1-578]|91\"],\"0$1\"],[\"(\\\\d{3})(\\\\d{3})(\\\\d{5})\",\"$1 $2 $3\",[\"9\"],\"0$1\"]],\"0\"],\"NO\":[\"47\",\"00\",\"(?:0|[2-9]\\\\d{3})\\\\d{4}\",[5,8],[[\"(\\\\d{3})(\\\\d{2})(\\\\d{3})\",\"$1 $2 $3\",[\"8\"]],[\"(\\\\d{2})(\\\\d{2})(\\\\d{2})(\\\\d{2})\",\"$1 $2 $3 $4\",[\"[2-79]\"]]],0,0,0,0,0,\"[02-689]|7[0-8]\"],\"NP\":[\"977\",\"00\",\"(?:1\\\\d|9)\\\\d{9}|[1-9]\\\\d{7}\",[8,10,11],[[\"(\\\\d)(\\\\d{7})\",\"$1-$2\",[\"1[2-6]\"],\"0$1\"],[\"(\\\\d{2})(\\\\d{6})\",\"$1-$2\",[\"1[01]|[2-8]|9(?:[1-59]|[67][2-6])\"],\"0$1\"],[\"(\\\\d{3})(\\\\d{7})\",\"$1-$2\",[\"9\"]]],\"0\"],\"NR\":[\"674\",\"00\",\"(?:222|444|(?:55|8\\\\d)\\\\d|666|777|999)\\\\d{4}\",[7],[[\"(\\\\d{3})(\\\\d{4})\",\"$1 $2\",[\"[24-9]\"]]]],\"NU\":[\"683\",\"00\",\"(?:[4-7]|888\\\\d)\\\\d{3}\",[4,7],[[\"(\\\\d{3})(\\\\d{4})\",\"$1 $2\",[\"8\"]]]],\"NZ\":[\"64\",\"0(?:0|161)\",\"[1289]\\\\d{9}|50\\\\d{5}(?:\\\\d{2,3})?|[27-9]\\\\d{7,8}|(?:[34]\\\\d|6[0-35-9])\\\\d{6}|8\\\\d{4,6}\",[5,6,7,8,9,10],[[\"(\\\\d{2})(\\\\d{3,8})\",\"$1 $2\",[\"8[1-79]\"],\"0$1\"],[\"(\\\\d{3})(\\\\d{2})(\\\\d{2,3})\",\"$1 $2 $3\",[\"50[036-8]|8|90\",\"50(?:[0367]|88)|8|90\"],\"0$1\"],[\"(\\\\d)(\\\\d{3})(\\\\d{4})\",\"$1 $2 $3\",[\"24|[346]|7[2-57-9]|9[2-9]\"],\"0$1\"],[\"(\\\\d{3})(\\\\d{3})(\\\\d{3,4})\",\"$1 $2 $3\",[\"2(?:10|74)|[589]\"],\"0$1\"],[\"(\\\\d{2})(\\\\d{3,4})(\\\\d{4})\",\"$1 $2 $3\",[\"1|2[028]\"],\"0$1\"],[\"(\\\\d{2})(\\\\d{3})(\\\\d{3,5})\",\"$1 $2 $3\",[\"2(?:[169]|7[0-35-9])|7\"],\"0$1\"]],\"0\",0,0,0,0,0,0,\"00\"],\"OM\":[\"968\",\"00\",\"(?:1505|[279]\\\\d{3}|500)\\\\d{4}|800\\\\d{5,6}\",[7,8,9],[[\"(\\\\d{3})(\\\\d{4,6})\",\"$1 $2\",[\"[58]\"]],[\"(\\\\d{2})(\\\\d{6})\",\"$1 $2\",[\"2\"]],[\"(\\\\d{4})(\\\\d{4})\",\"$1 $2\",[\"[179]\"]]]],\"PA\":[\"507\",\"00\",\"(?:00800|8\\\\d{3})\\\\d{6}|[68]\\\\d{7}|[1-57-9]\\\\d{6}\",[7,8,10,11],[[\"(\\\\d{3})(\\\\d{4})\",\"$1-$2\",[\"[1-57-9]\"]],[\"(\\\\d{4})(\\\\d{4})\",\"$1-$2\",[\"[68]\"]],[\"(\\\\d{3})(\\\\d{3})(\\\\d{4})\",\"$1 $2 $3\",[\"8\"]]]],\"PE\":[\"51\",\"00|19(?:1[124]|77|90)00\",\"(?:[14-8]|9\\\\d)\\\\d{7}\",[8,9],[[\"(\\\\d{3})(\\\\d{5})\",\"$1 $2\",[\"80\"],\"(0$1)\"],[\"(\\\\d)(\\\\d{7})\",\"$1 $2\",[\"1\"],\"(0$1)\"],[\"(\\\\d{2})(\\\\d{6})\",\"$1 $2\",[\"[4-8]\"],\"(0$1)\"],[\"(\\\\d{3})(\\\\d{3})(\\\\d{3})\",\"$1 $2 $3\",[\"9\"]]],\"0\",0,0,0,0,0,0,\"00\",\" Anexo \"],\"PF\":[\"689\",\"00\",\"4\\\\d{5}(?:\\\\d{2})?|8\\\\d{7,8}\",[6,8,9],[[\"(\\\\d{2})(\\\\d{2})(\\\\d{2})\",\"$1 $2 $3\",[\"44\"]],[\"(\\\\d{2})(\\\\d{2})(\\\\d{2})(\\\\d{2})\",\"$1 $2 $3 $4\",[\"4|8[7-9]\"]],[\"(\\\\d{3})(\\\\d{2})(\\\\d{2})(\\\\d{2})\",\"$1 $2 $3 $4\",[\"8\"]]]],\"PG\":[\"675\",\"00|140[1-3]\",\"(?:180|[78]\\\\d{3})\\\\d{4}|(?:[2-589]\\\\d|64)\\\\d{5}\",[7,8],[[\"(\\\\d{3})(\\\\d{4})\",\"$1 $2\",[\"18|[2-69]|85\"]],[\"(\\\\d{4})(\\\\d{4})\",\"$1 $2\",[\"[78]\"]]],0,0,0,0,0,0,0,\"00\"],\"PH\":[\"63\",\"00\",\"(?:[2-7]|9\\\\d)\\\\d{8}|2\\\\d{5}|(?:1800|8)\\\\d{7,9}\",[6,8,9,10,11,12,13],[[\"(\\\\d)(\\\\d{5})\",\"$1 $2\",[\"2\"],\"(0$1)\"],[\"(\\\\d{4})(\\\\d{4,6})\",\"$1 $2\",[\"3(?:23|39|46)|4(?:2[3-6]|[35]9|4[26]|76)|544|88[245]|(?:52|64|86)2\",\"3(?:230|397|461)|4(?:2(?:35|[46]4|51)|396|4(?:22|63)|59[347]|76[15])|5(?:221|446)|642[23]|8(?:622|8(?:[24]2|5[13]))\"],\"(0$1)\"],[\"(\\\\d{5})(\\\\d{4})\",\"$1 $2\",[\"346|4(?:27|9[35])|883\",\"3469|4(?:279|9(?:30|56))|8834\"],\"(0$1)\"],[\"(\\\\d)(\\\\d{4})(\\\\d{4})\",\"$1 $2 $3\",[\"2\"],\"(0$1)\"],[\"(\\\\d{2})(\\\\d{3})(\\\\d{4})\",\"$1 $2 $3\",[\"[3-7]|8[2-8]\"],\"(0$1)\"],[\"(\\\\d{3})(\\\\d{3})(\\\\d{4})\",\"$1 $2 $3\",[\"[89]\"],\"0$1\"],[\"(\\\\d{4})(\\\\d{3})(\\\\d{4})\",\"$1 $2 $3\",[\"1\"]],[\"(\\\\d{4})(\\\\d{1,2})(\\\\d{3})(\\\\d{4})\",\"$1 $2 $3 $4\",[\"1\"]]],\"0\"],\"PK\":[\"92\",\"00\",\"122\\\\d{6}|[24-8]\\\\d{10,11}|9(?:[013-9]\\\\d{8,10}|2(?:[01]\\\\d\\\\d|2(?:[06-8]\\\\d|1[01]))\\\\d{7})|(?:[2-8]\\\\d{3}|92(?:[0-7]\\\\d|8[1-9]))\\\\d{6}|[24-9]\\\\d{8}|[89]\\\\d{7}\",[8,9,10,11,12],[[\"(\\\\d{3})(\\\\d{3})(\\\\d{2,7})\",\"$1 $2 $3\",[\"[89]0\"],\"0$1\"],[\"(\\\\d{4})(\\\\d{5})\",\"$1 $2\",[\"1\"]],[\"(\\\\d{3})(\\\\d{6,7})\",\"$1 $2\",[\"2(?:3[2358]|4[2-4]|9[2-8])|45[3479]|54[2-467]|60[468]|72[236]|8(?:2[2-689]|3[23578]|4[3478]|5[2356])|9(?:2[2-8]|3[27-9]|4[2-6]|6[3569]|9[25-8])\",\"9(?:2[3-8]|98)|(?:2(?:3[2358]|4[2-4]|9[2-8])|45[3479]|54[2-467]|60[468]|72[236]|8(?:2[2-689]|3[23578]|4[3478]|5[2356])|9(?:22|3[27-9]|4[2-6]|6[3569]|9[25-7]))[2-9]\"],\"(0$1)\"],[\"(\\\\d{2})(\\\\d{7,8})\",\"$1 $2\",[\"(?:2[125]|4[0-246-9]|5[1-35-7]|6[1-8]|7[14]|8[16]|91)[2-9]\"],\"(0$1)\"],[\"(\\\\d{5})(\\\\d{5})\",\"$1 $2\",[\"58\"],\"(0$1)\"],[\"(\\\\d{3})(\\\\d{7})\",\"$1 $2\",[\"3\"],\"0$1\"],[\"(\\\\d{2})(\\\\d{3})(\\\\d{3})(\\\\d{3})\",\"$1 $2 $3 $4\",[\"2[125]|4[0-246-9]|5[1-35-7]|6[1-8]|7[14]|8[16]|91\"],\"(0$1)\"],[\"(\\\\d{3})(\\\\d{3})(\\\\d{3})(\\\\d{3})\",\"$1 $2 $3 $4\",[\"[24-9]\"],\"(0$1)\"]],\"0\"],\"PL\":[\"48\",\"00\",\"(?:6|8\\\\d\\\\d)\\\\d{7}|[1-9]\\\\d{6}(?:\\\\d{2})?|[26]\\\\d{5}\",[6,7,8,9,10],[[\"(\\\\d{5})\",\"$1\",[\"19\"]],[\"(\\\\d{3})(\\\\d{3})\",\"$1 $2\",[\"11|20|64\"]],[\"(\\\\d{2})(\\\\d{2})(\\\\d{3})\",\"$1 $2 $3\",[\"30|(?:1[2-8]|2[2-69]|3[2-4]|4[1-468]|5[24-689]|6[1-3578]|7[14-7]|8[1-79]|9[145])1\",\"30|(?:1[2-8]|2[2-69]|3[2-4]|4[1-468]|5[24-689]|6[1-3578]|7[14-7]|8[1-79]|9[145])19\"]],[\"(\\\\d{3})(\\\\d{2})(\\\\d{2,3})\",\"$1 $2 $3\",[\"64\"]],[\"(\\\\d{3})(\\\\d{3})(\\\\d{3})\",\"$1 $2 $3\",[\"21|39|45|5[0137]|6[0469]|7[02389]|8(?:0[14]|8)\"]],[\"(\\\\d{2})(\\\\d{3})(\\\\d{2})(\\\\d{2})\",\"$1 $2 $3 $4\",[\"1[2-8]|[2-7]|8[1-79]|9[145]\"]],[\"(\\\\d{3})(\\\\d{3})(\\\\d{3,4})\",\"$1 $2 $3\",[\"8\"]]]],\"PM\":[\"508\",\"00\",\"[78]\\\\d{8}|[2-9]\\\\d{5}\",[6,9],[[\"(\\\\d{2})(\\\\d{2})(\\\\d{2})\",\"$1 $2 $3\",[\"[2-9]\"],\"0$1\"],[\"(\\\\d{3})(\\\\d{3})(\\\\d{3})\",\"$1 $2 $3\",[\"7\"]],[\"(\\\\d{3})(\\\\d{2})(\\\\d{2})(\\\\d{2})\",\"$1 $2 $3 $4\",[\"8\"],\"0$1\"]],\"0\"],\"PR\":[\"1\",\"011\",\"(?:[589]\\\\d\\\\d|787)\\\\d{7}\",[10],0,\"1\",0,0,0,0,\"787|939\"],\"PS\":[\"970\",\"00\",\"[2489]2\\\\d{6}|(?:1\\\\d|5)\\\\d{8}\",[8,9,10],[[\"(\\\\d)(\\\\d{3})(\\\\d{4})\",\"$1 $2 $3\",[\"[2489]\"],\"0$1\"],[\"(\\\\d{3})(\\\\d{3})(\\\\d{3})\",\"$1 $2 $3\",[\"5\"],\"0$1\"],[\"(\\\\d{4})(\\\\d{3})(\\\\d{3})\",\"$1 $2 $3\",[\"1\"]]],\"0\"],\"PT\":[\"351\",\"00\",\"1693\\\\d{5}|(?:[26-9]\\\\d|30)\\\\d{7}\",[9],[[\"(\\\\d{2})(\\\\d{3})(\\\\d{4})\",\"$1 $2 $3\",[\"2[12]\"]],[\"(\\\\d{3})(\\\\d{3})(\\\\d{3})\",\"$1 $2 $3\",[\"16|[236-9]\"]]]],\"PW\":[\"680\",\"01[12]\",\"(?:[24-8]\\\\d\\\\d|345|900)\\\\d{4}\",[7],[[\"(\\\\d{3})(\\\\d{4})\",\"$1 $2\",[\"[2-9]\"]]]],\"PY\":[\"595\",\"00\",\"[36-8]\\\\d{5,8}|4\\\\d{6,8}|59\\\\d{6}|9\\\\d{5,10}|(?:2\\\\d|5[0-8])\\\\d{6,7}\",[6,7,8,9,10,11],[[\"(\\\\d{3})(\\\\d{3,6})\",\"$1 $2\",[\"[2-9]0\"],\"0$1\"],[\"(\\\\d{2})(\\\\d{5})\",\"$1 $2\",[\"3[289]|4[246-8]|61|7[1-3]|8[1-36]\"],\"(0$1)\"],[\"(\\\\d{3})(\\\\d{4,5})\",\"$1 $2\",[\"2[279]|3[13-5]|4[359]|5|6(?:[34]|7[1-46-8])|7[46-8]|85\"],\"(0$1)\"],[\"(\\\\d{2})(\\\\d{3})(\\\\d{3,4})\",\"$1 $2 $3\",[\"2[14-68]|3[26-9]|4[1246-8]|6(?:1|75)|7[1-35]|8[1-36]\"],\"(0$1)\"],[\"(\\\\d{2})(\\\\d{3})(\\\\d{4})\",\"$1 $2 $3\",[\"87\"]],[\"(\\\\d{3})(\\\\d{6})\",\"$1 $2\",[\"9(?:[5-79]|8[1-7])\"],\"0$1\"],[\"(\\\\d{3})(\\\\d{3})(\\\\d{3})\",\"$1 $2 $3\",[\"[2-8]\"],\"0$1\"],[\"(\\\\d{4})(\\\\d{3})(\\\\d{4})\",\"$1 $2 $3\",[\"9\"]]],\"0\"],\"QA\":[\"974\",\"00\",\"800\\\\d{4}|(?:2|800)\\\\d{6}|(?:0080|[3-7])\\\\d{7}\",[7,8,9,11],[[\"(\\\\d{3})(\\\\d{4})\",\"$1 $2\",[\"2[136]|8\"]],[\"(\\\\d{4})(\\\\d{4})\",\"$1 $2\",[\"[3-7]\"]]]],\"RE\":[\"262\",\"00\",\"709\\\\d{6}|(?:26|[689]\\\\d)\\\\d{7}\",[9],[[\"(\\\\d{3})(\\\\d{2})(\\\\d{2})(\\\\d{2})\",\"$1 $2 $3 $4\",[\"[26-9]\"],\"0$1\"]],\"0\",0,0,0,0,0,[[\"2631[0-6]\\\\d{4}|26(?:2\\\\d|30|88)\\\\d{5}\"],[\"(?:69(?:2\\\\d\\\\d|3(?:[06][0-6]|1[0-3]|2[0-2]|3[0-39]|4\\\\d|5[0-5]|7[0-37]|8[0-8]|9[0-479]))|7092[0-3])\\\\d{4}\"],[\"80\\\\d{7}\"],[\"89[1-37-9]\\\\d{6}\"],0,0,0,0,[\"9(?:399[0-3]|479[0-6]|76(?:2[278]|3[0-37]))\\\\d{4}\"],[\"8(?:1[019]|2[0156]|84|90)\\\\d{6}\"]]],\"RO\":[\"40\",\"00\",\"(?:[236-8]\\\\d|90)\\\\d{7}|[23]\\\\d{5}\",[6,9],[[\"(\\\\d{3})(\\\\d{3})\",\"$1 $2\",[\"2[3-6]\",\"2[3-6]\\\\d9\"],\"0$1\"],[\"(\\\\d{2})(\\\\d{4})\",\"$1 $2\",[\"219|31\"],\"0$1\"],[\"(\\\\d{2})(\\\\d{3})(\\\\d{4})\",\"$1 $2 $3\",[\"[23]1\"],\"0$1\"],[\"(\\\\d{3})(\\\\d{3})(\\\\d{3})\",\"$1 $2 $3\",[\"[236-9]\"],\"0$1\"]],\"0\",0,0,0,0,0,0,0,\" int \"],\"RS\":[\"381\",\"00\",\"38[02-9]\\\\d{6,9}|6\\\\d{7,9}|90\\\\d{4,8}|38\\\\d{5,6}|(?:7\\\\d\\\\d|800)\\\\d{3,9}|(?:[12]\\\\d|3[0-79])\\\\d{5,10}\",[6,7,8,9,10,11,12],[[\"(\\\\d{3})(\\\\d{3,9})\",\"$1 $2\",[\"(?:2[389]|39)0|[7-9]\"],\"0$1\"],[\"(\\\\d{2})(\\\\d{5,10})\",\"$1 $2\",[\"[1-36]\"],\"0$1\"]],\"0\"],\"RU\":[\"7\",\"810\",\"8\\\\d{13}|[347-9]\\\\d{9}\",[10,14],[[\"(\\\\d{4})(\\\\d{2})(\\\\d{2})(\\\\d{2})\",\"$1 $2 $3 $4\",[\"7(?:1[0-8]|2[1-9])\",\"7(?:1(?:[0-356]2|4[29]|7|8[27])|2(?:1[23]|[2-9]2))\",\"7(?:1(?:[0-356]2|4[29]|7|8[27])|2(?:13[03-69]|62[013-9]))|72[1-57-9]2\"],\"8 ($1)\",1],[\"(\\\\d{5})(\\\\d)(\\\\d{2})(\\\\d{2})\",\"$1 $2 $3 $4\",[\"7(?:1[0-68]|2[1-9])\",\"7(?:1(?:[06][3-6]|[18]|2[35]|[3-5][3-5])|2(?:[13][3-5]|[24-689]|7[457]))\",\"7(?:1(?:0(?:[356]|4[023])|[18]|2(?:3[013-9]|5)|3[45]|43[013-79]|5(?:3[1-8]|4[1-7]|5)|6(?:3[0-35-9]|[4-6]))|2(?:1(?:3[178]|[45])|[24-689]|3[35]|7[457]))|7(?:14|23)4[0-8]|71(?:33|45)[1-79]\"],\"8 ($1)\",1],[\"(\\\\d{3})(\\\\d{3})(\\\\d{4})\",\"$1 $2 $3\",[\"7\"],\"8 ($1)\",1],[\"(\\\\d{3})(\\\\d{3})(\\\\d{2})(\\\\d{2})\",\"$1 $2-$3-$4\",[\"[349]|8(?:[02-7]|1[1-8])\"],\"8 ($1)\",1],[\"(\\\\d{4})(\\\\d{4})(\\\\d{3})(\\\\d{3})\",\"$1 $2 $3 $4\",[\"8\"],\"8 ($1)\"]],\"8\",0,0,0,0,\"[3489]\",0,\"8~10\"],\"RW\":[\"250\",\"00\",\"(?:06|[27]\\\\d\\\\d|[89]00)\\\\d{6}\",[8,9],[[\"(\\\\d{2})(\\\\d{2})(\\\\d{2})(\\\\d{2})\",\"$1 $2 $3 $4\",[\"0\"]],[\"(\\\\d{3})(\\\\d{3})(\\\\d{3})\",\"$1 $2 $3\",[\"2\"]],[\"(\\\\d{3})(\\\\d{3})(\\\\d{3})\",\"$1 $2 $3\",[\"[7-9]\"],\"0$1\"]],\"0\"],\"SA\":[\"966\",\"00\",\"(?:[15]\\\\d|800|92)\\\\d{7}\",[9,10],[[\"(\\\\d{4})(\\\\d{5})\",\"$1 $2\",[\"9\"]],[\"(\\\\d{2})(\\\\d{3})(\\\\d{4})\",\"$1 $2 $3\",[\"1\"],\"0$1\"],[\"(\\\\d{2})(\\\\d{3})(\\\\d{4})\",\"$1 $2 $3\",[\"5\"],\"0$1\"],[\"(\\\\d{3})(\\\\d{3})(\\\\d{4})\",\"$1 $2 $3\",[\"8\"]]],\"0\"],\"SB\":[\"677\",\"0[01]\",\"[6-9]\\\\d{6}|[1-6]\\\\d{4}\",[5,7],[[\"(\\\\d{2})(\\\\d{5})\",\"$1 $2\",[\"6[89]|7|8[4-9]|9(?:[1-8]|9[0-8])\"]]]],\"SC\":[\"248\",\"010|0[0-2]\",\"(?:[2489]\\\\d|64)\\\\d{5}\",[7],[[\"(\\\\d)(\\\\d{3})(\\\\d{3})\",\"$1 $2 $3\",[\"[246]|9[57]\"]]],0,0,0,0,0,0,0,\"00\"],\"SD\":[\"249\",\"00\",\"[19]\\\\d{8}\",[9],[[\"(\\\\d{2})(\\\\d{3})(\\\\d{4})\",\"$1 $2 $3\",[\"[19]\"],\"0$1\"]],\"0\"],\"SE\":[\"46\",\"00\",\"(?:[26]\\\\d\\\\d|9)\\\\d{9}|[1-9]\\\\d{8}|[1-689]\\\\d{7}|[1-4689]\\\\d{6}|2\\\\d{5}\",[6,7,8,9,10,12],[[\"(\\\\d{2})(\\\\d{2,3})(\\\\d{2})\",\"$1-$2 $3\",[\"20\"],\"0$1\",0,\"$1 $2 $3\"],[\"(\\\\d{3})(\\\\d{4})\",\"$1-$2\",[\"9(?:00|39|44|9)\"],\"0$1\",0,\"$1 $2\"],[\"(\\\\d{2})(\\\\d{3})(\\\\d{2})\",\"$1-$2 $3\",[\"[12][136]|3[356]|4[0246]|6[03]|90[1-9]\"],\"0$1\",0,\"$1 $2 $3\"],[\"(\\\\d)(\\\\d{2,3})(\\\\d{2})(\\\\d{2})\",\"$1-$2 $3 $4\",[\"8\"],\"0$1\",0,\"$1 $2 $3 $4\"],[\"(\\\\d{3})(\\\\d{2,3})(\\\\d{2})\",\"$1-$2 $3\",[\"1[2457]|2(?:[247-9]|5[0138])|3[0247-9]|4[1357-9]|5[0-35-9]|6(?:[125689]|4[02-57]|7[0-2])|9(?:[125-8]|3[02-5]|4[0-3])\"],\"0$1\",0,\"$1 $2 $3\"],[\"(\\\\d{3})(\\\\d{2,3})(\\\\d{3})\",\"$1-$2 $3\",[\"9(?:00|39|44)\"],\"0$1\",0,\"$1 $2 $3\"],[\"(\\\\d{2})(\\\\d{2,3})(\\\\d{2})(\\\\d{2})\",\"$1-$2 $3 $4\",[\"1[13689]|2[0136]|3[1356]|4[0246]|54|6[03]|90[1-9]\"],\"0$1\",0,\"$1 $2 $3 $4\"],[\"(\\\\d{2})(\\\\d{3})(\\\\d{2})(\\\\d{2})\",\"$1-$2 $3 $4\",[\"10|7\"],\"0$1\",0,\"$1 $2 $3 $4\"],[\"(\\\\d)(\\\\d{3})(\\\\d{3})(\\\\d{2})\",\"$1-$2 $3 $4\",[\"8\"],\"0$1\",0,\"$1 $2 $3 $4\"],[\"(\\\\d{3})(\\\\d{2})(\\\\d{2})(\\\\d{2})\",\"$1-$2 $3 $4\",[\"[13-5]|2(?:[247-9]|5[0138])|6(?:[124-689]|7[0-2])|9(?:[125-8]|3[02-5]|4[0-3])\"],\"0$1\",0,\"$1 $2 $3 $4\"],[\"(\\\\d{3})(\\\\d{2})(\\\\d{2})(\\\\d{3})\",\"$1-$2 $3 $4\",[\"9\"],\"0$1\",0,\"$1 $2 $3 $4\"],[\"(\\\\d{3})(\\\\d{2})(\\\\d{3})(\\\\d{2})(\\\\d{2})\",\"$1-$2 $3 $4 $5\",[\"[26]\"],\"0$1\",0,\"$1 $2 $3 $4 $5\"]],\"0\"],\"SG\":[\"65\",\"0[0-3]\\\\d\",\"(?:(?:1\\\\d|8)\\\\d\\\\d|7000)\\\\d{7}|[3689]\\\\d{7}\",[8,10,11],[[\"(\\\\d{4})(\\\\d{4})\",\"$1 $2\",[\"[369]|8(?:0[1-9]|[1-9])\"]],[\"(\\\\d{3})(\\\\d{3})(\\\\d{4})\",\"$1 $2 $3\",[\"8\"]],[\"(\\\\d{4})(\\\\d{4})(\\\\d{3})\",\"$1 $2 $3\",[\"7\"]],[\"(\\\\d{4})(\\\\d{3})(\\\\d{4})\",\"$1 $2 $3\",[\"1\"]]]],\"SH\":[\"290\",\"00\",\"(?:[256]\\\\d|8)\\\\d{3}\",[4,5],0,0,0,0,0,0,\"[256]\"],\"SI\":[\"386\",\"00|10(?:22|66|88|99)\",\"[1-7]\\\\d{7}|8\\\\d{4,7}|90\\\\d{4,6}\",[5,6,7,8],[[\"(\\\\d{2})(\\\\d{3,6})\",\"$1 $2\",[\"8[09]|9\"],\"0$1\"],[\"(\\\\d{3})(\\\\d{5})\",\"$1 $2\",[\"59|8\"],\"0$1\"],[\"(\\\\d{2})(\\\\d{3})(\\\\d{3})\",\"$1 $2 $3\",[\"[37][01]|4[013]|51|6\"],\"0$1\"],[\"(\\\\d)(\\\\d{3})(\\\\d{2})(\\\\d{2})\",\"$1 $2 $3 $4\",[\"[1-57]\"],\"(0$1)\"]],\"0\",0,0,0,0,0,0,\"00\"],\"SJ\":[\"47\",\"00\",\"0\\\\d{4}|(?:[489]\\\\d|79)\\\\d{6}\",[5,8],0,0,0,0,0,0,\"79\"],\"SK\":[\"421\",\"00\",\"[2-689]\\\\d{8}|[2-59]\\\\d{6}|[2-5]\\\\d{5}\",[6,7,9],[[\"(\\\\d)(\\\\d{2})(\\\\d{3,4})\",\"$1 $2 $3\",[\"21\"],\"0$1\"],[\"(\\\\d{2})(\\\\d{2})(\\\\d{2,3})\",\"$1 $2 $3\",[\"[3-5][1-8]1\",\"[3-5][1-8]1[67]\"],\"0$1\"],[\"(\\\\d)(\\\\d{3})(\\\\d{3})(\\\\d{2})\",\"$1 $2 $3 $4\",[\"2\"],\"0$1\"],[\"(\\\\d{3})(\\\\d{3})(\\\\d{3})\",\"$1 $2 $3\",[\"[689]\"],\"0$1\"],[\"(\\\\d{2})(\\\\d{3})(\\\\d{2})(\\\\d{2})\",\"$1 $2 $3 $4\",[\"[3-5]\"],\"0$1\"]],\"0\"],\"SL\":[\"232\",\"00\",\"(?:[237-9]\\\\d|66)\\\\d{6}\",[8],[[\"(\\\\d{2})(\\\\d{6})\",\"$1 $2\",[\"[236-9]\"],\"(0$1)\"]],\"0\"],\"SM\":[\"378\",\"00\",\"(?:0549|[5-7]\\\\d)\\\\d{6}\",[8,10],[[\"(\\\\d{2})(\\\\d{2})(\\\\d{2})(\\\\d{2})\",\"$1 $2 $3 $4\",[\"[5-7]\"]],[\"(\\\\d{4})(\\\\d{6})\",\"$1 $2\",[\"0\"]]],0,0,\"([89]\\\\d{5})$\",\"0549$1\"],\"SN\":[\"221\",\"00\",\"(?:[378]\\\\d|93)\\\\d{7}\",[9],[[\"(\\\\d{3})(\\\\d{2})(\\\\d{2})(\\\\d{2})\",\"$1 $2 $3 $4\",[\"8\"]],[\"(\\\\d{2})(\\\\d{3})(\\\\d{2})(\\\\d{2})\",\"$1 $2 $3 $4\",[\"[379]\"]]]],\"SO\":[\"252\",\"00\",\"[346-9]\\\\d{8}|[12679]\\\\d{7}|[1-5]\\\\d{6}|[1348]\\\\d{5}\",[6,7,8,9],[[\"(\\\\d{2})(\\\\d{4})\",\"$1 $2\",[\"8[125]\"]],[\"(\\\\d{6})\",\"$1\",[\"[134]\"]],[\"(\\\\d)(\\\\d{6})\",\"$1 $2\",[\"[15]|2[0-79]|3[0-46-8]|4[0-7]\"]],[\"(\\\\d{2})(\\\\d{5,7})\",\"$1 $2\",[\"1|28|9[2-9]\"]],[\"(\\\\d)(\\\\d{7})\",\"$1 $2\",[\"[267]|904\"]],[\"(\\\\d{2})(\\\\d{3})(\\\\d{4})\",\"$1 $2 $3\",[\"[346-9]\"]]],\"0\"],\"SR\":[\"597\",\"00\",\"(?:[2-5]|[6-9]\\\\d)\\\\d{5}\",[6,7],[[\"(\\\\d{2})(\\\\d{2})(\\\\d{2})\",\"$1-$2-$3\",[\"56\"]],[\"(\\\\d{3})(\\\\d{3})\",\"$1-$2\",[\"[2-5]\"]],[\"(\\\\d{3})(\\\\d{4})\",\"$1-$2\",[\"[6-9]\"]]]],\"SS\":[\"211\",\"00\",\"[19]\\\\d{8}\",[9],[[\"(\\\\d{3})(\\\\d{3})(\\\\d{3})\",\"$1 $2 $3\",[\"[19]\"],\"0$1\"]],\"0\"],\"ST\":[\"239\",\"00\",\"(?:22|9\\\\d)\\\\d{5}\",[7],[[\"(\\\\d{3})(\\\\d{4})\",\"$1 $2\",[\"[29]\"]]]],\"SV\":[\"503\",\"00\",\"[25-7]\\\\d{7}|(?:80\\\\d|900)\\\\d{4}(?:\\\\d{4})?\",[7,8,11],[[\"(\\\\d{3})(\\\\d{4})\",\"$1 $2\",[\"[89]\"]],[\"(\\\\d{4})(\\\\d{4})\",\"$1 $2\",[\"[25-7]\"]],[\"(\\\\d{3})(\\\\d{4})(\\\\d{4})\",\"$1 $2 $3\",[\"[89]\"]]]],\"SX\":[\"1\",\"011\",\"7215\\\\d{6}|(?:[58]\\\\d\\\\d|900)\\\\d{7}\",[10],0,\"1\",0,\"(5\\\\d{6})$|1\",\"721$1\",0,\"721\"],\"SY\":[\"963\",\"00\",\"[1-359]\\\\d{8}|[1-5]\\\\d{7}\",[8,9],[[\"(\\\\d{2})(\\\\d{3})(\\\\d{3,4})\",\"$1 $2 $3\",[\"[1-4]|5[1-3]\"],\"0$1\",1],[\"(\\\\d{3})(\\\\d{3})(\\\\d{3})\",\"$1 $2 $3\",[\"[59]\"],\"0$1\",1]],\"0\"],\"SZ\":[\"268\",\"00\",\"0800\\\\d{4}|(?:[237]\\\\d|900)\\\\d{6}\",[8,9],[[\"(\\\\d{4})(\\\\d{4})\",\"$1 $2\",[\"[0237]\"]],[\"(\\\\d{5})(\\\\d{4})\",\"$1 $2\",[\"9\"]]]],\"TA\":[\"290\",\"00\",\"8\\\\d{3}\",[4],0,0,0,0,0,0,\"8\"],\"TC\":[\"1\",\"011\",\"(?:[58]\\\\d\\\\d|649|900)\\\\d{7}\",[10],0,\"1\",0,\"([2-479]\\\\d{6})$|1\",\"649$1\",0,\"649\"],\"TD\":[\"235\",\"00|16\",\"(?:22|[3689]\\\\d|77)\\\\d{6}\",[8],[[\"(\\\\d{2})(\\\\d{2})(\\\\d{2})(\\\\d{2})\",\"$1 $2 $3 $4\",[\"[236-9]\"]]],0,0,0,0,0,0,0,\"00\"],\"TG\":[\"228\",\"00\",\"[279]\\\\d{7}\",[8],[[\"(\\\\d{2})(\\\\d{2})(\\\\d{2})(\\\\d{2})\",\"$1 $2 $3 $4\",[\"[279]\"]]]],\"TH\":[\"66\",\"00[1-9]\",\"(?:001800|[2-57]|[689]\\\\d)\\\\d{7}|1\\\\d{7,9}\",[8,9,10,13],[[\"(\\\\d)(\\\\d{3})(\\\\d{4})\",\"$1 $2 $3\",[\"2\"],\"0$1\"],[\"(\\\\d{2})(\\\\d{3})(\\\\d{3,4})\",\"$1 $2 $3\",[\"[13-9]\"],\"0$1\"],[\"(\\\\d{4})(\\\\d{3})(\\\\d{3})\",\"$1 $2 $3\",[\"1\"]]],\"0\"],\"TJ\":[\"992\",\"810\",\"(?:[0-57-9]\\\\d|66)\\\\d{7}\",[9],[[\"(\\\\d{6})(\\\\d)(\\\\d{2})\",\"$1 $2 $3\",[\"331\",\"3317\"]],[\"(\\\\d{3})(\\\\d{2})(\\\\d{4})\",\"$1 $2 $3\",[\"44[02-479]|[34]7\"]],[\"(\\\\d{4})(\\\\d)(\\\\d{4})\",\"$1 $2 $3\",[\"3(?:[1245]|3[12])\"]],[\"(\\\\d{2})(\\\\d{3})(\\\\d{4})\",\"$1 $2 $3\",[\"\\\\d\"]]],0,0,0,0,0,0,0,\"8~10\"],\"TK\":[\"690\",\"00\",\"[2-47]\\\\d{3,6}\",[4,5,6,7]],\"TL\":[\"670\",\"00\",\"7\\\\d{7}|(?:[2-47]\\\\d|[89]0)\\\\d{5}\",[7,8],[[\"(\\\\d{3})(\\\\d{4})\",\"$1 $2\",[\"[2-489]|70\"]],[\"(\\\\d{4})(\\\\d{4})\",\"$1 $2\",[\"7\"]]]],\"TM\":[\"993\",\"810\",\"(?:[1-6]\\\\d|71)\\\\d{6}\",[8],[[\"(\\\\d{2})(\\\\d{2})(\\\\d{2})(\\\\d{2})\",\"$1 $2-$3-$4\",[\"12\"],\"(8 $1)\"],[\"(\\\\d{3})(\\\\d)(\\\\d{2})(\\\\d{2})\",\"$1 $2-$3-$4\",[\"[1-5]\"],\"(8 $1)\"],[\"(\\\\d{2})(\\\\d{6})\",\"$1 $2\",[\"[67]\"],\"8 $1\"]],\"8\",0,0,0,0,0,0,\"8~10\"],\"TN\":[\"216\",\"00\",\"[2-57-9]\\\\d{7}\",[8],[[\"(\\\\d{2})(\\\\d{3})(\\\\d{3})\",\"$1 $2 $3\",[\"[2-57-9]\"]]]],\"TO\":[\"676\",\"00\",\"(?:0800|(?:[5-8]\\\\d\\\\d|999)\\\\d)\\\\d{3}|[2-8]\\\\d{4}\",[5,7],[[\"(\\\\d{2})(\\\\d{3})\",\"$1-$2\",[\"[2-4]|50|6[09]|7[0-24-69]|8[05]\"]],[\"(\\\\d{4})(\\\\d{3})\",\"$1 $2\",[\"0\"]],[\"(\\\\d{3})(\\\\d{4})\",\"$1 $2\",[\"[5-9]\"]]]],\"TR\":[\"90\",\"00\",\"4\\\\d{6}|8\\\\d{11,12}|(?:[2-58]\\\\d\\\\d|900)\\\\d{7}\",[7,10,12,13],[[\"(\\\\d{3})(\\\\d{3})(\\\\d{4})\",\"$1 $2 $3\",[\"512|8[01589]|90\"],\"0$1\",1],[\"(\\\\d{3})(\\\\d{3})(\\\\d{2})(\\\\d{2})\",\"$1 $2 $3 $4\",[\"5[0-79]\"],\"0$1\",1],[\"(\\\\d{3})(\\\\d{3})(\\\\d{2})(\\\\d{2})\",\"$1 $2 $3 $4\",[\"[24][1-8]|3[1-9]\"],\"(0$1)\",1],[\"(\\\\d{3})(\\\\d{3})(\\\\d{6,7})\",\"$1 $2 $3\",[\"80\"],\"0$1\",1]],\"0\"],\"TT\":[\"1\",\"011\",\"(?:[58]\\\\d\\\\d|900)\\\\d{7}\",[10],0,\"1\",0,\"([2-46-8]\\\\d{6})$|1\",\"868$1\",0,\"868\"],\"TV\":[\"688\",\"00\",\"(?:2|7\\\\d\\\\d|90)\\\\d{4}\",[5,6,7],[[\"(\\\\d{2})(\\\\d{3})\",\"$1 $2\",[\"2\"]],[\"(\\\\d{2})(\\\\d{4})\",\"$1 $2\",[\"90\"]],[\"(\\\\d{2})(\\\\d{5})\",\"$1 $2\",[\"7\"]]]],\"TW\":[\"886\",\"0(?:0[25-79]|19)\",\"[2-689]\\\\d{8}|7\\\\d{9,10}|[2-8]\\\\d{7}|2\\\\d{6}\",[7,8,9,10,11],[[\"(\\\\d{2})(\\\\d)(\\\\d{4})\",\"$1 $2 $3\",[\"202\"],\"0$1\"],[\"(\\\\d{3})(\\\\d{5})\",\"$1 $2\",[\"826\"],\"0$1\"],[\"(\\\\d{3})(\\\\d{2})(\\\\d{3})\",\"$1 $2 $3\",[\"83\"],\"0$1\"],[\"(\\\\d{2})(\\\\d{2})(\\\\d{4})\",\"$1 $2 $3\",[\"82\"],\"0$1\"],[\"(\\\\d{2})(\\\\d{3})(\\\\d{3,4})\",\"$1 $2 $3\",[\"[25]0|37|49|8[09]\"],\"0$1\"],[\"(\\\\d)(\\\\d{3,4})(\\\\d{4})\",\"$1 $2 $3\",[\"[23568]|4(?:0[02-48]|[1-478])|7[1-9]\",\"[23568]|4(?:0[2-48]|[1-478])|(?:400|7)[1-9]\"],\"0$1\"],[\"(\\\\d{3})(\\\\d{3})(\\\\d{3})\",\"$1 $2 $3\",[\"[49]\"],\"0$1\"],[\"(\\\\d{2})(\\\\d{4})(\\\\d{4,5})\",\"$1 $2 $3\",[\"7\"],\"0$1\"]],\"0\",0,0,0,0,0,0,0,\"#\"],\"TZ\":[\"255\",\"00[056]\",\"(?:[25-8]\\\\d|41|90)\\\\d{7}\",[9],[[\"(\\\\d{3})(\\\\d{2})(\\\\d{4})\",\"$1 $2 $3\",[\"[89]\"],\"0$1\"],[\"(\\\\d{2})(\\\\d{3})(\\\\d{4})\",\"$1 $2 $3\",[\"[24]\"],\"0$1\"],[\"(\\\\d{2})(\\\\d{7})\",\"$1 $2\",[\"5\"]],[\"(\\\\d{3})(\\\\d{3})(\\\\d{3})\",\"$1 $2 $3\",[\"[67]\"],\"0$1\"]],\"0\"],\"UA\":[\"380\",\"00\",\"[89]\\\\d{9}|[3-9]\\\\d{8}\",[9,10],[[\"(\\\\d{3})(\\\\d{3})(\\\\d{3})\",\"$1 $2 $3\",[\"6[12][29]|(?:3[1-8]|4[136-8]|5[12457]|6[49])2|(?:56|65)[24]\",\"6[12][29]|(?:35|4[1378]|5[12457]|6[49])2|(?:56|65)[24]|(?:3[1-46-8]|46)2[013-9]\"],\"0$1\"],[\"(\\\\d{4})(\\\\d{5})\",\"$1 $2\",[\"3[1-8]|4(?:[1367]|[45][6-9]|8[4-6])|5(?:[1-5]|6[0135689]|7[4-6])|6(?:[12][3-7]|[459])\",\"3[1-8]|4(?:[1367]|[45][6-9]|8[4-6])|5(?:[1-5]|6(?:[015689]|3[02389])|7[4-6])|6(?:[12][3-7]|[459])\"],\"0$1\"],[\"(\\\\d{2})(\\\\d{3})(\\\\d{4})\",\"$1 $2 $3\",[\"[3-7]|89|9[1-9]\"],\"0$1\"],[\"(\\\\d{3})(\\\\d{3})(\\\\d{3,4})\",\"$1 $2 $3\",[\"[89]\"],\"0$1\"]],\"0\",0,0,0,0,0,0,\"0~0\"],\"UG\":[\"256\",\"00[057]\",\"800\\\\d{6}|(?:[29]0|[347]\\\\d)\\\\d{7}\",[9],[[\"(\\\\d{4})(\\\\d{5})\",\"$1 $2\",[\"202\",\"2024\"],\"0$1\"],[\"(\\\\d{3})(\\\\d{6})\",\"$1 $2\",[\"[27-9]|4(?:6[45]|[7-9])\"],\"0$1\"],[\"(\\\\d{2})(\\\\d{7})\",\"$1 $2\",[\"[34]\"],\"0$1\"]],\"0\"],\"US\":[\"1\",\"011\",\"[2-9]\\\\d{9}|3\\\\d{6}\",[10],[[\"(\\\\d{3})(\\\\d{4})\",\"$1-$2\",[\"310\"],0,1],[\"(\\\\d{3})(\\\\d{3})(\\\\d{4})\",\"($1) $2-$3\",[\"[2-9]\"],0,1,\"$1-$2-$3\"]],\"1\",0,0,0,0,0,[[\"(?:274[27]|(?:472|983)[2-47-9])\\\\d{6}|(?:2(?:0[1-35-9]|1[02-9]|2[03-57-9]|3[1459]|4[08]|5[1-46]|6[0279]|7[0269]|8[13])|3(?:0[1-57-9]|1[02-9]|2[013-79]|3[0-24679]|4[167]|5[0-3]|6[01349]|8[056])|4(?:0[124-9]|1[02-579]|2[3-5]|3[0245]|4[023578]|58|6[349]|7[0589]|8[04])|5(?:0[1-57-9]|1[0235-8]|20|3[0149]|4[01]|5[179]|6[1-47]|7[0-5]|8[0256])|6(?:0[1-35-9]|1[024-9]|2[03689]|3[016]|4[0156]|5[01679]|6[0-279]|78|8[0-269])|7(?:0[1-46-8]|1[2-9]|2[04-8]|3[0-2478]|4[0378]|5[47]|6[02359]|7[0-59]|8[156])|8(?:0[1-68]|1[02-8]|2[0168]|3[0-2589]|4[03578]|5[046-9]|6[02-5]|7[028])|9(?:0[1346-9]|1[02-9]|2[0589]|3[0146-8]|4[01357-9]|5[12469]|7[0-3589]|8[04-69]))[2-9]\\\\d{6}\"],[\"\"],[\"8(?:00|33|44|55|66|77|88)[2-9]\\\\d{6}\"],[\"900[2-9]\\\\d{6}\"],[\"52(?:3(?:[2-46-9][02-9]\\\\d|5(?:[02-46-9]\\\\d|5[0-46-9]))|4(?:[2-478][02-9]\\\\d|5(?:[034]\\\\d|2[024-9]|5[0-46-9])|6(?:0[1-9]|[2-9]\\\\d)|9(?:[05-9]\\\\d|2[0-5]|49)))\\\\d{4}|52[34][2-9]1[02-9]\\\\d{4}|5(?:00|2[125-9]|3[23]|44|66|77|88)[2-9]\\\\d{6}\"]]],\"UY\":[\"598\",\"0(?:0|1[3-9]\\\\d)\",\"0004\\\\d{2,9}|[1249]\\\\d{7}|2\\\\d{3,4}|(?:[49]\\\\d|80)\\\\d{5}\",[4,5,6,7,8,9,10,11,12,13],[[\"(\\\\d{4,5})\",\"$1\",[\"21\"]],[\"(\\\\d{3})(\\\\d{3,4})\",\"$1 $2\",[\"0\"]],[\"(\\\\d{3})(\\\\d{4})\",\"$1 $2\",[\"[49]0|8\"],\"0$1\"],[\"(\\\\d{2})(\\\\d{3})(\\\\d{3})\",\"$1 $2 $3\",[\"9\"],\"0$1\"],[\"(\\\\d{4})(\\\\d{4})\",\"$1 $2\",[\"[124]\"]],[\"(\\\\d{3})(\\\\d{3})(\\\\d{2,4})\",\"$1 $2 $3\",[\"0\"]],[\"(\\\\d{3})(\\\\d{3})(\\\\d{3})(\\\\d{2,4})\",\"$1 $2 $3 $4\",[\"0\"]]],\"0\",0,0,0,0,0,0,\"00\",\" int. \"],\"UZ\":[\"998\",\"00\",\"(?:20|33|[5-9]\\\\d)\\\\d{7}\",[9],[[\"(\\\\d{2})(\\\\d{3})(\\\\d{2})(\\\\d{2})\",\"$1 $2 $3 $4\",[\"[235-9]\"]]]],\"VA\":[\"39\",\"00\",\"0\\\\d{5,10}|3[0-8]\\\\d{7,10}|55\\\\d{8}|8\\\\d{5}(?:\\\\d{2,4})?|(?:1\\\\d|39)\\\\d{7,8}\",[6,7,8,9,10,11,12],0,0,0,0,0,0,\"06698\"],\"VC\":[\"1\",\"011\",\"(?:[58]\\\\d\\\\d|784|900)\\\\d{7}\",[10],0,\"1\",0,\"([2-7]\\\\d{6})$|1\",\"784$1\",0,\"784\"],\"VE\":[\"58\",\"00\",\"[68]00\\\\d{7}|(?:[24]\\\\d|[59]0)\\\\d{8}\",[10],[[\"(\\\\d{3})(\\\\d{7})\",\"$1-$2\",[\"[24-689]\"],\"0$1\"]],\"0\"],\"VG\":[\"1\",\"011\",\"(?:284|[58]\\\\d\\\\d|900)\\\\d{7}\",[10],0,\"1\",0,\"([2-578]\\\\d{6})$|1\",\"284$1\",0,\"284\"],\"VI\":[\"1\",\"011\",\"[58]\\\\d{9}|(?:34|90)0\\\\d{7}\",[10],0,\"1\",0,\"([2-9]\\\\d{6})$|1\",\"340$1\",0,\"340\"],\"VN\":[\"84\",\"00\",\"[12]\\\\d{9}|[135-9]\\\\d{8}|[16]\\\\d{6,7}|7\\\\d{6}\",[7,8,9,10],[[\"(\\\\d{4})(\\\\d{4,6})\",\"$1 $2\",[\"1(?:2[02]|[89])\"],0,1],[\"(\\\\d{2})(\\\\d{3})(\\\\d{2})(\\\\d{2})\",\"$1 $2 $3 $4\",[\"1[26]|6\"],\"0$1\",1],[\"(\\\\d{3})(\\\\d{3})(\\\\d{3})\",\"$1 $2 $3\",[\"[357-9]\"],\"0$1\",1],[\"(\\\\d{2})(\\\\d{4})(\\\\d{4})\",\"$1 $2 $3\",[\"2[48]\"],\"0$1\",1],[\"(\\\\d{3})(\\\\d{4})(\\\\d{3})\",\"$1 $2 $3\",[\"2\"],\"0$1\",1]],\"0\"],\"VU\":[\"678\",\"00\",\"[57-9]\\\\d{6}|(?:[238]\\\\d|48)\\\\d{3}\",[5,7],[[\"(\\\\d{3})(\\\\d{4})\",\"$1 $2\",[\"[57-9]\"]]]],\"WF\":[\"681\",\"00\",\"(?:40|72|8\\\\d{4})\\\\d{4}|[89]\\\\d{5}\",[6,9],[[\"(\\\\d{2})(\\\\d{2})(\\\\d{2})\",\"$1 $2 $3\",[\"[47-9]\"]],[\"(\\\\d{3})(\\\\d{2})(\\\\d{2})(\\\\d{2})\",\"$1 $2 $3 $4\",[\"8\"]]]],\"WS\":[\"685\",\"0\",\"(?:[2-6]|8\\\\d{5})\\\\d{4}|[78]\\\\d{6}|[68]\\\\d{5}\",[5,6,7,10],[[\"(\\\\d{5})\",\"$1\",[\"[2-5]|6[1-9]\"]],[\"(\\\\d{3})(\\\\d{3,7})\",\"$1 $2\",[\"[68]\"]],[\"(\\\\d{2})(\\\\d{5})\",\"$1 $2\",[\"7\"]]]],\"XK\":[\"383\",\"00\",\"2\\\\d{7,8}|3\\\\d{7,11}|(?:4\\\\d\\\\d|[89]00)\\\\d{5}\",[8,9,10,11,12],[[\"(\\\\d{3})(\\\\d{5})\",\"$1 $2\",[\"[89]\"],\"0$1\"],[\"(\\\\d{2})(\\\\d{3})(\\\\d{3})\",\"$1 $2 $3\",[\"[2-4]\"],\"0$1\"],[\"(\\\\d{3})(\\\\d{3})(\\\\d{3})\",\"$1 $2 $3\",[\"2|39\"],\"0$1\"],[\"(\\\\d{2})(\\\\d{7,10})\",\"$1 $2\",[\"3\"],\"0$1\"]],\"0\"],\"YE\":[\"967\",\"00\",\"(?:1|7\\\\d)\\\\d{7}|[1-7]\\\\d{6}\",[7,8,9],[[\"(\\\\d)(\\\\d{3})(\\\\d{3,4})\",\"$1 $2 $3\",[\"[1-6]|7(?:[24-6]|8[0-7])\"],\"0$1\"],[\"(\\\\d{3})(\\\\d{3})(\\\\d{3})\",\"$1 $2 $3\",[\"7\"],\"0$1\"]],\"0\"],\"YT\":[\"262\",\"00\",\"(?:639\\\\d|7093)\\\\d{5}|(?:26|80|9\\\\d)\\\\d{7}\",[9],0,\"0\",0,0,0,0,0,[[\"26(?:89\\\\d|9(?:0[0-467]|15|5[0-4]|6\\\\d|[78]0))\\\\d{4}\"],[\"(?:639(?:0[0-79]|1[019]|[267]\\\\d|3[09]|40|5[05-9]|9[04-79])|7093[5-7])\\\\d{4}\"],[\"80\\\\d{7}\"],0,0,0,0,0,[\"9(?:(?:39|47)8[01]|769\\\\d)\\\\d{4}\"]]],\"ZA\":[\"27\",\"00\",\"[1-79]\\\\d{8}|8\\\\d{4,9}\",[5,6,7,8,9,10],[[\"(\\\\d{2})(\\\\d{3,4})\",\"$1 $2\",[\"8[1-4]\"],\"0$1\"],[\"(\\\\d{2})(\\\\d{3})(\\\\d{2,3})\",\"$1 $2 $3\",[\"8[1-4]\"],\"0$1\"],[\"(\\\\d{3})(\\\\d{3})(\\\\d{3})\",\"$1 $2 $3\",[\"860\"],\"0$1\"],[\"(\\\\d{2})(\\\\d{3})(\\\\d{4})\",\"$1 $2 $3\",[\"[1-9]\"],\"0$1\"],[\"(\\\\d{3})(\\\\d{3})(\\\\d{4})\",\"$1 $2 $3\",[\"8\"],\"0$1\"]],\"0\"],\"ZM\":[\"260\",\"00\",\"800\\\\d{6}|(?:21|[579]\\\\d|63)\\\\d{7}\",[9],[[\"(\\\\d{3})(\\\\d{3})(\\\\d{3})\",\"$1 $2 $3\",[\"[28]\"],\"0$1\"],[\"(\\\\d{2})(\\\\d{7})\",\"$1 $2\",[\"[579]\"],\"0$1\"]],\"0\"],\"ZW\":[\"263\",\"00\",\"2(?:[0-57-9]\\\\d{6,8}|6[0-24-9]\\\\d{6,7})|[38]\\\\d{9}|[35-8]\\\\d{8}|[3-6]\\\\d{7}|[1-689]\\\\d{6}|[1-3569]\\\\d{5}|[1356]\\\\d{4}\",[5,6,7,8,9,10],[[\"(\\\\d{3})(\\\\d{3,5})\",\"$1 $2\",[\"2(?:0[45]|2[278]|[49]8)|3(?:[09]8|17)|6(?:[29]8|37|75)|[23][78]|(?:33|5[15]|6[68])[78]\"],\"0$1\"],[\"(\\\\d)(\\\\d{3})(\\\\d{2,4})\",\"$1 $2 $3\",[\"[49]\"],\"0$1\"],[\"(\\\\d{3})(\\\\d{4})\",\"$1 $2\",[\"80\"],\"0$1\"],[\"(\\\\d{2})(\\\\d{7})\",\"$1 $2\",[\"24|8[13-59]|(?:2[05-79]|39|5[45]|6[15-8])2\",\"2(?:02[014]|4|[56]20|[79]2)|392|5(?:42|525)|6(?:[16-8]21|52[013])|8[13-59]\"],\"(0$1)\"],[\"(\\\\d{2})(\\\\d{3})(\\\\d{4})\",\"$1 $2 $3\",[\"7\"],\"0$1\"],[\"(\\\\d{3})(\\\\d{3})(\\\\d{3,4})\",\"$1 $2 $3\",[\"2(?:1[39]|2[0157]|[378]|[56][14])|3(?:12|29)\",\"2(?:1[39]|2[0157]|[378]|[56][14])|3(?:123|29)\"],\"0$1\"],[\"(\\\\d{4})(\\\\d{6})\",\"$1 $2\",[\"8\"],\"0$1\"],[\"(\\\\d{2})(\\\\d{3,5})\",\"$1 $2\",[\"1|2(?:0[0-36-9]|12|29|[56])|3(?:1[0-689]|[24-6])|5(?:[0236-9]|1[2-4])|6(?:[013-59]|7[0-46-9])|(?:33|55|6[68])[0-69]|(?:29|3[09]|62)[0-79]\"],\"0$1\"],[\"(\\\\d{2})(\\\\d{3})(\\\\d{3,4})\",\"$1 $2 $3\",[\"29[013-9]|39|54\"],\"0$1\"],[\"(\\\\d{4})(\\\\d{3,5})\",\"$1 $2\",[\"(?:25|54)8\",\"258|5483\"],\"0$1\"]],\"0\"]},\"nonGeographic\":{\"800\":[\"800\",0,\"(?:00|[1-9]\\\\d)\\\\d{6}\",[8],[[\"(\\\\d{4})(\\\\d{4})\",\"$1 $2\",[\"\\\\d\"]]],0,0,0,0,0,0,[0,0,[\"(?:00|[1-9]\\\\d)\\\\d{6}\"]]],\"808\":[\"808\",0,\"[1-9]\\\\d{7}\",[8],[[\"(\\\\d{4})(\\\\d{4})\",\"$1 $2\",[\"[1-9]\"]]],0,0,0,0,0,0,[0,0,0,0,0,0,0,0,0,[\"[1-9]\\\\d{7}\"]]],\"870\":[\"870\",0,\"7\\\\d{11}|[235-7]\\\\d{8}\",[9,12],[[\"(\\\\d{3})(\\\\d{3})(\\\\d{3})\",\"$1 $2 $3\",[\"[235-7]\"]]],0,0,0,0,0,0,[0,[\"(?:[356]|774[45])\\\\d{8}|7[6-8]\\\\d{7}\"],0,0,0,0,0,0,[\"2\\\\d{8}\",[9]]]],\"878\":[\"878\",0,\"10\\\\d{10}\",[12],[[\"(\\\\d{2})(\\\\d{5})(\\\\d{5})\",\"$1 $2 $3\",[\"1\"]]],0,0,0,0,0,0,[0,0,0,0,0,0,0,0,[\"10\\\\d{10}\"]]],\"881\":[\"881\",0,\"6\\\\d{9}|[0-36-9]\\\\d{8}\",[9,10],[[\"(\\\\d)(\\\\d{3})(\\\\d{5})\",\"$1 $2 $3\",[\"[0-37-9]\"]],[\"(\\\\d)(\\\\d{3})(\\\\d{5,6})\",\"$1 $2 $3\",[\"6\"]]],0,0,0,0,0,0,[0,[\"6\\\\d{9}|[0-36-9]\\\\d{8}\"]]],\"882\":[\"882\",0,\"[13]\\\\d{6}(?:\\\\d{2,5})?|[19]\\\\d{7}|(?:[25]\\\\d\\\\d|4)\\\\d{7}(?:\\\\d{2})?\",[7,8,9,10,11,12],[[\"(\\\\d{2})(\\\\d{5})\",\"$1 $2\",[\"16|342\"]],[\"(\\\\d{2})(\\\\d{6})\",\"$1 $2\",[\"49\"]],[\"(\\\\d{2})(\\\\d{2})(\\\\d{4})\",\"$1 $2 $3\",[\"1[36]|9\"]],[\"(\\\\d{2})(\\\\d{4})(\\\\d{3})\",\"$1 $2 $3\",[\"3[23]\"]],[\"(\\\\d{2})(\\\\d{3,4})(\\\\d{4})\",\"$1 $2 $3\",[\"16\"]],[\"(\\\\d{2})(\\\\d{4})(\\\\d{4})\",\"$1 $2 $3\",[\"10|23|3(?:[15]|4[57])|4|5[12]\"]],[\"(\\\\d{3})(\\\\d{4})(\\\\d{4})\",\"$1 $2 $3\",[\"34\"]],[\"(\\\\d{2})(\\\\d{4,5})(\\\\d{5})\",\"$1 $2 $3\",[\"[1-35]\"]]],0,0,0,0,0,0,[0,[\"342\\\\d{4}|(?:337|49)\\\\d{6}|(?:3(?:2|47|7\\\\d{3})|5(?:0\\\\d{3}|2[0-2]))\\\\d{7}\",[7,8,9,10,12]],0,0,0,[\"348[57]\\\\d{7}\",[11]],0,0,[\"1(?:3(?:0[0347]|[13][0139]|2[035]|4[013568]|6[0459]|7[06]|8[15-8]|9[0689])\\\\d{4}|6\\\\d{5,10})|(?:345\\\\d|9[89])\\\\d{6}|(?:10|2(?:3|85\\\\d)|3(?:[15]|[69]\\\\d\\\\d)|4[15-8]|51)\\\\d{8}\"]]],\"883\":[\"883\",0,\"(?:[1-4]\\\\d|51)\\\\d{6,10}\",[8,9,10,11,12],[[\"(\\\\d{3})(\\\\d{3})(\\\\d{2,8})\",\"$1 $2 $3\",[\"[14]|2[24-689]|3[02-689]|51[24-9]\"]],[\"(\\\\d{3})(\\\\d{3})(\\\\d{3})\",\"$1 $2 $3\",[\"510\"]],[\"(\\\\d{3})(\\\\d{3})(\\\\d{4})\",\"$1 $2 $3\",[\"21\"]],[\"(\\\\d{4})(\\\\d{4})(\\\\d{4})\",\"$1 $2 $3\",[\"51[13]\"]],[\"(\\\\d{3})(\\\\d{3})(\\\\d{3})(\\\\d{3})\",\"$1 $2 $3 $4\",[\"[235]\"]]],0,0,0,0,0,0,[0,0,0,0,0,0,0,0,[\"(?:2(?:00\\\\d\\\\d|10)|(?:370[1-9]|51\\\\d0)\\\\d)\\\\d{7}|51(?:00\\\\d{5}|[24-9]0\\\\d{4,7})|(?:1[0-79]|2[24-689]|3[02-689]|4[0-4])0\\\\d{5,9}\"]]],\"888\":[\"888\",0,\"\\\\d{11}\",[11],[[\"(\\\\d{3})(\\\\d{3})(\\\\d{5})\",\"$1 $2 $3\"]],0,0,0,0,0,0,[0,0,0,0,0,0,[\"\\\\d{11}\"]]],\"979\":[\"979\",0,\"[1359]\\\\d{8}\",[9],[[\"(\\\\d)(\\\\d{4})(\\\\d{4})\",\"$1 $2 $3\",[\"[1359]\"]]],0,0,0,0,0,0,[0,0,0,[\"[1359]\\\\d{8}\"]]]}}","// Importing from a \".js\" file is a workaround for Node.js \"ES Modules\"\r\n// importing system which is even uncapable of importing \"*.json\" files.\r\nimport metadata from '../../metadata.min.json.js'\r\n\r\nexport default function withMetadataArgument(func, _arguments) {\r\n\tvar args = Array.prototype.slice.call(_arguments)\r\n\targs.push(metadata)\r\n\treturn func.apply(this, args)\r\n}","// The minimum length of the national significant number.\nexport var MIN_LENGTH_FOR_NSN = 2;\n\n// The ITU says the maximum length should be 15,\n// but one can find longer numbers in Germany.\nexport var MAX_LENGTH_FOR_NSN = 17;\n\n// The maximum length of the country calling code.\nexport var MAX_LENGTH_COUNTRY_CODE = 3;\n\n// Digits accepted in phone numbers\n// (ascii, fullwidth, arabic-indic, and eastern arabic digits).\nexport var VALID_DIGITS = \"0-9\\uFF10-\\uFF19\\u0660-\\u0669\\u06F0-\\u06F9\";\n\n// `DASHES` will be right after the opening square bracket of the \"character class\"\nvar DASHES = \"-\\u2010-\\u2015\\u2212\\u30FC\\uFF0D\";\nvar SLASHES = \"\\uFF0F/\";\nvar DOTS = \"\\uFF0E.\";\nexport var WHITESPACE = \" \\xA0\\xAD\\u200B\\u2060\\u3000\";\nvar BRACKETS = \"()\\uFF08\\uFF09\\uFF3B\\uFF3D\\\\[\\\\]\";\n// export const OPENING_BRACKETS = '(\\uFF08\\uFF3B\\\\\\['\nvar TILDES = \"~\\u2053\\u223C\\uFF5E\";\n\n// Regular expression of acceptable punctuation found in phone numbers. This\n// excludes punctuation found as a leading character only. This consists of dash\n// characters, white space characters, full stops, slashes, square brackets,\n// parentheses and tildes. Full-width variants are also present.\nexport var VALID_PUNCTUATION = \"\".concat(DASHES).concat(SLASHES).concat(DOTS).concat(WHITESPACE).concat(BRACKETS).concat(TILDES);\nexport var PLUS_CHARS = \"+\\uFF0B\";\n// const LEADING_PLUS_CHARS_PATTERN = new RegExp('^[' + PLUS_CHARS + ']+')\n//# sourceMappingURL=constants.js.map","function _typeof(o) { \"@babel/helpers - typeof\"; return _typeof = \"function\" == typeof Symbol && \"symbol\" == typeof Symbol.iterator ? function (o) { return typeof o; } : function (o) { return o && \"function\" == typeof Symbol && o.constructor === Symbol && o !== Symbol.prototype ? \"symbol\" : typeof o; }, _typeof(o); }\nfunction _defineProperties(e, r) { for (var t = 0; t < r.length; t++) { var o = r[t]; o.enumerable = o.enumerable || !1, o.configurable = !0, \"value\" in o && (o.writable = !0), Object.defineProperty(e, _toPropertyKey(o.key), o); } }\nfunction _createClass(e, r, t) { return r && _defineProperties(e.prototype, r), t && _defineProperties(e, t), Object.defineProperty(e, \"prototype\", { writable: !1 }), e; }\nfunction _toPropertyKey(t) { var i = _toPrimitive(t, \"string\"); return \"symbol\" == _typeof(i) ? i : i + \"\"; }\nfunction _toPrimitive(t, r) { if (\"object\" != _typeof(t) || !t) return t; var e = t[Symbol.toPrimitive]; if (void 0 !== e) { var i = e.call(t, r || \"default\"); if (\"object\" != _typeof(i)) return i; throw new TypeError(\"@@toPrimitive must return a primitive value.\"); } return (\"string\" === r ? String : Number)(t); }\nfunction _classCallCheck(a, n) { if (!(a instanceof n)) throw new TypeError(\"Cannot call a class as a function\"); }\nfunction _callSuper(t, o, e) { return o = _getPrototypeOf(o), _possibleConstructorReturn(t, _isNativeReflectConstruct() ? Reflect.construct(o, e || [], _getPrototypeOf(t).constructor) : o.apply(t, e)); }\nfunction _possibleConstructorReturn(t, e) { if (e && (\"object\" == _typeof(e) || \"function\" == typeof e)) return e; if (void 0 !== e) throw new TypeError(\"Derived constructors may only return object or undefined\"); return _assertThisInitialized(t); }\nfunction _assertThisInitialized(e) { if (void 0 === e) throw new ReferenceError(\"this hasn't been initialised - super() hasn't been called\"); return e; }\nfunction _inherits(t, e) { if (\"function\" != typeof e && null !== e) throw new TypeError(\"Super expression must either be null or a function\"); t.prototype = Object.create(e && e.prototype, { constructor: { value: t, writable: !0, configurable: !0 } }), Object.defineProperty(t, \"prototype\", { writable: !1 }), e && _setPrototypeOf(t, e); }\nfunction _wrapNativeSuper(t) { var r = \"function\" == typeof Map ? new Map() : void 0; return _wrapNativeSuper = function _wrapNativeSuper(t) { if (null === t || !_isNativeFunction(t)) return t; if (\"function\" != typeof t) throw new TypeError(\"Super expression must either be null or a function\"); if (void 0 !== r) { if (r.has(t)) return r.get(t); r.set(t, Wrapper); } function Wrapper() { return _construct(t, arguments, _getPrototypeOf(this).constructor); } return Wrapper.prototype = Object.create(t.prototype, { constructor: { value: Wrapper, enumerable: !1, writable: !0, configurable: !0 } }), _setPrototypeOf(Wrapper, t); }, _wrapNativeSuper(t); }\nfunction _construct(t, e, r) { if (_isNativeReflectConstruct()) return Reflect.construct.apply(null, arguments); var o = [null]; o.push.apply(o, e); var p = new (t.bind.apply(t, o))(); return r && _setPrototypeOf(p, r.prototype), p; }\nfunction _isNativeReflectConstruct() { try { var t = !Boolean.prototype.valueOf.call(Reflect.construct(Boolean, [], function () {})); } catch (t) {} return (_isNativeReflectConstruct = function _isNativeReflectConstruct() { return !!t; })(); }\nfunction _isNativeFunction(t) { try { return -1 !== Function.toString.call(t).indexOf(\"[native code]\"); } catch (n) { return \"function\" == typeof t; } }\nfunction _setPrototypeOf(t, e) { return _setPrototypeOf = Object.setPrototypeOf ? Object.setPrototypeOf.bind() : function (t, e) { return t.__proto__ = e, t; }, _setPrototypeOf(t, e); }\nfunction _getPrototypeOf(t) { return _getPrototypeOf = Object.setPrototypeOf ? Object.getPrototypeOf.bind() : function (t) { return t.__proto__ || Object.getPrototypeOf(t); }, _getPrototypeOf(t); }\n// https://stackoverflow.com/a/46971044/970769\n// \"Breaking changes in Typescript 2.1\"\n// \"Extending built-ins like Error, Array, and Map may no longer work.\"\n// \"As a recommendation, you can manually adjust the prototype immediately after any super(...) calls.\"\n// https://github.com/Microsoft/TypeScript-wiki/blob/main/Breaking-Changes.md#extending-built-ins-like-error-array-and-map-may-no-longer-work\nvar ParseError = /*#__PURE__*/function (_Error) {\n function ParseError(code) {\n var _this;\n _classCallCheck(this, ParseError);\n _this = _callSuper(this, ParseError, [code]);\n // Set the prototype explicitly.\n // Any subclass of FooError will have to manually set the prototype as well.\n Object.setPrototypeOf(_this, ParseError.prototype);\n _this.name = _this.constructor.name;\n return _this;\n }\n _inherits(ParseError, _Error);\n return _createClass(ParseError);\n}(/*#__PURE__*/_wrapNativeSuper(Error));\nexport { ParseError as default };\n//# sourceMappingURL=ParseError.js.map","// Copy-pasted from:\n// https://github.com/substack/semver-compare/blob/master/index.js\n//\n// Inlining this function because some users reported issues with\n// importing from `semver-compare` in a browser with ES6 \"native\" modules.\n//\n// Fixes `semver-compare` not being able to compare versions with alpha/beta/etc \"tags\".\n// https://github.com/catamphetamine/libphonenumber-js/issues/381\nexport default function (a, b) {\n a = a.split('-');\n b = b.split('-');\n var pa = a[0].split('.');\n var pb = b[0].split('.');\n for (var i = 0; i < 3; i++) {\n var na = Number(pa[i]);\n var nb = Number(pb[i]);\n if (na > nb) return 1;\n if (nb > na) return -1;\n if (!isNaN(na) && isNaN(nb)) return 1;\n if (isNaN(na) && !isNaN(nb)) return -1;\n }\n if (a[1] && b[1]) {\n return a[1] > b[1] ? 1 : a[1] < b[1] ? -1 : 0;\n }\n return !a[1] && b[1] ? 1 : a[1] && !b[1] ? -1 : 0;\n}\n//# sourceMappingURL=semver-compare.js.map","var objectConstructor = {}.constructor;\nexport default function isObject(object) {\n return object !== undefined && object !== null && object.constructor === objectConstructor;\n}\n//# sourceMappingURL=isObject.js.map","var CALLING_CODE_REG_EXP = /^\\d+$/;\nexport default function isCallingCode(string) {\n return CALLING_CODE_REG_EXP.test(string);\n}\n//# sourceMappingURL=isCallingCode.js.map","function _readOnlyError(r) { throw new TypeError('\"' + r + '\" is read-only'); }\nfunction _typeof(o) { \"@babel/helpers - typeof\"; return _typeof = \"function\" == typeof Symbol && \"symbol\" == typeof Symbol.iterator ? function (o) { return typeof o; } : function (o) { return o && \"function\" == typeof Symbol && o.constructor === Symbol && o !== Symbol.prototype ? \"symbol\" : typeof o; }, _typeof(o); }\nfunction _classCallCheck(a, n) { if (!(a instanceof n)) throw new TypeError(\"Cannot call a class as a function\"); }\nfunction _defineProperties(e, r) { for (var t = 0; t < r.length; t++) { var o = r[t]; o.enumerable = o.enumerable || !1, o.configurable = !0, \"value\" in o && (o.writable = !0), Object.defineProperty(e, _toPropertyKey(o.key), o); } }\nfunction _createClass(e, r, t) { return r && _defineProperties(e.prototype, r), t && _defineProperties(e, t), Object.defineProperty(e, \"prototype\", { writable: !1 }), e; }\nfunction _toPropertyKey(t) { var i = _toPrimitive(t, \"string\"); return \"symbol\" == _typeof(i) ? i : i + \"\"; }\nfunction _toPrimitive(t, r) { if (\"object\" != _typeof(t) || !t) return t; var e = t[Symbol.toPrimitive]; if (void 0 !== e) { var i = e.call(t, r || \"default\"); if (\"object\" != _typeof(i)) return i; throw new TypeError(\"@@toPrimitive must return a primitive value.\"); } return (\"string\" === r ? String : Number)(t); }\nimport compare from './tools/semver-compare.js';\nimport isObject from './helpers/isObject.js';\nimport isCallingCode from './helpers/isCallingCode.js';\n\n// Added \"possibleLengths\" and renamed\n// \"country_phone_code_to_countries\" to \"country_calling_codes\".\nvar V2 = '1.0.18';\n\n// Added \"idd_prefix\" and \"default_idd_prefix\".\nvar V3 = '1.2.0';\n\n// Moved `001` country code to \"nonGeographic\" section of metadata.\nvar V4 = '1.7.35';\nvar DEFAULT_EXT_PREFIX = ' ext. ';\n\n/**\r\n * See: https://gitlab.com/catamphetamine/libphonenumber-js/blob/master/METADATA.md\r\n */\nvar Metadata = /*#__PURE__*/function () {\n /**\r\n * @param {object} metadata — Metadata JSON.\r\n */\n function Metadata(metadata) {\n _classCallCheck(this, Metadata);\n validateMetadata(metadata);\n this.metadata = metadata;\n setVersion.call(this, metadata);\n }\n return _createClass(Metadata, [{\n key: \"getCountries\",\n value: function getCountries() {\n return Object.keys(this.metadata.countries).filter(function (_) {\n return _ !== '001';\n });\n }\n }, {\n key: \"getCountryMetadata\",\n value: function getCountryMetadata(countryCode) {\n return this.metadata.countries[countryCode];\n }\n }, {\n key: \"nonGeographic\",\n value: function nonGeographic() {\n if (this.v1 || this.v2 || this.v3) return;\n // `nonGeographical` was a typo.\n // It's present in metadata generated from `1.7.35` to `1.7.37`.\n // The test case could be found by searching for \"nonGeographical\".\n return this.metadata.nonGeographic || this.metadata.nonGeographical;\n }\n }, {\n key: \"hasCountry\",\n value: function hasCountry(country) {\n return this.getCountryMetadata(country) !== undefined;\n }\n }, {\n key: \"hasCallingCode\",\n value: function hasCallingCode(callingCode) {\n if (this.getCountryCodesForCallingCode(callingCode)) {\n return true;\n }\n if (this.nonGeographic()) {\n if (this.nonGeographic()[callingCode]) {\n return true;\n }\n } else {\n // A hacky workaround for old custom metadata (generated before V4).\n var countryCodes = this.countryCallingCodes()[callingCode];\n if (countryCodes && countryCodes.length === 1 && countryCodes[0] === '001') {\n return true;\n }\n }\n }\n }, {\n key: \"isNonGeographicCallingCode\",\n value: function isNonGeographicCallingCode(callingCode) {\n if (this.nonGeographic()) {\n return this.nonGeographic()[callingCode] ? true : false;\n } else {\n return this.getCountryCodesForCallingCode(callingCode) ? false : true;\n }\n }\n\n // Deprecated.\n }, {\n key: \"country\",\n value: function country(countryCode) {\n return this.selectNumberingPlan(countryCode);\n }\n\n /**\r\n * Selects a telephone numbering plan based on either a country code or a calling code.\r\n * @param {string} argument — Country code or calling code.\r\n * @param {string} legacyArgumentCallingCode — Legacy argument: calling code, if the first argument is not passed.\r\n */\n }, {\n key: \"selectNumberingPlan\",\n value: function selectNumberingPlan(argument, legacyArgumentCallingCode) {\n var countryCode;\n var callingCode;\n if (argument) {\n if (isCallingCode(argument)) {\n callingCode = argument;\n } else {\n countryCode = argument;\n }\n }\n // Previously, the signature of this method was: `.selectNumberingPlan(country, callingCode)`.\n // And if `country` argument wasn't passed, it looked into the second argument `callingCode`.\n // Now it's preferred to only pass either `country` or `callingCode` as the first argument.\n if (legacyArgumentCallingCode) {\n callingCode = legacyArgumentCallingCode;\n }\n\n // Select a telephone numbering plan.\n if (countryCode && countryCode !== '001') {\n var countryMetadata = this.getCountryMetadata(countryCode);\n if (!countryMetadata) {\n throw new Error(\"Unknown country: \".concat(countryCode));\n }\n this.numberingPlan = new NumberingPlan(countryMetadata, this);\n } else if (callingCode) {\n if (!this.hasCallingCode(callingCode)) {\n throw new Error(\"Unknown calling code: \".concat(callingCode));\n }\n this.numberingPlan = new NumberingPlan(this.getNumberingPlanMetadata(callingCode), this);\n } else {\n this.numberingPlan = undefined;\n }\n return this;\n }\n }, {\n key: \"getCountryCodesForCallingCode\",\n value: function getCountryCodesForCallingCode(callingCode) {\n var countryCodes = this.countryCallingCodes()[callingCode];\n if (countryCodes) {\n // Metadata before V4 included \"non-geographic entity\" calling codes\n // inside `country_calling_codes` (for example, `\"881\":[\"001\"]`).\n // Now the semantics of `country_calling_codes` has changed:\n // it's specifically for \"countries\" now.\n // Older versions of custom metadata will simply skip parsing\n // \"non-geographic entity\" phone numbers with new versions\n // of this library: it's not considered a bug,\n // because such numbers are extremely rare,\n // and developers extremely rarely use custom metadata.\n if (countryCodes.length === 1 && countryCodes[0].length === 3) {\n return;\n }\n return countryCodes;\n }\n }\n }, {\n key: \"getCountryCodeForCallingCode\",\n value: function getCountryCodeForCallingCode(callingCode) {\n var countryCodes = this.getCountryCodesForCallingCode(callingCode);\n if (countryCodes) {\n return countryCodes[0];\n }\n }\n }, {\n key: \"getNumberingPlanMetadata\",\n value: function getNumberingPlanMetadata(callingCode) {\n // If a calling code is specified, choose the telephone numbering plan\n // of the \"default\" country for this calling code.\n // For example, if calling code `1` is passed,\n // the telephone numbering plan of `US` will be selected.\n var countryCode = this.getCountryCodeForCallingCode(callingCode);\n if (countryCode) {\n return this.getCountryMetadata(countryCode);\n }\n if (this.nonGeographic()) {\n var metadata = this.nonGeographic()[callingCode];\n if (metadata) {\n return metadata;\n }\n } else {\n // A hacky workaround for old custom metadata (generated before V4).\n // In that metadata, there was no concept of \"non-geographic\" metadata\n // so metadata for `001` country code was stored along with other countries.\n // The test case can be found by searching for:\n // \"should work around `nonGeographic` metadata not existing\".\n var countryCodes = this.countryCallingCodes()[callingCode];\n if (countryCodes && countryCodes.length === 1 && countryCodes[0] === '001') {\n return this.metadata.countries['001'];\n }\n }\n }\n\n // Deprecated.\n }, {\n key: \"countryCallingCode\",\n value: function countryCallingCode() {\n return this.numberingPlan.callingCode();\n }\n\n // Deprecated.\n }, {\n key: \"IDDPrefix\",\n value: function IDDPrefix() {\n return this.numberingPlan.IDDPrefix();\n }\n\n // Deprecated.\n }, {\n key: \"defaultIDDPrefix\",\n value: function defaultIDDPrefix() {\n return this.numberingPlan.defaultIDDPrefix();\n }\n\n // Deprecated.\n }, {\n key: \"nationalNumberPattern\",\n value: function nationalNumberPattern() {\n return this.numberingPlan.nationalNumberPattern();\n }\n\n // Deprecated.\n }, {\n key: \"possibleLengths\",\n value: function possibleLengths() {\n return this.numberingPlan.possibleLengths();\n }\n\n // Deprecated.\n }, {\n key: \"formats\",\n value: function formats() {\n return this.numberingPlan.formats();\n }\n\n // Deprecated.\n }, {\n key: \"nationalPrefixForParsing\",\n value: function nationalPrefixForParsing() {\n return this.numberingPlan.nationalPrefixForParsing();\n }\n\n // Deprecated.\n }, {\n key: \"nationalPrefixTransformRule\",\n value: function nationalPrefixTransformRule() {\n return this.numberingPlan.nationalPrefixTransformRule();\n }\n\n // Deprecated.\n }, {\n key: \"leadingDigits\",\n value: function leadingDigits() {\n return this.numberingPlan.leadingDigits();\n }\n\n // Deprecated.\n }, {\n key: \"hasTypes\",\n value: function hasTypes() {\n return this.numberingPlan.hasTypes();\n }\n\n // Deprecated.\n }, {\n key: \"type\",\n value: function type(_type) {\n return this.numberingPlan.type(_type);\n }\n\n // Deprecated.\n }, {\n key: \"ext\",\n value: function ext() {\n return this.numberingPlan.ext();\n }\n }, {\n key: \"countryCallingCodes\",\n value: function countryCallingCodes() {\n if (this.v1) return this.metadata.country_phone_code_to_countries;\n return this.metadata.country_calling_codes;\n }\n\n // Deprecated.\n }, {\n key: \"chooseCountryByCountryCallingCode\",\n value: function chooseCountryByCountryCallingCode(callingCode) {\n return this.selectNumberingPlan(callingCode);\n }\n }, {\n key: \"hasSelectedNumberingPlan\",\n value: function hasSelectedNumberingPlan() {\n return this.numberingPlan !== undefined;\n }\n }]);\n}();\nexport { Metadata as default };\nvar NumberingPlan = /*#__PURE__*/function () {\n function NumberingPlan(metadata, globalMetadataObject) {\n _classCallCheck(this, NumberingPlan);\n this.globalMetadataObject = globalMetadataObject;\n this.metadata = metadata;\n setVersion.call(this, globalMetadataObject.metadata);\n }\n return _createClass(NumberingPlan, [{\n key: \"callingCode\",\n value: function callingCode() {\n return this.metadata[0];\n }\n\n // When multiple countries share the same calling code,\n // all phone number formatting rules are included in the metadata\n // of the \"default\" country for that calling code.\n // Any other countries' metdata doesn't include any formatting rules.\n // Google developers said that such storage architecture was chosen for performance reasons.\n //\n // For example, for NANPA region (\"North American Numbering Plan Administration\",\n // which includes USA, Canada, Cayman Islands, Bahamas, etc) all formatting rules\n // are contained in the metadata of `US` country.\n //\n // This is not public API.\n //\n }, {\n key: \"_getDefaultCountryMetadataForThisCallingCode\",\n value: function _getDefaultCountryMetadataForThisCallingCode() {\n return this.globalMetadataObject.getNumberingPlanMetadata(this.callingCode());\n }\n\n // Deprecated.\n }, {\n key: \"getDefaultCountryMetadataForRegion\",\n value: function getDefaultCountryMetadataForRegion() {\n return this._getDefaultCountryMetadataForThisCallingCode();\n }\n\n // Is always present.\n }, {\n key: \"IDDPrefix\",\n value: function IDDPrefix() {\n if (this.v1 || this.v2) return;\n return this.metadata[1];\n }\n\n // Is only present when a country supports multiple IDD prefixes.\n }, {\n key: \"defaultIDDPrefix\",\n value: function defaultIDDPrefix() {\n if (this.v1 || this.v2) return;\n return this.metadata[12];\n }\n }, {\n key: \"nationalNumberPattern\",\n value: function nationalNumberPattern() {\n if (this.v1 || this.v2) return this.metadata[1];\n return this.metadata[2];\n }\n\n // \"possible length\" data is always present in Google's metadata.\n }, {\n key: \"possibleLengths\",\n value: function possibleLengths() {\n if (this.v1) return;\n return this.metadata[this.v2 ? 2 : 3];\n }\n }, {\n key: \"_getFormats\",\n value: function _getFormats(metadata) {\n return metadata[this.v1 ? 2 : this.v2 ? 3 : 4];\n }\n\n // For countries of the same region (e.g. NANPA)\n // formats are all stored in the \"main\" country for that region.\n // E.g. \"RU\" and \"KZ\", \"US\" and \"CA\".\n }, {\n key: \"formats\",\n value: function formats() {\n var _this = this;\n var formats = this._getFormats(this.metadata) || this._getFormats(this._getDefaultCountryMetadataForThisCallingCode()) || [];\n return formats.map(function (_) {\n return new Format(_, _this);\n });\n }\n }, {\n key: \"nationalPrefix\",\n value: function nationalPrefix() {\n return this.metadata[this.v1 ? 3 : this.v2 ? 4 : 5];\n }\n }, {\n key: \"_getNationalPrefixFormattingRule\",\n value: function _getNationalPrefixFormattingRule(metadata) {\n return metadata[this.v1 ? 4 : this.v2 ? 5 : 6];\n }\n\n // For countries of the same region (e.g. NANPA)\n // national prefix formatting rule is stored in the \"main\" country for that region.\n // E.g. \"RU\" and \"KZ\", \"US\" and \"CA\".\n }, {\n key: \"nationalPrefixFormattingRule\",\n value: function nationalPrefixFormattingRule() {\n return this._getNationalPrefixFormattingRule(this.metadata) || this._getNationalPrefixFormattingRule(this._getDefaultCountryMetadataForThisCallingCode());\n }\n }, {\n key: \"_nationalPrefixForParsing\",\n value: function _nationalPrefixForParsing() {\n return this.metadata[this.v1 ? 5 : this.v2 ? 6 : 7];\n }\n }, {\n key: \"nationalPrefixForParsing\",\n value: function nationalPrefixForParsing() {\n // If `national_prefix_for_parsing` is not set explicitly,\n // then infer it from `national_prefix` (if any)\n return this._nationalPrefixForParsing() || this.nationalPrefix();\n }\n }, {\n key: \"nationalPrefixTransformRule\",\n value: function nationalPrefixTransformRule() {\n return this.metadata[this.v1 ? 6 : this.v2 ? 7 : 8];\n }\n }, {\n key: \"_getNationalPrefixIsOptionalWhenFormatting\",\n value: function _getNationalPrefixIsOptionalWhenFormatting() {\n return !!this.metadata[this.v1 ? 7 : this.v2 ? 8 : 9];\n }\n\n // For countries of the same region (e.g. NANPA)\n // \"national prefix is optional when formatting\" flag is\n // stored in the \"main\" country for that region.\n // E.g. \"RU\" and \"KZ\", \"US\" and \"CA\".\n }, {\n key: \"nationalPrefixIsOptionalWhenFormattingInNationalFormat\",\n value: function nationalPrefixIsOptionalWhenFormattingInNationalFormat() {\n return this._getNationalPrefixIsOptionalWhenFormatting(this.metadata) || this._getNationalPrefixIsOptionalWhenFormatting(this._getDefaultCountryMetadataForThisCallingCode());\n }\n }, {\n key: \"leadingDigits\",\n value: function leadingDigits() {\n return this.metadata[this.v1 ? 8 : this.v2 ? 9 : 10];\n }\n }, {\n key: \"types\",\n value: function types() {\n return this.metadata[this.v1 ? 9 : this.v2 ? 10 : 11];\n }\n }, {\n key: \"hasTypes\",\n value: function hasTypes() {\n // Versions 1.2.0 - 1.2.4: can be `[]`.\n /* istanbul ignore next */\n if (this.types() && this.types().length === 0) {\n return false;\n }\n // Versions <= 1.2.4: can be `undefined`.\n // Version >= 1.2.5: can be `0`.\n return !!this.types();\n }\n }, {\n key: \"type\",\n value: function type(_type2) {\n if (this.hasTypes() && getType(this.types(), _type2)) {\n return new Type(getType(this.types(), _type2), this);\n }\n }\n }, {\n key: \"ext\",\n value: function ext() {\n if (this.v1 || this.v2) return DEFAULT_EXT_PREFIX;\n return this.metadata[13] || DEFAULT_EXT_PREFIX;\n }\n }]);\n}();\nvar Format = /*#__PURE__*/function () {\n function Format(format, metadata) {\n _classCallCheck(this, Format);\n this._format = format;\n this.metadata = metadata;\n }\n return _createClass(Format, [{\n key: \"pattern\",\n value: function pattern() {\n return this._format[0];\n }\n }, {\n key: \"format\",\n value: function format() {\n return this._format[1];\n }\n }, {\n key: \"leadingDigitsPatterns\",\n value: function leadingDigitsPatterns() {\n return this._format[2] || [];\n }\n }, {\n key: \"nationalPrefixFormattingRule\",\n value: function nationalPrefixFormattingRule() {\n return this._format[3] || this.metadata.nationalPrefixFormattingRule();\n }\n }, {\n key: \"nationalPrefixIsOptionalWhenFormattingInNationalFormat\",\n value: function nationalPrefixIsOptionalWhenFormattingInNationalFormat() {\n return !!this._format[4] || this.metadata.nationalPrefixIsOptionalWhenFormattingInNationalFormat();\n }\n }, {\n key: \"nationalPrefixIsMandatoryWhenFormattingInNationalFormat\",\n value: function nationalPrefixIsMandatoryWhenFormattingInNationalFormat() {\n // National prefix is omitted if there's no national prefix formatting rule\n // set for this country, or when the national prefix formatting rule\n // contains no national prefix itself, or when this rule is set but\n // national prefix is optional for this phone number format\n // (and it is not enforced explicitly)\n return this.usesNationalPrefix() && !this.nationalPrefixIsOptionalWhenFormattingInNationalFormat();\n }\n\n // Checks whether national prefix formatting rule contains national prefix.\n }, {\n key: \"usesNationalPrefix\",\n value: function usesNationalPrefix() {\n return this.nationalPrefixFormattingRule() &&\n // Check that national prefix formatting rule is not a \"dummy\" one.\n !FIRST_GROUP_ONLY_PREFIX_PATTERN.test(this.nationalPrefixFormattingRule())\n // In compressed metadata, `this.nationalPrefixFormattingRule()` is `0`\n // when `national_prefix_formatting_rule` is not present.\n // So, `true` or `false` are returned explicitly here, so that\n // `0` number isn't returned.\n ? true : false;\n }\n }, {\n key: \"internationalFormat\",\n value: function internationalFormat() {\n return this._format[5] || this.format();\n }\n }]);\n}();\n/**\r\n * A pattern that is used to determine if the national prefix formatting rule\r\n * has the first group only, i.e., does not start with the national prefix.\r\n * Note that the pattern explicitly allows for unbalanced parentheses.\r\n */\nvar FIRST_GROUP_ONLY_PREFIX_PATTERN = /^\\(?\\$1\\)?$/;\nvar Type = /*#__PURE__*/function () {\n function Type(type, metadata) {\n _classCallCheck(this, Type);\n this.type = type;\n this.metadata = metadata;\n }\n return _createClass(Type, [{\n key: \"pattern\",\n value: function pattern() {\n if (this.metadata.v1) return this.type;\n return this.type[0];\n }\n }, {\n key: \"possibleLengths\",\n value: function possibleLengths() {\n if (this.metadata.v1) return;\n return this.type[1] || this.metadata.possibleLengths();\n }\n }]);\n}();\nfunction getType(types, type) {\n switch (type) {\n case 'FIXED_LINE':\n return types[0];\n case 'MOBILE':\n return types[1];\n case 'TOLL_FREE':\n return types[2];\n case 'PREMIUM_RATE':\n return types[3];\n case 'PERSONAL_NUMBER':\n return types[4];\n case 'VOICEMAIL':\n return types[5];\n case 'UAN':\n return types[6];\n case 'PAGER':\n return types[7];\n case 'VOIP':\n return types[8];\n case 'SHARED_COST':\n return types[9];\n }\n}\nexport function validateMetadata(metadata) {\n if (!metadata) {\n throw new Error('[libphonenumber-js] `metadata` argument not passed. Check your arguments.');\n }\n\n // `country_phone_code_to_countries` was renamed to `country_calling_codes` in `1.0.18`.\n // For that reason, it's not used in this detection algorithm.\n // Instead, it detects by `countries: {}` property existence.\n if (!isObject(metadata) || !isObject(metadata.countries)) {\n 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(isObject(metadata) ? 'an object of shape: { ' + Object.keys(metadata).join(', ') + ' }' : 'a ' + typeOf(metadata) + ': ' + metadata, \".\"));\n }\n}\n\n// Babel transforms `typeof` into some \"branches\"\n// so istanbul will show this as \"branch not covered\".\n/* istanbul ignore next */\nvar typeOf = function typeOf(_) {\n return _typeof(_);\n};\n\n/**\r\n * Returns extension prefix for a country.\r\n * @param {string} country\r\n * @param {object} metadata\r\n * @return {string?}\r\n * @example\r\n * // Returns \" ext. \"\r\n * getExtPrefix(\"US\")\r\n */\nexport function getExtPrefix(country, metadataJson) {\n var metadata = new Metadata(metadataJson);\n if (metadata.hasCountry(country)) {\n return metadata.selectNumberingPlan(country).ext();\n }\n return DEFAULT_EXT_PREFIX;\n}\n\n/**\r\n * Returns \"country calling code\" for a country.\r\n * Throws an error if the country doesn't exist or isn't supported by this library.\r\n * @param {string} country\r\n * @param {object} metadataJson\r\n * @return {string}\r\n * @example\r\n * // Returns \"44\"\r\n * getCountryCallingCode(\"GB\")\r\n */\nexport function getCountryCallingCode(country, metadataJson) {\n var metadata = new Metadata(metadataJson);\n if (metadata.hasCountry(country)) {\n return metadata.selectNumberingPlan(country).countryCallingCode();\n }\n throw new Error(\"Unknown country: \".concat(country));\n}\n\n/**\r\n * Tells if a country code is supported.\r\n * @param {string} country\r\n * @param {object} metadataJson\r\n * @return {boolean}\r\n * @example\r\n * // Returns `true`\r\n * isSupportedCountry(\"GB\")\r\n */\nexport function isSupportedCountry(country, metadataJson) {\n // const metadata = new Metadata(metadataJson)\n // return metadata.hasCountry(country)\n return metadataJson.countries.hasOwnProperty(country);\n}\n\n/**\r\n * Sets `v1`/`v2`/`v3`/`v4` properties on `this` object.\r\n * @param {object} metadata — Metadata JSON\r\n */\nfunction setVersion(metadata) {\n var version = metadata.version;\n if (typeof version === 'number') {\n this.v1 = version === 1;\n this.v2 = version === 2;\n this.v3 = version === 3;\n this.v4 = version === 4;\n } else {\n if (!version) {\n this.v1 = true;\n } else if (compare(version, V3) === -1) {\n this.v2 = true;\n } else if (compare(version, V4) === -1) {\n this.v3 = true;\n } else {\n this.v4 = true;\n }\n }\n}\n//# sourceMappingURL=metadata.js.map","import { VALID_DIGITS } from '../../constants.js';\n\n// The RFC 3966 format for extensions.\nvar RFC3966_EXTN_PREFIX = ';ext=';\n\n/**\r\n * Helper method for constructing regular expressions for parsing. Creates\r\n * an expression that captures up to max_length digits.\r\n * @return {string} RegEx pattern to capture extension digits.\r\n */\nvar getExtensionDigitsPattern = function getExtensionDigitsPattern(maxLength) {\n return \"([\".concat(VALID_DIGITS, \"]{1,\").concat(maxLength, \"})\");\n};\n\n/**\r\n * Helper initialiser method to create the regular-expression pattern to match\r\n * extensions.\r\n * Copy-pasted from Google's `libphonenumber`:\r\n * https://github.com/google/libphonenumber/blob/55b2646ec9393f4d3d6661b9c82ef9e258e8b829/javascript/i18n/phonenumbers/phonenumberutil.js#L759-L766\r\n * @return {string} RegEx pattern to capture extensions.\r\n */\nexport default function createExtensionPattern(purpose) {\n // We cap the maximum length of an extension based on the ambiguity of the way\n // the extension is prefixed. As per ITU, the officially allowed length for\n // extensions is actually 40, but we don't support this since we haven't seen real\n // examples and this introduces many false interpretations as the extension labels\n // are not standardized.\n /** @type {string} */\n var extLimitAfterExplicitLabel = '20';\n /** @type {string} */\n var extLimitAfterLikelyLabel = '15';\n /** @type {string} */\n var extLimitAfterAmbiguousChar = '9';\n /** @type {string} */\n var extLimitWhenNotSure = '6';\n\n /** @type {string} */\n var possibleSeparatorsBetweenNumberAndExtLabel = \"[ \\xA0\\\\t,]*\";\n // Optional full stop (.) or colon, followed by zero or more spaces/tabs/commas.\n /** @type {string} */\n var possibleCharsAfterExtLabel = \"[:\\\\.\\uFF0E]?[ \\xA0\\\\t,-]*\";\n /** @type {string} */\n var optionalExtnSuffix = \"#?\";\n\n // Here the extension is called out in more explicit way, i.e mentioning it obvious\n // patterns like \"ext.\".\n /** @type {string} */\n var explicitExtLabels = \"(?:e?xt(?:ensi(?:o\\u0301?|\\xF3))?n?|\\uFF45?\\uFF58\\uFF54\\uFF4E?|\\u0434\\u043E\\u0431|anexo)\";\n // One-character symbols that can be used to indicate an extension, and less\n // commonly used or more ambiguous extension labels.\n /** @type {string} */\n var ambiguousExtLabels = \"(?:[x\\uFF58#\\uFF03~\\uFF5E]|int|\\uFF49\\uFF4E\\uFF54)\";\n // When extension is not separated clearly.\n /** @type {string} */\n var ambiguousSeparator = \"[- ]+\";\n // This is the same as possibleSeparatorsBetweenNumberAndExtLabel, but not matching\n // comma as extension label may have it.\n /** @type {string} */\n var possibleSeparatorsNumberExtLabelNoComma = \"[ \\xA0\\\\t]*\";\n // \",,\" is commonly used for auto dialling the extension when connected. First\n // comma is matched through possibleSeparatorsBetweenNumberAndExtLabel, so we do\n // not repeat it here. Semi-colon works in Iphone and Android also to pop up a\n // button with the extension number following.\n /** @type {string} */\n var autoDiallingAndExtLabelsFound = \"(?:,{2}|;)\";\n\n /** @type {string} */\n var rfcExtn = RFC3966_EXTN_PREFIX + getExtensionDigitsPattern(extLimitAfterExplicitLabel);\n /** @type {string} */\n var explicitExtn = possibleSeparatorsBetweenNumberAndExtLabel + explicitExtLabels + possibleCharsAfterExtLabel + getExtensionDigitsPattern(extLimitAfterExplicitLabel) + optionalExtnSuffix;\n /** @type {string} */\n var ambiguousExtn = possibleSeparatorsBetweenNumberAndExtLabel + ambiguousExtLabels + possibleCharsAfterExtLabel + getExtensionDigitsPattern(extLimitAfterAmbiguousChar) + optionalExtnSuffix;\n /** @type {string} */\n var americanStyleExtnWithSuffix = ambiguousSeparator + getExtensionDigitsPattern(extLimitWhenNotSure) + \"#\";\n\n /** @type {string} */\n var autoDiallingExtn = possibleSeparatorsNumberExtLabelNoComma + autoDiallingAndExtLabelsFound + possibleCharsAfterExtLabel + getExtensionDigitsPattern(extLimitAfterLikelyLabel) + optionalExtnSuffix;\n /** @type {string} */\n var onlyCommasExtn = possibleSeparatorsNumberExtLabelNoComma + \"(?:,)+\" + possibleCharsAfterExtLabel + getExtensionDigitsPattern(extLimitAfterAmbiguousChar) + optionalExtnSuffix;\n\n // The first regular expression covers RFC 3966 format, where the extension is added\n // using \";ext=\". The second more generic where extension is mentioned with explicit\n // labels like \"ext:\". In both the above cases we allow more numbers in extension than\n // any other extension labels. The third one captures when single character extension\n // labels or less commonly used labels are used. In such cases we capture fewer\n // extension digits in order to reduce the chance of falsely interpreting two\n // numbers beside each other as a number + extension. The fourth one covers the\n // special case of American numbers where the extension is written with a hash\n // at the end, such as \"- 503#\". The fifth one is exclusively for extension\n // autodialling formats which are used when dialling and in this case we accept longer\n // extensions. The last one is more liberal on the number of commas that acts as\n // extension labels, so we have a strict cap on the number of digits in such extensions.\n return rfcExtn + \"|\" + explicitExtn + \"|\" + ambiguousExtn + \"|\" + americanStyleExtnWithSuffix + \"|\" + autoDiallingExtn + \"|\" + onlyCommasExtn;\n}\n//# sourceMappingURL=createExtensionPattern.js.map","import { MIN_LENGTH_FOR_NSN, VALID_DIGITS, VALID_PUNCTUATION, PLUS_CHARS } from '../constants.js';\nimport createExtensionPattern from './extension/createExtensionPattern.js';\n\n// Regular expression of viable phone numbers. This is location independent.\n// Checks we have at least three leading digits, and only valid punctuation,\n// alpha characters and digits in the phone number. Does not include extension\n// data. The symbol 'x' is allowed here as valid punctuation since it is often\n// used as a placeholder for carrier codes, for example in Brazilian phone\n// numbers. We also allow multiple '+' characters at the start.\n//\n// Corresponds to the following:\n// [digits]{minLengthNsn}|\n// plus_sign*\n// (([punctuation]|[star])*[digits]){3,}([punctuation]|[star]|[digits]|[alpha])*\n//\n// The first reg-ex is to allow short numbers (two digits long) to be parsed if\n// they are entered as \"15\" etc, but only if there is no punctuation in them.\n// The second expression restricts the number of digits to three or more, but\n// then allows them to be in international form, and to have alpha-characters\n// and punctuation. We split up the two reg-exes here and combine them when\n// creating the reg-ex VALID_PHONE_NUMBER_PATTERN itself so we can prefix it\n// with ^ and append $ to each branch.\n//\n// \"Note VALID_PUNCTUATION starts with a -,\n// so must be the first in the range\" (c) Google devs.\n// (wtf did they mean by saying that; probably nothing)\n//\nvar MIN_LENGTH_PHONE_NUMBER_PATTERN = '[' + VALID_DIGITS + ']{' + MIN_LENGTH_FOR_NSN + '}';\n//\n// And this is the second reg-exp:\n// (see MIN_LENGTH_PHONE_NUMBER_PATTERN for a full description of this reg-exp)\n//\nexport var VALID_PHONE_NUMBER = '[' + PLUS_CHARS + ']{0,1}' + '(?:' + '[' + VALID_PUNCTUATION + ']*' + '[' + VALID_DIGITS + ']' + '){3,}' + '[' + VALID_PUNCTUATION + VALID_DIGITS + ']*';\n\n// This regular expression isn't present in Google's `libphonenumber`\n// and is only used to determine whether the phone number being input\n// is too short for it to even consider it a \"valid\" number.\n// This is just a way to differentiate between a really invalid phone\n// number like \"abcde\" and a valid phone number that a user has just\n// started inputting, like \"+1\" or \"1\": both these cases would be\n// considered `NOT_A_NUMBER` by Google's `libphonenumber`, but this\n// library can provide a more detailed error message — whether it's\n// really \"not a number\", or is it just a start of a valid phone number.\nvar VALID_PHONE_NUMBER_START_REG_EXP = new RegExp('^' + '[' + PLUS_CHARS + ']{0,1}' + '(?:' + '[' + VALID_PUNCTUATION + ']*' + '[' + VALID_DIGITS + ']' + '){1,2}' + '$', 'i');\nexport var VALID_PHONE_NUMBER_WITH_EXTENSION = VALID_PHONE_NUMBER +\n// Phone number extensions\n'(?:' + createExtensionPattern() + ')?';\n\n// The combined regular expression for valid phone numbers:\n//\nvar VALID_PHONE_NUMBER_PATTERN = new RegExp(\n// Either a short two-digit-only phone number\n'^' + MIN_LENGTH_PHONE_NUMBER_PATTERN + '$' + '|' +\n// Or a longer fully parsed phone number (min 3 characters)\n'^' + VALID_PHONE_NUMBER_WITH_EXTENSION + '$', 'i');\n\n// Checks to see if the string of characters could possibly be a phone number at\n// all. At the moment, checks to see that the string begins with at least 2\n// digits, ignoring any punctuation commonly found in phone numbers. This method\n// does not require the number to be normalized in advance - but does assume\n// that leading non-number symbols have been removed, such as by the method\n// `extract_possible_number`.\n//\nexport default function isViablePhoneNumber(number) {\n return number.length >= MIN_LENGTH_FOR_NSN && VALID_PHONE_NUMBER_PATTERN.test(number);\n}\n\n// This is just a way to differentiate between a really invalid phone\n// number like \"abcde\" and a valid phone number that a user has just\n// started inputting, like \"+1\" or \"1\": both these cases would be\n// considered `NOT_A_NUMBER` by Google's `libphonenumber`, but this\n// library can provide a more detailed error message — whether it's\n// really \"not a number\", or is it just a start of a valid phone number.\nexport function isViablePhoneNumberStart(number) {\n return VALID_PHONE_NUMBER_START_REG_EXP.test(number);\n}\n//# sourceMappingURL=isViablePhoneNumber.js.map","import createExtensionPattern from './createExtensionPattern.js';\n\n// Regexp of all known extension prefixes used by different regions followed by\n// 1 or more valid digits, for use when parsing.\nvar EXTN_PATTERN = new RegExp('(?:' + createExtensionPattern() + ')$', 'i');\n\n// Strips any extension (as in, the part of the number dialled after the call is\n// connected, usually indicated with extn, ext, x or similar) from the end of\n// the number, and returns it.\nexport default function extractExtension(number) {\n var start = number.search(EXTN_PATTERN);\n if (start < 0) {\n return {};\n }\n // If we find a potential extension, and the number preceding this is a viable\n // number, we assume it is an extension.\n var numberWithoutExtension = number.slice(0, start);\n var matches = number.match(EXTN_PATTERN);\n var i = 1;\n while (i < matches.length) {\n if (matches[i]) {\n return {\n number: numberWithoutExtension,\n ext: matches[i]\n };\n }\n i++;\n }\n}\n//# sourceMappingURL=extractExtension.js.map","function _createForOfIteratorHelperLoose(r, e) { var t = \"undefined\" != typeof Symbol && r[Symbol.iterator] || r[\"@@iterator\"]; if (t) return (t = t.call(r)).next.bind(t); if (Array.isArray(r) || (t = _unsupportedIterableToArray(r)) || e && r && \"number\" == typeof r.length) { t && (r = t); var o = 0; return function () { return o >= r.length ? { done: !0 } : { done: !1, value: r[o++] }; }; } throw new TypeError(\"Invalid attempt to iterate non-iterable instance.\\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.\"); }\nfunction _unsupportedIterableToArray(r, a) { if (r) { if (\"string\" == typeof r) return _arrayLikeToArray(r, a); var t = {}.toString.call(r).slice(8, -1); return \"Object\" === t && r.constructor && (t = r.constructor.name), \"Map\" === t || \"Set\" === t ? Array.from(r) : \"Arguments\" === t || /^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(t) ? _arrayLikeToArray(r, a) : void 0; } }\nfunction _arrayLikeToArray(r, a) { (null == a || a > r.length) && (a = r.length); for (var e = 0, n = Array(a); e < a; e++) n[e] = r[e]; return n; }\n// These mappings map a character (key) to a specific digit that should\n// replace it for normalization purposes. Non-European digits that\n// may be used in phone numbers are mapped to a European equivalent.\n//\n// E.g. in Iraq they don't write `+442323234` but rather `+٤٤٢٣٢٣٢٣٤`.\n//\nexport var DIGITS = {\n '0': '0',\n '1': '1',\n '2': '2',\n '3': '3',\n '4': '4',\n '5': '5',\n '6': '6',\n '7': '7',\n '8': '8',\n '9': '9',\n \"\\uFF10\": '0',\n // Fullwidth digit 0\n \"\\uFF11\": '1',\n // Fullwidth digit 1\n \"\\uFF12\": '2',\n // Fullwidth digit 2\n \"\\uFF13\": '3',\n // Fullwidth digit 3\n \"\\uFF14\": '4',\n // Fullwidth digit 4\n \"\\uFF15\": '5',\n // Fullwidth digit 5\n \"\\uFF16\": '6',\n // Fullwidth digit 6\n \"\\uFF17\": '7',\n // Fullwidth digit 7\n \"\\uFF18\": '8',\n // Fullwidth digit 8\n \"\\uFF19\": '9',\n // Fullwidth digit 9\n \"\\u0660\": '0',\n // Arabic-indic digit 0\n \"\\u0661\": '1',\n // Arabic-indic digit 1\n \"\\u0662\": '2',\n // Arabic-indic digit 2\n \"\\u0663\": '3',\n // Arabic-indic digit 3\n \"\\u0664\": '4',\n // Arabic-indic digit 4\n \"\\u0665\": '5',\n // Arabic-indic digit 5\n \"\\u0666\": '6',\n // Arabic-indic digit 6\n \"\\u0667\": '7',\n // Arabic-indic digit 7\n \"\\u0668\": '8',\n // Arabic-indic digit 8\n \"\\u0669\": '9',\n // Arabic-indic digit 9\n \"\\u06F0\": '0',\n // Eastern-Arabic digit 0\n \"\\u06F1\": '1',\n // Eastern-Arabic digit 1\n \"\\u06F2\": '2',\n // Eastern-Arabic digit 2\n \"\\u06F3\": '3',\n // Eastern-Arabic digit 3\n \"\\u06F4\": '4',\n // Eastern-Arabic digit 4\n \"\\u06F5\": '5',\n // Eastern-Arabic digit 5\n \"\\u06F6\": '6',\n // Eastern-Arabic digit 6\n \"\\u06F7\": '7',\n // Eastern-Arabic digit 7\n \"\\u06F8\": '8',\n // Eastern-Arabic digit 8\n \"\\u06F9\": '9' // Eastern-Arabic digit 9\n};\nexport function parseDigit(character) {\n return DIGITS[character];\n}\n\n/**\r\n * Parses phone number digits from a string.\r\n * Drops all punctuation leaving only digits.\r\n * Also converts wide-ascii and arabic-indic numerals to conventional numerals.\r\n * E.g. in Iraq they don't write `+442323234` but rather `+٤٤٢٣٢٣٢٣٤`.\r\n * @param {string} string\r\n * @return {string}\r\n * @example\r\n * ```js\r\n * parseDigits('8 (800) 555')\r\n * // Outputs '8800555'.\r\n * ```\r\n */\nexport default function parseDigits(string) {\n var result = '';\n // Using `.split('')` here instead of normal `for ... of`\n // because the importing application doesn't neccessarily include an ES6 polyfill.\n // The `.split('')` approach discards \"exotic\" UTF-8 characters\n // (the ones consisting of four bytes) but digits\n // (including non-European ones) don't fall into that range\n // so such \"exotic\" characters would be discarded anyway.\n for (var _iterator = _createForOfIteratorHelperLoose(string.split('')), _step; !(_step = _iterator()).done;) {\n var character = _step.value;\n var digit = parseDigit(character);\n if (digit) {\n result += digit;\n }\n }\n return result;\n}\n//# sourceMappingURL=parseDigits.js.map","function _createForOfIteratorHelperLoose(r, e) { var t = \"undefined\" != typeof Symbol && r[Symbol.iterator] || r[\"@@iterator\"]; if (t) return (t = t.call(r)).next.bind(t); if (Array.isArray(r) || (t = _unsupportedIterableToArray(r)) || e && r && \"number\" == typeof r.length) { t && (r = t); var o = 0; return function () { return o >= r.length ? { done: !0 } : { done: !1, value: r[o++] }; }; } throw new TypeError(\"Invalid attempt to iterate non-iterable instance.\\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.\"); }\nfunction _unsupportedIterableToArray(r, a) { if (r) { if (\"string\" == typeof r) return _arrayLikeToArray(r, a); var t = {}.toString.call(r).slice(8, -1); return \"Object\" === t && r.constructor && (t = r.constructor.name), \"Map\" === t || \"Set\" === t ? Array.from(r) : \"Arguments\" === t || /^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(t) ? _arrayLikeToArray(r, a) : void 0; } }\nfunction _arrayLikeToArray(r, a) { (null == a || a > r.length) && (a = r.length); for (var e = 0, n = Array(a); e < a; e++) n[e] = r[e]; return n; }\nimport { parseDigit } from './helpers/parseDigits.js';\n\n/**\r\n * Parses phone number characters from a string.\r\n * Drops all punctuation leaving only digits and the leading `+` sign (if any).\r\n * Also converts wide-ascii and arabic-indic numerals to conventional numerals.\r\n * E.g. in Iraq they don't write `+442323234` but rather `+٤٤٢٣٢٣٢٣٤`.\r\n * @param {string} string\r\n * @return {string}\r\n * @example\r\n * ```js\r\n * // Outputs '8800555'.\r\n * parseIncompletePhoneNumber('8 (800) 555')\r\n * // Outputs '+7800555'.\r\n * parseIncompletePhoneNumber('+7 800 555')\r\n * ```\r\n */\nexport default function parseIncompletePhoneNumber(string) {\n var result = '';\n // Using `.split('')` here instead of normal `for ... of`\n // because the importing application doesn't neccessarily include an ES6 polyfill.\n // The `.split('')` approach discards \"exotic\" UTF-8 characters\n // (the ones consisting of four bytes) but digits\n // (including non-European ones) don't fall into that range\n // so such \"exotic\" characters would be discarded anyway.\n for (var _iterator = _createForOfIteratorHelperLoose(string.split('')), _step; !(_step = _iterator()).done;) {\n var character = _step.value;\n result += parsePhoneNumberCharacter(character, result) || '';\n }\n return result;\n}\n\n/**\r\n * Parses next character while parsing phone number digits (including a `+`)\r\n * from text: discards everything except `+` and digits, and `+` is only allowed\r\n * at the start of a phone number.\r\n * For example, is used in `react-phone-number-input` where it uses\r\n * [`input-format`](https://gitlab.com/catamphetamine/input-format).\r\n * @param {string} character - Yet another character from raw input string.\r\n * @param {string?} prevParsedCharacters - Previous parsed characters.\r\n * @param {function?} eventListener - An optional \"on event\" function.\r\n * @return {string?} The parsed character.\r\n */\nexport function parsePhoneNumberCharacter(character, prevParsedCharacters, eventListener) {\n // Only allow a leading `+`.\n if (character === '+') {\n // If this `+` is not the first parsed character\n // then discard it.\n if (prevParsedCharacters) {\n // `eventListener` argument was added to this `export`ed function on Dec 26th, 2023.\n // Any 3rd-party code that used to `import` and call this function before that\n // won't be passing any `eventListener` argument.\n //\n // The addition of the `eventListener` argument was to fix the slightly-weird behavior\n // of parsing an input string when the user inputs something like `\"2+7\"\n // https://github.com/catamphetamine/react-phone-number-input/issues/437\n //\n // If the parser encounters an unexpected `+` in a string being parsed\n // then it simply discards that out-of-place `+` and any following characters.\n //\n if (typeof eventListener === 'function') {\n eventListener('end');\n }\n return;\n }\n return '+';\n }\n // Allow digits.\n return parseDigit(character);\n}\n//# sourceMappingURL=parseIncompletePhoneNumber.js.map","function _createForOfIteratorHelperLoose(r, e) { var t = \"undefined\" != typeof Symbol && r[Symbol.iterator] || r[\"@@iterator\"]; if (t) return (t = t.call(r)).next.bind(t); if (Array.isArray(r) || (t = _unsupportedIterableToArray(r)) || e && r && \"number\" == typeof r.length) { t && (r = t); var o = 0; return function () { return o >= r.length ? { done: !0 } : { done: !1, value: r[o++] }; }; } throw new TypeError(\"Invalid attempt to iterate non-iterable instance.\\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.\"); }\nfunction _unsupportedIterableToArray(r, a) { if (r) { if (\"string\" == typeof r) return _arrayLikeToArray(r, a); var t = {}.toString.call(r).slice(8, -1); return \"Object\" === t && r.constructor && (t = r.constructor.name), \"Map\" === t || \"Set\" === t ? Array.from(r) : \"Arguments\" === t || /^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(t) ? _arrayLikeToArray(r, a) : void 0; } }\nfunction _arrayLikeToArray(r, a) { (null == a || a > r.length) && (a = r.length); for (var e = 0, n = Array(a); e < a; e++) n[e] = r[e]; return n; }\n/**\r\n * Merges two arrays.\r\n * @param {*} a\r\n * @param {*} b\r\n * @return {*}\r\n */\nexport default function mergeArrays(a, b) {\n var merged = a.slice();\n for (var _iterator = _createForOfIteratorHelperLoose(b), _step; !(_step = _iterator()).done;) {\n var element = _step.value;\n if (a.indexOf(element) < 0) {\n merged.push(element);\n }\n }\n return merged.sort(function (a, b) {\n return a - b;\n });\n\n // ES6 version, requires Set polyfill.\n // let merged = new Set(a)\n // for (const element of b) {\n // \tmerged.add(i)\n // }\n // return Array.from(merged).sort((a, b) => a - b)\n}\n//# sourceMappingURL=mergeArrays.js.map","import Metadata from '../metadata.js';\nimport mergeArrays from './mergeArrays.js';\n\n/**\r\n * Checks phone number length against the phone numbering plan selected in metadata.\r\n * Optionally, it could be restrained by a specific country.\r\n * @param {string} nationalNumber\r\n * @param {string?} country — Specific country to use rather than the one that is pre-selected in the metadata instance.\r\n * @param {Metadata} metadata — Metadata instance with a selected numbering plan.\r\n * @returns {string}\r\n */\nexport default function checkNumberLength(nationalNumber, country, metadata) {\n return checkNumberLengthForType(nationalNumber, undefined, country, metadata);\n}\n\n/**\r\n * Checks phone number length against the phone numbering plan selected in metadata.\r\n * Optionally, it could be restrained by a specific phone number type or a specific country.\r\n * @param {string} nationalNumber\r\n * @param {string?} type — Specific phone number type.\r\n * @param {string?} country — Specific country to use instead of the one that is pre-selected in the metadata instance.\r\n * @param {Metadata} metadata — Metadata instance with a selected numbering plan.\r\n * @returns {string} See the README on `validatePhoneNumberLength()` function, with an addition of a special case: when phone numbers of type `type` aren't possible in the telephone numbering plan, it will return \"INVALID_LENGTH\".\r\n */\n// Checks whether a number is possible for a certain `country` based on the number length.\n//\n// This function is not supported by metadata generated with ancient versions of\n// `libphonenumber-js` (before version `1.0.18`) which didn't include \"possible lengths\".\n//\n// There was also a known issue with `checkNumberLength()` function:\n// if a number is possible only in a certain `country` among several `countries`\n// that share the same \"country calling code\", that function would check\n// the possibility of the phone number only in the \"main\" `country` for the \"country calling code\"\n// and would not check if it's actually be possible in the speciifc `country`.\n//\n// For example, \"+1310xxxx\" numbers are valid in Canada.\n// However, they are not possible in the US due to being too short.\n// Since Canada and the US share the same country calling code — \"+1\" —\n// `checkNumberLength()` function used to return not \"IS_POSSIBLE\" for \"+1310xxxx\" numbers.\n//\n// In such cases, when using \"/max\" metadata, `isValid()` could output `true`\n// but at the same time `isPossible()` could output `false`, which was contradictory.\n//\n// See https://issuetracker.google.com/issues/335892662 for the discusson in Google's issues.\n//\n// The solution suggested by Google was implemented: an optional `country` argument\n// was added to `checkNumberLength()` function. If present, that `country` will be used\n// to check phone number length for that specific `country` rather than the \"main\" country\n// for the shared \"country calling code\".\n//\nexport function checkNumberLengthForType(nationalNumber, type, country, metadata) {\n if (country) {\n // If a specific `country` is specified, re-create a metadata instance with it.\n metadata = new Metadata(metadata.metadata);\n metadata.selectNumberingPlan(country);\n }\n var type_info = metadata.type(type);\n\n // There should always be \"<possiblePengths/>\" set for every type element.\n // This is declared in the XML schema.\n // For size efficiency, where a sub-description (e.g. fixed-line)\n // has the same \"<possiblePengths/>\" as the \"general description\", this is missing,\n // so we fall back to the \"general description\". Where no numbers of the type\n // exist at all, there is one possible length (-1) which is guaranteed\n // not to match the length of any real phone number.\n var possible_lengths = type_info && type_info.possibleLengths() || metadata.possibleLengths();\n // let local_lengths = type_info && type.possibleLengthsLocal() || metadata.possibleLengthsLocal()\n\n // Metadata before version `1.0.18` didn't contain `possible_lengths`.\n if (!possible_lengths) {\n return 'IS_POSSIBLE';\n }\n if (type === 'FIXED_LINE_OR_MOBILE') {\n // No such country in metadata.\n /* istanbul ignore next */\n if (!metadata.type('FIXED_LINE')) {\n // The rare case has been encountered where no fixedLine data is available\n // (true for some non-geographic entities), so we just check mobile.\n return checkNumberLengthForType(nationalNumber, 'MOBILE', country, metadata);\n }\n var mobile_type = metadata.type('MOBILE');\n if (mobile_type) {\n // Merge the mobile data in if there was any. \"Concat\" creates a new\n // array, it doesn't edit possible_lengths in place, so we don't need a copy.\n // Note that when adding the possible lengths from mobile, we have\n // to again check they aren't empty since if they are this indicates\n // they are the same as the general desc and should be obtained from there.\n possible_lengths = mergeArrays(possible_lengths, mobile_type.possibleLengths());\n // The current list is sorted; we need to merge in the new list and\n // re-sort (duplicates are okay). Sorting isn't so expensive because\n // the lists are very small.\n\n // if (local_lengths) {\n // \tlocal_lengths = mergeArrays(local_lengths, mobile_type.possibleLengthsLocal())\n // } else {\n // \tlocal_lengths = mobile_type.possibleLengthsLocal()\n // }\n }\n }\n // If the type doesn't exist then return 'INVALID_LENGTH'.\n else if (type && !type_info) {\n return 'INVALID_LENGTH';\n }\n var actual_length = nationalNumber.length;\n\n // In `libphonenumber-js` all \"local-only\" formats are dropped for simplicity.\n // // This is safe because there is never an overlap beween the possible lengths\n // // and the local-only lengths; this is checked at build time.\n // if (local_lengths && local_lengths.indexOf(nationalNumber.length) >= 0)\n // {\n // \treturn 'IS_POSSIBLE_LOCAL_ONLY'\n // }\n\n var minimum_length = possible_lengths[0];\n if (minimum_length === actual_length) {\n return 'IS_POSSIBLE';\n }\n if (minimum_length > actual_length) {\n return 'TOO_SHORT';\n }\n if (possible_lengths[possible_lengths.length - 1] < actual_length) {\n return 'TOO_LONG';\n }\n\n // We skip the first element since we've already checked it.\n return possible_lengths.indexOf(actual_length, 1) >= 0 ? 'IS_POSSIBLE' : 'INVALID_LENGTH';\n}\n//# sourceMappingURL=checkNumberLength.js.map","import Metadata from './metadata.js';\nimport checkNumberLength from './helpers/checkNumberLength.js';\n\n/**\r\n * Checks if a phone number is \"possible\" (basically just checks its length).\r\n *\r\n * isPossible(phoneNumberInstance, { ..., v2: true }, metadata)\r\n *\r\n * isPossible({ phone: '8005553535', country: 'RU' }, { ... }, metadata)\r\n * isPossible({ phone: '8005553535', country: 'RU' }, undefined, metadata)\r\n *\r\n * @param {object|PhoneNumber} input — If `options.v2: true` flag is passed, the `input` should be a `PhoneNumber` instance. Otherwise, it should be an object of shape `{ phone: '...', country: '...' }`.\r\n * @param {object} [options]\r\n * @param {object} metadataJson\r\n * @return {string}\r\n */\nexport default function isPossiblePhoneNumber(input, options, metadataJson) {\n /* istanbul ignore if */\n if (options === undefined) {\n options = {};\n }\n var metadata = new Metadata(metadataJson);\n if (options.v2) {\n if (!input.countryCallingCode) {\n throw new Error('Invalid phone number object passed');\n }\n metadata.selectNumberingPlan(input.country || input.countryCallingCode);\n } else {\n if (!input.phone) {\n return false;\n }\n if (input.country) {\n if (!metadata.hasCountry(input.country)) {\n throw new Error(\"Unknown country: \".concat(input.country));\n }\n metadata.selectNumberingPlan(input.country);\n } else {\n if (!input.countryCallingCode) {\n throw new Error('Invalid phone number object passed');\n }\n metadata.selectNumberingPlan(input.countryCallingCode);\n }\n }\n\n // Old (legacy) metadata (< 1.0.18) had no \"possible length\" data.\n // So `isPossibleNumber()` function is supported only for non-legacy metadata.\n if (metadata.possibleLengths()) {\n return isPossibleNumber(input.phone || input.nationalNumber, metadata);\n }\n\n // There was a bug in versions from `1.7.35` to `1.7.37` of `libphonenumber-js`\n // where \"possible_lengths\" property was missing from \"non-geographical\" numbering plans' metadata.\n // After that, the bug was noticed and fixed.\n // So for versions from `1.7.35` to `1.7.37`, just assume that all \"non=geotraphical\" numbers are possible.\n // The reason is that the bug was noticed relatively quickly (within a day or so)\n // and it's unlikely that anyone generated their custom metadata in that short time span.\n // And if they didn't generate any custom metadata then a follow-up package update would've silently fixed the bug.\n if (input.countryCallingCode && metadata.isNonGeographicCallingCode(input.countryCallingCode)) {\n return true;\n }\n\n // `isPossibleNumber()` function is not supported.\n throw new Error('Missing \"possibleLengths\" in metadata. Perhaps the metadata has been generated before v1.0.18.');\n}\n\n/**\r\n * Tells if a given national (significant) number is possible\r\n * @param {string} nationalNumber\r\n * @param {Metadata} metadata = Metadata instance with a pre-selected telephone numbering plan.\r\n * @returns {boolean}\r\n */\nexport function isPossibleNumber(nationalNumber, metadata) {\n switch (checkNumberLength(nationalNumber, undefined, metadata)) {\n case 'IS_POSSIBLE':\n return true;\n // This library ignores \"local-only\" phone numbers (for simplicity).\n // See the readme for more info on what are \"local-only\" phone numbers.\n // case 'IS_POSSIBLE_LOCAL_ONLY':\n // \treturn !isInternational\n default:\n return false;\n }\n}\n//# sourceMappingURL=isPossible.js.map","/**\r\n * Checks whether the entire input sequence can be matched\r\n * against the regular expression.\r\n * @return {boolean}\r\n */\nexport default function matchesEntirely(text, regularExpressionText) {\n // If the assigning of the `''` default value is moved to the arguments above,\n // the code coverage would decrease for some weird reason.\n text = text || '';\n return new RegExp('^(?:' + regularExpressionText + ')$').test(text);\n}\n//# sourceMappingURL=matchesEntirely.js.map","function _createForOfIteratorHelperLoose(r, e) { var t = \"undefined\" != typeof Symbol && r[Symbol.iterator] || r[\"@@iterator\"]; if (t) return (t = t.call(r)).next.bind(t); if (Array.isArray(r) || (t = _unsupportedIterableToArray(r)) || e && r && \"number\" == typeof r.length) { t && (r = t); var o = 0; return function () { return o >= r.length ? { done: !0 } : { done: !1, value: r[o++] }; }; } throw new TypeError(\"Invalid attempt to iterate non-iterable instance.\\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.\"); }\nfunction _unsupportedIterableToArray(r, a) { if (r) { if (\"string\" == typeof r) return _arrayLikeToArray(r, a); var t = {}.toString.call(r).slice(8, -1); return \"Object\" === t && r.constructor && (t = r.constructor.name), \"Map\" === t || \"Set\" === t ? Array.from(r) : \"Arguments\" === t || /^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(t) ? _arrayLikeToArray(r, a) : void 0; } }\nfunction _arrayLikeToArray(r, a) { (null == a || a > r.length) && (a = r.length); for (var e = 0, n = Array(a); e < a; e++) n[e] = r[e]; return n; }\nimport Metadata from '../metadata.js';\nimport matchesEntirely from './matchesEntirely.js';\nvar NON_FIXED_LINE_PHONE_TYPES = ['MOBILE', 'PREMIUM_RATE', 'TOLL_FREE', 'SHARED_COST', 'VOIP', 'PERSONAL_NUMBER', 'PAGER', 'UAN', 'VOICEMAIL'];\n\n// Finds out national phone number type (fixed line, mobile, etc)\nexport default function getNumberType(input, options, metadataJson) {\n // If assigning the `{}` default value is moved to the arguments above,\n // code coverage would decrease for some weird reason.\n options = options || {};\n\n // When `parse()` returns an empty object — `{}` —\n // that means that the phone number is malformed,\n // so it can't possibly be valid.\n if (!input.country && !input.countryCallingCode) {\n return;\n }\n var metadata = new Metadata(metadataJson);\n metadata.selectNumberingPlan(input.country || input.countryCallingCode);\n var nationalNumber = options.v2 ? input.nationalNumber : input.phone;\n\n // The following is copy-pasted from the original function:\n // https://github.com/googlei18n/libphonenumber/blob/3ea547d4fbaa2d0b67588904dfa5d3f2557c27ff/javascript/i18n/phonenumbers/phonenumberutil.js#L2835\n\n // Is this national number even valid for this country\n if (!matchesEntirely(nationalNumber, metadata.nationalNumberPattern())) {\n return;\n }\n\n // Is it fixed line number\n if (isNumberTypeEqualTo(nationalNumber, 'FIXED_LINE', metadata)) {\n // Because duplicate regular expressions are removed\n // to reduce metadata size, if \"mobile\" pattern is \"\"\n // then it means it was removed due to being a duplicate of the fixed-line pattern.\n //\n if (metadata.type('MOBILE') && metadata.type('MOBILE').pattern() === '') {\n return 'FIXED_LINE_OR_MOBILE';\n }\n\n // `MOBILE` type pattern isn't included if it matched `FIXED_LINE` one.\n // For example, for \"US\" country.\n // Old metadata (< `1.0.18`) had a specific \"types\" data structure\n // that happened to be `undefined` for `MOBILE` in that case.\n // Newer metadata (>= `1.0.18`) has another data structure that is\n // not `undefined` for `MOBILE` in that case (it's just an empty array).\n // So this `if` is just for backwards compatibility with old metadata.\n if (!metadata.type('MOBILE')) {\n return 'FIXED_LINE_OR_MOBILE';\n }\n\n // Check if the number happens to qualify as both fixed line and mobile.\n // (no such country in the minimal metadata set)\n /* istanbul ignore if */\n if (isNumberTypeEqualTo(nationalNumber, 'MOBILE', metadata)) {\n return 'FIXED_LINE_OR_MOBILE';\n }\n return 'FIXED_LINE';\n }\n for (var _iterator = _createForOfIteratorHelperLoose(NON_FIXED_LINE_PHONE_TYPES), _step; !(_step = _iterator()).done;) {\n var type = _step.value;\n if (isNumberTypeEqualTo(nationalNumber, type, metadata)) {\n return type;\n }\n }\n}\nexport function isNumberTypeEqualTo(nationalNumber, type, metadata) {\n var typeDefinition = metadata.type(type);\n if (!typeDefinition || !typeDefinition.pattern()) {\n return false;\n }\n\n // Check if any possible number lengths are present;\n // if so, we use them to avoid checking\n // the validation pattern if they don't match.\n // If they are absent, this means they match\n // the general description, which we have\n // already checked before a specific number type.\n if (typeDefinition.possibleLengths() && typeDefinition.possibleLengths().indexOf(nationalNumber.length) < 0) {\n return false;\n }\n return matchesEntirely(nationalNumber, typeDefinition.pattern());\n}\n//# sourceMappingURL=getNumberType.js.map","import Metadata from './metadata.js';\nimport matchesEntirely from './helpers/matchesEntirely.js';\nimport getNumberType from './helpers/getNumberType.js';\n\n/**\r\n * Checks if a given phone number is valid.\r\n *\r\n * isValid(phoneNumberInstance, { ..., v2: true }, metadata)\r\n *\r\n * isPossible({ phone: '8005553535', country: 'RU' }, { ... }, metadata)\r\n * isPossible({ phone: '8005553535', country: 'RU' }, undefined, metadata)\r\n *\r\n * If the `number` is a string, it will be parsed to an object,\r\n * but only if it contains only valid phone number characters (including punctuation).\r\n * If the `number` is an object, it is used as is.\r\n *\r\n * The optional `defaultCountry` argument is the default country.\r\n * I.e. it does not restrict to just that country,\r\n * e.g. in those cases where several countries share\r\n * the same phone numbering rules (NANPA, Britain, etc).\r\n * For example, even though the number `07624 369230`\r\n * belongs to the Isle of Man (\"IM\" country code)\r\n * calling `isValidNumber('07624369230', 'GB', metadata)`\r\n * still returns `true` because the country is not restricted to `GB`,\r\n * it's just that `GB` is the default one for the phone numbering rules.\r\n * For restricting the country see `isValidNumberForRegion()`\r\n * though restricting a country might not be a good idea.\r\n * https://github.com/googlei18n/libphonenumber/blob/master/FAQ.md#when-should-i-use-isvalidnumberforregion\r\n *\r\n * Examples:\r\n *\r\n * ```js\r\n * isValidNumber('+78005553535', metadata)\r\n * isValidNumber('8005553535', 'RU', metadata)\r\n * isValidNumber('88005553535', 'RU', metadata)\r\n * isValidNumber({ phone: '8005553535', country: 'RU' }, metadata)\r\n * ```\r\n */\nexport default function isValidNumber(input, options, metadataJson) {\n // If assigning the `{}` default value is moved to the arguments above,\n // code coverage would decrease for some weird reason.\n options = options || {};\n var metadata = new Metadata(metadataJson);\n metadata.selectNumberingPlan(input.country || input.countryCallingCode);\n\n // By default, countries only have type regexps when it's required for\n // distinguishing different countries having the same `countryCallingCode`.\n if (metadata.hasTypes()) {\n return getNumberType(input, options, metadata.metadata) !== undefined;\n }\n\n // If there are no type regexps for this country in metadata then use\n // `nationalNumberPattern` as a \"better than nothing\" replacement.\n var nationalNumber = options.v2 ? input.nationalNumber : input.phone;\n return matchesEntirely(nationalNumber, metadata.nationalNumberPattern());\n}\n//# sourceMappingURL=isValid.js.map","var COUNTRY_CODE_REG_EXP = /^[A-Z]{2}$/;\nexport default function isCountryCode(string) {\n return COUNTRY_CODE_REG_EXP.test(string);\n}\n//# sourceMappingURL=isCountryCode.js.map","import Metadata from '../metadata.js';\nimport isCountryCode from './isCountryCode.js';\nvar USE_NON_GEOGRAPHIC_COUNTRY_CODE = false;\nexport default function getCountryAndCallingCodeFromOneOfThem(countryOrCallingCode, metadataJson) {\n var country;\n var callingCode;\n var metadata = new Metadata(metadataJson);\n // If country code is passed then derive `countryCallingCode` from it.\n // Also store the country code as `.country`.\n if (isCountryCode(countryOrCallingCode)) {\n country = countryOrCallingCode;\n metadata.selectNumberingPlan(country);\n callingCode = metadata.countryCallingCode();\n } else {\n callingCode = countryOrCallingCode;\n /* istanbul ignore if */\n if (USE_NON_GEOGRAPHIC_COUNTRY_CODE) {\n if (metadata.isNonGeographicCallingCode(callingCode)) {\n country = '001';\n }\n }\n }\n return {\n country: country,\n callingCode: callingCode\n };\n}\n//# sourceMappingURL=getCountryAndCallingCodeFromOneOfThem.js.map","import Metadata from '../metadata.js';\n\n/**\r\n * Returns a list of countries that the phone number could potentially belong to.\r\n * @param {string} callingCode — Calling code.\r\n * @param {string} nationalNumber — National (significant) number.\r\n * @param {object} metadata — Metadata.\r\n * @return {string[]} A list of possible countries.\r\n */\nexport default function getPossibleCountriesForNumber(callingCode, nationalNumber, metadata) {\n var _metadata = new Metadata(metadata);\n var possibleCountries = _metadata.getCountryCodesForCallingCode(callingCode);\n if (!possibleCountries) {\n return [];\n }\n return possibleCountries.filter(function (country) {\n return couldNationalNumberBelongToCountry(nationalNumber, country, metadata);\n });\n}\nfunction couldNationalNumberBelongToCountry(nationalNumber, country, metadataJson) {\n var metadata = new Metadata(metadataJson);\n metadata.selectNumberingPlan(country);\n return metadata.numberingPlan.possibleLengths().indexOf(nationalNumber.length) >= 0;\n}\n//# sourceMappingURL=getPossibleCountriesForNumber.js.map","import Metadata from '../metadata.js';\nimport { VALID_DIGITS } from '../constants.js';\nvar CAPTURING_DIGIT_PATTERN = new RegExp('([' + VALID_DIGITS + '])');\nexport default function stripIddPrefix(number, country, callingCode, metadataJson) {\n if (!country) {\n return;\n }\n\n // Get the IDD prefix pattern.\n var metadata = new Metadata(metadataJson);\n metadata.selectNumberingPlan(country || callingCode);\n var IDDPrefixPattern = new RegExp(metadata.IDDPrefix());\n\n // Check if the number is IDD-prefixed.\n if (number.search(IDDPrefixPattern) !== 0) {\n return;\n }\n\n // Strip IDD prefix.\n number = number.slice(number.match(IDDPrefixPattern)[0].length);\n\n // If there're any digits after an IDD prefix,\n // then those digits are a country calling code.\n // Since no country code starts with a `0`,\n // the code below validates that the next digit (if present) is not `0`.\n var matchedGroups = number.match(CAPTURING_DIGIT_PATTERN);\n if (matchedGroups && matchedGroups[1] != null && matchedGroups[1].length > 0) {\n if (matchedGroups[1] === '0') {\n return;\n }\n }\n return number;\n}\n//# sourceMappingURL=stripIddPrefix.js.map","/**\r\n * Strips any national prefix (such as 0, 1) present in a\r\n * (possibly incomplete) number provided.\r\n * \"Carrier codes\" are only used in Colombia and Brazil,\r\n * and only when dialing within those countries from a mobile phone to a fixed line number.\r\n * Sometimes it won't actually strip national prefix\r\n * and will instead prepend some digits to the `number`:\r\n * for example, when number `2345678` is passed with `VI` country selected,\r\n * it will return `{ number: \"3402345678\" }`, because `340` area code is prepended.\r\n * @param {string} number — National number digits.\r\n * @param {object} metadata — Metadata with country selected.\r\n * @return {object} `{ nationalNumber: string, nationalPrefix: string? carrierCode: string? }`. Even if a national prefix was extracted, it's not necessarily present in the returned object, so don't rely on its presence in the returned object in order to find out whether a national prefix has been extracted or not.\r\n */\nexport default function extractNationalNumberFromPossiblyIncompleteNumber(number, metadata) {\n if (number && metadata.numberingPlan.nationalPrefixForParsing()) {\n // See METADATA.md for the description of\n // `national_prefix_for_parsing` and `national_prefix_transform_rule`.\n // Attempt to parse the first digits as a national prefix.\n var prefixPattern = new RegExp('^(?:' + metadata.numberingPlan.nationalPrefixForParsing() + ')');\n var prefixMatch = prefixPattern.exec(number);\n if (prefixMatch) {\n var nationalNumber;\n var carrierCode;\n // https://gitlab.com/catamphetamine/libphonenumber-js/-/blob/master/METADATA.md#national_prefix_for_parsing--national_prefix_transform_rule\n // If a `national_prefix_for_parsing` has any \"capturing groups\"\n // then it means that the national (significant) number is equal to\n // those \"capturing groups\" transformed via `national_prefix_transform_rule`,\n // and nothing could be said about the actual national prefix:\n // what is it and was it even there.\n // If a `national_prefix_for_parsing` doesn't have any \"capturing groups\",\n // then everything it matches is a national prefix.\n // To determine whether `national_prefix_for_parsing` matched any\n // \"capturing groups\", the value of the result of calling `.exec()`\n // is looked at, and if it has non-undefined values where there're\n // \"capturing groups\" in the regular expression, then it means\n // that \"capturing groups\" have been matched.\n // It's not possible to tell whether there'll be any \"capturing gropus\"\n // before the matching process, because a `national_prefix_for_parsing`\n // could exhibit both behaviors.\n var capturedGroupsCount = prefixMatch.length - 1;\n var hasCapturedGroups = capturedGroupsCount > 0 && prefixMatch[capturedGroupsCount];\n if (metadata.nationalPrefixTransformRule() && hasCapturedGroups) {\n nationalNumber = number.replace(prefixPattern, metadata.nationalPrefixTransformRule());\n // If there's more than one captured group,\n // then carrier code is the second one.\n if (capturedGroupsCount > 1) {\n carrierCode = prefixMatch[1];\n }\n }\n // If there're no \"capturing groups\",\n // or if there're \"capturing groups\" but no\n // `national_prefix_transform_rule`,\n // then just strip the national prefix from the number,\n // and possibly a carrier code.\n // Seems like there could be more.\n else {\n // `prefixBeforeNationalNumber` is the whole substring matched by\n // the `national_prefix_for_parsing` regular expression.\n // There seem to be no guarantees that it's just a national prefix.\n // For example, if there's a carrier code, it's gonna be a\n // part of `prefixBeforeNationalNumber` too.\n var prefixBeforeNationalNumber = prefixMatch[0];\n nationalNumber = number.slice(prefixBeforeNationalNumber.length);\n // If there's at least one captured group,\n // then carrier code is the first one.\n if (hasCapturedGroups) {\n carrierCode = prefixMatch[1];\n }\n }\n // Tries to guess whether a national prefix was present in the input.\n // This is not something copy-pasted from Google's library:\n // they don't seem to have an equivalent for that.\n // So this isn't an \"officially approved\" way of doing something like that.\n // But since there seems no other existing method, this library uses it.\n var nationalPrefix;\n if (hasCapturedGroups) {\n var possiblePositionOfTheFirstCapturedGroup = number.indexOf(prefixMatch[1]);\n var possibleNationalPrefix = number.slice(0, possiblePositionOfTheFirstCapturedGroup);\n // Example: an Argentinian (AR) phone number `0111523456789`.\n // `prefixMatch[0]` is `01115`, and `$1` is `11`,\n // and the rest of the phone number is `23456789`.\n // The national number is transformed via `9$1` to `91123456789`.\n // National prefix `0` is detected being present at the start.\n // if (possibleNationalPrefix.indexOf(metadata.numberingPlan.nationalPrefix()) === 0) {\n if (possibleNationalPrefix === metadata.numberingPlan.nationalPrefix()) {\n nationalPrefix = metadata.numberingPlan.nationalPrefix();\n }\n } else {\n nationalPrefix = prefixMatch[0];\n }\n return {\n nationalNumber: nationalNumber,\n nationalPrefix: nationalPrefix,\n carrierCode: carrierCode\n };\n }\n }\n return {\n nationalNumber: number\n };\n}\n//# sourceMappingURL=extractNationalNumberFromPossiblyIncompleteNumber.js.map","function _createForOfIteratorHelperLoose(r, e) { var t = \"undefined\" != typeof Symbol && r[Symbol.iterator] || r[\"@@iterator\"]; if (t) return (t = t.call(r)).next.bind(t); if (Array.isArray(r) || (t = _unsupportedIterableToArray(r)) || e && r && \"number\" == typeof r.length) { t && (r = t); var o = 0; return function () { return o >= r.length ? { done: !0 } : { done: !1, value: r[o++] }; }; } throw new TypeError(\"Invalid attempt to iterate non-iterable instance.\\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.\"); }\nfunction _unsupportedIterableToArray(r, a) { if (r) { if (\"string\" == typeof r) return _arrayLikeToArray(r, a); var t = {}.toString.call(r).slice(8, -1); return \"Object\" === t && r.constructor && (t = r.constructor.name), \"Map\" === t || \"Set\" === t ? Array.from(r) : \"Arguments\" === t || /^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(t) ? _arrayLikeToArray(r, a) : void 0; } }\nfunction _arrayLikeToArray(r, a) { (null == a || a > r.length) && (a = r.length); for (var e = 0, n = Array(a); e < a; e++) n[e] = r[e]; return n; }\nimport Metadata from '../metadata.js';\nimport getNumberType from './getNumberType.js';\n\n/**\r\n * Returns the exact country that a given national (significant) number belongs to\r\n * in case of ambiguity, i.e. when multiple countries share the same \"country calling code\".\r\n * @param {string} [nationalNumber]\r\n * @param {string[]} countries — A list of countries that share the same calling code.\r\n * @param {object} metadata — Metadata JSON.\r\n * @returns {string?} Returns the exact country this number belongs to, or `undefined` if the exact country couldn't be determined.\r\n */\nexport default function getCountryByNationalNumber(nationalNumber, countries, metadataJson) {\n // Create a new `metadata` instance because it will be selecting a `country`.\n var metadata = new Metadata(metadataJson);\n\n // const matchingCountries = []\n\n for (var _iterator = _createForOfIteratorHelperLoose(countries), _step; !(_step = _iterator()).done;) {\n var country = _step.value;\n metadata.selectNumberingPlan(country);\n // \"Leading digits\" patterns are only defined for about 20% of all countries.\n // By definition, matching \"leading digits\" is a sufficient but not a necessary\n // condition for a phone number to belong to a country.\n // The point of \"leading digits\" check is that it's the fastest one to get a match.\n // https://gitlab.com/catamphetamine/libphonenumber-js/blob/master/METADATA.md#leading_digits\n // I'd suppose that \"leading digits\" patterns are mutually exclusive for different countries\n // because of the intended use of that feature.\n if (metadata.leadingDigits()) {\n if (nationalNumber && nationalNumber.search(metadata.leadingDigits()) === 0) {\n return country;\n }\n }\n // Else perform full validation with all of those\n // fixed-line/mobile/etc regular expressions.\n else if (getNumberType({\n phone: nationalNumber,\n country: country\n }, undefined, metadata.metadata)) {\n // When multiple countries share the same \"country calling code\",\n // type patterns aren't guaranteed to be unique among them.\n // For example, both `US` and `CA` have the same pattern for `toll_free` numbers.\n // https://gitlab.com/catamphetamine/libphonenumber-js/-/issues/103#note_1417147572\n //\n // That means that this `if` condition could be `true` for multiple countries from the list.\n // Currently, it just returns the first one, which is also the \"main\" country for the \"country calling code\".\n // In an example with `toll_free` numbers above, `\"US\"` would be returned even though\n // it could as well be `\"CA\"`.\n //\n // There was also a time when this attempted to be overly smart\n // and kept track of all such multiple matching countries\n // and then picked the one that matched the `defaultCountry`, if provided.\n // For example, with `toll_free` numbers above, and with `defaultCountry: \"CA\"`,\n // it would've returned `\"CA\"` instead of `\"US\"`.\n // Later it turned out that such \"overly smart\" behavior turned out to be just confusing,\n // so this \"overly smart\" country detection was reverted to returning the \"main\" country\n // for the \"country calling code\".\n // https://gitlab.com/catamphetamine/libphonenumber-js/-/issues/154\n //\n return country;\n //\n // The \"overly smart\" behavior code:\n //\n // if (defaultCountry) {\n // \tif (country === defaultCountry) {\n // \t\treturn country\n // \t} else {\n // \t\tmatchingCountries.push(country)\n // \t}\n // } else {\n // \treturn country\n // }\n }\n }\n\n // // Return the first (\"main\") one of the `matchingCountries`.\n // if (matchingCountries.length > 0) {\n // \treturn matchingCountries[0]\n // }\n}\n//# sourceMappingURL=getCountryByNationalNumber.js.map","import getCountryByNationalNumber from './getCountryByNationalNumber.js';\nvar USE_NON_GEOGRAPHIC_COUNTRY_CODE = false;\n\n/**\r\n * Returns the exact country that a given national (significant) number belongs to\r\n * in case of ambiguity, i.e. when multiple countries share the same \"country calling code\".\r\n * @param {string} [callingCode]\r\n * @param {string} [options.nationalNumber] — National (significant) number.\r\n * @param {Metadata} options.metadata — Metadata instance.\r\n * @returns {string?} Returns the most suitable country for this calling code and national (significant) number.\r\n */\nexport default function getCountryByCallingCode(callingCode, _ref) {\n var nationalNumber = _ref.nationalNumber,\n metadata = _ref.metadata;\n /* istanbul ignore if */\n if (USE_NON_GEOGRAPHIC_COUNTRY_CODE) {\n if (metadata.isNonGeographicCallingCode(callingCode)) {\n return '001';\n }\n }\n var possibleCountries = metadata.getCountryCodesForCallingCode(callingCode);\n if (!possibleCountries) {\n return;\n }\n // If there's just one country corresponding to the country code,\n // then just return it, without further phone number digits validation.\n if (possibleCountries.length === 1) {\n return possibleCountries[0];\n }\n return getCountryByNationalNumber(nationalNumber, possibleCountries, metadata.metadata);\n}\n//# sourceMappingURL=getCountryByCallingCode.js.map","import extractNationalNumberFromPossiblyIncompleteNumber from './extractNationalNumberFromPossiblyIncompleteNumber.js';\nimport matchesEntirely from './matchesEntirely.js';\nimport checkNumberLength from './checkNumberLength.js';\nimport getCountryByCallingCode from './getCountryByCallingCode.js';\n\n/**\r\n * Strips national prefix and carrier code from a complete phone number.\r\n * The difference from the non-\"FromCompleteNumber\" function is that\r\n * it won't extract national prefix if the resultant number is too short\r\n * to be a complete number for the selected phone numbering plan.\r\n * @param {string} number — Complete phone number digits.\r\n * @param {string?} country — Specific country to use instead of the one that is pre-selected in the metadata instance.\r\n * @param {Metadata} metadata — Metadata instance with a selected numbering plan.\r\n * @return {object} `{ nationalNumber: string, carrierCode: string? }`.\r\n */\nexport default function extractNationalNumber(number, country, metadata) {\n // Parsing national prefixes and carrier codes\n // is only required for local phone numbers\n // but some people don't understand that\n // and sometimes write international phone numbers\n // with national prefixes (or maybe even carrier codes).\n // http://ucken.blogspot.ru/2016/03/trunk-prefixes-in-skype4b.html\n // Google's original library forgives such mistakes\n // and so does this library, because it has been requested:\n // https://github.com/catamphetamine/libphonenumber-js/issues/127\n var _extractNationalNumbe = extractNationalNumberFromPossiblyIncompleteNumber(number, metadata),\n carrierCode = _extractNationalNumbe.carrierCode,\n nationalNumber = _extractNationalNumbe.nationalNumber;\n if (nationalNumber !== number) {\n if (!shouldHaveExtractedNationalPrefix(number, nationalNumber, metadata)) {\n // Don't strip the national prefix.\n return {\n nationalNumber: number\n };\n }\n // Check the national (significant) number length after extracting national prefix and carrier code.\n // Legacy generated metadata (before `1.0.18`) didn't support the \"possible lengths\" feature,\n // so this `if` will only be executed with newer metadata.\n if (metadata.numberingPlan.possibleLengths()) {\n // If an exact `country` is not specified, attempt to detect it from the assumed national number.\n if (!country) {\n country = getCountryByCallingCode(metadata.numberingPlan.callingCode(), {\n nationalNumber: nationalNumber,\n metadata: metadata\n });\n }\n\n // The number remaining after stripping the national prefix and carrier code\n // should be long enough to have a possible length for the country.\n // Otherwise, don't strip the national prefix and carrier code,\n // since the original number could be a valid number.\n // This check has been copy-pasted \"as is\" from Google's original library:\n // https://github.com/google/libphonenumber/blob/876268eb1ad6cdc1b7b5bef17fc5e43052702d57/java/libphonenumber/src/com/google/i18n/phonenumbers/PhoneNumberUtil.java#L3236-L3250\n // It doesn't check for the \"possibility\" of the original `number`.\n // I guess it's fine not checking that one. It works as is anyway.\n if (!isPossibleIncompleteNationalNumber(nationalNumber, country, metadata)) {\n // Don't strip the national prefix.\n return {\n nationalNumber: number\n };\n }\n }\n }\n return {\n nationalNumber: nationalNumber,\n carrierCode: carrierCode\n };\n}\n\n// In some countries, the same digit could be a national prefix\n// or a leading digit of a valid phone number.\n// For example, in Russia, national prefix is `8`,\n// and also `800 555 35 35` is a valid number\n// in which `8` is not a national prefix, but the first digit\n// of a national (significant) number.\n// Same's with Belarus:\n// `82004910060` is a valid national (significant) number,\n// but `2004910060` is not.\n// To support such cases (to prevent the code from always stripping\n// national prefix), a condition is imposed: a national prefix\n// is not extracted when the original number is \"viable\" and the\n// resultant number is not, a \"viable\" national number being the one\n// that matches `national_number_pattern`.\nfunction shouldHaveExtractedNationalPrefix(nationalNumberBefore, nationalNumberAfter, metadata) {\n // The equivalent in Google's code is:\n // https://github.com/google/libphonenumber/blob/e326fa1fc4283bb05eb35cb3c15c18f98a31af33/java/libphonenumber/src/com/google/i18n/phonenumbers/PhoneNumberUtil.java#L2969-L3004\n if (matchesEntirely(nationalNumberBefore, metadata.nationalNumberPattern()) && !matchesEntirely(nationalNumberAfter, metadata.nationalNumberPattern())) {\n return false;\n }\n // This \"is possible\" national number (length) check has been commented out\n // because it's superceded by the (effectively) same check done in the\n // `extractNationalNumber()` function after it calls `shouldHaveExtractedNationalPrefix()`.\n // In other words, why run the same check twice if it could only be run once.\n // // Check the national (significant) number length after extracting national prefix and carrier code.\n // // Fixes a minor \"weird behavior\" bug: https://gitlab.com/catamphetamine/libphonenumber-js/-/issues/57\n // // (Legacy generated metadata (before `1.0.18`) didn't support the \"possible lengths\" feature).\n // if (metadata.possibleLengths()) {\n // \tif (isPossibleIncompleteNationalNumber(nationalNumberBefore, metadata) &&\n // \t\t!isPossibleIncompleteNationalNumber(nationalNumberAfter, metadata)) {\n // \t\treturn false\n // \t}\n // }\n return true;\n}\n\n/**\r\n * Tells if a given incomplete national number is possible or not.\r\n * @param {string} nationalNumber\r\n * @param {string?} country — Specific country rather than the one that is pre-selected in the metadata instance.\r\n * @param {Metadata} metadata — Metadata instance with a selected numbering plan.\r\n * @returns {boolean}\r\n */\nfunction isPossibleIncompleteNationalNumber(nationalNumber, country, metadata) {\n switch (checkNumberLength(nationalNumber, country, metadata)) {\n case 'TOO_SHORT':\n case 'INVALID_LENGTH':\n // This library ignores \"local-only\" phone numbers (for simplicity).\n // See the readme for more info on what are \"local-only\" phone numbers.\n // case 'IS_POSSIBLE_LOCAL_ONLY':\n return false;\n default:\n return true;\n }\n}\n//# sourceMappingURL=extractNationalNumber.js.map","import Metadata from '../metadata.js';\nimport matchesEntirely from './matchesEntirely.js';\nimport extractNationalNumber from './extractNationalNumber.js';\nimport checkNumberLength from './checkNumberLength.js';\nimport getCountryCallingCode from '../getCountryCallingCode.js';\n\n/**\r\n * Sometimes some people incorrectly input international phone numbers\r\n * without the leading `+`. This function corrects such input.\r\n * @param {string} number — Phone number digits (only digits, no `+`).\r\n * @param {string} [country] — Exact country of the phone number.\r\n * @param {string} [defaultCountry]\r\n * @param {string} [defaultCallingCode]\r\n * @param {object} metadataJson\r\n * @return {object} `{ countryCallingCode: string?, number: string }`, where `countryCallingCode` is the calling code that was extracted from the input `number` string, and `number` is the originally passed `number` without the extracted calling code.\r\n */\nexport default function extractCountryCallingCodeFromInternationalNumberWithoutPlusSign(number, country, defaultCountry, defaultCallingCode, metadataJson) {\n // Validate arguments.\n // The `number` is known to be in a non-international form\n // because there's no leading \"+\" character.\n // Therefore, there must be either `country` or `defaultCountry` or `defaultCallingCode`.\n // Otherwise, there'd be no source for the calling code to search for in the `number`.\n if (!(country || defaultCountry || defaultCallingCode)) {\n // There's no source for the calling code to search for in the `number`.\n return {\n number: number\n };\n }\n var countryCallingCode = country || defaultCountry ? getCountryCallingCode(country || defaultCountry, metadataJson) : defaultCallingCode;\n if (number.indexOf(countryCallingCode) === 0) {\n var metadata = new Metadata(metadataJson);\n metadata.selectNumberingPlan(country || defaultCountry || defaultCallingCode);\n var possibleShorterNumber = number.slice(countryCallingCode.length);\n var _extractNationalNumbe = extractNationalNumber(possibleShorterNumber, undefined, metadata),\n possibleShorterNationalNumber = _extractNationalNumbe.nationalNumber;\n var _extractNationalNumbe2 = extractNationalNumber(number, undefined, metadata),\n nationalNumber = _extractNationalNumbe2.nationalNumber;\n\n // If the number was not valid before but is valid now,\n // or if it was too long before, we consider the number\n // with the country calling code stripped to be a better result\n // and keep that instead.\n // For example, in Germany (+49), `49` is a valid area code,\n // so if a number starts with `49`, it could be both a valid\n // national German number or an international number without\n // a leading `+`.\n if (!matchesEntirely(nationalNumber, metadata.nationalNumberPattern()) && matchesEntirely(possibleShorterNationalNumber, metadata.nationalNumberPattern()) || checkNumberLength(nationalNumber, undefined, metadata) === 'TOO_LONG') {\n return {\n countryCallingCode: countryCallingCode,\n number: possibleShorterNumber\n };\n }\n }\n return {\n number: number\n };\n}\n//# sourceMappingURL=extractCountryCallingCodeFromInternationalNumberWithoutPlusSign.js.map","import stripIddPrefix from './stripIddPrefix.js';\nimport extractCountryCallingCodeFromInternationalNumberWithoutPlusSign from './extractCountryCallingCodeFromInternationalNumberWithoutPlusSign.js';\nimport Metadata from '../metadata.js';\nimport { MAX_LENGTH_COUNTRY_CODE } from '../constants.js';\n\n/**\r\n * Attempts to extract a calling code from a phone number.\r\n * * If the phone number is found to be \"international\":\r\n * * It will attempt to identify the calling code part of it and whether that part is complete and valid.\r\n * * If the calling code part is complete and valid, it will return two properties:\r\n * that calling code part (without `+`) and the rest of the digits.\r\n * * Otherwise, i.e. if the calling code part is incomplete or invalid,\r\n * it will return an empty object.\r\n * * Otherwise, i.e. if the phone number is national, there's no callind code to extract\r\n * so it will just return the originally-passed `number` string as the only property.\r\n * @param {string} number — Phone number digits (possibly with a `+`).\r\n * @param {string} [country] — Country.\r\n * @param {string} [defaultCountry] — Default country.\r\n * @param {string} [defaultCallingCode] — Default calling code (some phone numbering plans are non-geographic).\r\n * @param {object} metadataJson\r\n * @return {object} `{ countryCallingCodeSource: string?, countryCallingCode: string?, number: string }`, where `countryCallingCodeSource` tells how the returned calling code was extracted (if it was extracted), `countryCallingCode` is the calling code that was extracted from the input `number` string, and `number` is the originally passed `number` without the extracted calling code (and without a `+`). If the calling code is present but incomplete or invalid, it will return an empty object.\r\n * @example\r\n * // Returns `{ countryCallingCode: \"1\", number: \"2133734253\" }`.\r\n * extractCountryCallingCode('2133734253', 'US', null, null, metadata)\r\n * extractCountryCallingCode('2133734253', null, 'US', null, metadata)\r\n * extractCountryCallingCode('2133734253', null, null, '1', metadata)\r\n * extractCountryCallingCode('+12133734253', null, null, null, metadata)\r\n * extractCountryCallingCode('+12133734253', null, 'RU', null, metadata)\r\n */\nexport default function extractCountryCallingCode(number, country, defaultCountry, defaultCallingCode, metadataJson) {\n if (!number) {\n return {};\n }\n var isNumberWithIddPrefix;\n\n // If this is not an international phone number,\n // then either extract an \"IDD\" prefix, or extract a\n // country calling code from a number by autocorrecting it\n // by prepending a leading `+` in cases when it starts\n // with the country calling code.\n // https://wikitravel.org/en/International_dialling_prefix\n // https://github.com/catamphetamine/libphonenumber-js/issues/376\n if (number[0] !== '+') {\n // Convert an \"out-of-country\" dialing phone number\n // to a proper international phone number.\n var numberWithoutIDD = stripIddPrefix(number, country || defaultCountry, defaultCallingCode, metadataJson);\n // If an IDD prefix was stripped then\n // convert the number to international one\n // for subsequent parsing.\n if (numberWithoutIDD && numberWithoutIDD !== number) {\n isNumberWithIddPrefix = true;\n number = '+' + numberWithoutIDD;\n } else {\n // Check to see if the number starts with the country calling code\n // for the default country. If so, we remove the country calling code,\n // and do some checks on the validity of the number before and after.\n // https://github.com/catamphetamine/libphonenumber-js/issues/376\n if (country || defaultCountry || defaultCallingCode) {\n var _extractCountryCallin = extractCountryCallingCodeFromInternationalNumberWithoutPlusSign(number, country, defaultCountry, defaultCallingCode, metadataJson),\n countryCallingCode = _extractCountryCallin.countryCallingCode,\n shorterNumber = _extractCountryCallin.number;\n if (countryCallingCode) {\n return {\n countryCallingCodeSource: 'FROM_NUMBER_WITHOUT_PLUS_SIGN',\n countryCallingCode: countryCallingCode,\n number: shorterNumber\n };\n }\n }\n return {\n // No need to set it to `UNSPECIFIED`. It can be just `undefined`.\n // countryCallingCodeSource: 'UNSPECIFIED',\n number: number\n };\n }\n }\n\n // `number` can only be international at this point.\n\n // Fast abortion: country codes do not begin with a '0'\n if (number[1] === '0') {\n return {};\n }\n var metadata = new Metadata(metadataJson);\n\n // The thing with country phone codes\n // is that they are orthogonal to each other\n // i.e. there's no such country phone code A\n // for which country phone code B exists\n // where B starts with A.\n // Therefore, while scanning digits,\n // if a valid country code is found,\n // that means that it is the country code.\n //\n var i = 2;\n while (i - 1 <= MAX_LENGTH_COUNTRY_CODE && i <= number.length) {\n var _countryCallingCode = number.slice(1, i);\n if (metadata.hasCallingCode(_countryCallingCode)) {\n metadata.selectNumberingPlan(_countryCallingCode);\n return {\n countryCallingCodeSource: isNumberWithIddPrefix ? 'FROM_NUMBER_WITH_IDD' : 'FROM_NUMBER_WITH_PLUS_SIGN',\n countryCallingCode: _countryCallingCode,\n number: number.slice(i)\n };\n }\n i++;\n }\n return {};\n}\n\n// The possible values for the returned `countryCallingCodeSource` are:\n//\n// Copy-pasted from:\n// https://github.com/google/libphonenumber/blob/master/resources/phonenumber.proto\n//\n// // The source from which the country_code is derived. This is not set in the\n// // general parsing method, but in the method that parses and keeps raw_input.\n// // New fields could be added upon request.\n// enum CountryCodeSource {\n// // Default value returned if this is not set, because the phone number was\n// // created using parse, not parseAndKeepRawInput. hasCountryCodeSource will\n// // return false if this is the case.\n// UNSPECIFIED = 0;\n//\n// // The country_code is derived based on a phone number with a leading \"+\",\n// // e.g. the French number \"+33 1 42 68 53 00\".\n// FROM_NUMBER_WITH_PLUS_SIGN = 1;\n//\n// // The country_code is derived based on a phone number with a leading IDD,\n// // e.g. the French number \"011 33 1 42 68 53 00\", as it is dialled from US.\n// FROM_NUMBER_WITH_IDD = 5;\n//\n// // The country_code is derived based on a phone number without a leading\n// // \"+\", e.g. the French number \"33 1 42 68 53 00\" when defaultCountry is\n// // supplied as France.\n// FROM_NUMBER_WITHOUT_PLUS_SIGN = 10;\n//\n// // The country_code is derived NOT based on the phone number itself, but\n// // from the defaultCountry parameter provided in the parsing function by the\n// // clients. This happens mostly for numbers written in the national format\n// // (without country code). For example, this would be set when parsing the\n// // French number \"01 42 68 53 00\", when defaultCountry is supplied as\n// // France.\n// FROM_DEFAULT_COUNTRY = 20;\n// }\n//# sourceMappingURL=extractCountryCallingCode.js.map","import { VALID_PUNCTUATION } from '../constants.js';\n\n// Removes brackets and replaces dashes with spaces.\n//\n// E.g. \"(999) 111-22-33\" -> \"999 111 22 33\"\n//\n// For some reason Google's metadata contains `<intlFormat/>`s with brackets and dashes.\n// Meanwhile, there's no single opinion about using punctuation in international phone numbers.\n//\n// For example, Google's `<intlFormat/>` for USA is `+1 213-373-4253`.\n// And here's a quote from WikiPedia's \"North American Numbering Plan\" page:\n// https://en.wikipedia.org/wiki/North_American_Numbering_Plan\n//\n// \"The country calling code for all countries participating in the NANP is 1.\n// In international format, an NANP number should be listed as +1 301 555 01 00,\n// where 301 is an area code (Maryland).\"\n//\n// I personally prefer the international format without any punctuation.\n// For example, brackets are remnants of the old age, meaning that the\n// phone number part in brackets (so called \"area code\") can be omitted\n// if dialing within the same \"area\".\n// And hyphens were clearly introduced for splitting local numbers into memorizable groups.\n// For example, remembering \"5553535\" is difficult but \"555-35-35\" is much simpler.\n// Imagine a man taking a bus from home to work and seeing an ad with a phone number.\n// He has a couple of seconds to memorize that number until it passes by.\n// If it were spaces instead of hyphens the man wouldn't necessarily get it,\n// but with hyphens instead of spaces the grouping is more explicit.\n// I personally think that hyphens introduce visual clutter,\n// so I prefer replacing them with spaces in international numbers.\n// In the modern age all output is done on displays where spaces are clearly distinguishable\n// so hyphens can be safely replaced with spaces without losing any legibility.\n//\nexport default function applyInternationalSeparatorStyle(formattedNumber) {\n return formattedNumber.replace(new RegExp(\"[\".concat(VALID_PUNCTUATION, \"]+\"), 'g'), ' ').trim();\n}\n//# sourceMappingURL=applyInternationalSeparatorStyle.js.map","import applyInternationalSeparatorStyle from './applyInternationalSeparatorStyle.js';\n\n// This was originally set to $1 but there are some countries for which the\n// first group is not used in the national pattern (e.g. Argentina) so the $1\n// group does not match correctly. Therefore, we use `\\d`, so that the first\n// group actually used in the pattern will be matched.\nexport var FIRST_GROUP_PATTERN = /(\\$\\d)/;\nexport default function formatNationalNumberUsingFormat(number, format, _ref) {\n var useInternationalFormat = _ref.useInternationalFormat,\n withNationalPrefix = _ref.withNationalPrefix,\n carrierCode = _ref.carrierCode,\n metadata = _ref.metadata;\n var formattedNumber = number.replace(new RegExp(format.pattern()), useInternationalFormat ? format.internationalFormat() :\n // This library doesn't use `domestic_carrier_code_formatting_rule`,\n // because that one is only used when formatting phone numbers\n // for dialing from a mobile phone, and this is not a dialing library.\n // carrierCode && format.domesticCarrierCodeFormattingRule()\n // \t// First, replace the $CC in the formatting rule with the desired carrier code.\n // \t// Then, replace the $FG in the formatting rule with the first group\n // \t// and the carrier code combined in the appropriate way.\n // \t? format.format().replace(FIRST_GROUP_PATTERN, format.domesticCarrierCodeFormattingRule().replace('$CC', carrierCode))\n // \t: (\n // \t\twithNationalPrefix && format.nationalPrefixFormattingRule()\n // \t\t\t? format.format().replace(FIRST_GROUP_PATTERN, format.nationalPrefixFormattingRule())\n // \t\t\t: format.format()\n // \t)\n withNationalPrefix && format.nationalPrefixFormattingRule() ? format.format().replace(FIRST_GROUP_PATTERN, format.nationalPrefixFormattingRule()) : format.format());\n if (useInternationalFormat) {\n return applyInternationalSeparatorStyle(formattedNumber);\n }\n return formattedNumber;\n}\n//# sourceMappingURL=formatNationalNumberUsingFormat.js.map","import Metadata from '../metadata.js';\n\n/**\r\n * Pattern that makes it easy to distinguish whether a region has a single\r\n * international dialing prefix or not. If a region has a single international\r\n * prefix (e.g. 011 in USA), it will be represented as a string that contains\r\n * a sequence of ASCII digits, and possibly a tilde, which signals waiting for\r\n * the tone. If there are multiple available international prefixes in a\r\n * region, they will be represented as a regex string that always contains one\r\n * or more characters that are not ASCII digits or a tilde.\r\n */\nvar SINGLE_IDD_PREFIX_REG_EXP = /^[\\d]+(?:[~\\u2053\\u223C\\uFF5E][\\d]+)?$/;\n\n// If the `country` supports IDD calling, it returns a preferred IDD prefix.\n// If the `country` doesn't support IDD calling, it returns `undefined`.\nexport default function getIddPrefix(country, callingCode, metadata) {\n var countryMetadata = new Metadata(metadata);\n countryMetadata.selectNumberingPlan(country || callingCode);\n if (countryMetadata.defaultIDDPrefix()) {\n return countryMetadata.defaultIDDPrefix();\n }\n if (SINGLE_IDD_PREFIX_REG_EXP.test(countryMetadata.IDDPrefix())) {\n return countryMetadata.IDDPrefix();\n }\n}\n//# sourceMappingURL=getIddPrefix.js.map","function _slicedToArray(r, e) { return _arrayWithHoles(r) || _iterableToArrayLimit(r, e) || _unsupportedIterableToArray(r, e) || _nonIterableRest(); }\nfunction _nonIterableRest() { throw new TypeError(\"Invalid attempt to destructure non-iterable instance.\\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.\"); }\nfunction _iterableToArrayLimit(r, l) { var t = null == r ? null : \"undefined\" != typeof Symbol && r[Symbol.iterator] || r[\"@@iterator\"]; if (null != t) { var e, n, i, u, a = [], f = !0, o = !1; try { if (i = (t = t.call(r)).next, 0 === l) { if (Object(t) !== t) return; f = !1; } else for (; !(f = (e = i.call(t)).done) && (a.push(e.value), a.length !== l); f = !0); } catch (r) { o = !0, n = r; } finally { try { if (!f && null != t[\"return\"] && (u = t[\"return\"](), Object(u) !== u)) return; } finally { if (o) throw n; } } return a; } }\nfunction _arrayWithHoles(r) { if (Array.isArray(r)) return r; }\nfunction _createForOfIteratorHelperLoose(r, e) { var t = \"undefined\" != typeof Symbol && r[Symbol.iterator] || r[\"@@iterator\"]; if (t) return (t = t.call(r)).next.bind(t); if (Array.isArray(r) || (t = _unsupportedIterableToArray(r)) || e && r && \"number\" == typeof r.length) { t && (r = t); var o = 0; return function () { return o >= r.length ? { done: !0 } : { done: !1, value: r[o++] }; }; } throw new TypeError(\"Invalid attempt to iterate non-iterable instance.\\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.\"); }\nfunction _unsupportedIterableToArray(r, a) { if (r) { if (\"string\" == typeof r) return _arrayLikeToArray(r, a); var t = {}.toString.call(r).slice(8, -1); return \"Object\" === t && r.constructor && (t = r.constructor.name), \"Map\" === t || \"Set\" === t ? Array.from(r) : \"Arguments\" === t || /^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(t) ? _arrayLikeToArray(r, a) : void 0; } }\nfunction _arrayLikeToArray(r, a) { (null == a || a > r.length) && (a = r.length); for (var e = 0, n = Array(a); e < a; e++) n[e] = r[e]; return n; }\nimport isViablePhoneNumber from './isViablePhoneNumber.js';\n\n// https://www.ietf.org/rfc/rfc3966.txt\n\n/**\r\n * @param {string} text - Phone URI (RFC 3966).\r\n * @return {object} `{ ?number, ?ext }`.\r\n */\nexport function parseRFC3966(text) {\n var number;\n var ext;\n\n // Replace \"tel:\" with \"tel=\" for parsing convenience.\n text = text.replace(/^tel:/, 'tel=');\n for (var _iterator = _createForOfIteratorHelperLoose(text.split(';')), _step; !(_step = _iterator()).done;) {\n var part = _step.value;\n var _part$split = part.split('='),\n _part$split2 = _slicedToArray(_part$split, 2),\n name = _part$split2[0],\n value = _part$split2[1];\n switch (name) {\n case 'tel':\n number = value;\n break;\n case 'ext':\n ext = value;\n break;\n case 'phone-context':\n // Only \"country contexts\" are supported.\n // \"Domain contexts\" are ignored.\n if (value[0] === '+') {\n number = value + number;\n }\n break;\n }\n }\n\n // If the phone number is not viable, then abort.\n if (!isViablePhoneNumber(number)) {\n return {};\n }\n var result = {\n number: number\n };\n if (ext) {\n result.ext = ext;\n }\n return result;\n}\n\n/**\r\n * @param {object} - `{ ?number, ?extension }`.\r\n * @return {string} Phone URI (RFC 3966).\r\n */\nexport function formatRFC3966(_ref) {\n var number = _ref.number,\n ext = _ref.ext;\n if (!number) {\n return '';\n }\n if (number[0] !== '+') {\n throw new Error(\"\\\"formatRFC3966()\\\" expects \\\"number\\\" to be in E.164 format.\");\n }\n return \"tel:\".concat(number).concat(ext ? ';ext=' + ext : '');\n}\n//# sourceMappingURL=RFC3966.js.map","// This is a port of Google Android `libphonenumber`'s\n// `phonenumberutil.js` of December 31th, 2018.\n//\n// https://github.com/googlei18n/libphonenumber/commits/master/javascript/i18n/phonenumbers/phonenumberutil.js\n\nimport matchesEntirely from './helpers/matchesEntirely.js';\nimport formatNationalNumberUsingFormat from './helpers/formatNationalNumberUsingFormat.js';\nimport Metadata, { getCountryCallingCode } from './metadata.js';\nimport getIddPrefix from './helpers/getIddPrefix.js';\nimport { formatRFC3966 } from './helpers/RFC3966.js';\nvar DEFAULT_OPTIONS = {\n formatExtension: function formatExtension(formattedNumber, extension, metadata) {\n return \"\".concat(formattedNumber).concat(metadata.ext()).concat(extension);\n }\n};\n\n/**\r\n * Formats a phone number.\r\n *\r\n * format(phoneNumberInstance, 'INTERNATIONAL', { ..., v2: true }, metadata)\r\n * format(phoneNumberInstance, 'NATIONAL', { ..., v2: true }, metadata)\r\n *\r\n * format({ phone: '8005553535', country: 'RU' }, 'INTERNATIONAL', { ... }, metadata)\r\n * format({ phone: '8005553535', country: 'RU' }, 'NATIONAL', undefined, metadata)\r\n *\r\n * @param {object|PhoneNumber} input — If `options.v2: true` flag is passed, the `input` should be a `PhoneNumber` instance. Otherwise, it should be an object of shape `{ phone: '...', country: '...' }`.\r\n * @param {string} format\r\n * @param {object} [options]\r\n * @param {object} metadataJson\r\n * @return {string}\r\n */\nexport default function formatNumber(input, format, options, metadataJson) {\n // Apply default options.\n if (options) {\n // Using ES6 \"rest spread\" syntax here didn't work with `babel`/`istanbul`\n // for some weird reason: this line of code would cause the code coverage\n // to show as not 100%. That's because `babel`/`istanbul`, for some weird reason,\n // apparently doesn't know how to properly exclude Babel polyfills from code coverage.\n //\n // options = { ...DEFAULT_OPTIONS, ...options }\n //\n options = merge({}, DEFAULT_OPTIONS, options);\n } else {\n options = DEFAULT_OPTIONS;\n }\n var metadata = new Metadata(metadataJson);\n\n // Normally, the `input` object is supposed to be a `PhoneNumber` class instance.\n // Also, according to the `PhoneNumber` class source code, `country` can't be \"001\".\n // It means that normally `input.country` or `input.countryCallingCode` is supposed\n // to be present because either of the two is always required to exist in a `PhoneNumber` instance.\n // This means that realistically, it's gonna step into either the first `if`\n // or the following `else if`, and normally it won't even reach the legacy-compatibility\n // `else return input.phone || ''` part.\n // So normally, it won't ever return an empty string here.\n if (input.country && input.country !== '001') {\n // Validate `input.country`.\n if (!metadata.hasCountry(input.country)) {\n throw new Error(\"Unknown country: \".concat(input.country));\n }\n metadata.selectNumberingPlan(input.country);\n } else if (input.countryCallingCode) {\n metadata.selectNumberingPlan(input.countryCallingCode);\n } else return input.phone || '';\n var countryCallingCode = metadata.countryCallingCode();\n var nationalNumber = options.v2 ? input.nationalNumber : input.phone;\n\n // This variable should have been declared inside `case`s\n // but Babel has a bug and it says \"duplicate variable declaration\".\n var number;\n switch (format) {\n case 'NATIONAL':\n // Normally, the `input` object is supposed to be a `PhoneNumber` class instance,\n // and a `PhoneNumber` class instance is always required to have a `nationalNumber`.\n // This means that the `if (!nationalNumber)` below is just for legacy-compatibility\n // and it normally can't really happen, so normally it won't ever return an empty string here.\n if (!nationalNumber) {\n return '';\n }\n number = formatNationalNumber(nationalNumber, input.carrierCode, 'NATIONAL', metadata, options);\n return addExtension(number, input.ext, metadata, options.formatExtension);\n case 'INTERNATIONAL':\n // Legacy argument support.\n // (`{ country: ..., phone: '' }`)\n if (!nationalNumber) {\n return \"+\".concat(countryCallingCode);\n }\n number = formatNationalNumber(nationalNumber, null, 'INTERNATIONAL', metadata, options);\n number = \"+\".concat(countryCallingCode, \" \").concat(number);\n return addExtension(number, input.ext, metadata, options.formatExtension);\n case 'E.164':\n // `E.164` doesn't define \"phone number extensions\".\n return \"+\".concat(countryCallingCode).concat(nationalNumber);\n case 'RFC3966':\n return formatRFC3966({\n number: \"+\".concat(countryCallingCode).concat(nationalNumber),\n ext: input.ext\n });\n\n // For reference, here's Google's IDD formatter:\n // https://github.com/google/libphonenumber/blob/32719cf74e68796788d1ca45abc85dcdc63ba5b9/java/libphonenumber/src/com/google/i18n/phonenumbers/PhoneNumberUtil.java#L1546\n // Not saying that this IDD formatter replicates it 1:1, but it seems to work.\n // Who would even need to format phone numbers in IDD format anyway?\n case 'IDD':\n // If the required `fromCountry` parameter is not passed, it will return `undefined`.\n if (!options.fromCountry) {\n return;\n // throw new Error('`fromCountry` option not passed for IDD-prefixed formatting.')\n }\n var formattedNumber = formatIDD(nationalNumber, input.carrierCode, countryCallingCode, options.fromCountry, metadata);\n // If the country of the phone number doesn't support IDD calling, it will return `undefined`.\n if (!formattedNumber) {\n return;\n }\n return addExtension(formattedNumber, input.ext, metadata, options.formatExtension);\n default:\n throw new Error(\"Unknown \\\"format\\\" argument passed to \\\"formatNumber()\\\": \\\"\".concat(format, \"\\\"\"));\n }\n}\nfunction formatNationalNumber(number, carrierCode, formatAs, metadata, options) {\n var format = chooseFormatForNumber(metadata.formats(), number);\n if (!format) {\n return number;\n }\n return formatNationalNumberUsingFormat(number, format, {\n useInternationalFormat: formatAs === 'INTERNATIONAL',\n withNationalPrefix: format.nationalPrefixIsOptionalWhenFormattingInNationalFormat() && options && options.nationalPrefix === false ? false : true,\n carrierCode: carrierCode,\n metadata: metadata\n });\n}\nexport function chooseFormatForNumber(availableFormats, nationalNumber) {\n // Using a `for ... of` loop here didn't work with `babel`/`istanbul`:\n // for some weird reason, it showed code coverage less than 100%.\n // That's because `babel`/`istanbul`, for some weird reason,\n // apparently doesn't know how to properly exclude Babel polyfills from code coverage.\n //\n // for (const format of availableFormats) { ... }\n //\n return pickFirstMatchingElement(availableFormats, function (format) {\n // Validate leading digits.\n // The test case for \"else path\" could be found by searching for\n // \"format.leadingDigitsPatterns().length === 0\".\n if (format.leadingDigitsPatterns().length > 0) {\n // The last leading_digits_pattern is used here, as it is the most detailed\n var lastLeadingDigitsPattern = format.leadingDigitsPatterns()[format.leadingDigitsPatterns().length - 1];\n // If leading digits don't match then move on to the next phone number format\n if (nationalNumber.search(lastLeadingDigitsPattern) !== 0) {\n return false;\n }\n }\n // Check that the national number matches the phone number format regular expression\n return matchesEntirely(nationalNumber, format.pattern());\n });\n}\nfunction addExtension(formattedNumber, ext, metadata, formatExtension) {\n return ext ? formatExtension(formattedNumber, ext, metadata) : formattedNumber;\n}\nfunction formatIDD(nationalNumber, carrierCode, countryCallingCode, fromCountry, metadata) {\n var fromCountryCallingCode = getCountryCallingCode(fromCountry, metadata.metadata);\n // When calling within the same country calling code.\n if (fromCountryCallingCode === countryCallingCode) {\n var formattedNumber = formatNationalNumber(nationalNumber, carrierCode, 'NATIONAL', metadata);\n // For NANPA regions, return the national format for these regions\n // but prefix it with the country calling code.\n if (countryCallingCode === '1') {\n return countryCallingCode + ' ' + formattedNumber;\n }\n // If regions share a country calling code, the country calling code need\n // not be dialled. This also applies when dialling within a region, so this\n // if clause covers both these cases. Technically this is the case for\n // dialling from La Reunion to other overseas departments of France (French\n // Guiana, Martinique, Guadeloupe), but not vice versa - so we don't cover\n // this edge case for now and for those cases return the version including\n // country calling code. Details here:\n // http://www.petitfute.com/voyage/225-info-pratiques-reunion\n //\n return formattedNumber;\n }\n var iddPrefix = getIddPrefix(fromCountry, undefined, metadata.metadata);\n if (iddPrefix) {\n return \"\".concat(iddPrefix, \" \").concat(countryCallingCode, \" \").concat(formatNationalNumber(nationalNumber, null, 'INTERNATIONAL', metadata));\n }\n}\nfunction merge() {\n var i = 1;\n for (var _len = arguments.length, objects = new Array(_len), _key = 0; _key < _len; _key++) {\n objects[_key] = arguments[_key];\n }\n while (i < objects.length) {\n if (objects[i]) {\n for (var key in objects[i]) {\n objects[0][key] = objects[i][key];\n }\n }\n i++;\n }\n return objects[0];\n}\nfunction pickFirstMatchingElement(elements, testFunction) {\n var i = 0;\n while (i < elements.length) {\n if (testFunction(elements[i])) {\n return elements[i];\n }\n i++;\n }\n}\n//# sourceMappingURL=format.js.map","function _typeof(o) { \"@babel/helpers - typeof\"; return _typeof = \"function\" == typeof Symbol && \"symbol\" == typeof Symbol.iterator ? function (o) { return typeof o; } : function (o) { return o && \"function\" == typeof Symbol && o.constructor === Symbol && o !== Symbol.prototype ? \"symbol\" : typeof o; }, _typeof(o); }\nfunction ownKeys(e, r) { var t = Object.keys(e); if (Object.getOwnPropertySymbols) { var o = Object.getOwnPropertySymbols(e); r && (o = o.filter(function (r) { return Object.getOwnPropertyDescriptor(e, r).enumerable; })), t.push.apply(t, o); } return t; }\nfunction _objectSpread(e) { for (var r = 1; r < arguments.length; r++) { var t = null != arguments[r] ? arguments[r] : {}; r % 2 ? ownKeys(Object(t), !0).forEach(function (r) { _defineProperty(e, r, t[r]); }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(e, Object.getOwnPropertyDescriptors(t)) : ownKeys(Object(t)).forEach(function (r) { Object.defineProperty(e, r, Object.getOwnPropertyDescriptor(t, r)); }); } return e; }\nfunction _defineProperty(e, r, t) { return (r = _toPropertyKey(r)) in e ? Object.defineProperty(e, r, { value: t, enumerable: !0, configurable: !0, writable: !0 }) : e[r] = t, e; }\nfunction _classCallCheck(a, n) { if (!(a instanceof n)) throw new TypeError(\"Cannot call a class as a function\"); }\nfunction _defineProperties(e, r) { for (var t = 0; t < r.length; t++) { var o = r[t]; o.enumerable = o.enumerable || !1, o.configurable = !0, \"value\" in o && (o.writable = !0), Object.defineProperty(e, _toPropertyKey(o.key), o); } }\nfunction _createClass(e, r, t) { return r && _defineProperties(e.prototype, r), t && _defineProperties(e, t), Object.defineProperty(e, \"prototype\", { writable: !1 }), e; }\nfunction _toPropertyKey(t) { var i = _toPrimitive(t, \"string\"); return \"symbol\" == _typeof(i) ? i : i + \"\"; }\nfunction _toPrimitive(t, r) { if (\"object\" != _typeof(t) || !t) return t; var e = t[Symbol.toPrimitive]; if (void 0 !== e) { var i = e.call(t, r || \"default\"); if (\"object\" != _typeof(i)) return i; throw new TypeError(\"@@toPrimitive must return a primitive value.\"); } return (\"string\" === r ? String : Number)(t); }\nimport Metadata, { validateMetadata } from './metadata.js';\nimport isPossibleNumber from './isPossible.js';\nimport isValidNumber from './isValid.js';\nimport getNumberType from './helpers/getNumberType.js';\nimport getCountryAndCallingCodeFromOneOfThem from './helpers/getCountryAndCallingCodeFromOneOfThem.js';\nimport getPossibleCountriesForNumber from './helpers/getPossibleCountriesForNumber.js';\nimport extractCountryCallingCode from './helpers/extractCountryCallingCode.js';\nimport isObject from './helpers/isObject.js';\nimport formatNumber from './format.js';\nvar USE_NON_GEOGRAPHIC_COUNTRY_CODE = false;\nvar PhoneNumber = /*#__PURE__*/function () {\n /**\r\n * @param {string} countryOrCountryCallingCode\r\n * @param {string} nationalNumber\r\n * @param {object} metadata — Metadata JSON\r\n * @return {PhoneNumber}\r\n */\n function PhoneNumber(countryOrCountryCallingCode, nationalNumber, metadata) {\n _classCallCheck(this, PhoneNumber);\n // Validate `countryOrCountryCallingCode` argument.\n if (!countryOrCountryCallingCode) {\n throw new TypeError('First argument is required');\n }\n if (typeof countryOrCountryCallingCode !== 'string') {\n throw new TypeError('First argument must be a string');\n }\n\n // In case of public API use: `constructor(number, metadata)`.\n // Transform the arguments from `constructor(number, metadata)` to\n // `constructor(countryOrCountryCallingCode, nationalNumber, metadata)`.\n if (countryOrCountryCallingCode[0] === '+' && !nationalNumber) {\n throw new TypeError('`metadata` argument not passed');\n }\n if (isObject(nationalNumber) && isObject(nationalNumber.countries)) {\n metadata = nationalNumber;\n var e164Number = countryOrCountryCallingCode;\n if (!E164_NUMBER_REGEXP.test(e164Number)) {\n throw new Error('Invalid `number` argument passed: must consist of a \"+\" followed by digits');\n }\n var _extractCountryCallin = extractCountryCallingCode(e164Number, undefined, undefined, undefined, metadata),\n _countryCallingCode = _extractCountryCallin.countryCallingCode,\n number = _extractCountryCallin.number;\n nationalNumber = number;\n countryOrCountryCallingCode = _countryCallingCode;\n if (!nationalNumber) {\n throw new Error('Invalid `number` argument passed: too short');\n }\n }\n\n // Validate `nationalNumber` argument.\n if (!nationalNumber) {\n throw new TypeError('`nationalNumber` argument is required');\n }\n if (typeof nationalNumber !== 'string') {\n throw new TypeError('`nationalNumber` argument must be a string');\n }\n\n // Validate `metadata` argument.\n validateMetadata(metadata);\n\n // Initialize properties.\n var _getCountryAndCalling = getCountryAndCallingCodeFromOneOfThem(countryOrCountryCallingCode, metadata),\n country = _getCountryAndCalling.country,\n countryCallingCode = _getCountryAndCalling.callingCode;\n this.country = country;\n this.countryCallingCode = countryCallingCode;\n this.nationalNumber = nationalNumber;\n this.number = '+' + this.countryCallingCode + this.nationalNumber;\n // Exclude `metadata` property output from `PhoneNumber.toString()`\n // so that it doesn't clutter the console output of Node.js.\n // Previously, when Node.js did `console.log(new PhoneNumber(...))`,\n // it would output the whole internal structure of the `metadata` object.\n this.getMetadata = function () {\n return metadata;\n };\n }\n return _createClass(PhoneNumber, [{\n key: \"setExt\",\n value: function setExt(ext) {\n this.ext = ext;\n }\n }, {\n key: \"getPossibleCountries\",\n value: function getPossibleCountries() {\n if (this.country) {\n return [this.country];\n }\n return getPossibleCountriesForNumber(this.countryCallingCode, this.nationalNumber, this.getMetadata());\n }\n }, {\n key: \"isPossible\",\n value: function isPossible() {\n return isPossibleNumber(this, {\n v2: true\n }, this.getMetadata());\n }\n }, {\n key: \"isValid\",\n value: function isValid() {\n return isValidNumber(this, {\n v2: true\n }, this.getMetadata());\n }\n }, {\n key: \"isNonGeographic\",\n value: function isNonGeographic() {\n var metadata = new Metadata(this.getMetadata());\n return metadata.isNonGeographicCallingCode(this.countryCallingCode);\n }\n }, {\n key: \"isEqual\",\n value: function isEqual(phoneNumber) {\n return this.number === phoneNumber.number && this.ext === phoneNumber.ext;\n }\n\n // `validateLength()` method was originally meant to be an equivalent for `validatePhoneNumberLength()`.\n //\n // Later, it became apparent that it's not really a true equivalent.\n // The reason is that a `PhoneNumber` instance is not created\n // when the phone number string is too short for it to be considered a valid phone number:\n // * When there must be at least 2 national (significant) number digits: `\"1\"`.\n // * When the country calling code part of an international number is incomplete: `\"+12\"`.\n //\n // So leaving this `validateLength()` method here would suggest a hidden anti-pattern\n // of using it instead of `validatePhoneNumberLength()` while ignoring\n // the \"too short to be even possible\" case from phone number length validation.\n // And ignoring that case wouldn't make any sense in a real-world application\n // because it would still be a valid case that should be handled.\n //\n // Because of that, this method was eventually commented out in order to not introduce\n // that kind of an anti-pattern.\n //\n // validateLength() {\n // \tconst result = checkNumberLength(\n // \t\tthis.nationalNumber,\n // \t\tundefined,\n // \t\tthis.getMetadata()\n // \t)\n // \tif (result !== 'IS_POSSIBLE') {\n // \t\treturn result\n // \t}\n // }\n }, {\n key: \"getType\",\n value: function getType() {\n return getNumberType(this, {\n v2: true\n }, this.getMetadata());\n }\n }, {\n key: \"format\",\n value: function format(_format, options) {\n return formatNumber(this, _format, options ? _objectSpread(_objectSpread({}, options), {}, {\n v2: true\n }) : {\n v2: true\n }, this.getMetadata());\n }\n }, {\n key: \"formatNational\",\n value: function formatNational(options) {\n return this.format('NATIONAL', options);\n }\n }, {\n key: \"formatInternational\",\n value: function formatInternational(options) {\n return this.format('INTERNATIONAL', options);\n }\n }, {\n key: \"getURI\",\n value: function getURI(options) {\n return this.format('RFC3966', options);\n }\n }]);\n}();\nexport { PhoneNumber as default };\nvar E164_NUMBER_REGEXP = /^\\+\\d+$/;\n//# sourceMappingURL=PhoneNumber.js.map","// When phone numbers are written in `RFC3966` format — `\"tel:+12133734253\"` —\n// they can have their \"calling code\" part written separately in a `phone-context` parameter.\n// Example: `\"tel:12133734253;phone-context=+1\"`.\n// This function parses the full phone number from the local number and the `phone-context`\n// when the `phone-context` contains a `+` sign.\n\nimport { VALID_DIGITS\n// PLUS_CHARS\n} from '../constants.js';\nexport var PLUS_SIGN = '+';\nvar RFC3966_VISUAL_SEPARATOR_ = '[\\\\-\\\\.\\\\(\\\\)]?';\nvar RFC3966_PHONE_DIGIT_ = '(' + '[' + VALID_DIGITS + ']' + '|' + RFC3966_VISUAL_SEPARATOR_ + ')';\nvar RFC3966_GLOBAL_NUMBER_DIGITS_ = '^' + '\\\\' + PLUS_SIGN + RFC3966_PHONE_DIGIT_ + '*' + '[' + VALID_DIGITS + ']' + RFC3966_PHONE_DIGIT_ + '*' + '$';\n\n/**\r\n * Regular expression of valid global-number-digits for the phone-context\r\n * parameter, following the syntax defined in RFC3966.\r\n */\nvar RFC3966_GLOBAL_NUMBER_DIGITS_PATTERN_ = new RegExp(RFC3966_GLOBAL_NUMBER_DIGITS_, 'g');\n\n// In this port of Google's library, we don't accept alpha characters in phone numbers.\n// const ALPHANUM_ = VALID_ALPHA_ + VALID_DIGITS\nvar ALPHANUM_ = VALID_DIGITS;\nvar RFC3966_DOMAINLABEL_ = '[' + ALPHANUM_ + ']+((\\\\-)*[' + ALPHANUM_ + '])*';\nvar VALID_ALPHA_ = 'a-zA-Z';\nvar RFC3966_TOPLABEL_ = '[' + VALID_ALPHA_ + ']+((\\\\-)*[' + ALPHANUM_ + '])*';\nvar RFC3966_DOMAINNAME_ = '^(' + RFC3966_DOMAINLABEL_ + '\\\\.)*' + RFC3966_TOPLABEL_ + '\\\\.?$';\n\n/**\r\n * Regular expression of valid domainname for the phone-context parameter,\r\n * following the syntax defined in RFC3966.\r\n */\nvar RFC3966_DOMAINNAME_PATTERN_ = new RegExp(RFC3966_DOMAINNAME_, 'g');\nexport var RFC3966_PREFIX_ = 'tel:';\nexport var RFC3966_PHONE_CONTEXT_ = ';phone-context=';\nexport var RFC3966_ISDN_SUBADDRESS_ = ';isub=';\n\n/**\r\n * Extracts the value of the phone-context parameter of `numberToExtractFrom`,\r\n * following the syntax defined in RFC3966.\r\n *\r\n * @param {string} numberToExtractFrom\r\n * @return {string|null} the extracted string (possibly empty), or `null` if no phone-context parameter is found.\r\n */\nexport default function extractPhoneContext(numberToExtractFrom) {\n var indexOfPhoneContext = numberToExtractFrom.indexOf(RFC3966_PHONE_CONTEXT_);\n // If no phone-context parameter is present\n if (indexOfPhoneContext < 0) {\n return null;\n }\n var phoneContextStart = indexOfPhoneContext + RFC3966_PHONE_CONTEXT_.length;\n // If phone-context parameter is empty\n if (phoneContextStart >= numberToExtractFrom.length) {\n return '';\n }\n var phoneContextEnd = numberToExtractFrom.indexOf(';', phoneContextStart);\n // If phone-context is not the last parameter\n if (phoneContextEnd >= 0) {\n return numberToExtractFrom.substring(phoneContextStart, phoneContextEnd);\n } else {\n return numberToExtractFrom.substring(phoneContextStart);\n }\n}\n\n/**\r\n * Returns whether the value of phoneContext follows the syntax defined in RFC3966.\r\n *\r\n * @param {string|null} phoneContext\r\n * @return {boolean}\r\n */\nexport function isPhoneContextValid(phoneContext) {\n if (phoneContext === null) {\n return true;\n }\n if (phoneContext.length === 0) {\n return false;\n }\n\n // Does phone-context value match pattern of global-number-digits or domainname.\n return RFC3966_GLOBAL_NUMBER_DIGITS_PATTERN_.test(phoneContext) || RFC3966_DOMAINNAME_PATTERN_.test(phoneContext);\n}\n//# sourceMappingURL=extractPhoneContext.js.map","import extractPhoneContext, { isPhoneContextValid, PLUS_SIGN, RFC3966_PREFIX_, RFC3966_PHONE_CONTEXT_, RFC3966_ISDN_SUBADDRESS_ } from './extractPhoneContext.js';\nimport ParseError from '../ParseError.js';\n\n/**\r\n * @param {string} numberToParse\r\n * @param {string} nationalNumber\r\n * @return {}\r\n */\nexport default function extractFormattedPhoneNumberFromPossibleRfc3966NumberUri(numberToParse, _ref) {\n var extractFormattedPhoneNumber = _ref.extractFormattedPhoneNumber;\n var phoneContext = extractPhoneContext(numberToParse);\n if (!isPhoneContextValid(phoneContext)) {\n throw new ParseError('NOT_A_NUMBER');\n }\n var phoneNumberString;\n if (phoneContext === null) {\n // Extract a possible number from the string passed in.\n // (this strips leading characters that could not be the start of a phone number)\n phoneNumberString = extractFormattedPhoneNumber(numberToParse) || '';\n } else {\n phoneNumberString = '';\n\n // If the phone context contains a phone number prefix, we need to capture\n // it, whereas domains will be ignored.\n if (phoneContext.charAt(0) === PLUS_SIGN) {\n phoneNumberString += phoneContext;\n }\n\n // Now append everything between the \"tel:\" prefix and the phone-context.\n // This should include the national number, an optional extension or\n // isdn-subaddress component. Note we also handle the case when \"tel:\" is\n // missing, as we have seen in some of the phone number inputs.\n // In that case, we append everything from the beginning.\n var indexOfRfc3966Prefix = numberToParse.indexOf(RFC3966_PREFIX_);\n var indexOfNationalNumber;\n // RFC 3966 \"tel:\" prefix is preset at this stage because\n // `isPhoneContextValid()` requires it to be present.\n /* istanbul ignore else */\n if (indexOfRfc3966Prefix >= 0) {\n indexOfNationalNumber = indexOfRfc3966Prefix + RFC3966_PREFIX_.length;\n } else {\n indexOfNationalNumber = 0;\n }\n var indexOfPhoneContext = numberToParse.indexOf(RFC3966_PHONE_CONTEXT_);\n phoneNumberString += numberToParse.substring(indexOfNationalNumber, indexOfPhoneContext);\n }\n\n // Delete the isdn-subaddress and everything after it if it is present.\n // Note extension won't appear at the same time with isdn-subaddress\n // according to paragraph 5.3 of the RFC3966 spec.\n var indexOfIsdn = phoneNumberString.indexOf(RFC3966_ISDN_SUBADDRESS_);\n if (indexOfIsdn > 0) {\n phoneNumberString = phoneNumberString.substring(0, indexOfIsdn);\n }\n // If both phone context and isdn-subaddress are absent but other\n // parameters are present, the parameters are left in nationalNumber.\n // This is because we are concerned about deleting content from a potential\n // number string when there is no strong evidence that the number is\n // actually written in RFC3966.\n\n if (phoneNumberString !== '') {\n return phoneNumberString;\n }\n}\n//# sourceMappingURL=extractFormattedPhoneNumberFromPossibleRfc3966NumberUri.js.map","// This is a port of Google Android `libphonenumber`'s\n// `phonenumberutil.js` of December 31th, 2018.\n//\n// https://github.com/googlei18n/libphonenumber/commits/master/javascript/i18n/phonenumbers/phonenumberutil.js\n\nimport { VALID_DIGITS, PLUS_CHARS, MIN_LENGTH_FOR_NSN, MAX_LENGTH_FOR_NSN } from './constants.js';\nimport ParseError from './ParseError.js';\nimport Metadata from './metadata.js';\nimport isViablePhoneNumber, { isViablePhoneNumberStart } from './helpers/isViablePhoneNumber.js';\nimport extractExtension from './helpers/extension/extractExtension.js';\nimport parseIncompletePhoneNumber from './parseIncompletePhoneNumber.js';\nimport getCountryCallingCode from './getCountryCallingCode.js';\nimport { isPossibleNumber } from './isPossible.js';\n// import { parseRFC3966 } from './helpers/RFC3966.js'\nimport PhoneNumber from './PhoneNumber.js';\nimport matchesEntirely from './helpers/matchesEntirely.js';\nimport extractCountryCallingCode from './helpers/extractCountryCallingCode.js';\nimport extractNationalNumber from './helpers/extractNationalNumber.js';\n// import stripIddPrefix from './helpers/stripIddPrefix.js'\nimport getCountryByCallingCode from './helpers/getCountryByCallingCode.js';\nimport extractFormattedPhoneNumberFromPossibleRfc3966NumberUri from './helpers/extractFormattedPhoneNumberFromPossibleRfc3966NumberUri.js';\n\n// We don't allow input strings for parsing to be longer than 250 chars.\n// This prevents malicious input from consuming CPU.\nvar MAX_INPUT_STRING_LENGTH = 250;\n\n// This consists of the plus symbol, digits, and arabic-indic digits.\nvar PHONE_NUMBER_START_PATTERN = new RegExp('[' + PLUS_CHARS + VALID_DIGITS + ']');\n\n// Regular expression of trailing characters that we want to remove.\n// A trailing `#` is sometimes used when writing phone numbers with extensions in US.\n// Example: \"+1 (645) 123 1234-910#\" number has extension \"910\".\nvar AFTER_PHONE_NUMBER_END_PATTERN = new RegExp('[^' + VALID_DIGITS + '#' + ']+$');\nvar USE_NON_GEOGRAPHIC_COUNTRY_CODE = false;\n\n// Examples:\n//\n// ```js\n// parse('8 (800) 555-35-35', 'RU')\n// parse('8 (800) 555-35-35', 'RU', metadata)\n// parse('8 (800) 555-35-35', { country: { default: 'RU' } })\n// parse('8 (800) 555-35-35', { country: { default: 'RU' } }, metadata)\n// parse('+7 800 555 35 35')\n// parse('+7 800 555 35 35', metadata)\n// ```\n//\n\n/**\r\n * Parses a phone number.\r\n *\r\n * parse('123456789', { defaultCountry: 'RU', v2: true }, metadata)\r\n * parse('123456789', { defaultCountry: 'RU' }, metadata)\r\n * parse('123456789', undefined, metadata)\r\n *\r\n * @param {string} input\r\n * @param {object} [options]\r\n * @param {object} metadataJson\r\n * @return {object|PhoneNumber?} If `options.v2: true` flag is passed, it returns a `PhoneNumber?` instance. Otherwise, returns an object of shape `{ phone: '...', country: '...' }` (or just `{}` if no phone number was parsed).\r\n */\nexport default function parse(text, options, metadataJson) {\n // If assigning the `{}` default value is moved to the arguments above,\n // code coverage would decrease for some weird reason.\n options = options || {};\n var metadata = new Metadata(metadataJson);\n\n // Validate `defaultCountry`.\n if (options.defaultCountry && !metadata.hasCountry(options.defaultCountry)) {\n if (options.v2) {\n throw new ParseError('INVALID_COUNTRY');\n }\n throw new Error(\"Unknown country: \".concat(options.defaultCountry));\n }\n\n // Parse the phone number.\n var _parseInput = parseInput(text, options.v2, options.extract),\n formattedPhoneNumber = _parseInput.number,\n ext = _parseInput.ext,\n error = _parseInput.error;\n\n // If the phone number is not viable then return nothing.\n if (!formattedPhoneNumber) {\n if (options.v2) {\n if (error === 'TOO_SHORT') {\n throw new ParseError('TOO_SHORT');\n }\n throw new ParseError('NOT_A_NUMBER');\n }\n return {};\n }\n var _parsePhoneNumber = parsePhoneNumber(formattedPhoneNumber, options.defaultCountry, options.defaultCallingCode,\n // If `country` is returned, its numbering plan will also be selected in `metadata`.\n // Otherwise, if `countryCallingCode` is returned, its numbering plan will also be selected in `metadata`.\n // Otherwise, if neither `country` nor `countryCallingCode` are returned, no numbering plan will be selected in `metadata`.\n metadata),\n country = _parsePhoneNumber.country,\n nationalNumber = _parsePhoneNumber.nationalNumber,\n countryCallingCode = _parsePhoneNumber.countryCallingCode,\n countryCallingCodeSource = _parsePhoneNumber.countryCallingCodeSource,\n carrierCode = _parsePhoneNumber.carrierCode;\n if (!metadata.hasSelectedNumberingPlan()) {\n if (options.v2) {\n throw new ParseError('INVALID_COUNTRY');\n }\n return {};\n }\n\n // Validate national (significant) number length.\n if (!nationalNumber || nationalNumber.length < MIN_LENGTH_FOR_NSN) {\n // Won't throw here because the regexp already demands length > 1.\n /* istanbul ignore if */\n if (options.v2) {\n throw new ParseError('TOO_SHORT');\n }\n // Google's demo just throws an error in this case.\n return {};\n }\n\n // Validate national (significant) number length.\n //\n // A sidenote:\n //\n // They say that sometimes national (significant) numbers\n // can be longer than `MAX_LENGTH_FOR_NSN` (e.g. in Germany).\n // https://github.com/googlei18n/libphonenumber/blob/7e1748645552da39c4e1ba731e47969d97bdb539/resources/phonenumber.proto#L36\n // Such numbers will just be discarded.\n //\n if (nationalNumber.length > MAX_LENGTH_FOR_NSN) {\n if (options.v2) {\n throw new ParseError('TOO_LONG');\n }\n // Google's demo just throws an error in this case.\n return {};\n }\n if (options.v2) {\n var phoneNumber = new PhoneNumber(countryCallingCode, nationalNumber, metadata.metadata);\n if (country) {\n phoneNumber.country = country;\n }\n if (carrierCode) {\n phoneNumber.carrierCode = carrierCode;\n }\n if (ext) {\n phoneNumber.ext = ext;\n }\n phoneNumber.__countryCallingCodeSource = countryCallingCodeSource;\n return phoneNumber;\n }\n\n // Check if national phone number pattern matches the number.\n // National number pattern is different for each country,\n // even for those ones which are part of the \"NANPA\" group.\n var valid = (options.extended ? metadata.hasSelectedNumberingPlan() : country) ? matchesEntirely(nationalNumber, metadata.nationalNumberPattern()) : false;\n if (!options.extended) {\n return valid ? result(country, nationalNumber, ext) : {};\n }\n\n // isInternational: countryCallingCode !== undefined\n\n return {\n country: country,\n countryCallingCode: countryCallingCode,\n carrierCode: carrierCode,\n valid: valid,\n possible: valid ? true : options.extended === true && metadata.possibleLengths() && isPossibleNumber(nationalNumber, metadata) ? true : false,\n phone: nationalNumber,\n ext: ext\n };\n}\n\n/**\r\n * Extracts a formatted phone number from text.\r\n * Doesn't guarantee that the extracted phone number\r\n * is a valid phone number (for example, doesn't validate its length).\r\n * @param {string} text\r\n * @param {boolean} [extract] — If `false`, then will parse the entire `text` as a phone number.\r\n * @param {boolean} [throwOnError] — By default, it won't throw if the text is too long.\r\n * @return {string}\r\n * @example\r\n * // Returns \"(213) 373-4253\".\r\n * extractFormattedPhoneNumber(\"Call (213) 373-4253 for assistance.\")\r\n */\nfunction _extractFormattedPhoneNumber(text, extract, throwOnError) {\n if (!text) {\n return;\n }\n if (text.length > MAX_INPUT_STRING_LENGTH) {\n if (throwOnError) {\n throw new ParseError('TOO_LONG');\n }\n return;\n }\n if (extract === false) {\n return text;\n }\n // Attempt to extract a possible number from the string passed in\n var startsAt = text.search(PHONE_NUMBER_START_PATTERN);\n if (startsAt < 0) {\n return;\n }\n return text\n // Trim everything to the left of the phone number\n .slice(startsAt)\n // Remove trailing non-numerical characters\n .replace(AFTER_PHONE_NUMBER_END_PATTERN, '');\n}\n\n/**\r\n * @param {string} text - Input.\r\n * @param {boolean} v2 - Legacy API functions don't pass `v2: true` flag.\r\n * @param {boolean} [extract] - Whether to extract a phone number from `text`, or attempt to parse the entire text as a phone number.\r\n * @return {object} `{ ?number, ?ext }`.\r\n */\nfunction parseInput(text, v2, extract) {\n // // Parse RFC 3966 phone number URI.\n // if (text && text.indexOf('tel:') === 0) {\n // \treturn parseRFC3966(text)\n // }\n // let number = extractFormattedPhoneNumber(text, extract, v2)\n var number = extractFormattedPhoneNumberFromPossibleRfc3966NumberUri(text, {\n extractFormattedPhoneNumber: function extractFormattedPhoneNumber(text) {\n return _extractFormattedPhoneNumber(text, extract, v2);\n }\n });\n // If the phone number is not viable, then abort.\n if (!number) {\n return {};\n }\n if (!isViablePhoneNumber(number)) {\n if (isViablePhoneNumberStart(number)) {\n return {\n error: 'TOO_SHORT'\n };\n }\n return {};\n }\n // Attempt to parse extension first, since it doesn't require region-specific\n // data and we want to have the non-normalised number here.\n var withExtensionStripped = extractExtension(number);\n if (withExtensionStripped.ext) {\n return withExtensionStripped;\n }\n return {\n number: number\n };\n}\n\n/**\r\n * Creates `parse()` result object.\r\n */\nfunction result(country, nationalNumber, ext) {\n var result = {\n country: country,\n phone: nationalNumber\n };\n if (ext) {\n result.ext = ext;\n }\n return result;\n}\n\n/**\r\n * Parses a viable phone number.\r\n * @param {string} formattedPhoneNumber — Example: \"(213) 373-4253\".\r\n * @param {string} [defaultCountry]\r\n * @param {string} [defaultCallingCode]\r\n * @param {Metadata} metadata — Metadata instance with no pre-selected numbering plan. If `country` is returned, its numbering plan will also be selected in `metadata`. Otherwise, if `countryCallingCode` is returned, its numbering plan will also be selected in `metadata`. Otherwise, if neither `country` nor `countryCallingCode` are returned, no numbering plan will be selected in `metadata`.\r\n * @return {object} Returns `{ country: string?, countryCallingCode: string?, nationalNumber: string? }`.\r\n */\nfunction parsePhoneNumber(formattedPhoneNumber, defaultCountry, defaultCallingCode, metadata) {\n // Attempt to extract a calling code from a phone number.\n // * If the phone number is found to be \"international\":\n // * It will attempt to identify the calling code part of it and whether that part is complete and valid.\n // * If the calling code part is complete and valid, it will return two properties:\n // that calling code part (without `+`) and the rest of the digits.\n // * Otherwise, i.e. if the calling code part is incomplete or invalid,\n // it will return an empty object.\n // * Otherwise, i.e. if the phone number is national, there's no callind code to extract\n // so it will just return the originally-passed `number` string as the only property.\n var _extractCountryCallin = extractCountryCallingCode(parseIncompletePhoneNumber(formattedPhoneNumber), undefined,\n // `defaultCountry` and `defaultCallingCode` are only used to detect\n // if it's an \"international\" phone number or not. They won't be used\n // to derive the resulting `countryCallingCode` from them, or anything like that.\n defaultCountry, defaultCallingCode, metadata.metadata),\n countryCallingCodeSource = _extractCountryCallin.countryCallingCodeSource,\n countryCallingCode = _extractCountryCallin.countryCallingCode,\n number = _extractCountryCallin.number;\n\n // The exact country of the phone number\n var country;\n\n // If `formattedPhoneNumber` is passed in \"international\" format,\n // choose a country by `countryCallingCode`.\n if (countryCallingCode) {\n metadata.selectNumberingPlan(countryCallingCode);\n }\n // Else, if `formattedPhoneNumber` is passed in \"national\" format,\n // then `number` is defined and `countryCallingCode` is `undefined`.\n else if (number && (defaultCountry || defaultCallingCode)) {\n if (defaultCountry) {\n country = defaultCountry;\n metadata.selectNumberingPlan(defaultCountry);\n countryCallingCode = metadata.numberingPlan.callingCode();\n } else {\n metadata.selectNumberingPlan(defaultCallingCode);\n countryCallingCode = defaultCallingCode;\n /* istanbul ignore if */\n if (USE_NON_GEOGRAPHIC_COUNTRY_CODE) {\n if (metadata.isNonGeographicCallingCode(countryCallingCode)) {\n country = '001';\n }\n }\n }\n } else return {};\n\n // At this point, `country` could be `undefined` but `countryCallingCode` is always defined.\n //\n // Also, if `country` is defined, its numbering plan is selected in `metadata`.\n // Otherwise, the numering plan for the `countryCallingCode` is selected in `metadata`.\n\n if (!number) {\n return {\n countryCallingCodeSource: countryCallingCodeSource,\n countryCallingCode: countryCallingCode\n };\n }\n var _extractNationalNumbe = extractNationalNumber(parseIncompletePhoneNumber(number), undefined, metadata),\n nationalNumber = _extractNationalNumbe.nationalNumber,\n carrierCode = _extractNationalNumbe.carrierCode;\n\n // Sometimes there are several countries\n // corresponding to the same country phone code\n // (e.g. NANPA countries all having `1` country phone code).\n // Therefore, to reliably determine the exact country,\n // national (significant) number should have been parsed first.\n //\n // When `metadata.json` is generated, all \"ambiguous\" country phone codes\n // get their countries populated with the full set of\n // \"phone number type\" regular expressions.\n //\n var exactCountry = getCountryByCallingCode(countryCallingCode, {\n nationalNumber: nationalNumber,\n metadata: metadata\n });\n if (exactCountry) {\n country = exactCountry;\n /* istanbul ignore if */\n if (exactCountry === '001') {\n // Can't happen with `USE_NON_GEOGRAPHIC_COUNTRY_CODE` being `false`.\n // If `USE_NON_GEOGRAPHIC_COUNTRY_CODE` is set to `true` for some reason,\n // then remove the \"istanbul ignore if\".\n } else {\n metadata.selectNumberingPlan(country);\n }\n }\n return {\n country: country,\n countryCallingCode: countryCallingCode,\n countryCallingCodeSource: countryCallingCodeSource,\n nationalNumber: nationalNumber,\n carrierCode: carrierCode\n };\n}\n//# sourceMappingURL=parse.js.map","function _typeof(o) { \"@babel/helpers - typeof\"; return _typeof = \"function\" == typeof Symbol && \"symbol\" == typeof Symbol.iterator ? function (o) { return typeof o; } : function (o) { return o && \"function\" == typeof Symbol && o.constructor === Symbol && o !== Symbol.prototype ? \"symbol\" : typeof o; }, _typeof(o); }\nfunction ownKeys(e, r) { var t = Object.keys(e); if (Object.getOwnPropertySymbols) { var o = Object.getOwnPropertySymbols(e); r && (o = o.filter(function (r) { return Object.getOwnPropertyDescriptor(e, r).enumerable; })), t.push.apply(t, o); } return t; }\nfunction _objectSpread(e) { for (var r = 1; r < arguments.length; r++) { var t = null != arguments[r] ? arguments[r] : {}; r % 2 ? ownKeys(Object(t), !0).forEach(function (r) { _defineProperty(e, r, t[r]); }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(e, Object.getOwnPropertyDescriptors(t)) : ownKeys(Object(t)).forEach(function (r) { Object.defineProperty(e, r, Object.getOwnPropertyDescriptor(t, r)); }); } return e; }\nfunction _defineProperty(e, r, t) { return (r = _toPropertyKey(r)) in e ? Object.defineProperty(e, r, { value: t, enumerable: !0, configurable: !0, writable: !0 }) : e[r] = t, e; }\nfunction _toPropertyKey(t) { var i = _toPrimitive(t, \"string\"); return \"symbol\" == _typeof(i) ? i : i + \"\"; }\nfunction _toPrimitive(t, r) { if (\"object\" != _typeof(t) || !t) return t; var e = t[Symbol.toPrimitive]; if (void 0 !== e) { var i = e.call(t, r || \"default\"); if (\"object\" != _typeof(i)) return i; throw new TypeError(\"@@toPrimitive must return a primitive value.\"); } return (\"string\" === r ? String : Number)(t); }\nimport parse from './parse.js';\nexport default function parsePhoneNumberWithError(text, options, metadata) {\n return parse(text, _objectSpread(_objectSpread({}, options), {}, {\n v2: true\n }), metadata);\n}\n//# sourceMappingURL=parsePhoneNumberWithError_.js.map","function _typeof(o) { \"@babel/helpers - typeof\"; return _typeof = \"function\" == typeof Symbol && \"symbol\" == typeof Symbol.iterator ? function (o) { return typeof o; } : function (o) { return o && \"function\" == typeof Symbol && o.constructor === Symbol && o !== Symbol.prototype ? \"symbol\" : typeof o; }, _typeof(o); }\nfunction ownKeys(e, r) { var t = Object.keys(e); if (Object.getOwnPropertySymbols) { var o = Object.getOwnPropertySymbols(e); r && (o = o.filter(function (r) { return Object.getOwnPropertyDescriptor(e, r).enumerable; })), t.push.apply(t, o); } return t; }\nfunction _objectSpread(e) { for (var r = 1; r < arguments.length; r++) { var t = null != arguments[r] ? arguments[r] : {}; r % 2 ? ownKeys(Object(t), !0).forEach(function (r) { _defineProperty(e, r, t[r]); }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(e, Object.getOwnPropertyDescriptors(t)) : ownKeys(Object(t)).forEach(function (r) { Object.defineProperty(e, r, Object.getOwnPropertyDescriptor(t, r)); }); } return e; }\nfunction _defineProperty(e, r, t) { return (r = _toPropertyKey(r)) in e ? Object.defineProperty(e, r, { value: t, enumerable: !0, configurable: !0, writable: !0 }) : e[r] = t, e; }\nfunction _toPropertyKey(t) { var i = _toPrimitive(t, \"string\"); return \"symbol\" == _typeof(i) ? i : i + \"\"; }\nfunction _toPrimitive(t, r) { if (\"object\" != _typeof(t) || !t) return t; var e = t[Symbol.toPrimitive]; if (void 0 !== e) { var i = e.call(t, r || \"default\"); if (\"object\" != _typeof(i)) return i; throw new TypeError(\"@@toPrimitive must return a primitive value.\"); } return (\"string\" === r ? String : Number)(t); }\nfunction _slicedToArray(r, e) { return _arrayWithHoles(r) || _iterableToArrayLimit(r, e) || _unsupportedIterableToArray(r, e) || _nonIterableRest(); }\nfunction _nonIterableRest() { throw new TypeError(\"Invalid attempt to destructure non-iterable instance.\\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.\"); }\nfunction _unsupportedIterableToArray(r, a) { if (r) { if (\"string\" == typeof r) return _arrayLikeToArray(r, a); var t = {}.toString.call(r).slice(8, -1); return \"Object\" === t && r.constructor && (t = r.constructor.name), \"Map\" === t || \"Set\" === t ? Array.from(r) : \"Arguments\" === t || /^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(t) ? _arrayLikeToArray(r, a) : void 0; } }\nfunction _arrayLikeToArray(r, a) { (null == a || a > r.length) && (a = r.length); for (var e = 0, n = Array(a); e < a; e++) n[e] = r[e]; return n; }\nfunction _iterableToArrayLimit(r, l) { var t = null == r ? null : \"undefined\" != typeof Symbol && r[Symbol.iterator] || r[\"@@iterator\"]; if (null != t) { var e, n, i, u, a = [], f = !0, o = !1; try { if (i = (t = t.call(r)).next, 0 === l) { if (Object(t) !== t) return; f = !1; } else for (; !(f = (e = i.call(t)).done) && (a.push(e.value), a.length !== l); f = !0); } catch (r) { o = !0, n = r; } finally { try { if (!f && null != t[\"return\"] && (u = t[\"return\"](), Object(u) !== u)) return; } finally { if (o) throw n; } } return a; } }\nfunction _arrayWithHoles(r) { if (Array.isArray(r)) return r; }\nimport isObject from './helpers/isObject.js';\n\n// Extracts the following properties from function arguments:\n// * input `text`\n// * `options` object\n// * `metadata` JSON\nexport default function normalizeArguments(args) {\n var _Array$prototype$slic = Array.prototype.slice.call(args),\n _Array$prototype$slic2 = _slicedToArray(_Array$prototype$slic, 4),\n arg_1 = _Array$prototype$slic2[0],\n arg_2 = _Array$prototype$slic2[1],\n arg_3 = _Array$prototype$slic2[2],\n arg_4 = _Array$prototype$slic2[3];\n var text;\n var options;\n var metadata;\n\n // If the phone number is passed as a string.\n // `parsePhoneNumber('88005553535', ...)`.\n if (typeof arg_1 === 'string') {\n text = arg_1;\n } else throw new TypeError('A text for parsing must be a string.');\n\n // If \"default country\" argument is being passed then move it to `options`.\n // `parsePhoneNumber('88005553535', 'RU', [options], metadata)`.\n if (!arg_2 || typeof arg_2 === 'string') {\n if (arg_4) {\n options = arg_3;\n metadata = arg_4;\n } else {\n options = undefined;\n metadata = arg_3;\n }\n if (arg_2) {\n options = _objectSpread({\n defaultCountry: arg_2\n }, options);\n }\n }\n // `defaultCountry` is not passed.\n // Example: `parsePhoneNumber('+78005553535', [options], metadata)`.\n else if (isObject(arg_2)) {\n if (arg_3) {\n options = arg_2;\n metadata = arg_3;\n } else {\n metadata = arg_2;\n }\n } else throw new Error(\"Invalid second argument: \".concat(arg_2));\n return {\n text: text,\n options: options,\n metadata: metadata\n };\n}\n//# sourceMappingURL=normalizeArguments.js.map","import parsePhoneNumberWithError_ from './parsePhoneNumberWithError_.js';\nimport normalizeArguments from './normalizeArguments.js';\nexport default function parsePhoneNumberWithError() {\n var _normalizeArguments = normalizeArguments(arguments),\n text = _normalizeArguments.text,\n options = _normalizeArguments.options,\n metadata = _normalizeArguments.metadata;\n return parsePhoneNumberWithError_(text, options, metadata);\n}\n//# sourceMappingURL=parsePhoneNumberWithError.js.map","function _typeof(o) { \"@babel/helpers - typeof\"; return _typeof = \"function\" == typeof Symbol && \"symbol\" == typeof Symbol.iterator ? function (o) { return typeof o; } : function (o) { return o && \"function\" == typeof Symbol && o.constructor === Symbol && o !== Symbol.prototype ? \"symbol\" : typeof o; }, _typeof(o); }\nfunction ownKeys(e, r) { var t = Object.keys(e); if (Object.getOwnPropertySymbols) { var o = Object.getOwnPropertySymbols(e); r && (o = o.filter(function (r) { return Object.getOwnPropertyDescriptor(e, r).enumerable; })), t.push.apply(t, o); } return t; }\nfunction _objectSpread(e) { for (var r = 1; r < arguments.length; r++) { var t = null != arguments[r] ? arguments[r] : {}; r % 2 ? ownKeys(Object(t), !0).forEach(function (r) { _defineProperty(e, r, t[r]); }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(e, Object.getOwnPropertyDescriptors(t)) : ownKeys(Object(t)).forEach(function (r) { Object.defineProperty(e, r, Object.getOwnPropertyDescriptor(t, r)); }); } return e; }\nfunction _defineProperty(e, r, t) { return (r = _toPropertyKey(r)) in e ? Object.defineProperty(e, r, { value: t, enumerable: !0, configurable: !0, writable: !0 }) : e[r] = t, e; }\nfunction _toPropertyKey(t) { var i = _toPrimitive(t, \"string\"); return \"symbol\" == _typeof(i) ? i : i + \"\"; }\nfunction _toPrimitive(t, r) { if (\"object\" != _typeof(t) || !t) return t; var e = t[Symbol.toPrimitive]; if (void 0 !== e) { var i = e.call(t, r || \"default\"); if (\"object\" != _typeof(i)) return i; throw new TypeError(\"@@toPrimitive must return a primitive value.\"); } return (\"string\" === r ? String : Number)(t); }\nimport parsePhoneNumberWithError from './parsePhoneNumberWithError_.js';\nimport ParseError from './ParseError.js';\nimport { isSupportedCountry } from './metadata.js';\nexport default function parsePhoneNumber(text, options, metadata) {\n // Validate `defaultCountry`.\n if (options && options.defaultCountry && !isSupportedCountry(options.defaultCountry, metadata)) {\n options = _objectSpread(_objectSpread({}, options), {}, {\n defaultCountry: undefined\n });\n }\n // Parse phone number.\n try {\n return parsePhoneNumberWithError(text, options, metadata);\n } catch (error) {\n /* istanbul ignore else */\n if (error instanceof ParseError) {\n //\n } else {\n throw error;\n }\n }\n}\n//# sourceMappingURL=parsePhoneNumber_.js.map","function _typeof(o) { \"@babel/helpers - typeof\"; return _typeof = \"function\" == typeof Symbol && \"symbol\" == typeof Symbol.iterator ? function (o) { return typeof o; } : function (o) { return o && \"function\" == typeof Symbol && o.constructor === Symbol && o !== Symbol.prototype ? \"symbol\" : typeof o; }, _typeof(o); }\nfunction ownKeys(e, r) { var t = Object.keys(e); if (Object.getOwnPropertySymbols) { var o = Object.getOwnPropertySymbols(e); r && (o = o.filter(function (r) { return Object.getOwnPropertyDescriptor(e, r).enumerable; })), t.push.apply(t, o); } return t; }\nfunction _objectSpread(e) { for (var r = 1; r < arguments.length; r++) { var t = null != arguments[r] ? arguments[r] : {}; r % 2 ? ownKeys(Object(t), !0).forEach(function (r) { _defineProperty(e, r, t[r]); }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(e, Object.getOwnPropertyDescriptors(t)) : ownKeys(Object(t)).forEach(function (r) { Object.defineProperty(e, r, Object.getOwnPropertyDescriptor(t, r)); }); } return e; }\nfunction _defineProperty(e, r, t) { return (r = _toPropertyKey(r)) in e ? Object.defineProperty(e, r, { value: t, enumerable: !0, configurable: !0, writable: !0 }) : e[r] = t, e; }\nfunction _toPropertyKey(t) { var i = _toPrimitive(t, \"string\"); return \"symbol\" == _typeof(i) ? i : i + \"\"; }\nfunction _toPrimitive(t, r) { if (\"object\" != _typeof(t) || !t) return t; var e = t[Symbol.toPrimitive]; if (void 0 !== e) { var i = e.call(t, r || \"default\"); if (\"object\" != _typeof(i)) return i; throw new TypeError(\"@@toPrimitive must return a primitive value.\"); } return (\"string\" === r ? String : Number)(t); }\nimport normalizeArguments from './normalizeArguments.js';\nimport parsePhoneNumber from './parsePhoneNumber_.js';\nexport default function isValidPhoneNumber() {\n var _normalizeArguments = normalizeArguments(arguments),\n text = _normalizeArguments.text,\n options = _normalizeArguments.options,\n metadata = _normalizeArguments.metadata;\n options = _objectSpread(_objectSpread({}, options), {}, {\n extract: false\n });\n var phoneNumber = parsePhoneNumber(text, options, metadata);\n return phoneNumber && phoneNumber.isValid() || false;\n}\n//# sourceMappingURL=isValidPhoneNumber.js.map","function _typeof(o) { \"@babel/helpers - typeof\"; return _typeof = \"function\" == typeof Symbol && \"symbol\" == typeof Symbol.iterator ? function (o) { return typeof o; } : function (o) { return o && \"function\" == typeof Symbol && o.constructor === Symbol && o !== Symbol.prototype ? \"symbol\" : typeof o; }, _typeof(o); }\nfunction _classCallCheck(a, n) { if (!(a instanceof n)) throw new TypeError(\"Cannot call a class as a function\"); }\nfunction _defineProperties(e, r) { for (var t = 0; t < r.length; t++) { var o = r[t]; o.enumerable = o.enumerable || !1, o.configurable = !0, \"value\" in o && (o.writable = !0), Object.defineProperty(e, _toPropertyKey(o.key), o); } }\nfunction _createClass(e, r, t) { return r && _defineProperties(e.prototype, r), t && _defineProperties(e, t), Object.defineProperty(e, \"prototype\", { writable: !1 }), e; }\nfunction _toPropertyKey(t) { var i = _toPrimitive(t, \"string\"); return \"symbol\" == _typeof(i) ? i : i + \"\"; }\nfunction _toPrimitive(t, r) { if (\"object\" != _typeof(t) || !t) return t; var e = t[Symbol.toPrimitive]; if (void 0 !== e) { var i = e.call(t, r || \"default\"); if (\"object\" != _typeof(i)) return i; throw new TypeError(\"@@toPrimitive must return a primitive value.\"); } return (\"string\" === r ? String : Number)(t); }\n// This \"state\" object simply holds the state of the \"AsYouType\" parser:\n//\n// Sidenote:\n// `state.callingCode` and `state.country` are somewhat independent from one another\n// and there could be situations when one is defined but the other is not.\n// * Situations when `state.country` would be defined but `state.callingCode` would be `undefined`:\n// \t\t * When `defaultCountry` is specified and inputting a phone number not in \"international\" format.\n// * When `defaultCountry` is specified and inputting a phone number in \"international\" format,\n// but before the `+` character has been input.\n// * Situations when `state.country` would be `undefined` but `state.callingCode` would be defined:\n// * When `defaultCountry` is not specified and inputting a phone number in \"international\" format,\n// and the \"calling code\" part is already complete, but multiple countries share this \"calling code\"\n// and there's not enough national (significant) number digits yet to determine the exact country.\n// * In any other sigutations, `state.country` and `state.callingCode` are either both defined or both `undefined`.\n// * When they're both defined, `state.callingCode` always corresponds to `state.country`.\n// So both are always consistent in this case.\n//\n// * `country?: string` — The exact country of the phone number, if it could be determined.\n// When inputting a phone number in \"international\" format, it will derive the `country` from \"country calling code\" and the phone number digits.\n// When inputting a phone number in \"national\" format, it will derive the `country` from `defaultCountry` that was specified when creating the `AsYouType` formatter.\n// Sidenote: If `USE_NON_GEOGRAPHIC_COUNTRY_CODE` flag was `true`, then for \"non-geographic phone numbers\" `state.country` would've been \"001\".\n// * `callingCode?: string` — \"Country calling code\" that has been extracted from the input phone number.\n// When inputting a phone number in \"international\" format, it will extract the \"country calling code\" from the digits that follow the \"+\" character.\n// When inputting a phone number in \"national\" format, `callingCode` will be `undefined`.\n// * `digits: string` — Phone number digits that have been input so far, including the \"+\" character, if present. In case of inputting non-arabic digits, those will be converted to arabic ones.\n// * `international: boolean` — Whether the phone number is being input in \"international\" format, i.e. with a \"+\" character.\n// * `missingPlus: boolean` — Whether it's a phone number in \"international\" format that is missing the leading \"+\" character for some reason — apparently, Google thinks that it's a common mistake when inputting a phone number.\n// * `IDDPrefix?: string` — An \"IDD prefix\", when the phone number is being input in an \"out-of-country dialing\" format. https://wikitravel.org/en/International_dialling_prefix\n// * `carrierCode?: string` — A \"carrier code\", if the phone number contains it. Normally, those can only be present in Colombia or Brazil, and only when calling from mobile phones to fixed-line numbers.\n// * `nationalPrefix?: string` — \"National prefix\", if present in the phone number input.\n// * `nationalSignificantNumber?: string` — National (significant) number digits that have been input so far.\n// * `nationalSignificantNumberIsModified: boolean` — Tells if the parsed national (significant) number is present as-is in the input string. For example, when inputting \"0343515551212999\" Argentinian mobile number, the parsed national (significant) number is \"93435551212999\". There, one can see how it stripped \"0\" national prefix and prepended a \"9\", because that's how it is instructed to do in Argentina's metadata. So in the described example, the parsed national (significant) number is not present as-is in the input string. Instead, it's \"modified\" in the input string. https://gitlab.com/caamphetamine/libphonenumber-js/-/blob/master/METADATA.md#national_prefix_for_parsing--national_prefix_transform_rule\n// * `prefixBeforeNationalSignificantNumberThatIsNotNationalPrefix?: string` — In some countries, a phone number could have a prefix that is not a \"national prefix\" but rather some other type of \"utility\" prefix.\n// For example, when calling within Australia, one could prepend `1831` prefix to hide caller's phone number.\n// https://gitlab.com/catamphetamine/libphonenumber-js/-/blob/master/METADATA.md#national_prefix_for_parsing--national_prefix_transform_rule\n//\nvar AsYouTypeState = /*#__PURE__*/function () {\n function AsYouTypeState(_ref) {\n var onCountryChange = _ref.onCountryChange,\n onCallingCodeChange = _ref.onCallingCodeChange;\n _classCallCheck(this, AsYouTypeState);\n this.onCountryChange = onCountryChange;\n this.onCallingCodeChange = onCallingCodeChange;\n }\n return _createClass(AsYouTypeState, [{\n key: \"reset\",\n value: function reset(_ref2) {\n var country = _ref2.country,\n callingCode = _ref2.callingCode;\n this.international = false;\n this.missingPlus = false;\n this.IDDPrefix = undefined;\n this.callingCode = undefined;\n this.digits = '';\n this.resetNationalSignificantNumber();\n this.initCountryAndCallingCode(country, callingCode);\n }\n }, {\n key: \"resetNationalSignificantNumber\",\n value: function resetNationalSignificantNumber() {\n this.nationalSignificantNumber = this.getNationalDigits();\n this.nationalSignificantNumberIsModified = false;\n this.nationalPrefix = undefined;\n this.carrierCode = undefined;\n this.prefixBeforeNationalSignificantNumberThatIsNotNationalPrefix = undefined;\n }\n }, {\n key: \"update\",\n value: function update(properties) {\n for (var _i = 0, _Object$keys = Object.keys(properties); _i < _Object$keys.length; _i++) {\n var key = _Object$keys[_i];\n this[key] = properties[key];\n }\n }\n }, {\n key: \"initCountryAndCallingCode\",\n value: function initCountryAndCallingCode(country, callingCode) {\n this.setCountry(country);\n this.setCallingCode(callingCode);\n }\n }, {\n key: \"setCountry\",\n value: function setCountry(country) {\n this.country = country;\n this.onCountryChange(country);\n }\n }, {\n key: \"setCallingCode\",\n value: function setCallingCode(callingCode) {\n this.callingCode = callingCode;\n this.onCallingCodeChange(callingCode, this.country);\n }\n }, {\n key: \"startInternationalNumber\",\n value: function startInternationalNumber(country, callingCode) {\n // Prepend the `+` to parsed input.\n this.international = true;\n // If a default country was set then reset it\n // because an explicitly international phone\n // number is being entered.\n this.initCountryAndCallingCode(country, callingCode);\n }\n }, {\n key: \"appendDigits\",\n value: function appendDigits(nextDigits) {\n this.digits += nextDigits;\n }\n }, {\n key: \"appendNationalSignificantNumberDigits\",\n value: function appendNationalSignificantNumberDigits(nextDigits) {\n this.nationalSignificantNumber += nextDigits;\n }\n\n /**\r\n * Returns the part of `this.digits` that corresponds to the national number.\r\n * Basically, all digits that have been input by the user, except for the\r\n * international prefix and the country calling code part\r\n * (if the number is an international one).\r\n * @return {string}\r\n */\n }, {\n key: \"getNationalDigits\",\n value: function getNationalDigits() {\n if (this.international) {\n return this.digits.slice((this.IDDPrefix ? this.IDDPrefix.length : 0) + (this.callingCode ? this.callingCode.length : 0));\n }\n return this.digits;\n }\n }, {\n key: \"getDigitsWithoutInternationalPrefix\",\n value: function getDigitsWithoutInternationalPrefix() {\n if (this.international) {\n if (this.IDDPrefix) {\n return this.digits.slice(this.IDDPrefix.length);\n }\n }\n return this.digits;\n }\n }]);\n}();\nexport { AsYouTypeState as default };\n//# sourceMappingURL=AsYouTypeState.js.map","function _createForOfIteratorHelperLoose(r, e) { var t = \"undefined\" != typeof Symbol && r[Symbol.iterator] || r[\"@@iterator\"]; if (t) return (t = t.call(r)).next.bind(t); if (Array.isArray(r) || (t = _unsupportedIterableToArray(r)) || e && r && \"number\" == typeof r.length) { t && (r = t); var o = 0; return function () { return o >= r.length ? { done: !0 } : { done: !1, value: r[o++] }; }; } throw new TypeError(\"Invalid attempt to iterate non-iterable instance.\\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.\"); }\nfunction _unsupportedIterableToArray(r, a) { if (r) { if (\"string\" == typeof r) return _arrayLikeToArray(r, a); var t = {}.toString.call(r).slice(8, -1); return \"Object\" === t && r.constructor && (t = r.constructor.name), \"Map\" === t || \"Set\" === t ? Array.from(r) : \"Arguments\" === t || /^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(t) ? _arrayLikeToArray(r, a) : void 0; } }\nfunction _arrayLikeToArray(r, a) { (null == a || a > r.length) && (a = r.length); for (var e = 0, n = Array(a); e < a; e++) n[e] = r[e]; return n; }\n// Should be the same as `DIGIT_PLACEHOLDER` in `libphonenumber-metadata-generator`.\nexport var DIGIT_PLACEHOLDER = 'x'; // '\\u2008' (punctuation space)\nvar DIGIT_PLACEHOLDER_MATCHER = new RegExp(DIGIT_PLACEHOLDER);\n\n// Counts all occurences of a symbol in a string.\n// Unicode-unsafe (because using `.split()`).\nexport function countOccurences(symbol, string) {\n var count = 0;\n // Using `.split('')` to iterate through a string here\n // to avoid requiring `Symbol.iterator` polyfill.\n // `.split('')` is generally not safe for Unicode,\n // but in this particular case for counting brackets it is safe.\n // for (const character of string)\n for (var _iterator = _createForOfIteratorHelperLoose(string.split('')), _step; !(_step = _iterator()).done;) {\n var character = _step.value;\n if (character === symbol) {\n count++;\n }\n }\n return count;\n}\n\n// Repeats a string (or a symbol) N times.\n// http://stackoverflow.com/questions/202605/repeat-string-javascript\nexport function repeat(string, times) {\n if (times < 1) {\n return '';\n }\n var result = '';\n while (times > 1) {\n if (times & 1) {\n result += string;\n }\n times >>= 1;\n string += string;\n }\n return result + string;\n}\nexport function cutAndStripNonPairedParens(string, cutBeforeIndex) {\n if (string[cutBeforeIndex] === ')') {\n cutBeforeIndex++;\n }\n return stripNonPairedParens(string.slice(0, cutBeforeIndex));\n}\nexport function closeNonPairedParens(template, cut_before) {\n var retained_template = template.slice(0, cut_before);\n var opening_braces = countOccurences('(', retained_template);\n var closing_braces = countOccurences(')', retained_template);\n var dangling_braces = opening_braces - closing_braces;\n while (dangling_braces > 0 && cut_before < template.length) {\n if (template[cut_before] === ')') {\n dangling_braces--;\n }\n cut_before++;\n }\n return template.slice(0, cut_before);\n}\nexport function stripNonPairedParens(string) {\n var dangling_braces = [];\n var i = 0;\n while (i < string.length) {\n if (string[i] === '(') {\n dangling_braces.push(i);\n } else if (string[i] === ')') {\n dangling_braces.pop();\n }\n i++;\n }\n var start = 0;\n var cleared_string = '';\n dangling_braces.push(string.length);\n for (var _i = 0, _dangling_braces = dangling_braces; _i < _dangling_braces.length; _i++) {\n var index = _dangling_braces[_i];\n cleared_string += string.slice(start, index);\n start = index + 1;\n }\n return cleared_string;\n}\nexport function populateTemplateWithDigits(template, position, digits) {\n // Using `.split('')` to iterate through a string here\n // to avoid requiring `Symbol.iterator` polyfill.\n // `.split('')` is generally not safe for Unicode,\n // but in this particular case for `digits` it is safe.\n // for (const digit of digits)\n for (var _iterator2 = _createForOfIteratorHelperLoose(digits.split('')), _step2; !(_step2 = _iterator2()).done;) {\n var digit = _step2.value;\n // If there is room for more digits in current `template`,\n // then set the next digit in the `template`,\n // and return the formatted digits so far.\n // If more digits are entered than the current format could handle.\n if (template.slice(position + 1).search(DIGIT_PLACEHOLDER_MATCHER) < 0) {\n return;\n }\n position = template.search(DIGIT_PLACEHOLDER_MATCHER);\n template = template.replace(DIGIT_PLACEHOLDER_MATCHER, digit);\n }\n return [template, position];\n}\n//# sourceMappingURL=AsYouTypeFormatter.util.js.map","import checkNumberLength from './helpers/checkNumberLength.js';\nimport parseDigits from './helpers/parseDigits.js';\nimport formatNationalNumberUsingFormat from './helpers/formatNationalNumberUsingFormat.js';\nexport default function formatCompleteNumber(state, format, _ref) {\n var metadata = _ref.metadata,\n shouldTryNationalPrefixFormattingRule = _ref.shouldTryNationalPrefixFormattingRule,\n getSeparatorAfterNationalPrefix = _ref.getSeparatorAfterNationalPrefix;\n var matcher = new RegExp(\"^(?:\".concat(format.pattern(), \")$\"));\n if (matcher.test(state.nationalSignificantNumber)) {\n return formatNationalNumberWithAndWithoutNationalPrefixFormattingRule(state, format, {\n metadata: metadata,\n shouldTryNationalPrefixFormattingRule: shouldTryNationalPrefixFormattingRule,\n getSeparatorAfterNationalPrefix: getSeparatorAfterNationalPrefix\n });\n }\n}\nexport function canFormatCompleteNumber(nationalSignificantNumber, metadata) {\n return checkNumberLength(nationalSignificantNumber, undefined, metadata) === 'IS_POSSIBLE';\n}\nfunction formatNationalNumberWithAndWithoutNationalPrefixFormattingRule(state, format, _ref2) {\n var metadata = _ref2.metadata,\n shouldTryNationalPrefixFormattingRule = _ref2.shouldTryNationalPrefixFormattingRule,\n getSeparatorAfterNationalPrefix = _ref2.getSeparatorAfterNationalPrefix;\n // `format` has already been checked for `nationalPrefix` requirement.\n\n var nationalSignificantNumber = state.nationalSignificantNumber,\n international = state.international,\n nationalPrefix = state.nationalPrefix,\n carrierCode = state.carrierCode;\n\n // Format the number with using `national_prefix_formatting_rule`.\n // If the resulting formatted number is a valid formatted number, then return it.\n //\n // Google's AsYouType formatter is different in a way that it doesn't try\n // to format using the \"national prefix formatting rule\", and instead it\n // simply prepends a national prefix followed by a \" \" character.\n // This code does that too, but as a fallback.\n // The reason is that \"national prefix formatting rule\" may use parentheses,\n // which wouldn't be included has it used the simpler Google's way.\n //\n if (shouldTryNationalPrefixFormattingRule(format)) {\n var formattedNumber = formatNationalNumber(state, format, {\n useNationalPrefixFormattingRule: true,\n getSeparatorAfterNationalPrefix: getSeparatorAfterNationalPrefix,\n metadata: metadata\n });\n if (formattedNumber) {\n return formattedNumber;\n }\n }\n\n // Format the number without using `national_prefix_formatting_rule`.\n return formatNationalNumber(state, format, {\n useNationalPrefixFormattingRule: false,\n getSeparatorAfterNationalPrefix: getSeparatorAfterNationalPrefix,\n metadata: metadata\n });\n}\nfunction formatNationalNumber(state, format, _ref3) {\n var metadata = _ref3.metadata,\n useNationalPrefixFormattingRule = _ref3.useNationalPrefixFormattingRule,\n getSeparatorAfterNationalPrefix = _ref3.getSeparatorAfterNationalPrefix;\n var formattedNationalNumber = formatNationalNumberUsingFormat(state.nationalSignificantNumber, format, {\n carrierCode: state.carrierCode,\n useInternationalFormat: state.international,\n withNationalPrefix: useNationalPrefixFormattingRule,\n metadata: metadata\n });\n if (!useNationalPrefixFormattingRule) {\n if (state.nationalPrefix) {\n // If a national prefix was extracted, then just prepend it,\n // followed by a \" \" character.\n formattedNationalNumber = state.nationalPrefix + getSeparatorAfterNationalPrefix(format) + formattedNationalNumber;\n } else if (state.prefixBeforeNationalSignificantNumberThatIsNotNationalPrefix) {\n formattedNationalNumber = state.prefixBeforeNationalSignificantNumberThatIsNotNationalPrefix + ' ' + formattedNationalNumber;\n }\n }\n if (isValidFormattedNationalNumber(formattedNationalNumber, state)) {\n return formattedNationalNumber;\n }\n}\n\n// Check that the formatted phone number contains exactly\n// the same digits that have been input by the user.\n// For example, when \"0111523456789\" is input for `AR` country,\n// the extracted `this.nationalSignificantNumber` is \"91123456789\",\n// which means that the national part of `this.digits` isn't simply equal to\n// `this.nationalPrefix` + `this.nationalSignificantNumber`.\n//\n// Also, a `format` can add extra digits to the `this.nationalSignificantNumber`\n// being formatted via `metadata[country].national_prefix_transform_rule`.\n// For example, for `VI` country, it prepends `340` to the national number,\n// and if this check hasn't been implemented, then there would be a bug\n// when `340` \"area coude\" is \"duplicated\" during input for `VI` country:\n// https://github.com/catamphetamine/libphonenumber-js/issues/318\n//\n// So, all these \"gotchas\" are filtered out.\n//\n// In the original Google's code, the comments say:\n// \"Check that we didn't remove nor add any extra digits when we matched\n// this formatting pattern. This usually happens after we entered the last\n// digit during AYTF. Eg: In case of MX, we swallow mobile token (1) when\n// formatted but AYTF should retain all the number entered and not change\n// in order to match a format (of same leading digits and length) display\n// in that way.\"\n// \"If it's the same (i.e entered number and format is same), then it's\n// safe to return this in formatted number as nothing is lost / added.\"\n// Otherwise, don't use this format.\n// https://github.com/google/libphonenumber/commit/3e7c1f04f5e7200f87fb131e6f85c6e99d60f510#diff-9149457fa9f5d608a11bb975c6ef4bc5\n// https://github.com/google/libphonenumber/commit/3ac88c7106e7dcb553bcc794b15f19185928a1c6#diff-2dcb77e833422ee304da348b905cde0b\n//\nfunction isValidFormattedNationalNumber(formattedNationalNumber, state) {\n return parseDigits(formattedNationalNumber) === state.getNationalDigits();\n}\n//# sourceMappingURL=AsYouTypeFormatter.complete.js.map","function _typeof(o) { \"@babel/helpers - typeof\"; return _typeof = \"function\" == typeof Symbol && \"symbol\" == typeof Symbol.iterator ? function (o) { return typeof o; } : function (o) { return o && \"function\" == typeof Symbol && o.constructor === Symbol && o !== Symbol.prototype ? \"symbol\" : typeof o; }, _typeof(o); }\nfunction _classCallCheck(a, n) { if (!(a instanceof n)) throw new TypeError(\"Cannot call a class as a function\"); }\nfunction _defineProperties(e, r) { for (var t = 0; t < r.length; t++) { var o = r[t]; o.enumerable = o.enumerable || !1, o.configurable = !0, \"value\" in o && (o.writable = !0), Object.defineProperty(e, _toPropertyKey(o.key), o); } }\nfunction _createClass(e, r, t) { return r && _defineProperties(e.prototype, r), t && _defineProperties(e, t), Object.defineProperty(e, \"prototype\", { writable: !1 }), e; }\nfunction _toPropertyKey(t) { var i = _toPrimitive(t, \"string\"); return \"symbol\" == _typeof(i) ? i : i + \"\"; }\nfunction _toPrimitive(t, r) { if (\"object\" != _typeof(t) || !t) return t; var e = t[Symbol.toPrimitive]; if (void 0 !== e) { var i = e.call(t, r || \"default\"); if (\"object\" != _typeof(i)) return i; throw new TypeError(\"@@toPrimitive must return a primitive value.\"); } return (\"string\" === r ? String : Number)(t); }\nvar PatternParser = /*#__PURE__*/function () {\n function PatternParser() {\n _classCallCheck(this, PatternParser);\n }\n return _createClass(PatternParser, [{\n key: \"parse\",\n value: function parse(pattern) {\n this.context = [{\n or: true,\n instructions: []\n }];\n this.parsePattern(pattern);\n if (this.context.length !== 1) {\n throw new Error('Non-finalized contexts left when pattern parse ended');\n }\n var _this$context$ = this.context[0],\n branches = _this$context$.branches,\n instructions = _this$context$.instructions;\n if (branches) {\n return {\n op: '|',\n args: branches.concat([expandSingleElementArray(instructions)])\n };\n }\n\n /* istanbul ignore if */\n if (instructions.length === 0) {\n throw new Error('Pattern is required');\n }\n if (instructions.length === 1) {\n return instructions[0];\n }\n return instructions;\n }\n }, {\n key: \"startContext\",\n value: function startContext(context) {\n this.context.push(context);\n }\n }, {\n key: \"endContext\",\n value: function endContext() {\n this.context.pop();\n }\n }, {\n key: \"getContext\",\n value: function getContext() {\n return this.context[this.context.length - 1];\n }\n }, {\n key: \"parsePattern\",\n value: function parsePattern(pattern) {\n if (!pattern) {\n throw new Error('Pattern is required');\n }\n var match = pattern.match(OPERATOR);\n if (!match) {\n if (ILLEGAL_CHARACTER_REGEXP.test(pattern)) {\n throw new Error(\"Illegal characters found in a pattern: \".concat(pattern));\n }\n this.getContext().instructions = this.getContext().instructions.concat(pattern.split(''));\n return;\n }\n var operator = match[1];\n var before = pattern.slice(0, match.index);\n var rightPart = pattern.slice(match.index + operator.length);\n switch (operator) {\n case '(?:':\n if (before) {\n this.parsePattern(before);\n }\n this.startContext({\n or: true,\n instructions: [],\n branches: []\n });\n break;\n case ')':\n if (!this.getContext().or) {\n throw new Error('\")\" operator must be preceded by \"(?:\" operator');\n }\n if (before) {\n this.parsePattern(before);\n }\n if (this.getContext().instructions.length === 0) {\n throw new Error('No instructions found after \"|\" operator in an \"or\" group');\n }\n var _this$getContext = this.getContext(),\n branches = _this$getContext.branches;\n branches.push(expandSingleElementArray(this.getContext().instructions));\n this.endContext();\n this.getContext().instructions.push({\n op: '|',\n args: branches\n });\n break;\n case '|':\n if (!this.getContext().or) {\n throw new Error('\"|\" operator can only be used inside \"or\" groups');\n }\n if (before) {\n this.parsePattern(before);\n }\n // The top-level is an implicit \"or\" group, if required.\n if (!this.getContext().branches) {\n // `branches` are not defined only for the root implicit \"or\" operator.\n /* istanbul ignore else */\n if (this.context.length === 1) {\n this.getContext().branches = [];\n } else {\n throw new Error('\"branches\" not found in an \"or\" group context');\n }\n }\n this.getContext().branches.push(expandSingleElementArray(this.getContext().instructions));\n this.getContext().instructions = [];\n break;\n case '[':\n if (before) {\n this.parsePattern(before);\n }\n this.startContext({\n oneOfSet: true\n });\n break;\n case ']':\n if (!this.getContext().oneOfSet) {\n throw new Error('\"]\" operator must be preceded by \"[\" operator');\n }\n this.endContext();\n this.getContext().instructions.push({\n op: '[]',\n args: parseOneOfSet(before)\n });\n break;\n\n /* istanbul ignore next */\n default:\n throw new Error(\"Unknown operator: \".concat(operator));\n }\n if (rightPart) {\n this.parsePattern(rightPart);\n }\n }\n }]);\n}();\nexport { PatternParser as default };\nfunction parseOneOfSet(pattern) {\n var values = [];\n var i = 0;\n while (i < pattern.length) {\n if (pattern[i] === '-') {\n if (i === 0 || i === pattern.length - 1) {\n throw new Error(\"Couldn't parse a one-of set pattern: \".concat(pattern));\n }\n var prevValue = pattern[i - 1].charCodeAt(0) + 1;\n var nextValue = pattern[i + 1].charCodeAt(0) - 1;\n var value = prevValue;\n while (value <= nextValue) {\n values.push(String.fromCharCode(value));\n value++;\n }\n } else {\n values.push(pattern[i]);\n }\n i++;\n }\n return values;\n}\nvar ILLEGAL_CHARACTER_REGEXP = /[\\(\\)\\[\\]\\?\\:\\|]/;\nvar OPERATOR = new RegExp(\n// any of:\n'(' +\n// or operator\n'\\\\|' +\n// or\n'|' +\n// or group start\n'\\\\(\\\\?\\\\:' +\n// or\n'|' +\n// or group end\n'\\\\)' +\n// or\n'|' +\n// one-of set start\n'\\\\[' +\n// or\n'|' +\n// one-of set end\n'\\\\]' + ')');\nfunction expandSingleElementArray(array) {\n if (array.length === 1) {\n return array[0];\n }\n return array;\n}\n//# sourceMappingURL=AsYouTypeFormatter.PatternParser.js.map","function _createForOfIteratorHelperLoose(r, e) { var t = \"undefined\" != typeof Symbol && r[Symbol.iterator] || r[\"@@iterator\"]; if (t) return (t = t.call(r)).next.bind(t); if (Array.isArray(r) || (t = _unsupportedIterableToArray(r)) || e && r && \"number\" == typeof r.length) { t && (r = t); var o = 0; return function () { return o >= r.length ? { done: !0 } : { done: !1, value: r[o++] }; }; } throw new TypeError(\"Invalid attempt to iterate non-iterable instance.\\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.\"); }\nfunction _unsupportedIterableToArray(r, a) { if (r) { if (\"string\" == typeof r) return _arrayLikeToArray(r, a); var t = {}.toString.call(r).slice(8, -1); return \"Object\" === t && r.constructor && (t = r.constructor.name), \"Map\" === t || \"Set\" === t ? Array.from(r) : \"Arguments\" === t || /^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(t) ? _arrayLikeToArray(r, a) : void 0; } }\nfunction _arrayLikeToArray(r, a) { (null == a || a > r.length) && (a = r.length); for (var e = 0, n = Array(a); e < a; e++) n[e] = r[e]; return n; }\nfunction _typeof(o) { \"@babel/helpers - typeof\"; return _typeof = \"function\" == typeof Symbol && \"symbol\" == typeof Symbol.iterator ? function (o) { return typeof o; } : function (o) { return o && \"function\" == typeof Symbol && o.constructor === Symbol && o !== Symbol.prototype ? \"symbol\" : typeof o; }, _typeof(o); }\nfunction _classCallCheck(a, n) { if (!(a instanceof n)) throw new TypeError(\"Cannot call a class as a function\"); }\nfunction _defineProperties(e, r) { for (var t = 0; t < r.length; t++) { var o = r[t]; o.enumerable = o.enumerable || !1, o.configurable = !0, \"value\" in o && (o.writable = !0), Object.defineProperty(e, _toPropertyKey(o.key), o); } }\nfunction _createClass(e, r, t) { return r && _defineProperties(e.prototype, r), t && _defineProperties(e, t), Object.defineProperty(e, \"prototype\", { writable: !1 }), e; }\nfunction _toPropertyKey(t) { var i = _toPrimitive(t, \"string\"); return \"symbol\" == _typeof(i) ? i : i + \"\"; }\nfunction _toPrimitive(t, r) { if (\"object\" != _typeof(t) || !t) return t; var e = t[Symbol.toPrimitive]; if (void 0 !== e) { var i = e.call(t, r || \"default\"); if (\"object\" != _typeof(i)) return i; throw new TypeError(\"@@toPrimitive must return a primitive value.\"); } return (\"string\" === r ? String : Number)(t); }\nimport PatternParser from './AsYouTypeFormatter.PatternParser.js';\nvar PatternMatcher = /*#__PURE__*/function () {\n function PatternMatcher(pattern) {\n _classCallCheck(this, PatternMatcher);\n this.matchTree = new PatternParser().parse(pattern);\n }\n return _createClass(PatternMatcher, [{\n key: \"match\",\n value: function match(string) {\n var _ref = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : {},\n allowOverflow = _ref.allowOverflow;\n if (!string) {\n throw new Error('String is required');\n }\n var result = _match(string.split(''), this.matchTree, true);\n if (result && result.match) {\n delete result.matchedChars;\n }\n if (result && result.overflow) {\n if (!allowOverflow) {\n return;\n }\n }\n return result;\n }\n }]);\n}();\n/**\r\n * Matches `characters` against a pattern compiled into a `tree`.\r\n * @param {string[]} characters\r\n * @param {Tree} tree — A pattern compiled into a `tree`. See the `*.d.ts` file for the description of the `tree` structure.\r\n * @param {boolean} last — Whether it's the last (rightmost) subtree on its level of the match tree.\r\n * @return {object} See the `*.d.ts` file for the description of the result object.\r\n */\nexport { PatternMatcher as default };\nfunction _match(characters, tree, last) {\n // If `tree` is a string, then `tree` is a single character.\n // That's because when a pattern is parsed, multi-character-string parts\n // of a pattern are compiled into arrays of single characters.\n // I still wrote this piece of code for a \"general\" hypothetical case\n // when `tree` could be a string of several characters, even though\n // such case is not possible with the current implementation.\n if (typeof tree === 'string') {\n var characterString = characters.join('');\n if (tree.indexOf(characterString) === 0) {\n // `tree` is always a single character.\n // If `tree.indexOf(characterString) === 0`\n // then `characters.length === tree.length`.\n /* istanbul ignore else */\n if (characters.length === tree.length) {\n return {\n match: true,\n matchedChars: characters\n };\n }\n // `tree` is always a single character.\n // If `tree.indexOf(characterString) === 0`\n // then `characters.length === tree.length`.\n /* istanbul ignore next */\n return {\n partialMatch: true\n // matchedChars: characters\n };\n }\n if (characterString.indexOf(tree) === 0) {\n if (last) {\n // The `else` path is not possible because `tree` is always a single character.\n // The `else` case for `characters.length > tree.length` would be\n // `characters.length <= tree.length` which means `characters.length <= 1`.\n // `characters` array can't be empty, so that means `characters === [tree]`,\n // which would also mean `tree.indexOf(characterString) === 0` and that'd mean\n // that the `if (tree.indexOf(characterString) === 0)` condition before this\n // `if` condition would be entered, and returned from there, not reaching this code.\n /* istanbul ignore else */\n if (characters.length > tree.length) {\n return {\n overflow: true\n };\n }\n }\n return {\n match: true,\n matchedChars: characters.slice(0, tree.length)\n };\n }\n return;\n }\n if (Array.isArray(tree)) {\n var restCharacters = characters.slice();\n var i = 0;\n while (i < tree.length) {\n var subtree = tree[i];\n var result = _match(restCharacters, subtree, last && i === tree.length - 1);\n if (!result) {\n return;\n } else if (result.overflow) {\n return result;\n } else if (result.match) {\n // Continue with the next subtree with the rest of the characters.\n restCharacters = restCharacters.slice(result.matchedChars.length);\n if (restCharacters.length === 0) {\n if (i === tree.length - 1) {\n return {\n match: true,\n matchedChars: characters\n };\n } else {\n return {\n partialMatch: true\n // matchedChars: characters\n };\n }\n }\n } else {\n /* istanbul ignore else */\n if (result.partialMatch) {\n return {\n partialMatch: true\n // matchedChars: characters\n };\n } else {\n throw new Error(\"Unsupported match result:\\n\".concat(JSON.stringify(result, null, 2)));\n }\n }\n i++;\n }\n // If `last` then overflow has already been checked\n // by the last element of the `tree` array.\n /* istanbul ignore if */\n if (last) {\n return {\n overflow: true\n };\n }\n return {\n match: true,\n matchedChars: characters.slice(0, characters.length - restCharacters.length)\n };\n }\n switch (tree.op) {\n case '|':\n var partialMatch;\n for (var _iterator = _createForOfIteratorHelperLoose(tree.args), _step; !(_step = _iterator()).done;) {\n var branch = _step.value;\n var _result = _match(characters, branch, last);\n if (_result) {\n if (_result.overflow) {\n return _result;\n } else if (_result.match) {\n return {\n match: true,\n matchedChars: _result.matchedChars\n };\n } else {\n /* istanbul ignore else */\n if (_result.partialMatch) {\n partialMatch = true;\n } else {\n throw new Error(\"Unsupported match result:\\n\".concat(JSON.stringify(_result, null, 2)));\n }\n }\n }\n }\n if (partialMatch) {\n return {\n partialMatch: true\n // matchedChars: ...\n };\n }\n // Not even a partial match.\n return;\n case '[]':\n for (var _iterator2 = _createForOfIteratorHelperLoose(tree.args), _step2; !(_step2 = _iterator2()).done;) {\n var _char = _step2.value;\n if (characters[0] === _char) {\n if (characters.length === 1) {\n return {\n match: true,\n matchedChars: characters\n };\n }\n if (last) {\n return {\n overflow: true\n };\n }\n return {\n match: true,\n matchedChars: [_char]\n };\n }\n }\n // No character matches.\n return;\n\n /* istanbul ignore next */\n default:\n throw new Error(\"Unsupported instruction tree: \".concat(tree));\n }\n}\n//# sourceMappingURL=AsYouTypeFormatter.PatternMatcher.js.map","function _typeof(o) { \"@babel/helpers - typeof\"; return _typeof = \"function\" == typeof Symbol && \"symbol\" == typeof Symbol.iterator ? function (o) { return typeof o; } : function (o) { return o && \"function\" == typeof Symbol && o.constructor === Symbol && o !== Symbol.prototype ? \"symbol\" : typeof o; }, _typeof(o); }\nfunction _createForOfIteratorHelperLoose(r, e) { var t = \"undefined\" != typeof Symbol && r[Symbol.iterator] || r[\"@@iterator\"]; if (t) return (t = t.call(r)).next.bind(t); if (Array.isArray(r) || (t = _unsupportedIterableToArray(r)) || e && r && \"number\" == typeof r.length) { t && (r = t); var o = 0; return function () { return o >= r.length ? { done: !0 } : { done: !1, value: r[o++] }; }; } throw new TypeError(\"Invalid attempt to iterate non-iterable instance.\\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.\"); }\nfunction _unsupportedIterableToArray(r, a) { if (r) { if (\"string\" == typeof r) return _arrayLikeToArray(r, a); var t = {}.toString.call(r).slice(8, -1); return \"Object\" === t && r.constructor && (t = r.constructor.name), \"Map\" === t || \"Set\" === t ? Array.from(r) : \"Arguments\" === t || /^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(t) ? _arrayLikeToArray(r, a) : void 0; } }\nfunction _arrayLikeToArray(r, a) { (null == a || a > r.length) && (a = r.length); for (var e = 0, n = Array(a); e < a; e++) n[e] = r[e]; return n; }\nfunction _classCallCheck(a, n) { if (!(a instanceof n)) throw new TypeError(\"Cannot call a class as a function\"); }\nfunction _defineProperties(e, r) { for (var t = 0; t < r.length; t++) { var o = r[t]; o.enumerable = o.enumerable || !1, o.configurable = !0, \"value\" in o && (o.writable = !0), Object.defineProperty(e, _toPropertyKey(o.key), o); } }\nfunction _createClass(e, r, t) { return r && _defineProperties(e.prototype, r), t && _defineProperties(e, t), Object.defineProperty(e, \"prototype\", { writable: !1 }), e; }\nfunction _toPropertyKey(t) { var i = _toPrimitive(t, \"string\"); return \"symbol\" == _typeof(i) ? i : i + \"\"; }\nfunction _toPrimitive(t, r) { if (\"object\" != _typeof(t) || !t) return t; var e = t[Symbol.toPrimitive]; if (void 0 !== e) { var i = e.call(t, r || \"default\"); if (\"object\" != _typeof(i)) return i; throw new TypeError(\"@@toPrimitive must return a primitive value.\"); } return (\"string\" === r ? String : Number)(t); }\nimport { DIGIT_PLACEHOLDER, countOccurences, repeat, cutAndStripNonPairedParens, closeNonPairedParens, stripNonPairedParens, populateTemplateWithDigits } from './AsYouTypeFormatter.util.js';\nimport formatCompleteNumber, { canFormatCompleteNumber } from './AsYouTypeFormatter.complete.js';\nimport PatternMatcher from './AsYouTypeFormatter.PatternMatcher.js';\nimport parseDigits from './helpers/parseDigits.js';\nexport { DIGIT_PLACEHOLDER } from './AsYouTypeFormatter.util.js';\nimport { FIRST_GROUP_PATTERN } from './helpers/formatNationalNumberUsingFormat.js';\nimport { VALID_PUNCTUATION } from './constants.js';\nimport applyInternationalSeparatorStyle from './helpers/applyInternationalSeparatorStyle.js';\n\n// Used in phone number format template creation.\n// Could be any digit, I guess.\nvar DUMMY_DIGIT = '9';\n// I don't know why is it exactly `15`\nvar LONGEST_NATIONAL_PHONE_NUMBER_LENGTH = 15;\n// Create a phone number consisting only of the digit 9 that matches the\n// `number_pattern` by applying the pattern to the \"longest phone number\" string.\nvar LONGEST_DUMMY_PHONE_NUMBER = repeat(DUMMY_DIGIT, LONGEST_NATIONAL_PHONE_NUMBER_LENGTH);\n\n// A set of characters that, if found in a national prefix formatting rules, are an indicator to\n// us that we should separate the national prefix from the number when formatting.\nvar NATIONAL_PREFIX_SEPARATORS_PATTERN = /[- ]/;\n\n// Deprecated: Google has removed some formatting pattern related code from their repo.\n// https://github.com/googlei18n/libphonenumber/commit/a395b4fef3caf57c4bc5f082e1152a4d2bd0ba4c\n// \"We no longer have numbers in formatting matching patterns, only \\d.\"\n// Because this library supports generating custom metadata\n// some users may still be using old metadata so the relevant\n// code seems to stay until some next major version update.\nvar SUPPORT_LEGACY_FORMATTING_PATTERNS = true;\n\n// A pattern that is used to match character classes in regular expressions.\n// An example of a character class is \"[1-4]\".\nvar CREATE_CHARACTER_CLASS_PATTERN = SUPPORT_LEGACY_FORMATTING_PATTERNS && function () {\n return /\\[([^\\[\\]])*\\]/g;\n};\n\n// Any digit in a regular expression that actually denotes a digit. For\n// example, in the regular expression \"80[0-2]\\d{6,10}\", the first 2 digits\n// (8 and 0) are standalone digits, but the rest are not.\n// Two look-aheads are needed because the number following \\\\d could be a\n// two-digit number, since the phone number can be as long as 15 digits.\nvar CREATE_STANDALONE_DIGIT_PATTERN = SUPPORT_LEGACY_FORMATTING_PATTERNS && function () {\n return /\\d(?=[^,}][^,}])/g;\n};\n\n// A regular expression that is used to determine if a `format` is\n// suitable to be used in the \"as you type formatter\".\n// A `format` is suitable when the resulting formatted number has\n// the same digits as the user has entered.\n//\n// In the simplest case, that would mean that the format\n// doesn't add any additional digits when formatting a number.\n// Google says that it also shouldn't add \"star\" (`*`) characters,\n// like it does in some Israeli formats.\n// Such basic format would only contain \"valid punctuation\"\n// and \"captured group\" identifiers ($1, $2, etc).\n//\n// An example of a format that adds additional digits:\n//\n// Country: `AR` (Argentina).\n// Format:\n// {\n// \"pattern\": \"(\\\\d)(\\\\d{2})(\\\\d{4})(\\\\d{4})\",\n// \"leading_digits_patterns\": [\"91\"],\n// \"national_prefix_formatting_rule\": \"0$1\",\n// \"format\": \"$2 15-$3-$4\",\n// \"international_format\": \"$1 $2 $3-$4\"\n// }\n//\n// In the format above, the `format` adds `15` to the digits when formatting a number.\n// A sidenote: this format actually is suitable because `national_prefix_for_parsing`\n// has previously removed `15` from a national number, so re-adding `15` in `format`\n// doesn't actually result in any extra digits added to user's input.\n// But verifying that would be a complex procedure, so the code chooses a simpler path:\n// it simply filters out all `format`s that contain anything but \"captured group\" ids.\n//\n// This regular expression is called `ELIGIBLE_FORMAT_PATTERN` in Google's\n// `libphonenumber` code.\n//\nvar NON_ALTERING_FORMAT_REG_EXP = new RegExp('[' + VALID_PUNCTUATION + ']*' +\n// Google developers say:\n// \"We require that the first matching group is present in the\n// output pattern to ensure no data is lost while formatting.\"\n'\\\\$1' + '[' + VALID_PUNCTUATION + ']*' + '(\\\\$\\\\d[' + VALID_PUNCTUATION + ']*)*' + '$');\n\n// This is the minimum length of the leading digits of a phone number\n// to guarantee the first \"leading digits pattern\" for a phone number format\n// to be preemptive.\nvar MIN_LEADING_DIGITS_LENGTH = 3;\nvar AsYouTypeFormatter = /*#__PURE__*/function () {\n function AsYouTypeFormatter(_ref) {\n var state = _ref.state,\n metadata = _ref.metadata;\n _classCallCheck(this, AsYouTypeFormatter);\n this.metadata = metadata;\n this.resetFormat();\n }\n return _createClass(AsYouTypeFormatter, [{\n key: \"resetFormat\",\n value: function resetFormat() {\n this.chosenFormat = undefined;\n this.template = undefined;\n this.nationalNumberTemplate = undefined;\n this.populatedNationalNumberTemplate = undefined;\n this.populatedNationalNumberTemplatePosition = -1;\n }\n }, {\n key: \"reset\",\n value: function reset(numberingPlan, state) {\n this.resetFormat();\n if (numberingPlan) {\n this.isNANP = numberingPlan.callingCode() === '1';\n this.matchingFormats = numberingPlan.formats();\n if (state.nationalSignificantNumber) {\n this.narrowDownMatchingFormats(state);\n }\n } else {\n this.isNANP = undefined;\n this.matchingFormats = [];\n }\n }\n\n /**\r\n * Formats an updated phone number.\r\n * @param {string} nextDigits — Additional phone number digits.\r\n * @param {object} state — `AsYouType` state.\r\n * @return {[string]} Returns undefined if the updated phone number can't be formatted using any of the available formats.\r\n */\n }, {\n key: \"format\",\n value: function format(nextDigits, state) {\n var _this = this;\n // See if the phone number digits can be formatted as a complete phone number.\n // If not, use the results from `formatNationalNumberWithNextDigits()`,\n // which formats based on the chosen formatting pattern.\n //\n // Attempting to format complete phone number first is how it's done\n // in Google's `libphonenumber`, so this library just follows it.\n // Google's `libphonenumber` code doesn't explain in detail why does it\n // attempt to format digits as a complete phone number\n // instead of just going with a previoulsy (or newly) chosen `format`:\n //\n // \"Checks to see if there is an exact pattern match for these digits.\n // If so, we should use this instead of any other formatting template\n // whose leadingDigitsPattern also matches the input.\"\n //\n if (canFormatCompleteNumber(state.nationalSignificantNumber, this.metadata)) {\n for (var _iterator = _createForOfIteratorHelperLoose(this.matchingFormats), _step; !(_step = _iterator()).done;) {\n var _format = _step.value;\n var formattedCompleteNumber = formatCompleteNumber(state, _format, {\n metadata: this.metadata,\n shouldTryNationalPrefixFormattingRule: function shouldTryNationalPrefixFormattingRule(format) {\n return _this.shouldTryNationalPrefixFormattingRule(format, {\n international: state.international,\n nationalPrefix: state.nationalPrefix\n });\n },\n getSeparatorAfterNationalPrefix: function getSeparatorAfterNationalPrefix(format) {\n return _this.getSeparatorAfterNationalPrefix(format);\n }\n });\n if (formattedCompleteNumber) {\n this.resetFormat();\n this.chosenFormat = _format;\n this.setNationalNumberTemplate(formattedCompleteNumber.replace(/\\d/g, DIGIT_PLACEHOLDER), state);\n this.populatedNationalNumberTemplate = formattedCompleteNumber;\n // With a new formatting template, the matched position\n // using the old template needs to be reset.\n this.populatedNationalNumberTemplatePosition = this.template.lastIndexOf(DIGIT_PLACEHOLDER);\n return formattedCompleteNumber;\n }\n }\n }\n // Format the digits as a partial (incomplete) phone number\n // using the previously chosen formatting pattern (or a newly chosen one).\n return this.formatNationalNumberWithNextDigits(nextDigits, state);\n }\n\n // Formats the next phone number digits.\n }, {\n key: \"formatNationalNumberWithNextDigits\",\n value: function formatNationalNumberWithNextDigits(nextDigits, state) {\n var previouslyChosenFormat = this.chosenFormat;\n\n // Choose a format from the list of matching ones.\n var newlyChosenFormat = this.chooseFormat(state);\n if (newlyChosenFormat) {\n if (newlyChosenFormat === previouslyChosenFormat) {\n // If it can format the next (current) digits\n // using the previously chosen phone number format\n // then return the updated formatted number.\n return this.formatNextNationalNumberDigits(nextDigits);\n } else {\n // If a more appropriate phone number format\n // has been chosen for these \"leading digits\",\n // then re-format the national phone number part\n // using the newly selected format.\n return this.formatNextNationalNumberDigits(state.getNationalDigits());\n }\n }\n }\n }, {\n key: \"narrowDownMatchingFormats\",\n value: function narrowDownMatchingFormats(_ref2) {\n var _this2 = this;\n var nationalSignificantNumber = _ref2.nationalSignificantNumber,\n nationalPrefix = _ref2.nationalPrefix,\n international = _ref2.international;\n var leadingDigits = nationalSignificantNumber;\n\n // \"leading digits\" pattern list starts with a\n // \"leading digits\" pattern fitting a maximum of 3 leading digits.\n // So, after a user inputs 3 digits of a national (significant) phone number\n // this national (significant) number can already be formatted.\n // The next \"leading digits\" pattern is for 4 leading digits max,\n // and the \"leading digits\" pattern after it is for 5 leading digits max, etc.\n\n // This implementation is different from Google's\n // in that it searches for a fitting format\n // even if the user has entered less than\n // `MIN_LEADING_DIGITS_LENGTH` digits of a national number.\n // Because some leading digit patterns already match for a single first digit.\n var leadingDigitsPatternIndex = leadingDigits.length - MIN_LEADING_DIGITS_LENGTH;\n if (leadingDigitsPatternIndex < 0) {\n leadingDigitsPatternIndex = 0;\n }\n this.matchingFormats = this.matchingFormats.filter(function (format) {\n return _this2.formatSuits(format, international, nationalPrefix) && _this2.formatMatches(format, leadingDigits, leadingDigitsPatternIndex);\n });\n\n // If there was a phone number format chosen\n // and it no longer holds given the new leading digits then reset it.\n // The test for this `if` condition is marked as:\n // \"Reset a chosen format when it no longer holds given the new leading digits\".\n // To construct a valid test case for this one can find a country\n // in `PhoneNumberMetadata.xml` yielding one format for 3 `<leadingDigits>`\n // and yielding another format for 4 `<leadingDigits>` (Australia in this case).\n if (this.chosenFormat && this.matchingFormats.indexOf(this.chosenFormat) === -1) {\n this.resetFormat();\n }\n }\n }, {\n key: \"formatSuits\",\n value: function formatSuits(format, international, nationalPrefix) {\n // When a prefix before a national (significant) number is\n // simply a national prefix, then it's parsed as `this.nationalPrefix`.\n // In more complex cases, a prefix before national (significant) number\n // could include a national prefix as well as some \"capturing groups\",\n // and in that case there's no info whether a national prefix has been parsed.\n // If national prefix is not used when formatting a phone number\n // using this format, but a national prefix has been entered by the user,\n // and was extracted, then discard such phone number format.\n // In Google's \"AsYouType\" formatter code, the equivalent would be this part:\n // https://github.com/google/libphonenumber/blob/0a45cfd96e71cad8edb0e162a70fcc8bd9728933/java/libphonenumber/src/com/google/i18n/phonenumbers/AsYouTypeFormatter.java#L175-L184\n if (nationalPrefix && !format.usesNationalPrefix() &&\n // !format.domesticCarrierCodeFormattingRule() &&\n !format.nationalPrefixIsOptionalWhenFormattingInNationalFormat()) {\n return false;\n }\n // If national prefix is mandatory for this phone number format\n // and there're no guarantees that a national prefix is present in user input\n // then discard this phone number format as not suitable.\n // In Google's \"AsYouType\" formatter code, the equivalent would be this part:\n // https://github.com/google/libphonenumber/blob/0a45cfd96e71cad8edb0e162a70fcc8bd9728933/java/libphonenumber/src/com/google/i18n/phonenumbers/AsYouTypeFormatter.java#L185-L193\n if (!international && !nationalPrefix && format.nationalPrefixIsMandatoryWhenFormattingInNationalFormat()) {\n return false;\n }\n return true;\n }\n }, {\n key: \"formatMatches\",\n value: function formatMatches(format, leadingDigits, leadingDigitsPatternIndex) {\n var leadingDigitsPatternsCount = format.leadingDigitsPatterns().length;\n\n // If this format is not restricted to a certain\n // leading digits pattern then it fits.\n // The test case could be found by searching for \"leadingDigitsPatternsCount === 0\".\n if (leadingDigitsPatternsCount === 0) {\n return true;\n }\n\n // Start narrowing down the list of possible formats based on the leading digits.\n // (only previously matched formats take part in the narrowing down process)\n\n // `leading_digits_patterns` start with 3 digits min\n // and then go up from there one digit at a time.\n leadingDigitsPatternIndex = Math.min(leadingDigitsPatternIndex, leadingDigitsPatternsCount - 1);\n var leadingDigitsPattern = format.leadingDigitsPatterns()[leadingDigitsPatternIndex];\n\n // Google imposes a requirement on the leading digits\n // to be minimum 3 digits long in order to be eligible\n // for checking those with a leading digits pattern.\n //\n // Since `leading_digits_patterns` start with 3 digits min,\n // Google's original `libphonenumber` library only starts\n // excluding any non-matching formats only when the\n // national number entered so far is at least 3 digits long,\n // otherwise format matching would give false negatives.\n //\n // For example, when the digits entered so far are `2`\n // and the leading digits pattern is `21` –\n // it's quite obvious in this case that the format could be the one\n // but due to the absence of further digits it would give false negative.\n //\n // Also, `leading_digits_patterns` doesn't always correspond to a single\n // digits count. For example, `60|8` pattern would already match `8`\n // but the `60` part would require having at least two leading digits,\n // so the whole pattern would require inputting two digits first in order to\n // decide on whether it matches the input, even when the input is \"80\".\n //\n // This library — `libphonenumber-js` — allows filtering by `leading_digits_patterns`\n // even when there's only 1 or 2 digits of the national (significant) number.\n // To do that, it uses a non-strict pattern matcher written specifically for that.\n //\n if (leadingDigits.length < MIN_LEADING_DIGITS_LENGTH) {\n // Before leading digits < 3 matching was implemented:\n // return true\n //\n // After leading digits < 3 matching was implemented:\n try {\n return new PatternMatcher(leadingDigitsPattern).match(leadingDigits, {\n allowOverflow: true\n }) !== undefined;\n } catch (error) /* istanbul ignore next */{\n // There's a slight possibility that there could be some undiscovered bug\n // in the pattern matcher code. Since the \"leading digits < 3 matching\"\n // feature is not \"essential\" for operation, it can fall back to the old way\n // in case of any issues rather than halting the application's execution.\n console.error(error);\n return true;\n }\n }\n\n // If at least `MIN_LEADING_DIGITS_LENGTH` digits of a national number are\n // available then use the usual regular expression matching.\n //\n // The whole pattern is wrapped in round brackets (`()`) because\n // the pattern can use \"or\" operator (`|`) at the top level of the pattern.\n //\n return new RegExp(\"^(\".concat(leadingDigitsPattern, \")\")).test(leadingDigits);\n }\n }, {\n key: \"getFormatFormat\",\n value: function getFormatFormat(format, international) {\n return international ? format.internationalFormat() : format.format();\n }\n }, {\n key: \"chooseFormat\",\n value: function chooseFormat(state) {\n var _this3 = this;\n var _loop = function _loop() {\n var format = _step2.value;\n // If this format is currently being used\n // and is still suitable, then stick to it.\n if (_this3.chosenFormat === format) {\n return 0; // break\n }\n // Sometimes, a formatting rule inserts additional digits in a phone number,\n // and \"as you type\" formatter can't do that: it should only use the digits\n // that the user has input.\n //\n // For example, in Argentina, there's a format for mobile phone numbers:\n //\n // {\n // \"pattern\": \"(\\\\d)(\\\\d{2})(\\\\d{4})(\\\\d{4})\",\n // \"leading_digits_patterns\": [\"91\"],\n // \"national_prefix_formatting_rule\": \"0$1\",\n // \"format\": \"$2 15-$3-$4\",\n // \"international_format\": \"$1 $2 $3-$4\"\n // }\n //\n // In that format, `international_format` is used instead of `format`\n // because `format` inserts `15` in the formatted number,\n // and `AsYouType` formatter should only use the digits\n // the user has actually input, without adding any extra digits.\n // In this case, it wouldn't make a difference, because the `15`\n // is first stripped when applying `national_prefix_for_parsing`\n // and then re-added when using `format`, so in reality it doesn't\n // add any new digits to the number, but to detect that, the code\n // would have to be more complex: it would have to try formatting\n // the digits using the format and then see if any digits have\n // actually been added or removed, and then, every time a new digit\n // is input, it should re-check whether the chosen format doesn't\n // alter the digits.\n //\n // Google's code doesn't go that far, and so does this library:\n // it simply requires that a `format` doesn't add any additonal\n // digits to user's input.\n //\n // Also, people in general should move from inputting phone numbers\n // in national format (possibly with national prefixes)\n // and use international phone number format instead:\n // it's a logical thing in the modern age of mobile phones,\n // globalization and the internet.\n //\n /* istanbul ignore if */\n if (!NON_ALTERING_FORMAT_REG_EXP.test(_this3.getFormatFormat(format, state.international))) {\n return 1; // continue\n }\n if (!_this3.createTemplateForFormat(format, state)) {\n // Remove the format if it can't generate a template.\n _this3.matchingFormats = _this3.matchingFormats.filter(function (_) {\n return _ !== format;\n });\n return 1; // continue\n }\n _this3.chosenFormat = format;\n return 0; // break\n },\n _ret;\n // When there are multiple available formats, the formatter uses the first\n // format where a formatting template could be created.\n //\n // For some weird reason, `istanbul` says \"else path not taken\"\n // for the `for of` line below. Supposedly that means that\n // the loop doesn't ever go over the last element in the list.\n // That's true because there always is `this.chosenFormat`\n // when `this.matchingFormats` is non-empty.\n // And, for some weird reason, it doesn't think that the case\n // with empty `this.matchingFormats` qualifies for a valid \"else\" path.\n // So simply muting this `istanbul` warning.\n // It doesn't skip the contents of the `for of` loop,\n // it just skips the `for of` line.\n //\n /* istanbul ignore next */\n for (var _iterator2 = _createForOfIteratorHelperLoose(this.matchingFormats.slice()), _step2; !(_step2 = _iterator2()).done;) {\n _ret = _loop();\n if (_ret === 0) break;\n if (_ret === 1) continue;\n }\n if (!this.chosenFormat) {\n // No format matches the national (significant) phone number.\n this.resetFormat();\n }\n return this.chosenFormat;\n }\n }, {\n key: \"createTemplateForFormat\",\n value: function createTemplateForFormat(format, state) {\n // The formatter doesn't format numbers when numberPattern contains '|', e.g.\n // (20|3)\\d{4}. In those cases we quickly return.\n // (Though there's no such format in current metadata)\n /* istanbul ignore if */\n if (SUPPORT_LEGACY_FORMATTING_PATTERNS && format.pattern().indexOf('|') >= 0) {\n return;\n }\n // Get formatting template for this phone number format\n var template = this.getTemplateForFormat(format, state);\n // If the national number entered is too long\n // for any phone number format, then abort.\n if (template) {\n this.setNationalNumberTemplate(template, state);\n return true;\n }\n }\n }, {\n key: \"getSeparatorAfterNationalPrefix\",\n value: function getSeparatorAfterNationalPrefix(format) {\n // `US` metadata doesn't have a `national_prefix_formatting_rule`,\n // so the `if` condition below doesn't apply to `US`,\n // but in reality there shoudl be a separator\n // between a national prefix and a national (significant) number.\n // So `US` national prefix separator is a \"special\" \"hardcoded\" case.\n if (this.isNANP) {\n return ' ';\n }\n // If a `format` has a `national_prefix_formatting_rule`\n // and that rule has a separator after a national prefix,\n // then it means that there should be a separator\n // between a national prefix and a national (significant) number.\n if (format && format.nationalPrefixFormattingRule() && NATIONAL_PREFIX_SEPARATORS_PATTERN.test(format.nationalPrefixFormattingRule())) {\n return ' ';\n }\n // At this point, there seems to be no clear evidence that\n // there should be a separator between a national prefix\n // and a national (significant) number. So don't insert one.\n return '';\n }\n }, {\n key: \"getInternationalPrefixBeforeCountryCallingCode\",\n value: function getInternationalPrefixBeforeCountryCallingCode(_ref3, options) {\n var IDDPrefix = _ref3.IDDPrefix,\n missingPlus = _ref3.missingPlus;\n if (IDDPrefix) {\n return options && options.spacing === false ? IDDPrefix : IDDPrefix + ' ';\n }\n if (missingPlus) {\n return '';\n }\n return '+';\n }\n }, {\n key: \"getTemplate\",\n value: function getTemplate(state) {\n if (!this.template) {\n return;\n }\n // `this.template` holds the template for a \"complete\" phone number.\n // The currently entered phone number is most likely not \"complete\",\n // so trim all non-populated digits.\n var index = -1;\n var i = 0;\n var internationalPrefix = state.international ? this.getInternationalPrefixBeforeCountryCallingCode(state, {\n spacing: false\n }) : '';\n while (i < internationalPrefix.length + state.getDigitsWithoutInternationalPrefix().length) {\n index = this.template.indexOf(DIGIT_PLACEHOLDER, index + 1);\n i++;\n }\n return cutAndStripNonPairedParens(this.template, index + 1);\n }\n }, {\n key: \"setNationalNumberTemplate\",\n value: function setNationalNumberTemplate(template, state) {\n this.nationalNumberTemplate = template;\n this.populatedNationalNumberTemplate = template;\n // With a new formatting template, the matched position\n // using the old template needs to be reset.\n this.populatedNationalNumberTemplatePosition = -1;\n // For convenience, the public `.template` property\n // contains the whole international number\n // if the phone number being input is international:\n // 'x' for the '+' sign, 'x'es for the country phone code,\n // a spacebar and then the template for the formatted national number.\n if (state.international) {\n this.template = this.getInternationalPrefixBeforeCountryCallingCode(state).replace(/[\\d\\+]/g, DIGIT_PLACEHOLDER) + repeat(DIGIT_PLACEHOLDER, state.callingCode.length) + ' ' + template;\n } else {\n this.template = template;\n }\n }\n\n /**\r\n * Generates formatting template for a national phone number,\r\n * optionally containing a national prefix, for a format.\r\n * @param {Format} format\r\n * @param {string} nationalPrefix\r\n * @return {string}\r\n */\n }, {\n key: \"getTemplateForFormat\",\n value: function getTemplateForFormat(format, _ref4) {\n var nationalSignificantNumber = _ref4.nationalSignificantNumber,\n international = _ref4.international,\n nationalPrefix = _ref4.nationalPrefix,\n prefixBeforeNationalSignificantNumberThatIsNotNationalPrefix = _ref4.prefixBeforeNationalSignificantNumberThatIsNotNationalPrefix;\n var pattern = format.pattern();\n\n /* istanbul ignore else */\n if (SUPPORT_LEGACY_FORMATTING_PATTERNS) {\n pattern = pattern\n // Replace anything in the form of [..] with \\d\n .replace(CREATE_CHARACTER_CLASS_PATTERN(), '\\\\d')\n // Replace any standalone digit (not the one in `{}`) with \\d\n .replace(CREATE_STANDALONE_DIGIT_PATTERN(), '\\\\d');\n }\n\n // Generate a dummy national number (consisting of `9`s)\n // that fits this format's `pattern`.\n //\n // This match will always succeed,\n // because the \"longest dummy phone number\"\n // has enough length to accomodate any possible\n // national phone number format pattern.\n //\n var digits = LONGEST_DUMMY_PHONE_NUMBER.match(pattern)[0];\n\n // If the national number entered is too long\n // for any phone number format, then abort.\n if (nationalSignificantNumber.length > digits.length) {\n return;\n }\n\n // Get a formatting template which can be used to efficiently format\n // a partial number where digits are added one by one.\n\n // Below `strictPattern` is used for the\n // regular expression (with `^` and `$`).\n // This wasn't originally in Google's `libphonenumber`\n // and I guess they don't really need it\n // because they're not using \"templates\" to format phone numbers\n // but I added `strictPattern` after encountering\n // South Korean phone number formatting bug.\n //\n // Non-strict regular expression bug demonstration:\n //\n // this.nationalSignificantNumber : `111111111` (9 digits)\n //\n // pattern : (\\d{2})(\\d{3,4})(\\d{4})\n // format : `$1 $2 $3`\n // digits : `9999999999` (10 digits)\n //\n // '9999999999'.replace(new RegExp(/(\\d{2})(\\d{3,4})(\\d{4})/g), '$1 $2 $3') = \"99 9999 9999\"\n //\n // template : xx xxxx xxxx\n //\n // But the correct template in this case is `xx xxx xxxx`.\n // The template was generated incorrectly because of the\n // `{3,4}` variability in the `pattern`.\n //\n // The fix is, if `this.nationalSignificantNumber` has already sufficient length\n // to satisfy the `pattern` completely then `this.nationalSignificantNumber`\n // is used instead of `digits`.\n\n var strictPattern = new RegExp('^' + pattern + '$');\n var nationalNumberDummyDigits = nationalSignificantNumber.replace(/\\d/g, DUMMY_DIGIT);\n\n // If `this.nationalSignificantNumber` has already sufficient length\n // to satisfy the `pattern` completely then use it\n // instead of `digits`.\n if (strictPattern.test(nationalNumberDummyDigits)) {\n digits = nationalNumberDummyDigits;\n }\n var numberFormat = this.getFormatFormat(format, international);\n var nationalPrefixIncludedInTemplate;\n\n // If a user did input a national prefix (and that's guaranteed),\n // and if a `format` does have a national prefix formatting rule,\n // then see if that national prefix formatting rule\n // prepends exactly the same national prefix the user has input.\n // If that's the case, then use the `format` with the national prefix formatting rule.\n // Otherwise, use the `format` without the national prefix formatting rule,\n // and prepend a national prefix manually to it.\n if (this.shouldTryNationalPrefixFormattingRule(format, {\n international: international,\n nationalPrefix: nationalPrefix\n })) {\n var numberFormatWithNationalPrefix = numberFormat.replace(FIRST_GROUP_PATTERN, format.nationalPrefixFormattingRule());\n // If `national_prefix_formatting_rule` of a `format` simply prepends\n // national prefix at the start of a national (significant) number,\n // then such formatting can be used with `AsYouType` formatter.\n // There seems to be no `else` case: everywhere in metadata,\n // national prefix formatting rule is national prefix + $1,\n // or `($1)`, in which case such format isn't even considered\n // when the user has input a national prefix.\n /* istanbul ignore else */\n if (parseDigits(format.nationalPrefixFormattingRule()) === (nationalPrefix || '') + parseDigits('$1')) {\n numberFormat = numberFormatWithNationalPrefix;\n nationalPrefixIncludedInTemplate = true;\n // Replace all digits of the national prefix in the formatting template\n // with `DIGIT_PLACEHOLDER`s.\n if (nationalPrefix) {\n var i = nationalPrefix.length;\n while (i > 0) {\n numberFormat = numberFormat.replace(/\\d/, DIGIT_PLACEHOLDER);\n i--;\n }\n }\n }\n }\n\n // Generate formatting template for this phone number format.\n var template = digits\n // Format the dummy phone number according to the format.\n .replace(new RegExp(pattern), numberFormat)\n // Replace each dummy digit with a DIGIT_PLACEHOLDER.\n .replace(new RegExp(DUMMY_DIGIT, 'g'), DIGIT_PLACEHOLDER);\n\n // If a prefix of a national (significant) number is not as simple\n // as just a basic national prefix, then just prepend such prefix\n // before the national (significant) number, optionally spacing\n // the two with a whitespace.\n if (!nationalPrefixIncludedInTemplate) {\n if (prefixBeforeNationalSignificantNumberThatIsNotNationalPrefix) {\n // Prepend the prefix to the template manually.\n template = repeat(DIGIT_PLACEHOLDER, prefixBeforeNationalSignificantNumberThatIsNotNationalPrefix.length) + ' ' + template;\n } else if (nationalPrefix) {\n // Prepend national prefix to the template manually.\n template = repeat(DIGIT_PLACEHOLDER, nationalPrefix.length) + this.getSeparatorAfterNationalPrefix(format) + template;\n }\n }\n if (international) {\n template = applyInternationalSeparatorStyle(template);\n }\n return template;\n }\n }, {\n key: \"formatNextNationalNumberDigits\",\n value: function formatNextNationalNumberDigits(digits) {\n var result = populateTemplateWithDigits(this.populatedNationalNumberTemplate, this.populatedNationalNumberTemplatePosition, digits);\n if (!result) {\n // Reset the format.\n this.resetFormat();\n return;\n }\n this.populatedNationalNumberTemplate = result[0];\n this.populatedNationalNumberTemplatePosition = result[1];\n\n // Return the formatted phone number so far.\n return cutAndStripNonPairedParens(this.populatedNationalNumberTemplate, this.populatedNationalNumberTemplatePosition + 1);\n\n // The old way which was good for `input-format` but is not so good\n // for `react-phone-number-input`'s default input (`InputBasic`).\n // return closeNonPairedParens(this.populatedNationalNumberTemplate, this.populatedNationalNumberTemplatePosition + 1)\n // \t.replace(new RegExp(DIGIT_PLACEHOLDER, 'g'), ' ')\n }\n }, {\n key: \"shouldTryNationalPrefixFormattingRule\",\n value: function shouldTryNationalPrefixFormattingRule(format, _ref5) {\n var international = _ref5.international,\n nationalPrefix = _ref5.nationalPrefix;\n if (format.nationalPrefixFormattingRule()) {\n // In some countries, `national_prefix_formatting_rule` is `($1)`,\n // so it applies even if the user hasn't input a national prefix.\n // `format.usesNationalPrefix()` detects such cases.\n var usesNationalPrefix = format.usesNationalPrefix();\n if (usesNationalPrefix && nationalPrefix || !usesNationalPrefix && !international) {\n return true;\n }\n }\n }\n }]);\n}();\nexport { AsYouTypeFormatter as default };\n//# sourceMappingURL=AsYouTypeFormatter.js.map","function _typeof(o) { \"@babel/helpers - typeof\"; return _typeof = \"function\" == typeof Symbol && \"symbol\" == typeof Symbol.iterator ? function (o) { return typeof o; } : function (o) { return o && \"function\" == typeof Symbol && o.constructor === Symbol && o !== Symbol.prototype ? \"symbol\" : typeof o; }, _typeof(o); }\nfunction _slicedToArray(r, e) { return _arrayWithHoles(r) || _iterableToArrayLimit(r, e) || _unsupportedIterableToArray(r, e) || _nonIterableRest(); }\nfunction _nonIterableRest() { throw new TypeError(\"Invalid attempt to destructure non-iterable instance.\\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.\"); }\nfunction _unsupportedIterableToArray(r, a) { if (r) { if (\"string\" == typeof r) return _arrayLikeToArray(r, a); var t = {}.toString.call(r).slice(8, -1); return \"Object\" === t && r.constructor && (t = r.constructor.name), \"Map\" === t || \"Set\" === t ? Array.from(r) : \"Arguments\" === t || /^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(t) ? _arrayLikeToArray(r, a) : void 0; } }\nfunction _arrayLikeToArray(r, a) { (null == a || a > r.length) && (a = r.length); for (var e = 0, n = Array(a); e < a; e++) n[e] = r[e]; return n; }\nfunction _iterableToArrayLimit(r, l) { var t = null == r ? null : \"undefined\" != typeof Symbol && r[Symbol.iterator] || r[\"@@iterator\"]; if (null != t) { var e, n, i, u, a = [], f = !0, o = !1; try { if (i = (t = t.call(r)).next, 0 === l) { if (Object(t) !== t) return; f = !1; } else for (; !(f = (e = i.call(t)).done) && (a.push(e.value), a.length !== l); f = !0); } catch (r) { o = !0, n = r; } finally { try { if (!f && null != t[\"return\"] && (u = t[\"return\"](), Object(u) !== u)) return; } finally { if (o) throw n; } } return a; } }\nfunction _arrayWithHoles(r) { if (Array.isArray(r)) return r; }\nfunction _classCallCheck(a, n) { if (!(a instanceof n)) throw new TypeError(\"Cannot call a class as a function\"); }\nfunction _defineProperties(e, r) { for (var t = 0; t < r.length; t++) { var o = r[t]; o.enumerable = o.enumerable || !1, o.configurable = !0, \"value\" in o && (o.writable = !0), Object.defineProperty(e, _toPropertyKey(o.key), o); } }\nfunction _createClass(e, r, t) { return r && _defineProperties(e.prototype, r), t && _defineProperties(e, t), Object.defineProperty(e, \"prototype\", { writable: !1 }), e; }\nfunction _toPropertyKey(t) { var i = _toPrimitive(t, \"string\"); return \"symbol\" == _typeof(i) ? i : i + \"\"; }\nfunction _toPrimitive(t, r) { if (\"object\" != _typeof(t) || !t) return t; var e = t[Symbol.toPrimitive]; if (void 0 !== e) { var i = e.call(t, r || \"default\"); if (\"object\" != _typeof(i)) return i; throw new TypeError(\"@@toPrimitive must return a primitive value.\"); } return (\"string\" === r ? String : Number)(t); }\nimport _extractCountryCallingCode from './helpers/extractCountryCallingCode.js';\nimport extractCountryCallingCodeFromInternationalNumberWithoutPlusSign from './helpers/extractCountryCallingCodeFromInternationalNumberWithoutPlusSign.js';\nimport extractNationalNumberFromPossiblyIncompleteNumber from './helpers/extractNationalNumberFromPossiblyIncompleteNumber.js';\nimport stripIddPrefix from './helpers/stripIddPrefix.js';\nimport parseDigits from './helpers/parseDigits.js';\nimport { VALID_DIGITS, VALID_PUNCTUATION, PLUS_CHARS } from './constants.js';\nvar VALID_FORMATTED_PHONE_NUMBER_DIGITS_PART = '[' + VALID_PUNCTUATION + VALID_DIGITS + ']+';\nvar VALID_FORMATTED_PHONE_NUMBER_DIGITS_PART_PATTERN = new RegExp('^' + VALID_FORMATTED_PHONE_NUMBER_DIGITS_PART + '$', 'i');\nvar VALID_FORMATTED_PHONE_NUMBER_PART = '(?:' + '[' + PLUS_CHARS + ']' + '[' + VALID_PUNCTUATION + VALID_DIGITS + ']*' + '|' + '[' + VALID_PUNCTUATION + VALID_DIGITS + ']+' + ')';\nvar AFTER_PHONE_NUMBER_DIGITS_END_PATTERN = new RegExp('[^' + VALID_PUNCTUATION + VALID_DIGITS + ']+' + '.*' + '$');\n\n// Tests whether `national_prefix_for_parsing` could match\n// different national prefixes.\n// Matches anything that's not a digit or a square bracket.\nvar COMPLEX_NATIONAL_PREFIX = /[^\\d\\[\\]]/;\nvar AsYouTypeParser = /*#__PURE__*/function () {\n function AsYouTypeParser(_ref) {\n var defaultCountry = _ref.defaultCountry,\n defaultCallingCode = _ref.defaultCallingCode,\n metadata = _ref.metadata,\n onNationalSignificantNumberChange = _ref.onNationalSignificantNumberChange;\n _classCallCheck(this, AsYouTypeParser);\n this.defaultCountry = defaultCountry;\n this.defaultCallingCode = defaultCallingCode;\n this.metadata = metadata;\n this.onNationalSignificantNumberChange = onNationalSignificantNumberChange;\n }\n return _createClass(AsYouTypeParser, [{\n key: \"input\",\n value: function input(text, state) {\n var _extractFormattedDigi = extractFormattedDigitsAndPlus(text),\n _extractFormattedDigi2 = _slicedToArray(_extractFormattedDigi, 2),\n formattedDigits = _extractFormattedDigi2[0],\n hasPlus = _extractFormattedDigi2[1];\n var digits = parseDigits(formattedDigits);\n // Checks for a special case: just a leading `+` has been entered.\n var justLeadingPlus;\n if (hasPlus) {\n if (!state.digits) {\n state.startInternationalNumber(undefined, undefined);\n if (!digits) {\n justLeadingPlus = true;\n }\n }\n }\n if (digits) {\n this.inputDigits(digits, state);\n }\n return {\n digits: digits,\n justLeadingPlus: justLeadingPlus\n };\n }\n\n /**\r\n * Inputs \"next\" phone number digits.\r\n * @param {string} digits\r\n * @return {string} [formattedNumber] Formatted national phone number (if it can be formatted at this stage). Returning `undefined` means \"don't format the national phone number at this stage\".\r\n */\n }, {\n key: \"inputDigits\",\n value: function inputDigits(nextDigits, state) {\n var digits = state.digits;\n var hasReceivedThreeLeadingDigits = digits.length < 3 && digits.length + nextDigits.length >= 3;\n\n // Append phone number digits.\n state.appendDigits(nextDigits);\n\n // Attempt to extract IDD prefix:\n // Some users input their phone number in international format,\n // but in an \"out-of-country\" dialing format instead of using the leading `+`.\n // https://github.com/catamphetamine/libphonenumber-js/issues/185\n // Detect such numbers as soon as there're at least 3 digits.\n // Google's library attempts to extract IDD prefix at 3 digits,\n // so this library just copies that behavior.\n // I guess that's because the most commot IDD prefixes are\n // `00` (Europe) and `011` (US).\n // There exist really long IDD prefixes too:\n // for example, in Australia the default IDD prefix is `0011`,\n // and it could even be as long as `14880011`.\n // An IDD prefix is extracted here, and then every time when\n // there's a new digit and the number couldn't be formatted.\n if (hasReceivedThreeLeadingDigits) {\n this.extractIddPrefix(state);\n }\n if (this.isWaitingForCountryCallingCode(state)) {\n if (!this.extractCountryCallingCode(state)) {\n return;\n }\n } else {\n state.appendNationalSignificantNumberDigits(nextDigits);\n }\n\n // If a phone number is being input in international format,\n // then it's not valid for it to have a national prefix.\n // Still, some people incorrectly input such numbers with a national prefix.\n // In such cases, only attempt to strip a national prefix if the number becomes too long.\n // (but that is done later, not here)\n if (!state.international) {\n if (!this.hasExtractedNationalSignificantNumber) {\n this.extractNationalSignificantNumber(state.getNationalDigits(), function (stateUpdate) {\n return state.update(stateUpdate);\n });\n }\n }\n }\n }, {\n key: \"isWaitingForCountryCallingCode\",\n value: function isWaitingForCountryCallingCode(_ref2) {\n var international = _ref2.international,\n callingCode = _ref2.callingCode;\n return international && !callingCode;\n }\n\n // Extracts a country calling code from a number\n // being entered in internatonal format.\n }, {\n key: \"extractCountryCallingCode\",\n value: function extractCountryCallingCode(state) {\n var _extractCountryCallin = _extractCountryCallingCode('+' + state.getDigitsWithoutInternationalPrefix(), state.country, this.defaultCountry, this.defaultCallingCode, this.metadata.metadata),\n countryCallingCode = _extractCountryCallin.countryCallingCode,\n number = _extractCountryCallin.number;\n if (countryCallingCode) {\n state.setCallingCode(countryCallingCode);\n state.update({\n nationalSignificantNumber: number\n });\n return true;\n }\n }\n }, {\n key: \"reset\",\n value: function reset(numberingPlan) {\n if (numberingPlan) {\n this.hasSelectedNumberingPlan = true;\n var nationalPrefixForParsing = numberingPlan._nationalPrefixForParsing();\n this.couldPossiblyExtractAnotherNationalSignificantNumber = nationalPrefixForParsing && COMPLEX_NATIONAL_PREFIX.test(nationalPrefixForParsing);\n } else {\n this.hasSelectedNumberingPlan = undefined;\n this.couldPossiblyExtractAnotherNationalSignificantNumber = undefined;\n }\n }\n\n /**\r\n * Extracts a national (significant) number from user input.\r\n * Google's library is different in that it only applies `national_prefix_for_parsing`\r\n * and doesn't apply `national_prefix_transform_rule` after that.\r\n * https://github.com/google/libphonenumber/blob/a3d70b0487875475e6ad659af404943211d26456/java/libphonenumber/src/com/google/i18n/phonenumbers/AsYouTypeFormatter.java#L539\r\n * @return {boolean} [extracted]\r\n */\n }, {\n key: \"extractNationalSignificantNumber\",\n value: function extractNationalSignificantNumber(nationalDigits, setState) {\n if (!this.hasSelectedNumberingPlan) {\n return;\n }\n var _extractNationalNumbe = extractNationalNumberFromPossiblyIncompleteNumber(nationalDigits, this.metadata),\n nationalPrefix = _extractNationalNumbe.nationalPrefix,\n nationalNumber = _extractNationalNumbe.nationalNumber,\n carrierCode = _extractNationalNumbe.carrierCode;\n if (nationalNumber === nationalDigits) {\n return;\n }\n this.onExtractedNationalNumber(nationalPrefix, carrierCode, nationalNumber, nationalDigits, setState);\n return true;\n }\n\n /**\r\n * In Google's code this function is called \"attempt to extract longer NDD\".\r\n * \"Some national prefixes are a substring of others\", they say.\r\n * @return {boolean} [result] — Returns `true` if extracting a national prefix produced different results from what they were.\r\n */\n }, {\n key: \"extractAnotherNationalSignificantNumber\",\n value: function extractAnotherNationalSignificantNumber(nationalDigits, prevNationalSignificantNumber, setState) {\n if (!this.hasExtractedNationalSignificantNumber) {\n return this.extractNationalSignificantNumber(nationalDigits, setState);\n }\n if (!this.couldPossiblyExtractAnotherNationalSignificantNumber) {\n return;\n }\n var _extractNationalNumbe2 = extractNationalNumberFromPossiblyIncompleteNumber(nationalDigits, this.metadata),\n nationalPrefix = _extractNationalNumbe2.nationalPrefix,\n nationalNumber = _extractNationalNumbe2.nationalNumber,\n carrierCode = _extractNationalNumbe2.carrierCode;\n // If a national prefix has been extracted previously,\n // then it's always extracted as additional digits are added.\n // That's assuming `extractNationalNumberFromPossiblyIncompleteNumber()`\n // doesn't do anything different from what it currently does.\n // So, just in case, here's this check, though it doesn't occur.\n /* istanbul ignore if */\n if (nationalNumber === prevNationalSignificantNumber) {\n return;\n }\n this.onExtractedNationalNumber(nationalPrefix, carrierCode, nationalNumber, nationalDigits, setState);\n return true;\n }\n }, {\n key: \"onExtractedNationalNumber\",\n value: function onExtractedNationalNumber(nationalPrefix, carrierCode, nationalSignificantNumber, nationalDigits, setState) {\n // Tells if the parsed national (significant) number is present as-is in the input string.\n // For example, when inputting \"0343515551212999\" Argentinian mobile number,\n // the parsed national (significant) number is \"93435551212999\".\n // There, one can see how it stripped \"0\" national prefix and prepended a \"9\",\n // because that's how it is instructed to do in Argentina's metadata.\n // So in the described example, the parsed national (significant) number is not present\n // as-is in the input string. Instead, it's \"modified\" in the input string.\n // https://gitlab.com/catamphetamine/libphonenumber-js/-/blob/master/METADATA.md#national_prefix_for_parsing--national_prefix_transform_rule\n var nationalSignificantNumberIsModified = false;\n\n // In some countries, a phone number could have a prefix that is not a \"national prefix\"\n // but rather some other type of \"utility\" prefix.\n // For example, when calling within Australia, one could prepend `1831` prefix to hide\n // caller's phone number.\n // https://gitlab.com/catamphetamine/libphonenumber-js/-/blob/master/METADATA.md#national_prefix_for_parsing--national_prefix_transform_rule\n var prefixBeforeNationalSignificantNumberThatIsNotNationalPrefix;\n\n // `nationalSignificantNumber` could be empty. In that case, `.lastIndexOf()` still works correctly.\n var nationalSignificantNumberIndex = nationalDigits.lastIndexOf(nationalSignificantNumber);\n\n // If the parsed national (significant) number is the last substring of the `nationalDigits`,\n // then it means that it's present as-is in the input string.\n // In any other case, the parsed national (significant) number is \"modified\" in the input string.\n if (nationalSignificantNumberIndex < 0 || nationalSignificantNumberIndex !== nationalDigits.length - nationalSignificantNumber.length) {\n nationalSignificantNumberIsModified = true;\n } else {\n var prefixBeforeNationalNumber = nationalDigits.slice(0, nationalSignificantNumberIndex);\n // When national (significant) number is equal to the `nationalDigits`,\n // this `onExtractedNationalNumber()` function simply doesn't get called.\n // This means that at this point, `prefixBeforeNationalNumber` is always non-empty.\n // Still, added this `if` check just to prevent potential silly bugs.\n // The `!prefixBeforeNationalNumber` case is not really testable\n // so this line is exluded from the code coverage.\n /* istanbul ignore if */\n if (prefixBeforeNationalNumber) {\n if (prefixBeforeNationalNumber !== nationalPrefix) {\n prefixBeforeNationalSignificantNumberThatIsNotNationalPrefix = prefixBeforeNationalNumber;\n }\n }\n }\n setState({\n nationalPrefix: nationalPrefix,\n carrierCode: carrierCode,\n nationalSignificantNumber: nationalSignificantNumber,\n nationalSignificantNumberIsModified: nationalSignificantNumberIsModified,\n prefixBeforeNationalSignificantNumberThatIsNotNationalPrefix: prefixBeforeNationalSignificantNumberThatIsNotNationalPrefix\n });\n // `onExtractedNationalNumber()` is only called when\n // the national (significant) number actually did change.\n this.hasExtractedNationalSignificantNumber = true;\n this.onNationalSignificantNumberChange();\n }\n }, {\n key: \"reExtractNationalSignificantNumber\",\n value: function reExtractNationalSignificantNumber(state) {\n // Attempt to extract a national prefix.\n //\n // Some people incorrectly input national prefix\n // in an international phone number.\n // For example, some people write British phone numbers as `+44(0)...`.\n //\n // Also, in some rare cases, it is valid for a national prefix\n // to be a part of an international phone number.\n // For example, mobile phone numbers in Mexico are supposed to be\n // dialled internationally using a `1` national prefix,\n // so the national prefix will be part of an international number.\n //\n // Quote from:\n // https://www.mexperience.com/dialing-cell-phones-in-mexico/\n //\n // \"Dialing a Mexican cell phone from abroad\n // When you are calling a cell phone number in Mexico from outside Mexico,\n // it’s necessary to dial an additional “1” after Mexico’s country code\n // (which is “52”) and before the area code.\n // You also ignore the 045, and simply dial the area code and the\n // cell phone’s number.\n //\n // If you don’t add the “1”, you’ll receive a recorded announcement\n // asking you to redial using it.\n //\n // For example, if you are calling from the USA to a cell phone\n // in Mexico City, you would dial +52 – 1 – 55 – 1234 5678.\n // (Note that this is different to calling a land line in Mexico City\n // from abroad, where the number dialed would be +52 – 55 – 1234 5678)\".\n //\n // Google's demo output:\n // https://libphonenumber.appspot.com/phonenumberparser?number=%2b5215512345678&country=MX\n //\n if (this.extractAnotherNationalSignificantNumber(state.getNationalDigits(), state.nationalSignificantNumber, function (stateUpdate) {\n return state.update(stateUpdate);\n })) {\n return true;\n }\n // If no format matches the phone number, then it could be\n // \"a really long IDD\" (quote from a comment in Google's library).\n // An IDD prefix is first extracted when the user has entered at least 3 digits,\n // and then here — every time when there's a new digit and the number\n // couldn't be formatted.\n // For example, in Australia the default IDD prefix is `0011`,\n // and it could even be as long as `14880011`.\n //\n // Could also check `!hasReceivedThreeLeadingDigits` here\n // to filter out the case when this check duplicates the one\n // already performed when there're 3 leading digits,\n // but it's not a big deal, and in most cases there\n // will be a suitable `format` when there're 3 leading digits.\n //\n if (this.extractIddPrefix(state)) {\n this.extractCallingCodeAndNationalSignificantNumber(state);\n return true;\n }\n // Google's AsYouType formatter supports sort of an \"autocorrection\" feature\n // when it \"autocorrects\" numbers that have been input for a country\n // with that country's calling code.\n // Such \"autocorrection\" feature looks weird, but different people have been requesting it:\n // https://github.com/catamphetamine/libphonenumber-js/issues/376\n // https://github.com/catamphetamine/libphonenumber-js/issues/375\n // https://github.com/catamphetamine/libphonenumber-js/issues/316\n if (this.fixMissingPlus(state)) {\n this.extractCallingCodeAndNationalSignificantNumber(state);\n return true;\n }\n }\n }, {\n key: \"extractIddPrefix\",\n value: function extractIddPrefix(state) {\n // An IDD prefix can't be present in a number written with a `+`.\n // Also, don't re-extract an IDD prefix if has already been extracted.\n var international = state.international,\n IDDPrefix = state.IDDPrefix,\n digits = state.digits,\n nationalSignificantNumber = state.nationalSignificantNumber;\n if (international || IDDPrefix) {\n return;\n }\n // Some users input their phone number in \"out-of-country\"\n // dialing format instead of using the leading `+`.\n // https://github.com/catamphetamine/libphonenumber-js/issues/185\n // Detect such numbers.\n var numberWithoutIDD = stripIddPrefix(digits, this.defaultCountry, this.defaultCallingCode, this.metadata.metadata);\n if (numberWithoutIDD !== undefined && numberWithoutIDD !== digits) {\n // If an IDD prefix was stripped then convert the IDD-prefixed number\n // to international number for subsequent parsing.\n state.update({\n IDDPrefix: digits.slice(0, digits.length - numberWithoutIDD.length)\n });\n this.startInternationalNumber(state, {\n country: undefined,\n callingCode: undefined\n });\n return true;\n }\n }\n }, {\n key: \"fixMissingPlus\",\n value: function fixMissingPlus(state) {\n if (!state.international) {\n var _extractCountryCallin2 = extractCountryCallingCodeFromInternationalNumberWithoutPlusSign(state.digits, state.country, this.defaultCountry, this.defaultCallingCode, this.metadata.metadata),\n newCallingCode = _extractCountryCallin2.countryCallingCode;\n if (newCallingCode) {\n state.update({\n missingPlus: true\n });\n this.startInternationalNumber(state, {\n country: state.country,\n callingCode: newCallingCode\n });\n return true;\n }\n }\n }\n }, {\n key: \"startInternationalNumber\",\n value: function startInternationalNumber(state, _ref3) {\n var country = _ref3.country,\n callingCode = _ref3.callingCode;\n state.startInternationalNumber(country, callingCode);\n // If a national (significant) number has been extracted before, reset it.\n if (state.nationalSignificantNumber) {\n state.resetNationalSignificantNumber();\n this.onNationalSignificantNumberChange();\n this.hasExtractedNationalSignificantNumber = undefined;\n }\n }\n }, {\n key: \"extractCallingCodeAndNationalSignificantNumber\",\n value: function extractCallingCodeAndNationalSignificantNumber(state) {\n if (this.extractCountryCallingCode(state)) {\n // `this.extractCallingCode()` is currently called when the number\n // couldn't be formatted during the standard procedure.\n // Normally, the national prefix would be re-extracted\n // for an international number if such number couldn't be formatted,\n // but since it's already not able to be formatted,\n // there won't be yet another retry, so also extract national prefix here.\n this.extractNationalSignificantNumber(state.getNationalDigits(), function (stateUpdate) {\n return state.update(stateUpdate);\n });\n }\n }\n }]);\n}();\n/**\r\n * Extracts formatted phone number from text (if there's any).\r\n * @param {string} text\r\n * @return {string} [formattedPhoneNumber]\r\n */\nexport { AsYouTypeParser as default };\nfunction extractFormattedPhoneNumber(text) {\n // Attempt to extract a possible number from the string passed in.\n var startsAt = text.search(VALID_FORMATTED_PHONE_NUMBER_PART);\n if (startsAt < 0) {\n return;\n }\n // Trim everything to the left of the phone number.\n text = text.slice(startsAt);\n // Trim the `+`.\n var hasPlus;\n if (text[0] === '+') {\n hasPlus = true;\n text = text.slice('+'.length);\n }\n // Trim everything to the right of the phone number.\n text = text.replace(AFTER_PHONE_NUMBER_DIGITS_END_PATTERN, '');\n // Re-add the previously trimmed `+`.\n if (hasPlus) {\n text = '+' + text;\n }\n return text;\n}\n\n/**\r\n * Extracts formatted phone number digits (and a `+`) from text (if there're any).\r\n * @param {string} text\r\n * @return {any[]}\r\n */\nfunction _extractFormattedDigitsAndPlus(text) {\n // Extract a formatted phone number part from text.\n var extractedNumber = extractFormattedPhoneNumber(text) || '';\n // Trim a `+`.\n if (extractedNumber[0] === '+') {\n return [extractedNumber.slice('+'.length), true];\n }\n return [extractedNumber];\n}\n\n/**\r\n * Extracts formatted phone number digits (and a `+`) from text (if there're any).\r\n * @param {string} text\r\n * @return {any[]}\r\n */\nexport function extractFormattedDigitsAndPlus(text) {\n var _extractFormattedDigi3 = _extractFormattedDigitsAndPlus(text),\n _extractFormattedDigi4 = _slicedToArray(_extractFormattedDigi3, 2),\n formattedDigits = _extractFormattedDigi4[0],\n hasPlus = _extractFormattedDigi4[1];\n // If the extracted phone number part\n // can possibly be a part of some valid phone number\n // then parse phone number characters from a formatted phone number.\n if (!VALID_FORMATTED_PHONE_NUMBER_DIGITS_PART_PATTERN.test(formattedDigits)) {\n formattedDigits = '';\n }\n return [formattedDigits, hasPlus];\n}\n//# sourceMappingURL=AsYouTypeParser.js.map","function _typeof(o) { \"@babel/helpers - typeof\"; return _typeof = \"function\" == typeof Symbol && \"symbol\" == typeof Symbol.iterator ? function (o) { return typeof o; } : function (o) { return o && \"function\" == typeof Symbol && o.constructor === Symbol && o !== Symbol.prototype ? \"symbol\" : typeof o; }, _typeof(o); }\nfunction _slicedToArray(r, e) { return _arrayWithHoles(r) || _iterableToArrayLimit(r, e) || _unsupportedIterableToArray(r, e) || _nonIterableRest(); }\nfunction _nonIterableRest() { throw new TypeError(\"Invalid attempt to destructure non-iterable instance.\\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.\"); }\nfunction _unsupportedIterableToArray(r, a) { if (r) { if (\"string\" == typeof r) return _arrayLikeToArray(r, a); var t = {}.toString.call(r).slice(8, -1); return \"Object\" === t && r.constructor && (t = r.constructor.name), \"Map\" === t || \"Set\" === t ? Array.from(r) : \"Arguments\" === t || /^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(t) ? _arrayLikeToArray(r, a) : void 0; } }\nfunction _arrayLikeToArray(r, a) { (null == a || a > r.length) && (a = r.length); for (var e = 0, n = Array(a); e < a; e++) n[e] = r[e]; return n; }\nfunction _iterableToArrayLimit(r, l) { var t = null == r ? null : \"undefined\" != typeof Symbol && r[Symbol.iterator] || r[\"@@iterator\"]; if (null != t) { var e, n, i, u, a = [], f = !0, o = !1; try { if (i = (t = t.call(r)).next, 0 === l) { if (Object(t) !== t) return; f = !1; } else for (; !(f = (e = i.call(t)).done) && (a.push(e.value), a.length !== l); f = !0); } catch (r) { o = !0, n = r; } finally { try { if (!f && null != t[\"return\"] && (u = t[\"return\"](), Object(u) !== u)) return; } finally { if (o) throw n; } } return a; } }\nfunction _arrayWithHoles(r) { if (Array.isArray(r)) return r; }\nfunction _classCallCheck(a, n) { if (!(a instanceof n)) throw new TypeError(\"Cannot call a class as a function\"); }\nfunction _defineProperties(e, r) { for (var t = 0; t < r.length; t++) { var o = r[t]; o.enumerable = o.enumerable || !1, o.configurable = !0, \"value\" in o && (o.writable = !0), Object.defineProperty(e, _toPropertyKey(o.key), o); } }\nfunction _createClass(e, r, t) { return r && _defineProperties(e.prototype, r), t && _defineProperties(e, t), Object.defineProperty(e, \"prototype\", { writable: !1 }), e; }\nfunction _toPropertyKey(t) { var i = _toPrimitive(t, \"string\"); return \"symbol\" == _typeof(i) ? i : i + \"\"; }\nfunction _toPrimitive(t, r) { if (\"object\" != _typeof(t) || !t) return t; var e = t[Symbol.toPrimitive]; if (void 0 !== e) { var i = e.call(t, r || \"default\"); if (\"object\" != _typeof(i)) return i; throw new TypeError(\"@@toPrimitive must return a primitive value.\"); } return (\"string\" === r ? String : Number)(t); }\nimport Metadata from './metadata.js';\nimport PhoneNumber from './PhoneNumber.js';\nimport checkNumberLength from './helpers/checkNumberLength.js';\nimport AsYouTypeState from './AsYouTypeState.js';\nimport AsYouTypeFormatter, { DIGIT_PLACEHOLDER } from './AsYouTypeFormatter.js';\nimport AsYouTypeParser, { extractFormattedDigitsAndPlus } from './AsYouTypeParser.js';\nimport getCountryByCallingCode from './helpers/getCountryByCallingCode.js';\nimport getCountryByNationalNumber from './helpers/getCountryByNationalNumber.js';\nimport isObject from './helpers/isObject.js';\nvar USE_NON_GEOGRAPHIC_COUNTRY_CODE = false;\nvar AsYouType = /*#__PURE__*/function () {\n /**\r\n * @param {(string|object)?} [optionsOrDefaultCountry] - The default country used for parsing non-international phone numbers. Can also be an `options` object.\r\n * @param {Object} metadata\r\n */\n function AsYouType(optionsOrDefaultCountry, metadata) {\n _classCallCheck(this, AsYouType);\n // Metadata instance is created once and stays constant.\n // This is required because other utility classes such as `AsYouTypeFormatter`\n // will use this metadata instance \"reference\" and will assume that it stays constant.\n this.metadata = new Metadata(metadata);\n var _this$getCountryAndCa = this.getCountryAndCallingCode(optionsOrDefaultCountry),\n _this$getCountryAndCa2 = _slicedToArray(_this$getCountryAndCa, 2),\n defaultCountry = _this$getCountryAndCa2[0],\n defaultCallingCode = _this$getCountryAndCa2[1];\n // `this.defaultCountry` and `this.defaultCallingCode` aren't required to be in sync.\n // For example, `this.defaultCountry` could be `\"AR\"` and `this.defaultCallingCode` could be `undefined`.\n // So `this.defaultCountry` and `this.defaultCallingCode` are totally independent.\n this.defaultCountry = defaultCountry;\n this.defaultCallingCode = defaultCallingCode;\n this.reset();\n }\n return _createClass(AsYouType, [{\n key: \"getCountryAndCallingCode\",\n value: function getCountryAndCallingCode(optionsOrDefaultCountry) {\n // Set `defaultCountry` and `defaultCallingCode` options.\n var defaultCountry;\n var defaultCallingCode;\n // Turns out `null` also has type \"object\". Weird.\n if (optionsOrDefaultCountry) {\n if (isObject(optionsOrDefaultCountry)) {\n defaultCountry = optionsOrDefaultCountry.defaultCountry;\n defaultCallingCode = optionsOrDefaultCountry.defaultCallingCode;\n } else {\n defaultCountry = optionsOrDefaultCountry;\n }\n }\n if (defaultCountry && !this.metadata.hasCountry(defaultCountry)) {\n defaultCountry = undefined;\n }\n if (defaultCallingCode) {\n /* istanbul ignore if */\n if (USE_NON_GEOGRAPHIC_COUNTRY_CODE) {\n if (this.metadata.isNonGeographicCallingCode(defaultCallingCode)) {\n defaultCountry = '001';\n }\n }\n }\n return [defaultCountry, defaultCallingCode];\n }\n\n /**\r\n * Inputs \"next\" phone number characters.\r\n * @param {string} text\r\n * @return {string} Formatted phone number characters that have been input so far.\r\n */\n }, {\n key: \"input\",\n value: function input(text) {\n var _this$parser$input = this.parser.input(text, this.state),\n digits = _this$parser$input.digits,\n justLeadingPlus = _this$parser$input.justLeadingPlus;\n if (justLeadingPlus) {\n this.formattedOutput = '+';\n } else if (digits) {\n this.determineTheCountryIfNeeded();\n // Match the available formats by the currently available leading digits.\n if (this.state.nationalSignificantNumber) {\n this.formatter.narrowDownMatchingFormats(this.state);\n }\n var formattedNationalNumber;\n if (this.metadata.hasSelectedNumberingPlan()) {\n formattedNationalNumber = this.formatter.format(digits, this.state);\n }\n if (formattedNationalNumber === undefined) {\n // See if another national (significant) number could be re-extracted.\n if (this.parser.reExtractNationalSignificantNumber(this.state)) {\n this.determineTheCountryIfNeeded();\n // If it could, then re-try formatting the new national (significant) number.\n var nationalDigits = this.state.getNationalDigits();\n if (nationalDigits) {\n formattedNationalNumber = this.formatter.format(nationalDigits, this.state);\n }\n }\n }\n this.formattedOutput = formattedNationalNumber ? this.getFullNumber(formattedNationalNumber) : this.getNonFormattedNumber();\n }\n return this.formattedOutput;\n }\n }, {\n key: \"reset\",\n value: function reset() {\n var _this = this;\n this.state = new AsYouTypeState({\n onCountryChange: function onCountryChange(country) {\n // Before version `1.6.0`, the official `AsYouType` formatter API\n // included a `.country` property on an `AsYouType` instance.\n // Since that property (along with the others) have been moved to\n // `this.state`, `this.country` property is emulated for compatibility\n // with the old versions.\n _this.country = country;\n },\n onCallingCodeChange: function onCallingCodeChange(callingCode, country) {\n _this.metadata.selectNumberingPlan(country || callingCode);\n _this.formatter.reset(_this.metadata.numberingPlan, _this.state);\n _this.parser.reset(_this.metadata.numberingPlan);\n }\n });\n this.formatter = new AsYouTypeFormatter({\n state: this.state,\n metadata: this.metadata\n });\n this.parser = new AsYouTypeParser({\n defaultCountry: this.defaultCountry,\n defaultCallingCode: this.defaultCallingCode,\n metadata: this.metadata,\n state: this.state,\n onNationalSignificantNumberChange: function onNationalSignificantNumberChange() {\n _this.determineTheCountryIfNeeded();\n _this.formatter.reset(_this.metadata.numberingPlan, _this.state);\n }\n });\n this.state.reset({\n country: this.defaultCountry,\n callingCode: this.defaultCallingCode\n });\n this.formattedOutput = '';\n return this;\n }\n\n /**\r\n * Returns `true` if the phone number is being input in international format.\r\n * In other words, returns `true` if and only if the parsed phone number starts with a `\"+\"`.\r\n * @return {boolean}\r\n */\n }, {\n key: \"isInternational\",\n value: function isInternational() {\n return this.state.international;\n }\n\n /**\r\n * Returns the \"calling code\" part of the phone number when it's being input\r\n * in an international format.\r\n * If no valid calling code has been entered so far, returns `undefined`.\r\n * @return {string} [callingCode]\r\n */\n }, {\n key: \"getCallingCode\",\n value: function getCallingCode() {\n // If the number is being input in national format and some \"default calling code\"\n // has been passed to `AsYouType` constructor, then `this.state.callingCode`\n // is equal to that \"default calling code\".\n //\n // If the number is being input in national format and no \"default calling code\"\n // has been passed to `AsYouType` constructor, then returns `undefined`,\n // even if a \"default country\" has been passed to `AsYouType` constructor.\n //\n if (this.isInternational()) {\n return this.state.callingCode;\n }\n }\n\n // A legacy alias.\n }, {\n key: \"getCountryCallingCode\",\n value: function getCountryCallingCode() {\n return this.getCallingCode();\n }\n\n /**\r\n * Returns a two-letter country code of the phone number.\r\n * Returns `undefined` for \"non-geographic\" phone numbering plans.\r\n * Returns `undefined` if no phone number has been input yet.\r\n * @return {string} [country]\r\n */\n }, {\n key: \"getCountry\",\n value: function getCountry() {\n var digits = this.state.digits;\n // Return `undefined` if no digits have been input yet.\n if (digits) {\n return this._getCountry();\n }\n }\n\n /**\r\n * Returns a two-letter country code of the phone number.\r\n * Returns `undefined` for \"non-geographic\" phone numbering plans.\r\n * @return {string} [country]\r\n */\n }, {\n key: \"_getCountry\",\n value: function _getCountry() {\n var country = this.state.country;\n /* istanbul ignore if */\n if (USE_NON_GEOGRAPHIC_COUNTRY_CODE) {\n // `AsYouType.getCountry()` returns `undefined`\n // for \"non-geographic\" phone numbering plans.\n if (country === '001') {\n return;\n }\n }\n return country;\n }\n }, {\n key: \"determineTheCountryIfNeeded\",\n value: function determineTheCountryIfNeeded() {\n // Suppose a user enters a phone number in international format,\n // and there're several countries corresponding to that country calling code,\n // and a country has been derived from the number, and then\n // a user enters one more digit and the number is no longer\n // valid for the derived country, so the country should be re-derived\n // on every new digit in those cases.\n //\n // If the phone number is being input in national format,\n // then it could be a case when `defaultCountry` wasn't specified\n // when creating `AsYouType` instance, and just `defaultCallingCode` was specified,\n // and that \"calling code\" could correspond to a \"non-geographic entity\",\n // or there could be several countries corresponding to that country calling code.\n // In those cases, `this.country` is `undefined` and should be derived\n // from the number. Again, if country calling code is ambiguous, then\n // `this.country` should be re-derived with each new digit.\n //\n if (!this.state.country || this.isCountryCallingCodeAmbiguous()) {\n this.determineTheCountry();\n }\n }\n\n // Prepends `+CountryCode ` in case of an international phone number\n }, {\n key: \"getFullNumber\",\n value: function getFullNumber(formattedNationalNumber) {\n var _this2 = this;\n if (this.isInternational()) {\n var prefix = function prefix(text) {\n return _this2.formatter.getInternationalPrefixBeforeCountryCallingCode(_this2.state, {\n spacing: text ? true : false\n }) + text;\n };\n var callingCode = this.state.callingCode;\n if (!callingCode) {\n return prefix(\"\".concat(this.state.getDigitsWithoutInternationalPrefix()));\n }\n if (!formattedNationalNumber) {\n return prefix(callingCode);\n }\n return prefix(\"\".concat(callingCode, \" \").concat(formattedNationalNumber));\n }\n return formattedNationalNumber;\n }\n }, {\n key: \"getNonFormattedNationalNumberWithPrefix\",\n value: function getNonFormattedNationalNumberWithPrefix() {\n var _this$state = this.state,\n nationalSignificantNumber = _this$state.nationalSignificantNumber,\n prefixBeforeNationalSignificantNumberThatIsNotNationalPrefix = _this$state.prefixBeforeNationalSignificantNumberThatIsNotNationalPrefix,\n nationalPrefix = _this$state.nationalPrefix;\n var number = nationalSignificantNumber;\n var prefix = prefixBeforeNationalSignificantNumberThatIsNotNationalPrefix || nationalPrefix;\n if (prefix) {\n number = prefix + number;\n }\n return number;\n }\n }, {\n key: \"getNonFormattedNumber\",\n value: function getNonFormattedNumber() {\n var nationalSignificantNumberIsModified = this.state.nationalSignificantNumberIsModified;\n return this.getFullNumber(nationalSignificantNumberIsModified ? this.state.getNationalDigits() : this.getNonFormattedNationalNumberWithPrefix());\n }\n }, {\n key: \"getNonFormattedTemplate\",\n value: function getNonFormattedTemplate() {\n var number = this.getNonFormattedNumber();\n if (number) {\n return number.replace(/[\\+\\d]/g, DIGIT_PLACEHOLDER);\n }\n }\n }, {\n key: \"isCountryCallingCodeAmbiguous\",\n value: function isCountryCallingCodeAmbiguous() {\n var callingCode = this.state.callingCode;\n var countryCodes = this.metadata.getCountryCodesForCallingCode(callingCode);\n return countryCodes && countryCodes.length > 1;\n }\n\n // Determines the exact country of the phone number\n // entered so far based on the country phone code\n // and the national phone number.\n }, {\n key: \"determineTheCountry\",\n value: function determineTheCountry() {\n // Get a more precise country code for this national number.\n // It is possible that the precise country couldn't be determined\n // in cases when there're multiple countries sharing the same calling code.\n // In that case, `country` will be `undefined`.\n var country = getCountryByCallingCode(this.isInternational() ? this.state.callingCode : this.defaultCallingCode, {\n nationalNumber: this.state.nationalSignificantNumber,\n metadata: this.metadata\n });\n // If the derived country is indeed more precise,\n // or if no country could be derived for the updated phone number.\n if (country !== this.state.country) {\n // Set (or reset) the more precise country.\n this.state.setCountry(country);\n // If a more precise country could be derived.\n if (country) {\n // Select a more precise telephone numbering plan.\n // For example, consider that `AsYouType` instance was created with `defaultCountry: \"US\"` argument.\n // In that case, the metadata instance will be using \"US\" metadata.\n // But then the user could input a Canadian phone number, in which case\n // the metadata instance should be switched to Canadian telephone numbering plan.\n // It is required to do that because later `canFormatCompleteNumber()` function will be called,\n // and that function relies on the precise country being pre-selected in the metadata instance.\n // Or, for example, `checkNumberLength()` function also relies on same thing.\n this.metadata.selectNumberingPlan(country);\n }\n }\n }\n\n /**\r\n * Returns a E.164 phone number value for the user's input.\r\n *\r\n * For example, for country `\"US\"` and input `\"(222) 333-4444\"`\r\n * it will return `\"+12223334444\"`.\r\n *\r\n * For international phone number input, it will also auto-correct\r\n * some minor errors such as using a national prefix when writing\r\n * an international phone number. For example, if the user inputs\r\n * `\"+44 0 7400 000000\"` then it will return an auto-corrected\r\n * `\"+447400000000\"` phone number value.\r\n *\r\n * Will return `undefined` if no digits have been input,\r\n * or when inputting a phone number in national format and no\r\n * default country or default \"country calling code\" have been set.\r\n *\r\n * @return {string} [value]\r\n */\n }, {\n key: \"getNumberValue\",\n value: function getNumberValue() {\n var _this$state2 = this.state,\n digits = _this$state2.digits,\n callingCode = _this$state2.callingCode,\n country = _this$state2.country,\n nationalSignificantNumber = _this$state2.nationalSignificantNumber;\n\n // Will return `undefined` if no digits have been input.\n if (!digits) {\n return;\n }\n if (this.isInternational()) {\n if (callingCode) {\n return '+' + callingCode + nationalSignificantNumber;\n } else {\n return '+' + digits;\n }\n } else {\n if (country || callingCode) {\n var callingCode_ = country ? this.metadata.countryCallingCode() : callingCode;\n return '+' + callingCode_ + nationalSignificantNumber;\n }\n }\n }\n\n /**\r\n * Returns an instance of `PhoneNumber` class.\r\n * Will return `undefined` if no national (significant) number\r\n * digits have been entered so far, or if no `defaultCountry` has been\r\n * set and the user enters a phone number not in international format.\r\n */\n }, {\n key: \"getNumber\",\n value: function getNumber() {\n var _this$state3 = this.state,\n nationalSignificantNumber = _this$state3.nationalSignificantNumber,\n carrierCode = _this$state3.carrierCode,\n callingCode = _this$state3.callingCode;\n if (!nationalSignificantNumber) {\n return;\n }\n\n // `this._getCountry()` is basically same as `this.state.country`\n // with the only change that it returns `undefined` in case of a\n // \"non-geographic\" numbering plan instead of `\"001\"` \"internal use\" value.\n var country = this._getCountry();\n\n // Sidenote:\n // `state.callingCode` and `state.country` are somewhat independent from one another\n // and there could be situations when one is defined but the other is not.\n // See the comment in `AsYouTypeState.js` for more info on when that is possible.\n\n if (!country && !callingCode) {\n return;\n }\n\n // By default, if `defaultCountry` parameter was passed when\n // creating `AsYouType` instance, `state.country` is gonna be\n // that `defaultCountry`, which doesn't entirely conform with\n // `parsePhoneNumber()`'s behavior where it attempts to determine\n // the country more precisely in cases when multiple countries\n // could correspond to the same `countryCallingCode`.\n // https://gitlab.com/catamphetamine/libphonenumber-js/-/issues/103#note_1417192969\n //\n // Because `AsYouType.getNumber()` method is supposed to be a 1:1\n // equivalent for `parsePhoneNumber(AsYouType.getNumberValue())`,\n // it means that it should also behave accordingly in such cases of `country` ambiguity.\n // That's how users of this library would expect it to behave anyway.\n //\n // So here it checks if `state.country` is same as the `defaultCountry`,\n // and if it is, it attempts to get rid of any potential ambiguity.\n //\n if (country) {\n if (country === this.defaultCountry) {\n // // Create a `Metadata` instance just to get the calling code of the `country`.\n // const metadata = new Metadata(this.metadata.metadata)\n // // `state.callingCode` and `state.country` are somewhat independent from one another\n // // and there could be situations when one is defined but the other is not.\n // // See the comment in `AsYouTypeState.js` for more info on when that is possible.\n // // Here, it only passes `state.country` because there's no need to pass `state.callingCode`\n // // because `state.country` is known to be defined.\n // metadata.selectNumberingPlan(country)\n // const countryCallingCode = metadata.numberingPlan.callingCode()\n\n // Instead of getting `countryCallingCode` value above,\n // it could simply read it from the existing metadata instance.\n var countryCallingCode = this.metadata.numberingPlan.callingCode();\n\n // Attempt to rule out any potential country code ambiguity, if present.\n var exactCountry = getExactCountryForMultiCountryCallingCode(countryCallingCode, nationalSignificantNumber, this.metadata);\n if (exactCountry) {\n country = exactCountry;\n }\n }\n }\n var phoneNumber = new PhoneNumber(country || callingCode, nationalSignificantNumber, this.metadata.metadata);\n if (carrierCode) {\n phoneNumber.carrierCode = carrierCode;\n }\n // Phone number extensions are not supported by \"As You Type\" formatter.\n return phoneNumber;\n }\n\n /**\r\n * Returns `true` if the phone number is \"possible\".\r\n * Is just a shortcut for `PhoneNumber.isPossible()`.\r\n * @return {boolean}\r\n */\n }, {\n key: \"isPossible\",\n value: function isPossible() {\n var phoneNumber = this.getNumber();\n if (!phoneNumber) {\n return false;\n }\n return phoneNumber.isPossible();\n }\n\n /**\r\n * Returns `true` if the phone number is \"valid\".\r\n * Is just a shortcut for `PhoneNumber.isValid()`.\r\n * @return {boolean}\r\n */\n }, {\n key: \"isValid\",\n value: function isValid() {\n var phoneNumber = this.getNumber();\n if (!phoneNumber) {\n return false;\n }\n return phoneNumber.isValid();\n }\n\n /**\r\n * Checks if the phone number length is valid.\r\n * If it is, nothing is returned.\r\n * Otherwise, a rejection reason is returned.\r\n * @return {string?}\r\n */\n }, {\n key: \"validateLength\",\n value: function validateLength() {\n var _this$state4 = this.state,\n digits = _this$state4.digits,\n nationalSignificantNumber = _this$state4.nationalSignificantNumber;\n if (!digits) {\n return 'NOT_A_NUMBER';\n }\n if (!this.metadata.numberingPlan) {\n return 'INVALID_COUNTRY';\n }\n if (!nationalSignificantNumber) {\n return 'TOO_SHORT';\n }\n\n // `state.callingCode` and `state.country` are somewhat independent from one another\n // and there could be situations when one is defined but the other is not.\n // See the comment in `AsYouTypeState.js` for more info on when that is possible.\n // Here, it uses both: if `country` is defined then it will use that,\n // otherwise it will use `callingCode`.\n var result = checkNumberLength(nationalSignificantNumber, undefined, this.metadata);\n if (result !== 'IS_POSSIBLE') {\n return result;\n }\n }\n\n /**\r\n * @deprecated\r\n * This method is used in `react-phone-number-input/source/input-control.js`\r\n * in versions before `3.0.16`.\r\n */\n }, {\n key: \"getNationalNumber\",\n value: function getNationalNumber() {\n return this.state.nationalSignificantNumber;\n }\n\n /**\r\n * Returns the phone number characters entered by the user.\r\n * @return {string}\r\n */\n }, {\n key: \"getChars\",\n value: function getChars() {\n return (this.state.international ? '+' : '') + this.state.digits;\n }\n\n /**\r\n * Returns the template for the formatted phone number.\r\n * @return {string}\r\n */\n }, {\n key: \"getTemplate\",\n value: function getTemplate() {\n return this.formatter.getTemplate(this.state) || this.getNonFormattedTemplate() || '';\n }\n }]);\n}(); // In situations when multiple countries use the same calling code,\n// this function tells what exact country does a given national (significant) number belong to.\nexport { AsYouType as default };\nfunction getExactCountryForMultiCountryCallingCode(callingCode, nationalSignificantNumber, metadata) {\n var ambiguousCountries = metadata.getCountryCodesForCallingCode(callingCode);\n if (ambiguousCountries.length > 1) {\n return getCountryByNationalNumber(nationalSignificantNumber, ambiguousCountries, metadata.metadata);\n }\n}\n//# sourceMappingURL=AsYouType.js.map","import withMetadataArgument from './withMetadataArgument.js'\r\nimport { parsePhoneNumberWithError as _parsePhoneNumberWithError } from '../../core/index.js'\r\n\r\nexport function parsePhoneNumberWithError() {\r\n\treturn withMetadataArgument(_parsePhoneNumberWithError, arguments)\r\n}\r\n","import withMetadataArgument from './withMetadataArgument.js'\r\nimport { isValidPhoneNumber as _isValidPhoneNumber } from '../../core/index.js'\r\n\r\nexport function isValidPhoneNumber() {\r\n\treturn withMetadataArgument(_isValidPhoneNumber, arguments)\r\n}","// Importing from a \".js\" file is a workaround for Node.js \"ES Modules\"\r\n// importing system which is even uncapable of importing \"*.json\" files.\r\nimport metadata from '../../metadata.min.json.js'\r\n\r\nimport { AsYouType as _AsYouType } from '../../core/index.js'\r\n\r\nexport function AsYouType(country) {\r\n\treturn _AsYouType.call(this, country, metadata)\r\n}\r\n\r\nAsYouType.prototype = Object.create(_AsYouType.prototype, {})\r\nAsYouType.prototype.constructor = AsYouType","/**\n * A tiny, safe-by-default Markdown → HTML renderer for the chat widget.\n *\n * ## Why a hand-rolled renderer (and not markdown-it / snarkdown)?\n *\n * The widget renders **untrusted** text in two places: the assistant's reply\n * (LLM output, which can echo attacker-supplied content) and citation snippets\n * (raw scraped page chunks). Today both are written via `textContent`, so\n * `**bold**`, numbered lists, and `[links](url)` show up literally. We want\n * them rendered — without re-opening the XSS hole that `textContent` was\n * guarding against.\n *\n * markdown-it with `html:false` is safe-by-default but ships ~30 kB min into\n * what is an embeddable **global** bundle, where every kilobyte is on the host\n * page's critical path. snarkdown is ~1 kB but emits raw HTML, so it would\n * require bolting on a separate sanitizer. Instead, this renderer is\n * **safe-by-construction**:\n *\n * 1. It is a *tokenizer*, not an HTML passthrough. It only ever emits a\n * fixed allowlist of tags (`p`, `br`, `strong`, `em`, `ul`/`ol`/`li`,\n * `code`/`pre`, `a`, `blockquote`). There is no code path that copies a\n * tag out of the input — a literal `<script>` in the input is treated as\n * plain text.\n * 2. **Every** text run is HTML-escaped via {@link escapeHtml} before it\n * reaches the output. Raw `<`, `>`, `&`, `\"`, `'` can never become markup.\n * 3. **Images are dropped entirely** — `` renders as its alt text,\n * no `<img>` is ever produced (a scraped tracking pixel must not load).\n * 4. **Links** are gated through {@link safeHttpUrl}: only absolute `http(s)`\n * URLs become anchors (with `target=\"_blank\"` + a hardened `rel`);\n * `javascript:`/`data:`/relative/etc. fall back to plain (escaped) text.\n * 5. **Headings** (`#`..`######`) are *downgraded* to bold lines — a full\n * `<h1>` is far too large inside a chat bubble or citation card.\n *\n * The output is a string of HTML that is only ever assigned to `innerHTML` of\n * an element the caller controls; because of (1)–(4) it can only contain the\n * allowlisted, attribute-sanitized tags.\n *\n * Supported subset (deliberately small):\n * - Paragraphs (blank-line separated) and hard/soft line breaks\n * - `**bold**` / `__bold__`, `*italic*` / `_italic_`\n * - `` `inline code` `` and fenced ``` ```code blocks``` ```\n * - `- ` / `* ` / `+ ` unordered lists, `1.` ordered lists\n * - `> ` blockquotes\n * - `[text](http(s)://url)` links (images dropped to alt text)\n * - `#`..`######` headings → bold line\n */\n\n/** Escape the five HTML-significant characters so a text run can never be markup. */\nexport function escapeHtml(value: string): string {\n return value.replace(/[&<>\"']/g, (c) => {\n switch (c) {\n case '&':\n return '&';\n case '<':\n return '<';\n case '>':\n return '>';\n case '\"':\n return '"';\n default:\n return ''';\n }\n });\n}\n\n/**\n * Return `url` only if it is a valid absolute `http(s)` URL, else `null`.\n *\n * SECURITY: link targets here originate from untrusted content (LLM output /\n * scraped citation chunks). Allowing an arbitrary string as an `href` permits\n * `javascript:`/`data:`/`vbscript:` URLs that execute on click — a stored-XSS\n * vector. Only absolute http(s) links are rendered as anchors; anything else\n * falls back to plain text upstream.\n */\nexport function safeHttpUrl(url: string | undefined | null): string | null {\n if (!url) return null;\n try {\n const parsed = new URL(url);\n return parsed.protocol === 'http:' || parsed.protocol === 'https:' ? parsed.href : null;\n } catch {\n return null;\n }\n}\n\n// ───────────────────────────── Inline rendering ─────────────────────────────\n\n/**\n * Render the inline span grammar of a single line/segment to safe HTML.\n *\n * Order matters: code spans are extracted first (their contents are *not*\n * further parsed), then images are stripped to alt text, then links, then\n * emphasis. Every literal text run is escaped on the way out.\n */\nfunction renderInline(input: string): string {\n let out = '';\n let i = 0;\n const n = input.length;\n\n // Accumulate escaped literal text, flushing on each recognized token.\n let buf = '';\n const flush = () => {\n if (buf) {\n out += escapeHtml(buf);\n buf = '';\n }\n };\n\n while (i < n) {\n const ch = input[i]!;\n\n // Inline code: `...` — contents are literal (escaped), no nested parsing.\n if (ch === '`') {\n const end = input.indexOf('`', i + 1);\n if (end > i) {\n flush();\n out += `<code>${escapeHtml(input.slice(i + 1, end))}</code>`;\n i = end + 1;\n continue;\n }\n }\n\n // Image:  — DROPPED. Emit only the (escaped) alt text; never\n // produce an <img> (a scraped tracking pixel must not load).\n if (ch === '!' && input[i + 1] === '[') {\n const m = imageAt(input, i);\n if (m) {\n flush();\n out += renderInline(m.alt); // alt may itself contain emphasis\n i = m.end;\n continue;\n }\n }\n\n // Link: [text](href)\n if (ch === '[') {\n const m = linkAt(input, i);\n if (m) {\n flush();\n const safe = safeHttpUrl(m.href);\n const inner = renderInline(m.text);\n if (safe) {\n out += `<a href=\"${escapeHtml(safe)}\" target=\"_blank\" rel=\"noopener noreferrer nofollow\">${inner}</a>`;\n } else {\n // Unsafe scheme → render as plain (already-escaped) text, no anchor.\n out += inner;\n }\n i = m.end;\n continue;\n }\n }\n\n // Bold: **...** or __...__\n if ((ch === '*' && input[i + 1] === '*') || (ch === '_' && input[i + 1] === '_')) {\n const marker = ch + ch;\n const end = input.indexOf(marker, i + 2);\n if (end > i + 1) {\n flush();\n out += `<strong>${renderInline(input.slice(i + 2, end))}</strong>`;\n i = end + 2;\n continue;\n }\n }\n\n // Italic: *...* or _..._ (single marker, non-empty, not touching the other marker)\n if (ch === '*' || ch === '_') {\n const end = input.indexOf(ch, i + 1);\n if (end > i + 1 && input[i + 1] !== ch) {\n flush();\n out += `<em>${renderInline(input.slice(i + 1, end))}</em>`;\n i = end + 1;\n continue;\n }\n }\n\n buf += ch;\n i++;\n }\n\n flush();\n return out;\n}\n\n/** Parse a `[text](href)` link starting at `start` (`input[start] === '['`). */\nfunction linkAt(input: string, start: number): { text: string; href: string; end: number } | null {\n const close = matchBracket(input, start);\n if (close < 0 || input[close + 1] !== '(') return null;\n const paren = input.indexOf(')', close + 2);\n if (paren < 0) return null;\n const text = input.slice(start + 1, close);\n // href is the first whitespace-delimited token inside (...) — ignore any\n // markdown \"title\" portion; we never render titles.\n const href = input.slice(close + 2, paren).trim().split(/\\s+/)[0] ?? '';\n return { text, href, end: paren + 1 };\n}\n\n/** Parse a `` image starting at `start` (`input[start] === '!'`). */\nfunction imageAt(input: string, start: number): { alt: string; end: number } | null {\n const link = linkAt(input, start + 1);\n if (!link) return null;\n return { alt: link.text, end: link.end };\n}\n\n/** Find the matching `]` for a `[` at `open`, honoring one level of nesting. */\nfunction matchBracket(input: string, open: number): number {\n let depth = 0;\n for (let i = open; i < input.length; i++) {\n const c = input[i];\n if (c === '[') depth++;\n else if (c === ']') {\n depth--;\n if (depth === 0) return i;\n }\n }\n return -1;\n}\n\n// ───────────────────────────── Block rendering ──────────────────────────────\n\nconst UL_RE = /^\\s*[-*+]\\s+(.*)$/;\nconst OL_RE = /^\\s*\\d+[.)]\\s+(.*)$/;\nconst HEADING_RE = /^\\s{0,3}(#{1,6})\\s+(.*)$/;\nconst QUOTE_RE = /^\\s*>\\s?(.*)$/;\nconst FENCE_RE = /^\\s*(`{3,}|~{3,})\\s*(.*)$/;\n\n/**\n * Render a full Markdown string to safe HTML.\n *\n * @returns a string containing only the allowlisted tags described in the\n * module doc. Safe to assign to `innerHTML` of a caller-owned element.\n */\nexport function renderMarkdown(src: string): string {\n const lines = src.replace(/\\r\\n?/g, '\\n').split('\\n');\n const out: string[] = [];\n\n let i = 0;\n while (i < lines.length) {\n const line = lines[i]!;\n\n // Fenced code block: ```lang ... ```\n const fence = FENCE_RE.exec(line);\n if (fence) {\n const marker = fence[1]!;\n const body: string[] = [];\n i++;\n while (i < lines.length && !lines[i]!.trimStart().startsWith(marker)) {\n body.push(lines[i]!);\n i++;\n }\n if (i < lines.length) i++; // consume closing fence\n out.push(`<pre><code>${escapeHtml(body.join('\\n'))}</code></pre>`);\n continue;\n }\n\n // Blank line → paragraph boundary.\n if (line.trim() === '') {\n i++;\n continue;\n }\n\n // Heading → downgraded to a bold line (an <h1> is too big in a bubble).\n const heading = HEADING_RE.exec(line);\n if (heading) {\n out.push(`<p><strong>${renderInline(heading[2]!)}</strong></p>`);\n i++;\n continue;\n }\n\n // Unordered / ordered list — consume the contiguous run.\n if (UL_RE.test(line) || OL_RE.test(line)) {\n const ordered = OL_RE.test(line) && !UL_RE.test(line);\n const re = ordered ? OL_RE : UL_RE;\n const items: string[] = [];\n while (i < lines.length) {\n const m = re.exec(lines[i]!);\n if (!m) break;\n items.push(`<li>${renderInline(m[1]!)}</li>`);\n i++;\n }\n out.push(`<${ordered ? 'ol' : 'ul'}>${items.join('')}</${ordered ? 'ol' : 'ul'}>`);\n continue;\n }\n\n // Blockquote — consume the contiguous run.\n if (QUOTE_RE.test(line)) {\n const quoted: string[] = [];\n while (i < lines.length) {\n const m = QUOTE_RE.exec(lines[i]!);\n if (!m) break;\n quoted.push(m[1]!);\n i++;\n }\n out.push(`<blockquote>${renderInline(quoted.join('\\n')).replace(/\\n/g, '<br>')}</blockquote>`);\n continue;\n }\n\n // Paragraph — gather consecutive non-blank, non-block lines; soft breaks → <br>.\n const para: string[] = [];\n while (i < lines.length) {\n const l = lines[i]!;\n if (\n l.trim() === '' ||\n FENCE_RE.test(l) ||\n HEADING_RE.test(l) ||\n UL_RE.test(l) ||\n OL_RE.test(l) ||\n QUOTE_RE.test(l)\n ) {\n break;\n }\n para.push(l);\n i++;\n }\n out.push(`<p>${renderInline(para.join('\\n')).replace(/\\n/g, '<br>')}</p>`);\n }\n\n return out.join('');\n}\n\n// ───────────────────────── Citation-snippet cleanup ─────────────────────────\n\nconst SNIPPET_MAX = 260;\n\n/**\n * Clean a raw scraped citation snippet into a short, readable excerpt.\n *\n * Scraped chunks frequently begin with page boilerplate — a logo image wrapped\n * in a link, standalone nav, repeated whitespace — e.g.\n * `[](…) # Our Work We build…`. The source itself is already linked\n * from the citation card, so the snippet only needs to be a clean teaser.\n *\n * Steps:\n * 1. Strip a leading image / logo-link (`[](…)` or ``).\n * 2. Drop a leading standalone heading marker (`#`/`##`).\n * 3. Collapse all runs of whitespace to single spaces.\n * 4. Truncate to ~{@link SNIPPET_MAX} chars at a word boundary, adding `…`.\n *\n * The result is still rendered through {@link renderMarkdown} downstream, so any\n * remaining inline markup (bold/links) stays safe.\n */\nexport function cleanCitationSnippet(raw: string): string {\n let s = raw ?? '';\n\n // Repeatedly peel leading boilerplate tokens.\n let changed = true;\n while (changed) {\n changed = false;\n const before = s;\n // Leading linked image: [](href)\n s = s.replace(/^\\s*\\[!\\[[^\\]]*\\]\\([^)]*\\)\\]\\([^)]*\\)\\s*/, '');\n // Leading bare image: \n s = s.replace(/^\\s*!\\[[^\\]]*\\]\\([^)]*\\)\\s*/, '');\n // Leading heading marker(s): \"# \", \"## \" (keep the heading text)\n s = s.replace(/^\\s*#{1,6}\\s+/, '');\n if (s !== before) changed = true;\n }\n\n // Collapse whitespace.\n s = s.replace(/\\s+/g, ' ').trim();\n\n // Truncate at a word boundary.\n if (s.length > SNIPPET_MAX) {\n const cut = s.slice(0, SNIPPET_MAX);\n const lastSpace = cut.lastIndexOf(' ');\n s = (lastSpace > SNIPPET_MAX * 0.6 ? cut.slice(0, lastSpace) : cut).trimEnd() + '…';\n }\n\n return s;\n}\n","/**\n * Public configuration surface for the chat widget.\n *\n * A host page configures the widget either declaratively (HTML attributes on the\n * `<smooth-agent-chat>` element) or programmatically (passing this object to\n * {@link mountChatWidget} / `element.configure(...)`).\n */\nimport { safeHttpUrl } from './markdown.js';\n\nexport interface ChatWidgetTheme {\n /** Foreground text color for the widget chrome. */\n text?: string;\n /** Panel background color. */\n background?: string;\n /** Primary accent (launcher button, send button, outbound bubble). */\n primary?: string;\n /** Text color rendered on top of `primary`. */\n primaryText?: string;\n /** A secondary accent (used for subtle highlights). */\n secondary?: string;\n /** Inbound (assistant) chat bubble background. */\n assistantBubble?: string;\n /** Inbound (assistant) chat bubble text color. */\n assistantBubbleText?: string;\n /** Outbound (user) chat bubble background. Defaults to `primary`. */\n userBubble?: string;\n /** Outbound (user) chat bubble text color. Defaults to `primaryText`. */\n userBubbleText?: string;\n /** Border color for the panel and input. */\n border?: string;\n\n // ── Aliases for the dashboard's 10-color model (SmooAI agent widget config).\n // When provided, these take precedence over the canonical keys above, so a\n // config exported from the agent dashboard themes the widget directly.\n /** Alias for {@link assistantBubble}. */\n chatBubbleInbound?: string;\n /** Alias for {@link assistantBubbleText}. */\n chatBubbleInboundText?: string;\n /** Alias for {@link userBubble}. */\n chatBubbleOutbound?: string;\n /** Alias for {@link userBubbleText}. */\n chatBubbleOutboundText?: string;\n}\n\n/**\n * Layout mode for the widget.\n *\n * - `\"popover\"` (default) — the embeddable launcher bubble + floating panel.\n * - `\"fullpage\"` — no launcher; the chat fills its container/viewport with a\n * branded header, a scrollable message list, and an input bar. Ideal for a\n * dedicated support page (`/chat`, a docs site sidebar, an iframe, …).\n */\nexport type ChatWidgetMode = 'popover' | 'fullpage';\n\nexport interface ChatWidgetConfig {\n /**\n * smooth-operator WebSocket endpoint, e.g.\n * `ws://localhost:8787/ws` (local dev) or your deployed `wss://…/ws` URL.\n */\n endpoint: string;\n /**\n * Layout mode — `\"popover\"` (default, launcher + floating panel) or\n * `\"fullpage\"` (chat fills its container; no launcher). See {@link ChatWidgetMode}.\n */\n mode?: ChatWidgetMode;\n /** UUID of the agent to start a conversation session with. */\n agentId: string;\n /** Display name for the agent (header label). Defaults to \"Assistant\". */\n agentName?: string;\n /**\n * Brand logo shown in the full-page header avatar tile; falls back to the\n * Smooth icon. SECURITY: only absolute `http(s)` URLs are honored — any other\n * scheme (`javascript:`/`data:`/…) is ignored, so a hostile config can't\n * inject script.\n */\n logoUrl?: string;\n /** Optional display name for the user participant. */\n userName?: string;\n /** Optional email address for the user participant. */\n userEmail?: string;\n /** Optional phone number for the user participant (passed via session metadata). */\n userPhone?: string;\n /**\n * Optional pre-auth HMAC context. When the host page has a shared secret with\n * the agent, it can sign `{ userId, signature, timestamp }` so the chat-ws\n * wrapper's `/internal/*` identity routes (and the WS create path) verify the\n * caller without an OTP round-trip (ADR-046/ADR-048). Passed through verbatim.\n */\n authContext?: { userId: string; signature: string; timestamp: number };\n /** Placeholder text for the message input. */\n placeholder?: string;\n /** Greeting rendered when the conversation opens (before any messages). */\n greeting?: string;\n /** Message shown when the connection cannot be (re)established. */\n connectionErrorMessage?: string;\n /** Start the panel open instead of collapsed to the launcher. */\n startOpen?: boolean;\n /**\n * Hide the \"powered by smooth-operator\" branding in the header tag and the\n * composer footer. Defaults to `false` (branding shown). The `hide-branding`\n * HTML attribute maps to this.\n */\n hideBranding?: boolean;\n /**\n * Suggested starter prompts shown as clickable chips before the first message.\n * Clicking one sends it. Capped at 5 for layout.\n */\n examplePrompts?: string[];\n /**\n * Show mid-conversation suggested-reply chips (\"quick replies\") under the\n * latest assistant message when the agent returns follow-up suggestions.\n * Clicking one sends it. Defaults to `true` (shown unless explicitly `false`).\n */\n showSuggestedReplies?: boolean;\n /** Require the visitor's name before chatting. */\n requireName?: boolean;\n /** Require the visitor's email before chatting. */\n requireEmail?: boolean;\n /** Require the visitor's phone before chatting. */\n requirePhone?: boolean;\n /**\n * Show the phone field on the pre-chat form (optional unless {@link requirePhone}).\n * Defaults to `true` for this widget — phone rides the session metadata as\n * `userPhone` so the agent can follow up by SMS. Set `false` to hide it.\n */\n collectPhone?: boolean;\n /**\n * Show the email + SMS marketing-consent checkboxes on the pre-chat form.\n * Explicit opt-in, default UNCHECKED; a `consentAt` timestamp is stamped when\n * a box is ticked. Defaults to `true`. The consent record is threaded into the\n * session metadata (ADR-048).\n */\n collectConsent?: boolean;\n /**\n * Offer the cross-device \"Restore my chats\" affordance — an explicit link that\n * runs the identity-OTP → resolve → replay flow. Defaults to `true`.\n */\n allowChatRestore?: boolean;\n /**\n * Let visitors chat without providing any identity. When `true`, the\n * `require*` flags are ignored and the pre-chat form is skipped.\n */\n allowAnonymous?: boolean;\n /**\n * Show the agent's tool activity (grep / read_file / bash / knowledge_search…)\n * as inline chips interleaved with its prose, mirroring the smooth daemon SPA.\n *\n * Defaults to **`false`**: for a customer-facing support widget, surfacing raw\n * tool calls to an end-user is usually undesirable, so tool activity is hidden\n * and only the assistant's prose renders. Enable it for internal / power-user\n * surfaces where seeing what the agent did mid-turn is valuable.\n */\n showToolActivity?: boolean;\n /** Theme overrides. */\n theme?: ChatWidgetTheme;\n}\n\n/** The fully-resolved theme (canonical keys only — aliases are folded in). */\nexport type ResolvedTheme = Required<Omit<ChatWidgetTheme, 'chatBubbleInbound' | 'chatBubbleInboundText' | 'chatBubbleOutbound' | 'chatBubbleOutboundText'>>;\n\nexport type ResolvedConfig = Required<Omit<ChatWidgetConfig, 'theme' | 'userName' | 'userEmail' | 'userPhone' | 'authContext' | 'logoUrl'>> & {\n theme: ResolvedTheme;\n userName?: string;\n userEmail?: string;\n userPhone?: string;\n authContext?: { userId: string; signature: string; timestamp: number };\n /** Sanitized brand logo URL (`http(s)` only) or `undefined` — see {@link ChatWidgetConfig.logoUrl}. */\n logoUrl?: string;\n};\n\n/** Resolve a partial config against the built-in defaults. */\nexport function resolveConfig(config: ChatWidgetConfig): ResolvedConfig {\n const theme = config.theme ?? {};\n const primary = theme.primary ?? '#00a6a6';\n const primaryText = theme.primaryText ?? '#f8fafc';\n // Dashboard aliases win over canonical keys when present.\n const assistantBubble = theme.chatBubbleInbound ?? theme.assistantBubble ?? '#06134b';\n const assistantBubbleText = theme.chatBubbleInboundText ?? theme.assistantBubbleText ?? '#f8fafc';\n const userBubble = theme.chatBubbleOutbound ?? theme.userBubble ?? primary;\n const userBubbleText = theme.chatBubbleOutboundText ?? theme.userBubbleText ?? primaryText;\n return {\n endpoint: config.endpoint,\n mode: config.mode ?? 'popover',\n agentId: config.agentId,\n agentName: config.agentName ?? 'Assistant',\n // Only absolute http(s) URLs survive — anything else (javascript:/data:/\n // relative) is dropped so the header can never render a hostile logo src.\n logoUrl: safeHttpUrl(config.logoUrl) ?? undefined,\n userName: config.userName,\n userEmail: config.userEmail,\n userPhone: config.userPhone,\n authContext: config.authContext,\n placeholder: config.placeholder ?? 'Type a message…',\n greeting: config.greeting ?? 'Hi! How can I help you today?',\n connectionErrorMessage: config.connectionErrorMessage ?? \"We couldn't reach the chat. Please try again in a moment.\",\n startOpen: config.startOpen ?? false,\n hideBranding: config.hideBranding ?? false,\n examplePrompts: (config.examplePrompts ?? []).filter((p) => p.trim().length > 0).slice(0, 5),\n showSuggestedReplies: config.showSuggestedReplies ?? true,\n requireName: config.requireName ?? false,\n requireEmail: config.requireEmail ?? false,\n requirePhone: config.requirePhone ?? false,\n collectPhone: config.collectPhone ?? true,\n collectConsent: config.collectConsent ?? true,\n allowChatRestore: config.allowChatRestore ?? true,\n allowAnonymous: config.allowAnonymous ?? false,\n showToolActivity: config.showToolActivity ?? false,\n theme: {\n text: theme.text ?? '#f8fafc',\n background: theme.background ?? '#040d30',\n primary,\n primaryText,\n secondary: theme.secondary ?? '#ff6b6c',\n assistantBubble,\n assistantBubbleText,\n userBubble,\n userBubbleText,\n border: theme.border ?? 'rgba(255, 255, 255, 0.1)',\n },\n };\n}\n\n/**\n * Whether the pre-chat identity form should gate the conversation: at least one\n * field is required and anonymous chat is not allowed.\n */\nexport function needsUserInfo(resolved: ResolvedConfig): boolean {\n return !resolved.allowAnonymous && (resolved.requireName || resolved.requireEmail || resolved.requirePhone);\n}\n","/**\n * Transport abstraction for the client.\n *\n * The client is deliberately decoupled from any concrete WebSocket implementation\n * so it can be unit-tested with a mock and run on Node, the browser, or a custom\n * socket. A transport is anything that can send a string frame and surface\n * incoming string frames + lifecycle events.\n */\nconst WS_CONNECTING = 0;\nconst WS_OPEN = 1;\nconst WS_CLOSING = 2;\n/** Default connect timeout (ms) for the WebSocket transport. */\nconst DEFAULT_CONNECT_TIMEOUT = 30_000;\n/**\n * Default transport backed by a `WebSocket`-like object. By default it uses the\n * global `WebSocket`; pass a `factory` to inject one (e.g. the `ws` package on\n * Node, or a mock in tests).\n */\nexport class WebSocketTransport {\n socket = null;\n url;\n factory;\n connectTimeout;\n messageHandlers = new Set();\n closeHandlers = new Set();\n errorHandlers = new Set();\n constructor(url, factory, connectTimeout = DEFAULT_CONNECT_TIMEOUT) {\n this.url = url;\n this.connectTimeout = connectTimeout;\n if (factory) {\n this.factory = factory;\n }\n else {\n const G = globalThis;\n if (!G.WebSocket) {\n throw new Error('No global WebSocket available; pass a WebSocketFactory to WebSocketTransport.');\n }\n const Ctor = G.WebSocket;\n this.factory = (u) => new Ctor(u);\n }\n }\n get state() {\n if (!this.socket)\n return 'closed';\n switch (this.socket.readyState) {\n case WS_CONNECTING:\n return 'connecting';\n case WS_OPEN:\n return 'open';\n case WS_CLOSING:\n return 'closing';\n default:\n return 'closed';\n }\n }\n connect() {\n if (this.socket && this.socket.readyState === WS_OPEN)\n return Promise.resolve();\n // A prior socket that never reached OPEN (failed/half-open dial, or a closed\n // socket from a previous attempt) would otherwise be orphaned: its listeners\n // stay registered and keep dispatching into the shared handler sets, so a late\n // message/close from the dead socket double-fires. Close it and detach it\n // before dialing a fresh one. (WebSocketLike has no removeEventListener, so we\n // also guard every handler below with an identity check on `this.socket`.)\n if (this.socket && this.socket.readyState !== WS_OPEN) {\n const stale = this.socket;\n this.socket = null;\n try {\n stale.close();\n }\n catch {\n // ignore — best-effort teardown of a half-open socket\n }\n }\n return new Promise((resolve, reject) => {\n const socket = this.factory(this.url);\n this.socket = socket;\n let settled = false;\n const timer = this.connectTimeout > 0\n ? setTimeout(() => {\n if (settled)\n return;\n settled = true;\n // Tear down the half-open socket so it can't leak / fire later.\n if (this.socket === socket)\n this.socket = null;\n try {\n socket.close();\n }\n catch {\n // ignore\n }\n reject(new Error(`WebSocket connect to ${this.url} timed out after ${this.connectTimeout}ms`));\n }, this.connectTimeout)\n : undefined;\n socket.addEventListener('open', () => {\n // Ignore events from a socket we've already replaced/abandoned.\n if (this.socket !== socket)\n return;\n if (settled)\n return;\n settled = true;\n if (timer)\n clearTimeout(timer);\n resolve();\n });\n socket.addEventListener('error', (ev) => {\n if (this.socket !== socket)\n return;\n for (const h of this.errorHandlers)\n h(ev);\n if (!settled && this.state !== 'open') {\n settled = true;\n if (timer)\n clearTimeout(timer);\n if (this.socket === socket)\n this.socket = null;\n // Release the failed socket so it can't linger / fire later.\n try {\n socket.close();\n }\n catch {\n // ignore\n }\n reject(ev instanceof Error ? ev : new Error('WebSocket connection error'));\n }\n });\n socket.addEventListener('close', (ev) => {\n if (this.socket !== socket)\n return;\n if (timer)\n clearTimeout(timer);\n for (const h of this.closeHandlers)\n h({ code: ev.code, reason: ev.reason });\n });\n socket.addEventListener('message', (ev) => {\n if (this.socket !== socket)\n return;\n const data = typeof ev.data === 'string' ? ev.data : String(ev.data);\n for (const h of this.messageHandlers)\n h(data);\n });\n });\n }\n send(data) {\n if (!this.socket || this.socket.readyState !== WS_OPEN) {\n throw new Error(`Cannot send: transport is \"${this.state}\"`);\n }\n this.socket.send(data);\n }\n close(code, reason) {\n this.socket?.close(code, reason);\n }\n onMessage(handler) {\n this.messageHandlers.add(handler);\n return () => this.messageHandlers.delete(handler);\n }\n onClose(handler) {\n this.closeHandlers.add(handler);\n return () => this.closeHandlers.delete(handler);\n }\n onError(handler) {\n this.errorHandlers.add(handler);\n return () => this.errorHandlers.delete(handler);\n }\n}\n//# sourceMappingURL=transport.js.map","export * from './generated/types.js';\n// ───────────────────────────── Discriminators ──────────────────────────────\n/** Every client→server `action` discriminator value. */\nexport const ACTION_TYPES = [\n 'create_conversation_session',\n 'send_message',\n 'get_session',\n 'get_conversation_messages',\n 'confirm_tool_action',\n 'verify_otp',\n 'submit_interaction',\n 'ping',\n];\n/** Every server→client `type` discriminator value. */\nexport const EVENT_TYPES = [\n 'immediate_response',\n 'eventual_response',\n 'stream_chunk',\n 'stream_token',\n 'keepalive',\n 'write_confirmation_required',\n 'otp_verification_required',\n 'otp_sent',\n 'otp_verified',\n 'otp_invalid',\n 'interaction_required',\n 'interaction_invalid',\n 'error',\n 'pong',\n];\n// ───────────────────────────── Type guards ─────────────────────────────────\n/** True if `frame` is a server event of the given `type`, narrowing accordingly. */\nexport function isEvent(frame, type) {\n return isServerEvent(frame) && frame.type === type;\n}\n/** True if `frame` looks like any server event (has a known `type` discriminator). */\nexport function isServerEvent(frame) {\n return (typeof frame === 'object' &&\n frame !== null &&\n 'type' in frame &&\n typeof frame.type === 'string' &&\n EVENT_TYPES.includes(frame.type));\n}\n/** True if `frame` looks like any client action (has a known `action` discriminator). */\nexport function isClientAction(frame) {\n return (typeof frame === 'object' &&\n frame !== null &&\n 'action' in frame &&\n typeof frame.action === 'string' &&\n ACTION_TYPES.includes(frame.action));\n}\n//# sourceMappingURL=types.js.map","/**\n * SmoothAgentClient — a minimal, idiomatic, transport-agnostic client for the\n * smooth-operator WebSocket protocol.\n *\n * Design goals\n * ------------\n * - **Transport-agnostic.** The client never touches a real socket directly; it\n * talks to an injectable {@link Transport}. The default ({@link WebSocketTransport})\n * uses the global `WebSocket`, but tests inject a mock and Node can inject `ws`.\n * - **Request/response correlation by `requestId`.** Every action gets a generated\n * `requestId`; the client routes incoming events back to the originating call.\n * - **Streaming as an async iterator.** `sendMessage` returns a {@link MessageTurn}\n * that is both awaitable (resolves with the terminal `eventual_response`) and\n * async-iterable (yields each `stream_token` / `stream_chunk` / HITL event in\n * order). This models the `stream_token`/`stream_chunk` → `eventual_response`\n * flow without forcing a callback style on the caller.\n * - **No live server required.** Correctness is fully unit-testable with a mock\n * transport (see `test/client.test.ts`).\n */\nimport { WebSocketTransport, } from './transport.js';\nimport { isServerEvent } from './types.js';\n/** Events that terminate a streaming turn (success or error). */\nconst TURN_TERMINAL = new Set(['eventual_response', 'error']);\n/** A timeout that yields no terminal event. */\nclass RequestTimeoutError extends Error {\n constructor(requestId, ms) {\n super(`Request ${requestId} timed out after ${ms}ms`);\n this.name = 'RequestTimeoutError';\n }\n}\n/**\n * A streaming turn that received no terminal `eventual_response` / `error` within the\n * configured {@link SmoothAgentClientOptions.turnTimeout}. The turn rejects with this\n * and its async iteration throws it, so a stuck server can never hang the caller.\n */\nexport class TurnTimeoutError extends Error {\n requestId;\n constructor(requestId, ms) {\n super(`Turn ${requestId} timed out after ${ms}ms without a terminal response`);\n this.name = 'TurnTimeoutError';\n this.requestId = requestId;\n }\n}\n/** A protocol-level error event surfaced as a throwable. */\nexport class ProtocolError extends Error {\n code;\n requestId;\n constructor(code, message, requestId) {\n super(message);\n this.name = 'ProtocolError';\n this.code = code;\n this.requestId = requestId;\n }\n}\n/**\n * A streaming message turn. Await it for the terminal {@link EventualResponse},\n * or async-iterate it to receive every intermediate event in arrival order.\n *\n * ```ts\n * const turn = client.sendMessage({ sessionId, message: 'hi' });\n * for await (const ev of turn) {\n * if (ev.type === 'stream_token') process.stdout.write(ev.token ?? '');\n * }\n * const final = await turn; // EventualResponse\n * ```\n */\nexport class MessageTurn {\n /** The requestId this turn is correlated on. */\n requestId;\n queue = [];\n waiter = null;\n done = false;\n finalEvent = null;\n error = null;\n settled;\n settle;\n fail;\n onClose;\n timeoutTimer;\n constructor(requestId, onClose, turnTimeout = 0) {\n this.requestId = requestId;\n this.onClose = onClose;\n this.settled = new Promise((resolve, reject) => {\n this.settle = resolve;\n this.fail = reject;\n });\n // Avoid unhandled-rejection noise if the caller only iterates and never awaits.\n this.settled.catch(() => { });\n // Bound the turn: a server that accepts the message but never emits a terminal\n // event must not hang the caller forever.\n if (turnTimeout > 0) {\n this.timeoutTimer = setTimeout(() => {\n this.finish(null, new TurnTimeoutError(this.requestId, turnTimeout));\n }, turnTimeout);\n }\n }\n /** Feed an event into the turn (called by the client's dispatcher). */\n push(event) {\n if (this.done)\n return;\n if (event.type === 'error') {\n const code = event.data?.error?.code ?? 'INTERNAL_ERROR';\n const message = event.data?.error?.message ?? 'Unknown protocol error';\n this.deliver(event);\n this.finish(null, new ProtocolError(code, message, this.requestId));\n return;\n }\n this.deliver(event);\n if (event.type === 'eventual_response') {\n this.finish(event, null);\n }\n }\n /** Force-close the turn (e.g. on disconnect) with an error. */\n abort(err) {\n if (this.done)\n return;\n this.finish(null, err);\n }\n deliver(event) {\n if (this.waiter) {\n const w = this.waiter;\n this.waiter = null;\n w.resolve({ value: event, done: false });\n }\n else {\n this.queue.push(event);\n }\n }\n finish(final, err) {\n if (this.done)\n return;\n this.done = true;\n this.finalEvent = final;\n this.error = err;\n if (this.timeoutTimer) {\n clearTimeout(this.timeoutTimer);\n this.timeoutTimer = undefined;\n }\n this.onClose();\n if (err)\n this.fail(err);\n else if (final)\n this.settle(final);\n // Release any pending iterator waiter now that the stream has ended. On error\n // the parked next() must *reject* (mirroring the queued-error path in next())\n // so a pure `for await` consumer sees the terminal error thrown instead of a\n // silent, indistinguishable `{ done: true }`.\n if (this.waiter) {\n const w = this.waiter;\n this.waiter = null;\n if (err) {\n w.reject(err);\n }\n else {\n w.resolve({ value: undefined, done: true });\n }\n }\n }\n [Symbol.asyncIterator]() {\n return {\n next: () => {\n if (this.queue.length > 0) {\n return Promise.resolve({ value: this.queue.shift(), done: false });\n }\n if (this.done) {\n if (this.error)\n return Promise.reject(this.error);\n return Promise.resolve({ value: undefined, done: true });\n }\n return new Promise((resolve, reject) => {\n this.waiter = { resolve, reject };\n });\n },\n };\n }\n // PromiseLike — `await turn` resolves with the EventualResponse.\n then(onfulfilled, onrejected) {\n return this.settled.then(onfulfilled, onrejected);\n }\n}\nexport class SmoothAgentClient {\n transport;\n generateRequestId;\n requestTimeout;\n turnTimeout;\n /** requestId → single-response waiter (create_session, get_session, ping, …). */\n pending = new Map();\n /** requestId → active streaming turn (send_message, and HITL resumes). */\n turns = new Map();\n /** Unsolicited-event listeners (keepalive, server-push). */\n listeners = new Set();\n unsubscribe = [];\n constructor(options) {\n this.transport =\n options.transport ??\n new WebSocketTransport(withConnectionToken(options.url, options.token), options.webSocketFactory);\n this.requestTimeout = options.requestTimeout ?? 30_000;\n this.turnTimeout = options.turnTimeout ?? 120_000;\n this.generateRequestId =\n options.generateRequestId ??\n (() => `req-${(globalThis.crypto?.randomUUID?.() ?? Math.random().toString(36).slice(2))}`);\n this.unsubscribe.push(this.transport.onMessage((data) => this.handleFrame(data)));\n this.unsubscribe.push(this.transport.onClose(() => this.failAll(new Error('Transport closed'))));\n }\n /** Open the underlying transport. */\n async connect() {\n await this.transport.connect();\n }\n /** Close the transport and reject all in-flight work. */\n disconnect(reason = 'client disconnect') {\n this.failAll(new Error(reason));\n for (const u of this.unsubscribe)\n u();\n this.unsubscribe = [];\n this.transport.close(1000, reason);\n }\n /** Subscribe to unsolicited / uncorrelated server events (e.g. keepalive). */\n onEvent(listener) {\n this.listeners.add(listener);\n return () => this.listeners.delete(listener);\n }\n // ───────────────────────────── Actions ─────────────────────────────────\n /** Start a new conversation session. Resolves with the session descriptor. */\n async createConversationSession(req) {\n const event = await this.request({ action: 'create_conversation_session', ...req });\n return extractImmediateData(event);\n }\n /** Fetch a session snapshot by ID. */\n async getSession(req) {\n const event = await this.request({ action: 'get_session', ...req });\n return extractImmediateData(event);\n }\n /** Fetch a page of conversation messages. */\n async getMessages(req) {\n const event = await this.request({ action: 'get_conversation_messages', ...req });\n return extractImmediateData(event);\n }\n /** Keepalive ping. Resolves with the server timestamp from the `pong` event. */\n async ping() {\n const event = await this.request({ action: 'ping' });\n if (event.type === 'pong')\n return event.timestamp ?? event.data?.timestamp ?? Date.now();\n return Date.now();\n }\n /**\n * Submit a user message and return a {@link MessageTurn}: await it for the\n * terminal `eventual_response`, or async-iterate it for the streaming events.\n */\n sendMessage(req) {\n const requestId = this.generateRequestId();\n const turn = new MessageTurn(requestId, () => this.turns.delete(requestId), this.turnTimeout);\n this.turns.set(requestId, turn);\n try {\n this.transport.send(JSON.stringify({ action: 'send_message', requestId, ...req }));\n }\n catch (err) {\n this.turns.delete(requestId);\n turn.abort(err);\n }\n return turn;\n }\n /**\n * Approve or reject a pending tool write, resuming the paused turn identified\n * by `requestId`. The resumed streaming events flow back into the original\n * {@link MessageTurn} for that `requestId`.\n */\n confirmToolAction(req) {\n this.transport.send(JSON.stringify({ action: 'confirm_tool_action', ...req }));\n }\n /**\n * Submit an OTP code, resuming the paused turn identified by `requestId`.\n * The resumed streaming events flow back into the original {@link MessageTurn}.\n */\n verifyOtp(req) {\n this.transport.send(JSON.stringify({ action: 'verify_otp', ...req }));\n }\n /**\n * Submit (or decline) a Rich Interaction, resuming the turn parked by an\n * `interaction_required` event. This ONE verb serves every interaction kind\n * (identity intake, future date pickers, choice chips, …) — adding a kind\n * needs no new client method. Server-side validation may reply with an\n * `interaction_invalid` event (the turn stays parked — resubmit); a valid\n * submit resumes the stream back into the original {@link MessageTurn}.\n */\n submitInteraction(req) {\n this.transport.send(JSON.stringify({ action: 'submit_interaction', ...req }));\n }\n // ─────────────────────────── Internals ─────────────────────────────────\n /** Send an action that expects a single correlated response event. */\n request(action) {\n const requestId = action.requestId ?? this.generateRequestId();\n const frame = { ...action, requestId };\n return new Promise((resolve, reject) => {\n const timer = this.requestTimeout > 0\n ? setTimeout(() => {\n this.pending.delete(requestId);\n reject(new RequestTimeoutError(requestId, this.requestTimeout));\n }, this.requestTimeout)\n : undefined;\n this.pending.set(requestId, { resolve, reject, timer });\n try {\n this.transport.send(JSON.stringify(frame));\n }\n catch (err) {\n if (timer)\n clearTimeout(timer);\n this.pending.delete(requestId);\n reject(err);\n }\n });\n }\n /** Parse and route an incoming frame to the right consumer. */\n handleFrame(data) {\n let frame;\n try {\n frame = JSON.parse(data);\n }\n catch {\n return; // ignore malformed frames\n }\n if (!isServerEvent(frame))\n return;\n const event = frame;\n const requestId = event.requestId;\n // 1. Streaming turn? Route every related event into it.\n if (requestId && this.turns.has(requestId)) {\n this.turns.get(requestId).push(event);\n return;\n }\n // 2. Single-response request awaiting resolution?\n if (requestId && this.pending.has(requestId)) {\n const pending = this.pending.get(requestId);\n this.pending.delete(requestId);\n if (pending.timer)\n clearTimeout(pending.timer);\n if (event.type === 'error') {\n const code = event.data?.error?.code ?? 'INTERNAL_ERROR';\n const message = event.data?.error?.message ?? 'Unknown protocol error';\n pending.reject(new ProtocolError(code, message, requestId));\n }\n else {\n pending.resolve(event);\n }\n return;\n }\n // 3. Unsolicited / uncorrelated event (keepalive, server push).\n for (const l of this.listeners)\n l(event);\n }\n failAll(err) {\n for (const [, p] of this.pending) {\n if (p.timer)\n clearTimeout(p.timer);\n p.reject(err);\n }\n this.pending.clear();\n for (const [, turn] of this.turns)\n turn.abort(err);\n this.turns.clear();\n }\n}\n/**\n * Merge a connection auth `token` into a WebSocket URL as a `?token=` query param,\n * preserving any existing query string. Returns `url` unchanged when no token is\n * given, so the no-token path is byte-for-byte identical to before. Uses `URL` /\n * `URLSearchParams` so an existing `?foo=bar` becomes `?foo=bar&token=…` (and the\n * value is properly percent-encoded) rather than a naive `?`/`&` string-concat.\n *\n * Falls back to manual concatenation if `url` is not absolute (so `URL` can't parse\n * it) — e.g. a relative or mock URL used in tests.\n */\nfunction withConnectionToken(url, token) {\n if (!token)\n return url;\n try {\n const parsed = new URL(url);\n parsed.searchParams.set('token', token);\n return parsed.toString();\n }\n catch {\n const separator = url.includes('?') ? '&' : '?';\n return `${url}${separator}token=${encodeURIComponent(token)}`;\n }\n}\n/** Pull the typed `data` payload out of an `immediate_response` event. */\nfunction extractImmediateData(event) {\n if (event.type === 'immediate_response')\n return event.data;\n // Some servers may answer a non-streaming action with the payload elsewhere;\n // fall back to `data` if present.\n if ('data' in event && event.data && typeof event.data === 'object')\n return event.data;\n throw new ProtocolError('UNEXPECTED_EVENT', `Expected immediate_response, got \"${event.type}\"`, event.requestId);\n}\n//# sourceMappingURL=client.js.map","/**\n * Browser fingerprint — a stable, privacy-light identifier used by the\n * smooth-operator server to correlate an anonymous visitor's sessions across\n * page loads (and, server-side, to match an anonymous fingerprint to a known\n * CRM contact). It rides every `create_conversation_session` as\n * `browserFingerprint` (see ADR-048).\n *\n * ## Why not ThumbmarkJS\n *\n * The ADR floats ThumbmarkJS as the reference implementation. For an *embed*\n * that is injected onto arbitrary host pages, ThumbmarkJS is too heavy: its\n * full build pulls in extensive device-detection tables and async\n * component collection, adding tens of kilobytes (and async surface) to a\n * bundle whose whole selling point is staying out of the host page's\n * LCP/TBT budget. The fingerprint here is a few hundred bytes.\n *\n * ## What this is (and the tradeoff)\n *\n * The correlation that actually matters — \"is this the same browser as last\n * time?\" — is carried by a **persisted random UUID** (the `browserFingerprint`\n * field in the persisted store). That UUID is generated once and reused for\n * the life of the localStorage entry, so same-browser resume is exact and\n * deterministic. The signal hash below is a best-effort entropy *supplement*\n * mixed into that UUID's derivation seed on first generation — it gives the\n * server-side resolver a soft signal for the (rare) cross-storage case where\n * the UUID was cleared but the device is unchanged. It is intentionally NOT a\n * high-entropy device fingerprint: no canvas/WebGL/audio probes, no font\n * enumeration, nothing that reads as invasive tracking. The tradeoff is weaker\n * cross-storage matching in exchange for a tiny, transparent, no-network,\n * XSS-safe implementation. The server's resolver (SMOODEV-2129d) is the source\n * of truth for any fuzzy matching; the client just supplies a stable token.\n */\n\n/** Collect a small set of stable, non-invasive browser signals. */\nfunction collectSignals(): string {\n const parts: string[] = [];\n try {\n const nav = typeof navigator !== 'undefined' ? navigator : undefined;\n if (nav) {\n parts.push(`ua:${nav.userAgent ?? ''}`);\n parts.push(`lang:${nav.language ?? ''}`);\n parts.push(`langs:${Array.isArray(nav.languages) ? nav.languages.join(',') : ''}`);\n // `platform` is deprecated but still widely present and stable.\n parts.push(`plat:${(nav as Navigator & { platform?: string }).platform ?? ''}`);\n parts.push(`hc:${(nav as Navigator & { hardwareConcurrency?: number }).hardwareConcurrency ?? ''}`);\n parts.push(`dm:${(nav as Navigator & { deviceMemory?: number }).deviceMemory ?? ''}`);\n }\n if (typeof screen !== 'undefined') {\n parts.push(`scr:${screen.width}x${screen.height}x${screen.colorDepth}`);\n }\n if (typeof Intl !== 'undefined') {\n try {\n parts.push(`tz:${Intl.DateTimeFormat().resolvedOptions().timeZone ?? ''}`);\n } catch {\n /* resolvedOptions can throw in locked-down environments */\n }\n }\n parts.push(`tzo:${new Date().getTimezoneOffset()}`);\n } catch {\n /* a hostile/locked-down navigator must never break widget boot */\n }\n return parts.join('|');\n}\n\n/**\n * A small, fast, non-cryptographic string hash (FNV-1a, 32-bit) rendered as\n * an unsigned hex string. Stable across runs for the same input. Not used for\n * any security decision — only to derive a deterministic seed from the signal\n * string above.\n */\nfunction fnv1a(input: string): string {\n let h = 0x811c9dc5;\n for (let i = 0; i < input.length; i++) {\n h ^= input.charCodeAt(i);\n // 32-bit FNV prime multiply via shifts to stay in int range.\n h = Math.imul(h, 0x01000193);\n }\n // >>> 0 → unsigned; pad to 8 hex chars.\n return (h >>> 0).toString(16).padStart(8, '0');\n}\n\n/** Generate a UUID, preferring `crypto.randomUUID`, falling back to a v4-shaped string. */\nfunction generateUuid(): string {\n try {\n if (typeof crypto !== 'undefined' && typeof crypto.randomUUID === 'function') {\n return crypto.randomUUID();\n }\n } catch {\n /* fall through to the manual generator */\n }\n // RFC 4122 v4 shape from Math.random — only reached when crypto.randomUUID\n // is unavailable (very old engines). Sufficient for a correlation token.\n return 'xxxxxxxx-xxxx-4xxx-yxxx-xxxxxxxxxxxx'.replace(/[xy]/g, (c) => {\n const r = (Math.random() * 16) | 0;\n const v = c === 'x' ? r : (r & 0x3) | 0x8;\n return v.toString(16);\n });\n}\n\n/**\n * Compute a fresh fingerprint token: a stable random UUID, suffixed with the\n * FNV hash of the device signals so the server can recover a soft device\n * signal even if it only has the token. Called ONCE per browser (the result is\n * persisted and reused) — see {@link getOrCreateFingerprint}.\n */\nexport function computeFingerprint(): string {\n const signalHash = fnv1a(collectSignals());\n return `${generateUuid()}.${signalHash}`;\n}\n\n/**\n * Return the cached fingerprint if one was already computed for this browser,\n * otherwise compute + persist a new one via the provided accessors. The\n * persistence layer owns storage; this function owns the \"compute once\" policy.\n */\nexport function getOrCreateFingerprint(get: () => string | null, set: (fp: string) => void): string {\n const existing = get();\n if (existing) return existing;\n const fp = computeFingerprint();\n set(fp);\n return fp;\n}\n","const createStoreImpl = (createState) => {\n let state;\n const listeners = /* @__PURE__ */ new Set();\n const setState = (partial, replace) => {\n const nextState = typeof partial === \"function\" ? partial(state) : partial;\n if (!Object.is(nextState, state)) {\n const previousState = state;\n state = (replace != null ? replace : typeof nextState !== \"object\" || nextState === null) ? nextState : Object.assign({}, state, nextState);\n listeners.forEach((listener) => listener(state, previousState));\n }\n };\n const getState = () => state;\n const getInitialState = () => initialState;\n const subscribe = (listener) => {\n listeners.add(listener);\n return () => listeners.delete(listener);\n };\n const api = { setState, getState, getInitialState, subscribe };\n const initialState = state = createState(setState, getState, api);\n return api;\n};\nconst createStore = ((createState) => createState ? createStoreImpl(createState) : createStoreImpl);\n\nexport { createStore };\n","const reduxImpl = (reducer, initial) => (set, _get, api) => {\n api.dispatch = (action) => {\n set((state) => reducer(state, action), false, action);\n return action;\n };\n api.dispatchFromDevtools = true;\n return { dispatch: (...args) => api.dispatch(...args), ...initial };\n};\nconst redux = reduxImpl;\n\nconst shouldDispatchFromDevtools = (api) => !!api.dispatchFromDevtools && typeof api.dispatch === \"function\";\nconst trackedConnections = /* @__PURE__ */ new Map();\nconst getTrackedConnectionState = (name) => {\n const api = trackedConnections.get(name);\n if (!api) return {};\n return Object.fromEntries(\n Object.entries(api.stores).map(([key, api2]) => [key, api2.getState()])\n );\n};\nconst extractConnectionInformation = (store, extensionConnector, options) => {\n if (store === void 0) {\n return {\n type: \"untracked\",\n connection: extensionConnector.connect(options)\n };\n }\n const existingConnection = trackedConnections.get(options.name);\n if (existingConnection) {\n return { type: \"tracked\", store, ...existingConnection };\n }\n const newConnection = {\n connection: extensionConnector.connect(options),\n stores: {}\n };\n trackedConnections.set(options.name, newConnection);\n return { type: \"tracked\", store, ...newConnection };\n};\nconst removeStoreFromTrackedConnections = (name, store) => {\n if (store === void 0) return;\n const connectionInfo = trackedConnections.get(name);\n if (!connectionInfo) return;\n delete connectionInfo.stores[store];\n if (Object.keys(connectionInfo.stores).length === 0) {\n trackedConnections.delete(name);\n }\n};\nconst v8StackLineRe = /.+ (.+) .+/;\nconst geckoStackLineRe = /^([^@]+)@/;\nfunction findCallerName(stack) {\n var _a, _b, _c;\n if (!stack) return void 0;\n const traceLines = stack.split(\"\\n\");\n const apiSetStateLineIndex = traceLines.findIndex(\n (traceLine) => traceLine.includes(\"api.setState\")\n );\n if (apiSetStateLineIndex < 0) return void 0;\n const callerLine = ((_a = traceLines[apiSetStateLineIndex + 1]) == null ? void 0 : _a.trim()) || \"\";\n return ((_b = v8StackLineRe.exec(callerLine)) == null ? void 0 : _b[1]) || ((_c = geckoStackLineRe.exec(callerLine)) == null ? void 0 : _c[1]);\n}\nconst devtoolsImpl = (fn, devtoolsOptions = {}) => (set, get, api) => {\n const { enabled, anonymousActionType, store, ...options } = devtoolsOptions;\n let extensionConnector;\n try {\n extensionConnector = (enabled != null ? enabled : (import.meta.env ? import.meta.env.MODE : void 0) !== \"production\") && window.__REDUX_DEVTOOLS_EXTENSION__;\n } catch (e) {\n }\n if (!extensionConnector) {\n return fn(set, get, api);\n }\n const { connection, ...connectionInformation } = extractConnectionInformation(store, extensionConnector, options);\n let isRecording = true;\n api.setState = ((state, replace, nameOrAction) => {\n const r = set(state, replace);\n if (!isRecording) return r;\n const action = nameOrAction === void 0 ? {\n type: anonymousActionType || findCallerName(new Error().stack) || \"anonymous\"\n } : typeof nameOrAction === \"string\" ? { type: nameOrAction } : nameOrAction;\n if (store === void 0) {\n connection == null ? void 0 : connection.send(action, get());\n return r;\n }\n connection == null ? void 0 : connection.send(\n {\n ...action,\n type: `${store}/${action.type}`\n },\n {\n ...getTrackedConnectionState(options.name),\n [store]: api.getState()\n }\n );\n return r;\n });\n api.devtools = {\n cleanup: () => {\n if (connection && typeof connection.unsubscribe === \"function\") {\n connection.unsubscribe();\n }\n removeStoreFromTrackedConnections(options.name, store);\n }\n };\n const setStateFromDevtools = (...a) => {\n const originalIsRecording = isRecording;\n isRecording = false;\n set(...a);\n isRecording = originalIsRecording;\n };\n const initialState = fn(api.setState, get, api);\n if (connectionInformation.type === \"untracked\") {\n connection == null ? void 0 : connection.init(initialState);\n } else {\n connectionInformation.stores[connectionInformation.store] = api;\n connection == null ? void 0 : connection.init(\n Object.fromEntries(\n Object.entries(connectionInformation.stores).map(([key, store2]) => [\n key,\n key === connectionInformation.store ? initialState : store2.getState()\n ])\n )\n );\n }\n if (shouldDispatchFromDevtools(api)) {\n let didWarnAboutReservedActionType = false;\n const originalDispatch = api.dispatch;\n api.dispatch = (...args) => {\n if ((import.meta.env ? import.meta.env.MODE : void 0) !== \"production\" && args[0].type === \"__setState\" && !didWarnAboutReservedActionType) {\n console.warn(\n '[zustand devtools middleware] \"__setState\" action type is reserved to set state from the devtools. Avoid using it.'\n );\n didWarnAboutReservedActionType = true;\n }\n originalDispatch(...args);\n };\n }\n connection.subscribe((message) => {\n var _a;\n switch (message.type) {\n case \"ACTION\":\n if (typeof message.payload !== \"string\") {\n console.error(\n \"[zustand devtools middleware] Unsupported action format\"\n );\n return;\n }\n return parseJsonThen(\n message.payload,\n (action) => {\n if (action.type === \"__setState\") {\n if (store === void 0) {\n setStateFromDevtools(action.state);\n return;\n }\n if (Object.keys(action.state).length !== 1) {\n console.error(\n `\n [zustand devtools middleware] Unsupported __setState action format.\n When using 'store' option in devtools(), the 'state' should have only one key, which is a value of 'store' that was passed in devtools(),\n and value of this only key should be a state object. Example: { \"type\": \"__setState\", \"state\": { \"abc123Store\": { \"foo\": \"bar\" } } }\n `\n );\n }\n const stateFromDevtools = action.state[store];\n if (stateFromDevtools === void 0 || stateFromDevtools === null) {\n return;\n }\n if (JSON.stringify(api.getState()) !== JSON.stringify(stateFromDevtools)) {\n setStateFromDevtools(stateFromDevtools);\n }\n return;\n }\n if (shouldDispatchFromDevtools(api)) {\n api.dispatch(action);\n }\n }\n );\n case \"DISPATCH\":\n switch (message.payload.type) {\n case \"RESET\":\n setStateFromDevtools(initialState);\n if (store === void 0) {\n return connection == null ? void 0 : connection.init(api.getState());\n }\n return connection == null ? void 0 : connection.init(getTrackedConnectionState(options.name));\n case \"COMMIT\":\n if (store === void 0) {\n connection == null ? void 0 : connection.init(api.getState());\n return;\n }\n return connection == null ? void 0 : connection.init(getTrackedConnectionState(options.name));\n case \"ROLLBACK\":\n return parseJsonThen(message.state, (state) => {\n if (store === void 0) {\n setStateFromDevtools(state);\n connection == null ? void 0 : connection.init(api.getState());\n return;\n }\n setStateFromDevtools(state[store]);\n connection == null ? void 0 : connection.init(getTrackedConnectionState(options.name));\n });\n case \"JUMP_TO_STATE\":\n case \"JUMP_TO_ACTION\":\n return parseJsonThen(message.state, (state) => {\n if (store === void 0) {\n setStateFromDevtools(state);\n return;\n }\n if (JSON.stringify(api.getState()) !== JSON.stringify(state[store])) {\n setStateFromDevtools(state[store]);\n }\n });\n case \"IMPORT_STATE\": {\n const { nextLiftedState } = message.payload;\n const lastComputedState = (_a = nextLiftedState.computedStates.slice(-1)[0]) == null ? void 0 : _a.state;\n if (!lastComputedState) return;\n if (store === void 0) {\n setStateFromDevtools(lastComputedState);\n } else {\n setStateFromDevtools(lastComputedState[store]);\n }\n connection == null ? void 0 : connection.send(\n null,\n // FIXME no-any\n nextLiftedState\n );\n return;\n }\n case \"PAUSE_RECORDING\":\n return isRecording = !isRecording;\n }\n return;\n }\n });\n return initialState;\n};\nconst devtools = devtoolsImpl;\nconst parseJsonThen = (stringified, fn) => {\n let parsed;\n try {\n parsed = JSON.parse(stringified);\n } catch (e) {\n console.error(\n \"[zustand devtools middleware] Could not parse the received json\",\n e\n );\n }\n if (parsed !== void 0) fn(parsed);\n};\n\nconst subscribeWithSelectorImpl = (fn) => (set, get, api) => {\n const origSubscribe = api.subscribe;\n api.subscribe = ((selector, optListener, options) => {\n let listener = selector;\n if (optListener) {\n const equalityFn = (options == null ? void 0 : options.equalityFn) || Object.is;\n let currentSlice = selector(api.getState());\n listener = (state) => {\n const nextSlice = selector(state);\n if (!equalityFn(currentSlice, nextSlice)) {\n const previousSlice = currentSlice;\n optListener(currentSlice = nextSlice, previousSlice);\n }\n };\n if (options == null ? void 0 : options.fireImmediately) {\n optListener(currentSlice, currentSlice);\n }\n }\n return origSubscribe(listener);\n });\n const initialState = fn(set, get, api);\n return initialState;\n};\nconst subscribeWithSelector = subscribeWithSelectorImpl;\n\nfunction combine(initialState, create) {\n return (...args) => Object.assign({}, initialState, create(...args));\n}\n\nfunction createJSONStorage(getStorage, options) {\n let storage;\n try {\n storage = getStorage();\n } catch (e) {\n return;\n }\n const persistStorage = {\n getItem: (name) => {\n var _a;\n const parse = (str2) => {\n if (str2 === null) {\n return null;\n }\n return JSON.parse(str2, options == null ? void 0 : options.reviver);\n };\n const str = (_a = storage.getItem(name)) != null ? _a : null;\n if (str instanceof Promise) {\n return str.then(parse);\n }\n return parse(str);\n },\n setItem: (name, newValue) => storage.setItem(name, JSON.stringify(newValue, options == null ? void 0 : options.replacer)),\n removeItem: (name) => storage.removeItem(name)\n };\n return persistStorage;\n}\nconst toThenable = (fn) => (input) => {\n try {\n const result = fn(input);\n if (result instanceof Promise) {\n return result;\n }\n return {\n then(onFulfilled) {\n return toThenable(onFulfilled)(result);\n },\n catch(_onRejected) {\n return this;\n }\n };\n } catch (e) {\n return {\n then(_onFulfilled) {\n return this;\n },\n catch(onRejected) {\n return toThenable(onRejected)(e);\n }\n };\n }\n};\nconst persistImpl = (config, baseOptions) => (set, get, api) => {\n let options = {\n storage: createJSONStorage(() => window.localStorage),\n partialize: (state) => state,\n version: 0,\n merge: (persistedState, currentState) => ({\n ...currentState,\n ...persistedState\n }),\n ...baseOptions\n };\n let hasHydrated = false;\n let hydrationVersion = 0;\n const hydrationListeners = /* @__PURE__ */ new Set();\n const finishHydrationListeners = /* @__PURE__ */ new Set();\n let storage = options.storage;\n if (!storage) {\n return config(\n (...args) => {\n console.warn(\n `[zustand persist middleware] Unable to update item '${options.name}', the given storage is currently unavailable.`\n );\n set(...args);\n },\n get,\n api\n );\n }\n const setItem = () => {\n const state = options.partialize({ ...get() });\n return storage.setItem(options.name, {\n state,\n version: options.version\n });\n };\n const savedSetState = api.setState;\n api.setState = (state, replace) => {\n savedSetState(state, replace);\n return setItem();\n };\n const configResult = config(\n (...args) => {\n set(...args);\n return setItem();\n },\n get,\n api\n );\n api.getInitialState = () => configResult;\n let stateFromStorage;\n const hydrate = () => {\n var _a, _b;\n if (!storage) return;\n const currentVersion = ++hydrationVersion;\n hasHydrated = false;\n hydrationListeners.forEach((cb) => {\n var _a2;\n return cb((_a2 = get()) != null ? _a2 : configResult);\n });\n const postRehydrationCallback = ((_b = options.onRehydrateStorage) == null ? void 0 : _b.call(options, (_a = get()) != null ? _a : configResult)) || void 0;\n return toThenable(storage.getItem.bind(storage))(options.name).then((deserializedStorageValue) => {\n if (deserializedStorageValue) {\n if (typeof deserializedStorageValue.version === \"number\" && deserializedStorageValue.version !== options.version) {\n if (options.migrate) {\n const migration = options.migrate(\n deserializedStorageValue.state,\n deserializedStorageValue.version\n );\n if (migration instanceof Promise) {\n return migration.then((result) => [true, result]);\n }\n return [true, migration];\n }\n console.error(\n `State loaded from storage couldn't be migrated since no migrate function was provided`\n );\n } else {\n return [false, deserializedStorageValue.state];\n }\n }\n return [false, void 0];\n }).then((migrationResult) => {\n var _a2;\n if (currentVersion !== hydrationVersion) {\n return;\n }\n const [migrated, migratedState] = migrationResult;\n stateFromStorage = options.merge(\n migratedState,\n (_a2 = get()) != null ? _a2 : configResult\n );\n set(stateFromStorage, true);\n if (migrated) {\n return setItem();\n }\n }).then(() => {\n if (currentVersion !== hydrationVersion) {\n return;\n }\n postRehydrationCallback == null ? void 0 : postRehydrationCallback(get(), void 0);\n stateFromStorage = get();\n hasHydrated = true;\n finishHydrationListeners.forEach((cb) => cb(stateFromStorage));\n }).catch((e) => {\n if (currentVersion !== hydrationVersion) {\n return;\n }\n postRehydrationCallback == null ? void 0 : postRehydrationCallback(void 0, e);\n });\n };\n api.persist = {\n setOptions: (newOptions) => {\n options = {\n ...options,\n ...newOptions\n };\n if (newOptions.storage) {\n storage = newOptions.storage;\n }\n },\n clearStorage: () => {\n storage == null ? void 0 : storage.removeItem(options.name);\n },\n getOptions: () => options,\n rehydrate: () => hydrate(),\n hasHydrated: () => hasHydrated,\n onHydrate: (cb) => {\n hydrationListeners.add(cb);\n return () => {\n hydrationListeners.delete(cb);\n };\n },\n onFinishHydration: (cb) => {\n finishHydrationListeners.add(cb);\n return () => {\n finishHydrationListeners.delete(cb);\n };\n }\n };\n if (!options.skipHydration) {\n hydrate();\n }\n return stateFromStorage || configResult;\n};\nconst persist = persistImpl;\n\nfunction ssrSafe(config, isSSR = typeof window === \"undefined\") {\n return (set, get, api) => {\n if (!isSSR) {\n return config(set, get, api);\n }\n const ssrSet = () => {\n throw new Error(\"Cannot set state of Zustand store in SSR\");\n };\n api.setState = ssrSet;\n return config(ssrSet, get, api);\n };\n}\n\nexport { combine, createJSONStorage, devtools, persist, redux, subscribeWithSelector, ssrSafe as unstable_ssrSafe };\n","/**\n * Persisted widget state — the identity / consent / session-pointer client layer\n * (ADR-048, SMOODEV-2129e).\n *\n * Built on Zustand's framework-agnostic `vanilla` store + the `persist`\n * middleware (the user explicitly chose Zustand; it's ~1KB and has no React\n * dependency, so it works inside the web component). The store is keyed per\n * agent — localStorage key `smoo-chat-widget:<agentId>` — so two agents embedded\n * on the same origin don't clobber each other.\n *\n * ## What persists (and, deliberately, what does NOT)\n *\n * Only a **pointer** to the conversation plus the visitor's identity + marketing\n * consent + verified email + browser fingerprint. The transcript is **never**\n * persisted: the smooth-operator server is the source of truth and the widget\n * re-hydrates history via `getMessages` on resume. This keeps localStorage small\n * and avoids stale/divergent transcripts.\n *\n * `version` drives `persist.migrate` so future shape changes can upgrade old\n * blobs in place instead of silently dropping them.\n */\nimport { createStore, type StoreApi } from 'zustand/vanilla';\nimport { persist, type PersistStorage } from 'zustand/middleware';\n\n/** Current persisted-shape version. Bump when the shape below changes incompatibly. */\nexport const PERSIST_VERSION = 1 as const;\n\n/** Marketing-consent record captured at the pre-chat form. */\nexport interface ConsentState {\n emailOptIn: boolean;\n smsOptIn: boolean;\n /** Where the consent was captured. The widget always stamps `chat-widget-prechat`. */\n consentSource?: string;\n /** ISO 8601 timestamp stamped when the visitor ticked a consent box. */\n consentAt?: string;\n}\n\n/** Visitor identity collected from config or the pre-chat form. */\nexport interface IdentityState {\n name?: string;\n email?: string;\n phone?: string;\n}\n\n/**\n * The exact persisted shape (ADR-048 §d). Only the pointer + identity + consent\n * persist — never the transcript.\n */\nexport interface PersistedWidgetState {\n version: typeof PERSIST_VERSION;\n /** Pointer to the active conversation session; cleared on ended/404. */\n sessionId: string | null;\n identity: IdentityState;\n consent: ConsentState;\n /**\n * Email proven via OTP for the CURRENT session. Session-scoped: cleared on\n * `clearSession()` so it can't leak across visitors on a shared browser, and\n * only threaded into session metadata when {@link verifiedEmailSessionId}\n * matches the live session (i.e. on resume of the verified session) — never\n * auto-stamped onto a brand-new session.\n */\n verifiedEmail: string | null;\n /** The sessionId the {@link verifiedEmail} was proven against (binds the proof to one session). */\n verifiedEmailSessionId: string | null;\n /** Stable per-browser correlation token (see fingerprint.ts). */\n browserFingerprint: string | null;\n}\n\n/** Store actions layered on top of the persisted state. */\nexport interface WidgetStoreActions {\n setSessionId: (sessionId: string | null) => void;\n /** Merge identity fields (undefined values don't clobber existing ones). */\n mergeIdentity: (identity: IdentityState) => void;\n /** Replace consent wholesale (the pre-chat form computes the full record). */\n setConsent: (consent: ConsentState) => void;\n /** Record an OTP-proven email bound to a specific session. */\n setVerifiedEmail: (email: string | null, sessionId?: string | null) => void;\n setBrowserFingerprint: (fp: string) => void;\n /**\n * Clear the session pointer (and the session-scoped `verifiedEmail` proof) but\n * KEEP identity / consent / fingerprint — used when a persisted session has\n * ended or 404s so the next turn starts a fresh session for a known visitor.\n * `verifiedEmail` is deliberately cleared here: it is a per-session OTP proof,\n * not a durable identity, so it must NOT survive onto a new session (which on a\n * shared browser could be a different visitor).\n */\n clearSession: () => void;\n}\n\nexport type WidgetStore = PersistedWidgetState & WidgetStoreActions;\n\nconst EMPTY_CONSENT: ConsentState = { emailOptIn: false, smsOptIn: false };\n\nfunction initialPersisted(): PersistedWidgetState {\n return {\n version: PERSIST_VERSION,\n sessionId: null,\n identity: {},\n consent: { ...EMPTY_CONSENT },\n verifiedEmail: null,\n verifiedEmailSessionId: null,\n browserFingerprint: null,\n };\n}\n\n/** localStorage key for an agent's persisted widget state. */\nexport function storageKey(agentId: string): string {\n return `smoo-chat-widget:${agentId}`;\n}\n\n/**\n * An explicit in-memory (Map-backed) `PersistStorage`. Used as the fallback when\n * real localStorage is unavailable.\n *\n * IMPORTANT: we must NOT return `undefined` from {@link safeStorage} in that case.\n * zustand v5's `persist` treats a missing `storage` option by falling back to its\n * OWN `createJSONStorage(() => localStorage)` — i.e. it re-engages the very\n * localStorage the guard was trying to avoid (throwing again in privacy mode).\n * Handing it this no-op storage keeps the store working purely in memory and\n * guarantees the fallback can't touch real localStorage.\n */\nfunction memoryStorage(): PersistStorage<PersistedWidgetState> {\n const mem = new Map<string, string>();\n return {\n getItem: (name) => {\n const raw = mem.get(name);\n if (!raw) return null;\n try {\n return JSON.parse(raw) as ReturnType<PersistStorage<PersistedWidgetState>['getItem']>;\n } catch {\n return null;\n }\n },\n setItem: (name, value) => {\n mem.set(name, JSON.stringify(value));\n },\n removeItem: (name) => {\n mem.delete(name);\n },\n };\n}\n\n/**\n * A `persist` storage adapter that tolerates the *absence* of localStorage\n * (SSR, privacy-mode throwing on access, sandboxed iframes). When storage is\n * unavailable the store still works in-memory; nothing is persisted, but the\n * widget never throws on boot.\n */\nfunction safeStorage(): PersistStorage<PersistedWidgetState> {\n let ls: Storage | null = null;\n try {\n ls = typeof localStorage !== 'undefined' ? localStorage : null;\n // Probe: some environments expose localStorage but throw on access.\n if (ls) {\n const probe = '__smoo_probe__';\n ls.setItem(probe, '1');\n ls.removeItem(probe);\n }\n } catch {\n ls = null;\n }\n // Fall back to an explicit in-memory store — NEVER `undefined` (see memoryStorage).\n if (!ls) return memoryStorage();\n const storage = ls;\n return {\n getItem: (name) => {\n try {\n const raw = storage.getItem(name);\n return raw ? (JSON.parse(raw) as ReturnType<PersistStorage<PersistedWidgetState>['getItem']>) : null;\n } catch {\n return null;\n }\n },\n setItem: (name, value) => {\n try {\n storage.setItem(name, JSON.stringify(value));\n } catch {\n /* quota / privacy-mode write failures are non-fatal */\n }\n },\n removeItem: (name) => {\n try {\n storage.removeItem(name);\n } catch {\n /* non-fatal */\n }\n },\n };\n}\n\n/**\n * Migrate a persisted blob from an older `version` to the current shape. Today\n * v1 is the only version, so this just backfills any missing fields onto an\n * unknown old blob; future versions add `case` branches here.\n */\nfunction migrate(persisted: unknown): PersistedWidgetState {\n const base = initialPersisted();\n if (!persisted || typeof persisted !== 'object') return base;\n const p = persisted as Partial<PersistedWidgetState>;\n return {\n version: PERSIST_VERSION,\n sessionId: typeof p.sessionId === 'string' ? p.sessionId : null,\n identity: {\n name: typeof p.identity?.name === 'string' ? p.identity.name : undefined,\n email: typeof p.identity?.email === 'string' ? p.identity.email : undefined,\n phone: typeof p.identity?.phone === 'string' ? p.identity.phone : undefined,\n },\n consent: {\n emailOptIn: p.consent?.emailOptIn === true,\n smsOptIn: p.consent?.smsOptIn === true,\n consentSource: typeof p.consent?.consentSource === 'string' ? p.consent.consentSource : undefined,\n consentAt: typeof p.consent?.consentAt === 'string' ? p.consent.consentAt : undefined,\n },\n verifiedEmail: typeof p.verifiedEmail === 'string' ? p.verifiedEmail : null,\n verifiedEmailSessionId: typeof p.verifiedEmailSessionId === 'string' ? p.verifiedEmailSessionId : null,\n browserFingerprint: typeof p.browserFingerprint === 'string' ? p.browserFingerprint : null,\n };\n}\n\n/**\n * Create the per-agent persisted Zustand store. The `partialize` step ensures\n * only the persisted shape (never any future transient action/UI state) is\n * written to localStorage.\n */\nexport function createWidgetStore(agentId: string): StoreApi<WidgetStore> {\n return createStore<WidgetStore>()(\n persist(\n (set) => ({\n ...initialPersisted(),\n setSessionId: (sessionId) => set({ sessionId }),\n mergeIdentity: (identity) =>\n set((state) => ({\n identity: {\n ...state.identity,\n ...(identity.name !== undefined ? { name: identity.name } : {}),\n ...(identity.email !== undefined ? { email: identity.email } : {}),\n ...(identity.phone !== undefined ? { phone: identity.phone } : {}),\n },\n })),\n setConsent: (consent) => set({ consent: { ...consent } }),\n setVerifiedEmail: (verifiedEmail, sessionId) =>\n set((state) => ({\n verifiedEmail,\n // Bind the proof to the session it was verified against. When the\n // caller omits sessionId, fall back to the live pointer so the\n // proof is never left unbound.\n verifiedEmailSessionId: verifiedEmail === null ? null : (sessionId ?? state.sessionId),\n })),\n setBrowserFingerprint: (browserFingerprint) => set({ browserFingerprint }),\n // Drop the pointer AND the session-scoped OTP proof; keep durable identity.\n clearSession: () => set({ sessionId: null, verifiedEmail: null, verifiedEmailSessionId: null }),\n }),\n {\n name: storageKey(agentId),\n version: PERSIST_VERSION,\n storage: safeStorage(),\n migrate,\n // Persist ONLY the data shape — never the action functions.\n partialize: (state): PersistedWidgetState => ({\n version: PERSIST_VERSION,\n sessionId: state.sessionId,\n identity: state.identity,\n consent: state.consent,\n verifiedEmail: state.verifiedEmail,\n verifiedEmailSessionId: state.verifiedEmailSessionId,\n browserFingerprint: state.browserFingerprint,\n }),\n },\n ),\n );\n}\n","/**\n * ConversationController — the bridge between the widget UI and the\n * `@smooai/smooth-operator` protocol client.\n *\n * This is the piece that was rewired: the original smooai widget spoke to\n * `@smooai/realtime`; here every protocol action goes through {@link SmoothAgentClient}.\n * The wire shapes are identical (the protocol was lifted from `@smooai/realtime`),\n * so the swap is purely at the client-library boundary.\n *\n * Flow:\n * 1. `connect()` → opens the WebSocket transport and `create_conversation_session`\n * (or RESUMES a persisted session via `get_session`/`get_messages`).\n * 2. `send(text)` → `send_message`, streaming `stream_token` deltas into the\n * in-progress assistant message, then the terminal\n * `eventual_response`.\n *\n * 0.7.0 (SMOODEV-2129e) adds the identity / persistence / consent client layer:\n * - `browserFingerprint` computed once + sent on every `create_conversation_session`.\n * - identity + marketing consent threaded into the session `metadata`.\n * - same-session RESUME on load (no engine change — `get_session` + `get_messages`).\n * - returning-visitor RESUME via `POST /internal/resume-by-fingerprint`, and\n * cross-device \"restore my chats\" via the `POST /internal/identity/{request-otp,\n * verify-otp,resolve}` routes on the chat-ws wrapper. The engine (smooth-operator\n * 1.8.0) owns the `/ws` dispatch and REJECTS unknown verbs, so these are HTTP\n * `fetch()` calls (origin-allowlisted + optional authContext, per ADR-046/048) —\n * NOT WS frames.\n *\n * The controller is UI-agnostic: it emits typed events and the view renders them.\n */\nimport { type Citation, ProtocolError, type ServerEvent, SmoothAgentClient } from '@smooai/smooth-operator';\nimport type { StoreApi } from 'zustand/vanilla';\nimport type { ChatWidgetConfig } from './config.js';\nimport { getOrCreateFingerprint } from './fingerprint.js';\nimport { type ConsentState, createWidgetStore, type WidgetStore } from './persistence.js';\n\n/**\n * Derive the HTTP base for the chat-ws wrapper's `/internal/*` REST routes from\n * the WS endpoint: `wss://ai.smoo.ai/ws` → `https://ai.smoo.ai`. The engine\n * (smooth-operator 1.8.0) owns the `/ws` dispatch and REJECTS unknown verbs, so\n * the cross-device identity flow + fingerprint resume are HTTP POST routes on the\n * wrapper (origin-allowlisted + authContext, per ADR-046/ADR-048) — NOT WS frames.\n */\nexport function httpBaseFromWsEndpoint(endpoint: string): string | null {\n try {\n const u = new URL(endpoint);\n u.protocol = u.protocol === 'ws:' ? 'http:' : u.protocol === 'wss:' ? 'https:' : u.protocol;\n // The REST routes live at the host root (`/internal/*`), not under `/ws`.\n return `${u.protocol}//${u.host}`;\n } catch {\n // FAIL LOUD on a non-absolute endpoint. A relative fallback (e.g.\n // `string.replace`) would yield a relative base, and `fetch(\\`${base}/internal/...\\`)`\n // would then POST identity/OTP data to the HOST page origin (e.g. smoo.ai)\n // instead of the operator host (ai.smoo.ai) — leaking it to the wrong origin.\n // Returning null forces the controller into an error state and refuses the\n // `/internal/*` calls rather than mis-targeting them.\n return null;\n }\n}\n\nexport type { Citation };\n\nexport type Role = 'user' | 'assistant';\n\n/**\n * One tool invocation within an assistant turn. Mirrors the smooth daemon SPA's\n * `ToolCall` (`crates/smooth-web/web/src/operator.ts`): opens `done: false` on the\n * tool call and resolves on the tool result.\n */\nexport interface ToolCall {\n /** Stable id for keyed rendering (assigned when the call opens). */\n id: string;\n name: string;\n /** Raw arguments, JSON-stringified. */\n args: string;\n /** Present once the tool resolves. */\n result?: string;\n isError?: boolean;\n done: boolean;\n}\n\n/**\n * One ordered segment of an assistant turn: a run of prose, or a tool call.\n * Preserves the interleave order the model produced (say a bit → call a tool →\n * say a bit → …) so the UI can render tool chips INLINE where the model called\n * them. Mirrors the daemon SPA's `MessageBlock`. Only populated when the widget\n * is configured with `showToolActivity: true`.\n */\nexport type MessageBlock = { kind: 'text'; text: string } | { kind: 'tool'; tool: ToolCall };\n\nexport interface ChatMessage {\n id: string;\n role: Role;\n /** Accumulated text (assistant messages grow as tokens stream in). */\n text: string;\n /** True while an assistant message is still streaming. */\n streaming: boolean;\n /**\n * Ordered text + tool segments, interleaved as the model produced them. Present\n * only on assistant messages when `showToolActivity` is enabled (absent\n * otherwise — the default popover renders `text` alone, byte-for-byte unchanged).\n */\n blocks?: MessageBlock[];\n /**\n * Sources that grounded an assistant answer, when the terminal\n * `eventual_response` carried any. Optional + back-compatible: absent when\n * the turn used no knowledge sources (or for user messages). Read\n * defensively off the terminal event — see {@link extractCitations}.\n */\n citations?: Citation[];\n /**\n * Suggested follow-up replies (\"quick replies\") the agent offered on the\n * terminal `eventual_response`. Set ONLY on the finalized assistant message —\n * never mid-stream. Read defensively (see {@link extractSuggestions}); capped\n * at 4 for layout. Absent when the turn offered none.\n */\n suggestions?: string[];\n}\n\nexport type ConnectionStatus = 'idle' | 'connecting' | 'ready' | 'error' | 'closed';\n\n/**\n * A mid-turn pause that needs the visitor to act before the agent can continue:\n *\n * - `otp` — the agent requested OTP verification before an authenticated action.\n * Resume with {@link ConversationController.verifyOtp}.\n * - `confirm` — the agent wants to run a state-mutating tool and needs approval.\n * Resume with {@link ConversationController.confirmTool}.\n * - `interaction` — the agent raised a Rich Interaction (structured card, e.g.\n * identity intake). Resume with {@link ConversationController.submitInteraction}\n * or {@link ConversationController.declineInteraction}.\n */\nexport type Interrupt =\n | {\n kind: 'otp';\n toolId?: string;\n actionDescription?: string;\n availableChannels: ('email' | 'sms')[];\n /** Set once the server confirms an OTP was dispatched. */\n sent?: { channel?: string; maskedDestination?: string };\n /** Set when a submitted code was rejected. */\n error?: string;\n attemptsRemaining?: number;\n }\n | { kind: 'confirm'; toolId?: string; actionDescription?: string }\n | {\n kind: 'interaction';\n /** Server-generated interaction instance id (echoed on submit). */\n interactionId: string;\n /** The Rich Interaction kind (e.g. `identity_intake`) — selects the card. */\n interactionKind: string;\n /** Kind-specific render spec (identity_intake: `{ fields: [...] }`). */\n spec: Record<string, unknown>;\n /** Why the agent raised it (card header copy). */\n reason?: string;\n /** Per-field server-side validation errors (from `interaction_invalid`). */\n errors?: { field: string; message: string }[];\n };\n\n/**\n * The Rich-Interaction render capabilities this widget declares at session\n * create (`supports`). Must stay aligned with the card registry in\n * `element.ts` (`INTERACTION_CARDS`) — registering a card IS declaring its\n * capability; a test asserts the two match.\n */\nexport const SUPPORTED_INTERACTION_CAPABILITIES: readonly string[] = ['identity_form'];\n\nexport interface UserInfo {\n name?: string;\n email?: string;\n phone?: string;\n /** Marketing-consent opt-ins captured at the pre-chat form (ADR-048). */\n consent?: { emailOptIn: boolean; smsOptIn: boolean };\n}\n\n/** One conversation surfaced by `resolve_identity` for the cross-device picker. */\nexport interface RestorableConversation {\n conversationId: string;\n sessionId: string;\n lastActivityAt?: string;\n preview?: string;\n}\n\n/**\n * State machine for the cross-device \"restore my chats\" flow. Driven by the three\n * HTTP POST routes on the chat-ws wrapper — `/internal/identity/request-otp` →\n * `/internal/identity/verify-otp` → `/internal/identity/resolve` (ADR-048 §c).\n * The view renders a panel off this.\n */\nexport type IdentityRestore =\n | { phase: 'idle' }\n /** UI-local: the email-entry step before any request is sent. */\n | { phase: 'awaiting_email'; error?: string }\n | { phase: 'requesting'; email: string; channel: 'email' | 'sms' }\n | { phase: 'awaiting_code'; email: string; channel: 'email' | 'sms'; maskedDestination?: string; error?: string; attemptsRemaining?: number }\n | { phase: 'verifying'; email: string; channel: 'email' | 'sms' }\n | { phase: 'resolving'; email: string }\n | { phase: 'resolved'; email: string; conversations: RestorableConversation[] }\n | { phase: 'error'; message: string };\n\nexport interface ConversationEvents {\n /** Fired whenever the message list changes (append, token delta, finalize). */\n onMessages: (messages: ChatMessage[]) => void;\n /** Fired on connection-status transitions. */\n onStatus: (status: ConnectionStatus, detail?: string) => void;\n /** Fired when a turn pauses for OTP / tool-confirmation, and `null` when it clears. */\n onInterrupt?: (interrupt: Interrupt | null) => void;\n /** Fired on cross-device identity-restore state transitions. */\n onIdentityRestore?: (state: IdentityRestore) => void;\n}\n\n/** Pull the final assistant text out of an `eventual_response` data payload. */\nfunction extractFinalText(response: unknown): string | null {\n if (!response || typeof response !== 'object') return null;\n const r = response as { responseParts?: unknown };\n if (Array.isArray(r.responseParts)) {\n return r.responseParts.filter((p): p is string => typeof p === 'string').join('\\n\\n');\n }\n return null;\n}\n\n/**\n * Pull the grounding {@link Citation}s out of a terminal `eventual_response`.\n *\n * The protocol client types these (`eventual_response.data.data.citations`),\n * but they're optional and back-compatible — absent when the turn used no\n * knowledge sources. We read them defensively (tolerating their total absence,\n * non-array shapes, and missing fields) so a server that doesn't emit them, or\n * an older client, can't break rendering. Each citation always carries\n * `id`/`title`/`snippet`/`score`; `url` is present only for web-sourced docs.\n */\nfunction extractCitations(inner: unknown): Citation[] {\n if (!inner || typeof inner !== 'object') return [];\n const raw = (inner as { citations?: unknown }).citations;\n if (!Array.isArray(raw)) return [];\n const out: Citation[] = [];\n for (const c of raw) {\n if (!c || typeof c !== 'object') continue;\n const obj = c as Record<string, unknown>;\n const id = typeof obj.id === 'string' ? obj.id : '';\n const title = typeof obj.title === 'string' ? obj.title : id || 'Source';\n const snippet = typeof obj.snippet === 'string' ? obj.snippet : '';\n const url = typeof obj.url === 'string' && obj.url ? obj.url : undefined;\n const score = typeof obj.score === 'number' ? obj.score : 0;\n out.push({ id, title, snippet, score, url });\n }\n return out;\n}\n\n/**\n * Pull the suggested follow-up replies out of a terminal `eventual_response`'s\n * `response` object (`response.suggestedNextActions`). Optional + back-compatible\n * like citations — read defensively (tolerating absence, non-array shapes, and\n * non-string / blank entries) and capped at 4 so a chatty agent can't overflow\n * the composer chip row.\n */\nfunction extractSuggestions(response: unknown): string[] {\n if (!response || typeof response !== 'object') return [];\n const raw = (response as { suggestedNextActions?: unknown }).suggestedNextActions;\n if (!Array.isArray(raw)) return [];\n return raw.filter((s): s is string => typeof s === 'string' && s.trim().length > 0).slice(0, 4);\n}\n\n/** A `get_conversation_messages` row, narrowed defensively off the wire. */\ninterface WireMessage {\n id?: string;\n direction?: 'inbound' | 'outbound';\n content?: { text?: string };\n createdAt?: string;\n}\n\n/** Convert a server message row into a finalized {@link ChatMessage}. */\nfunction wireMessageToChat(m: WireMessage, idx: number): ChatMessage | null {\n const text = typeof m.content?.text === 'string' ? m.content.text : '';\n if (!text) return null;\n const role: Role = m.direction === 'outbound' ? 'assistant' : 'user';\n return { id: typeof m.id === 'string' ? m.id : `hist-${idx}`, role, text, streaming: false };\n}\n\nlet toolSeq = 0;\nconst nextToolId = (): string => `tool-${++toolSeq}`;\n\n/** Grow the trailing text block, or open a new one if the last block was a tool. */\nfunction growTextBlock(blocks: MessageBlock[], text: string): void {\n if (!text) return;\n const last = blocks[blocks.length - 1];\n if (last && last.kind === 'text') last.text += text;\n else blocks.push({ kind: 'text', text });\n}\n\n/**\n * Fold a `stream_chunk` node-state into the ordered block list, returning `true`\n * when the chunk carried tool activity.\n *\n * Tool activity rides `state.rawResponse.toolCall` / `state.rawResponse.toolResult`\n * — **NOT** `state.toolResult`. Reading the wrong path leaves every chip stuck on\n * \"running…\" forever (the exact bug the daemon SPA hit and this mirror avoids).\n */\nfunction applyToolChunk(blocks: MessageBlock[], state: unknown): boolean {\n const raw = (state as { rawResponse?: unknown } | null | undefined)?.rawResponse;\n if (!raw || typeof raw !== 'object') return false;\n const call = (raw as { toolCall?: { name?: string; arguments?: unknown } }).toolCall;\n const res = (raw as { toolResult?: { name?: string; isError?: boolean; result?: unknown } }).toolResult;\n if (call) {\n const args = typeof call.arguments === 'string' ? call.arguments : JSON.stringify(call.arguments ?? {});\n blocks.push({ kind: 'tool', tool: { id: nextToolId(), name: call.name ?? '', args, done: false } });\n return true;\n }\n if (res) {\n const result = typeof res.result === 'string' ? res.result : JSON.stringify(res.result ?? '');\n // Complete the most-recent still-open tool block matching this name.\n for (let i = blocks.length - 1; i >= 0; i--) {\n const b = blocks[i];\n if (b && b.kind === 'tool' && b.tool.name === (res.name ?? '') && !b.tool.done) {\n b.tool.done = true;\n b.tool.isError = !!res.isError;\n b.tool.result = result;\n break;\n }\n }\n return true;\n }\n return false;\n}\n\nexport class ConversationController {\n private readonly config: ChatWidgetConfig;\n private readonly events: ConversationEvents;\n private readonly store: StoreApi<WidgetStore>;\n private client: SmoothAgentClient | null = null;\n private sessionId: string | null = null;\n private readonly messages: ChatMessage[] = [];\n private status: ConnectionStatus = 'idle';\n private seq = 0;\n /** requestId of the in-flight turn — used to resume OTP / tool confirmations. */\n private activeRequestId: string | null = null;\n private interrupt: Interrupt | null = null;\n /** Values from the last interaction submit, merged into the persisted\n * identity (identity_intake only) once the server acks them. */\n private pendingInteractionValues: { kind: string; values: Record<string, unknown> } | null = null;\n private identityRestore: IdentityRestore = { phase: 'idle' };\n /**\n * True once the resume probe (persisted-pointer get_session OR the\n * `/internal/resume-by-fingerprint` POST) has run for this controller. Makes\n * `connect()` idempotent: re-entering after a transient `error` status (e.g. a\n * retried `send()`) creates a fresh session rather than re-running the resume\n * probe — which would fire another `resumeByFingerprint` POST and could adopt a\n * session we already decided not to resume.\n */\n private resumeAttempted = false;\n /**\n * HTTP base for the chat-ws wrapper's `/internal/*` REST routes. `null` when\n * the configured WS endpoint could not be parsed into an absolute origin — in\n * that case the `/internal/*` routes are refused (rather than mis-targeted at\n * the host page origin). See {@link httpBaseFromWsEndpoint}.\n */\n private readonly httpBase: string | null;\n\n constructor(config: ChatWidgetConfig, events: ConversationEvents, store?: StoreApi<WidgetStore>) {\n this.config = config;\n this.events = events;\n this.httpBase = httpBaseFromWsEndpoint(config.endpoint);\n if (this.httpBase === null) {\n // A non-absolute endpoint means the identity / resume `/internal/*` routes\n // have no safe target. Flag the controller in error so the UI surfaces it\n // and the routes refuse (see postInternal) rather than mis-targeting the\n // host page origin. Deferred to a microtask so listeners attached after\n // construction still observe the transition.\n queueMicrotask(() => this.setStatus('error', `Invalid chat endpoint: ${config.endpoint}`));\n }\n this.store = store ?? createWidgetStore(config.agentId);\n // Seed identity from config into the persisted store. `mergeIdentity` is\n // applied on EVERY construct, so a config-provided field always wins over\n // the persisted value (config is authoritative when present). Fields the\n // config does NOT provide keep their persisted value — those survive across\n // reloads; explicitly-configured ones are re-applied each load.\n const seed: { name?: string; email?: string; phone?: string } = {};\n if (config.userName) seed.name = config.userName;\n if (config.userEmail) seed.email = config.userEmail;\n if (config.userPhone) seed.phone = config.userPhone;\n if (Object.keys(seed).length > 0) this.store.getState().mergeIdentity(seed);\n }\n\n get connectionStatus(): ConnectionStatus {\n return this.status;\n }\n\n /** The persisted store, exposed so the view can read identity for the pre-chat gate. */\n getStore(): StoreApi<WidgetStore> {\n return this.store;\n }\n\n /** True when a persisted session pointer exists (drives the resume path). */\n hasPersistedSession(): boolean {\n return !!this.store.getState().sessionId;\n }\n\n /** True when persisted identity exists (lets the view skip the pre-chat form). */\n hasPersistedIdentity(): boolean {\n const id = this.store.getState().identity;\n return !!(id.name || id.email || id.phone);\n }\n\n /** Merge in visitor identity + consent (from the pre-chat form). Applied on next connect. */\n setUserInfo(info: UserInfo): void {\n const { name, email, phone, consent } = info;\n this.store.getState().mergeIdentity({ name, email, phone });\n if (consent) {\n const consentAt = consent.emailOptIn || consent.smsOptIn ? new Date().toISOString() : undefined;\n this.store.getState().setConsent({\n emailOptIn: consent.emailOptIn,\n smsOptIn: consent.smsOptIn,\n consentSource: 'chat-widget-prechat',\n consentAt,\n });\n }\n }\n\n private setInterrupt(interrupt: Interrupt | null): void {\n this.interrupt = interrupt;\n this.events.onInterrupt?.(interrupt);\n }\n\n private setIdentityRestore(state: IdentityRestore): void {\n this.identityRestore = state;\n this.events.onIdentityRestore?.(state);\n }\n\n get currentIdentityRestore(): IdentityRestore {\n return this.identityRestore;\n }\n\n /** Submit an OTP code to resume the paused turn. No-op if not awaiting OTP. */\n verifyOtp(code: string): void {\n if (!this.client || !this.sessionId || !this.activeRequestId || this.interrupt?.kind !== 'otp') return;\n this.client.verifyOtp({ sessionId: this.sessionId, requestId: this.activeRequestId, code });\n }\n\n /** Approve or reject a pending tool write to resume the paused turn. */\n confirmTool(approved: boolean): void {\n if (!this.client || !this.sessionId || !this.activeRequestId || this.interrupt?.kind !== 'confirm') return;\n this.client.confirmToolAction({ sessionId: this.sessionId, requestId: this.activeRequestId, approved });\n this.setInterrupt(null);\n }\n\n /**\n * Submit a Rich Interaction card to resume the parked turn. The server\n * routes to the kind's validator: invalid values come back as an\n * `interaction_invalid` event (the card re-renders with per-field errors —\n * the turn stays parked); a valid submit is acked and the turn resumes.\n * No-op if not awaiting an interaction.\n */\n submitInteraction(values: Record<string, unknown>): void {\n if (!this.client || !this.sessionId || !this.activeRequestId || this.interrupt?.kind !== 'interaction') return;\n // Stash the values so the ack (immediate_response) can merge accepted\n // identity values into the persisted store.\n this.pendingInteractionValues = { kind: this.interrupt.interactionKind, values };\n this.client.submitInteraction({\n sessionId: this.sessionId,\n requestId: this.activeRequestId,\n interactionId: this.interrupt.interactionId,\n kind: this.interrupt.interactionKind,\n values,\n });\n }\n\n /** Decline the pending Rich Interaction; the agent continues without it. */\n declineInteraction(): void {\n if (!this.client || !this.sessionId || !this.activeRequestId || this.interrupt?.kind !== 'interaction') return;\n this.client.submitInteraction({\n sessionId: this.sessionId,\n requestId: this.activeRequestId,\n interactionId: this.interrupt.interactionId,\n kind: this.interrupt.interactionKind,\n declined: true,\n });\n this.pendingInteractionValues = null;\n this.setInterrupt(null);\n }\n\n private nextId(prefix: string): string {\n this.seq += 1;\n return `${prefix}-${this.seq}-${Date.now().toString(36)}`;\n }\n\n private setStatus(status: ConnectionStatus, detail?: string): void {\n this.status = status;\n this.events.onStatus(status, detail);\n }\n\n private emitMessages(): void {\n // Hand out a shallow copy so the view can't mutate internal state.\n this.events.onMessages(this.messages.map((m) => ({ ...m })));\n }\n\n /** Compute (once) + return the persisted browser fingerprint. */\n private fingerprint(): string {\n const state = this.store.getState();\n return getOrCreateFingerprint(\n () => state.browserFingerprint,\n (fp) => this.store.getState().setBrowserFingerprint(fp),\n );\n }\n\n /**\n * Build the `metadata` payload threaded into `create_conversation_session`:\n * phone (no first-class engine field) and consent.\n *\n * NOTE: `verifiedEmail` is deliberately NOT stamped here. It is a per-session\n * OTP proof bound to the session it was verified against\n * (`verifiedEmailSessionId`), and the server only treats an actual OTP `verify`\n * as proof — metadata `verifiedEmail` is just a hint. Auto-stamping it onto\n * every brand-new `create_conversation_session` would mislabel a fresh\n * visitor's session with a prior (possibly different) visitor's email on a\n * shared browser. The verified email is only used when RESUMING the exact\n * session it was proven for — see {@link verifiedEmailForSession}.\n */\n private sessionMetadata(): Record<string, unknown> | undefined {\n const state = this.store.getState();\n const meta: Record<string, unknown> = {};\n if (state.identity.phone) meta.userPhone = state.identity.phone;\n const consent = state.consent;\n if (consent.emailOptIn || consent.smsOptIn || consent.consentAt) {\n const c: ConsentState = {\n emailOptIn: consent.emailOptIn,\n smsOptIn: consent.smsOptIn,\n consentSource: consent.consentSource ?? 'chat-widget-prechat',\n };\n if (consent.consentAt) c.consentAt = consent.consentAt;\n meta.consent = c;\n }\n return Object.keys(meta).length > 0 ? meta : undefined;\n }\n\n /**\n * The verified-email hint, but ONLY when the OTP proof is bound to the session\n * being resumed (`verifiedEmailSessionId === sessionId`). Returns null\n * otherwise so a stale/cross-visitor proof is never threaded onto a session it\n * wasn't proven for.\n */\n private verifiedEmailForSession(sessionId: string): string | null {\n const state = this.store.getState();\n if (state.verifiedEmail && state.verifiedEmailSessionId === sessionId) {\n return state.verifiedEmail;\n }\n return null;\n }\n\n /** Lazily open the WS client (default transport). Idempotent within a connect. */\n private async ensureClient(): Promise<void> {\n if (this.client) return;\n this.client = new SmoothAgentClient({ url: this.config.endpoint });\n await this.client.connect();\n }\n\n /**\n * Open the connection and either RESUME or create a session.\n *\n * 1. Persisted pointer (ADR-048 §b): `get_session` → if not `ended`, reuse +\n * hydrate from `get_messages` (newest-first, reversed). On ended/404 clear\n * ONLY the pointer (identity/consent survive).\n * 2. No persisted pointer: POST `/internal/resume-by-fingerprint` FIRST; if\n * `resumable`, adopt the returned session (the wrapper has primed the\n * operator registry), reuse the sessionId, and hydrate via get_session/\n * get_messages — rather than relying on createConversationSession to resume.\n * 3. Otherwise create a fresh session.\n */\n async connect(): Promise<void> {\n if (this.status === 'connecting' || this.status === 'ready') return;\n this.setStatus('connecting');\n try {\n await this.ensureClient();\n // The resume probe (persisted-pointer get_session OR the fingerprint\n // resume POST) runs AT MOST ONCE per controller lifecycle. Re-entering\n // connect() after a transient error (e.g. a retried send()) must not\n // re-run the probe — that would re-fire resumeByFingerprint and could\n // adopt a session we already chose not to resume. After the first\n // attempt, fall straight through to creating a fresh session.\n if (!this.resumeAttempted) {\n this.resumeAttempted = true;\n const persistedSessionId = this.store.getState().sessionId;\n if (persistedSessionId) {\n const resumed = await this.tryResume(persistedSessionId);\n if (resumed) {\n this.setStatus('ready');\n return;\n }\n // Resume failed (ended/404/gone) — clear the pointer, keep identity.\n this.store.getState().clearSession();\n } else {\n // Returning anonymous visitor with no stored pointer: ask the\n // wrapper to resolve a recent session for this fingerprint.\n const fpSessionId = await this.resumeByFingerprint();\n if (fpSessionId) {\n const resumed = await this.tryResume(fpSessionId);\n if (resumed) {\n this.store.getState().setSessionId(fpSessionId);\n this.setStatus('ready');\n return;\n }\n }\n }\n }\n await this.createSession();\n this.setStatus('ready');\n } catch (err) {\n this.setStatus('error', err instanceof Error ? err.message : String(err));\n throw err;\n }\n }\n\n // ─────────────────────── chat-ws `/internal/*` HTTP ─────────────────────────\n\n /**\n * Build the auth fields every `/internal/*` route shares: `agentId` (required\n * for the agent-policy lookup), `agentName` (used as the OTP email sender), and\n * the optional pre-auth `authContext` the host page may have configured. The\n * `Origin` header is sent automatically by the browser and checked server-side.\n */\n private authBody(): Record<string, unknown> {\n const body: Record<string, unknown> = { agentId: this.config.agentId };\n if (this.config.agentName) body.agentName = this.config.agentName;\n if (this.config.authContext) body.authContext = this.config.authContext;\n return body;\n }\n\n /** POST JSON to a `/internal/*` route; returns the parsed body (or throws). */\n private async postInternal(path: string, payload: Record<string, unknown>): Promise<Record<string, unknown>> {\n if (this.httpBase === null) {\n // No absolute origin could be derived from the WS endpoint — refuse the\n // call loudly rather than POST identity data to a relative (host-page) URL.\n throw new Error(`Cannot reach ${path}: the chat endpoint is not an absolute URL.`);\n }\n const res = await fetch(`${this.httpBase}${path}`, {\n method: 'POST',\n headers: { 'content-type': 'application/json' },\n // Auth is the `Origin` allowlist + the `authContext` body field — NOT\n // cookies. `credentials: 'include'` would force the server to reply with\n // `Access-Control-Allow-Credentials: true` AND a reflected origin (a\n // wildcard `*` is illegal with credentials), so a plain origin-allowlisted\n // CORS config would fail the preflight and break EVERY `/internal/*` call.\n // Omit credentials so the cross-origin POST works against an allowlist\n // that doesn't (and shouldn't need to) opt into credentialed CORS.\n credentials: 'omit',\n body: JSON.stringify({ ...this.authBody(), ...payload }),\n });\n let json: Record<string, unknown> = {};\n try {\n json = (await res.json()) as Record<string, unknown>;\n } catch {\n json = {};\n }\n if (!res.ok) {\n const err = json.error as { code?: string; message?: string } | undefined;\n throw new Error(err?.message ?? `${path} failed (${res.status})`);\n }\n return json;\n }\n\n /**\n * POST `/internal/resume-by-fingerprint`. Returns the resumable sessionId when\n * the wrapper found (and primed) a recent session for this fingerprint, else\n * null. Network/route failures are swallowed → null (fall through to create).\n */\n private async resumeByFingerprint(): Promise<string | null> {\n try {\n const json = await this.postInternal('/internal/resume-by-fingerprint', { browserFingerprint: this.fingerprint() });\n if (json.resumable === true && typeof json.sessionId === 'string') {\n return json.sessionId;\n }\n } catch {\n // Resume is best-effort; any failure just means a fresh session.\n }\n return null;\n }\n\n /** `create_conversation_session` with fingerprint + identity + consent metadata. */\n private async createSession(): Promise<void> {\n if (!this.client) throw new Error('Conversation is not connected');\n const state = this.store.getState();\n const metadata = this.sessionMetadata();\n const session = await this.client.createConversationSession({\n agentId: this.config.agentId,\n userName: state.identity.name,\n userEmail: state.identity.email,\n browserFingerprint: this.fingerprint(),\n // Declare the Rich-Interaction cards this widget can render (derived\n // from the card registry), so the server emits `interaction_required`\n // for those kinds instead of the conversational fallback.\n supports: [...SUPPORTED_INTERACTION_CAPABILITIES],\n ...(metadata ? { metadata } : {}),\n });\n this.sessionId = session.sessionId;\n this.store.getState().setSessionId(session.sessionId);\n }\n\n /**\n * Attempt to resume `sessionId`: returns true and hydrates the transcript when\n * the session is live, false when it has ended / can't be fetched.\n */\n private async tryResume(sessionId: string): Promise<boolean> {\n if (!this.client) return false;\n let snap: { status?: 'active' | 'idle' | 'ended' };\n try {\n snap = await this.client.getSession({ sessionId });\n } catch {\n return false; // 404 / SESSION_NOT_FOUND / network — start fresh.\n }\n if (snap.status === 'ended') return false;\n\n this.sessionId = sessionId;\n await this.hydrateHistory(sessionId);\n return true;\n }\n\n /** Page recent history (newest-first), reverse to chronological, and render. */\n private async hydrateHistory(sessionId: string): Promise<void> {\n if (!this.client) return;\n try {\n const page = await this.client.getMessages({ sessionId, limit: 50 });\n const rows = Array.isArray(page.messages) ? page.messages : [];\n // The server returns newest-first; reverse to chronological for the UI.\n const chronological = [...rows].reverse();\n const hydrated: ChatMessage[] = [];\n chronological.forEach((m, i) => {\n const chat = wireMessageToChat(m as WireMessage, i);\n if (chat) hydrated.push(chat);\n });\n this.messages.length = 0;\n this.messages.push(...hydrated);\n this.emitMessages();\n } catch {\n // History fetch is best-effort: a resumable session with no fetchable\n // history just shows an empty transcript rather than failing the resume.\n }\n }\n\n /**\n * Submit a user message. Appends the user bubble immediately, then streams the\n * assistant reply token-by-token, finalizing on `eventual_response`.\n */\n async send(text: string): Promise<void> {\n const trimmed = text.trim();\n if (!trimmed) return;\n if (!this.client || !this.sessionId || this.status !== 'ready') {\n await this.connect();\n }\n if (!this.client || !this.sessionId) {\n throw new Error('Conversation is not connected');\n }\n\n // 1. User bubble.\n this.messages.push({ id: this.nextId('u'), role: 'user', text: trimmed, streaming: false });\n\n // 2. Placeholder assistant bubble we grow as tokens arrive.\n const showTools = this.config.showToolActivity === true;\n const assistant: ChatMessage = { id: this.nextId('a'), role: 'assistant', text: '', streaming: true, blocks: showTools ? [] : undefined };\n this.messages.push(assistant);\n this.emitMessages();\n\n try {\n const turn = this.client.sendMessage({ sessionId: this.sessionId, message: trimmed, stream: true });\n this.activeRequestId = turn.requestId;\n\n for await (const event of turn) {\n if (event.type === 'stream_token') {\n const token = event.token ?? event.data?.token ?? '';\n if (token) {\n assistant.text += token;\n // Grow the trailing text block so prose interleaves with any\n // tool chips in the order the model produced them.\n if (showTools && assistant.blocks) growTextBlock(assistant.blocks, token);\n this.emitMessages();\n }\n } else if (showTools && event.type === 'stream_chunk') {\n // Tool activity (gated). Read state.rawResponse.toolCall/.toolResult.\n if (assistant.blocks && applyToolChunk(assistant.blocks, event.data?.state)) {\n this.emitMessages();\n }\n } else {\n // OTP / tool-confirmation pauses surface here; the loop keeps\n // iterating once the visitor resumes via verifyOtp/confirmTool.\n this.handleTurnEvent(event);\n }\n }\n\n const final = await turn;\n const inner = final.data?.data;\n const finalText = extractFinalText(inner?.response);\n if (finalText && finalText.length > assistant.text.length) {\n assistant.text = finalText;\n }\n if (!assistant.text) {\n assistant.text = '(no response)';\n }\n // Attach grounding sources from the terminal event, when present.\n const citations = extractCitations(inner);\n if (citations.length > 0) {\n assistant.citations = citations;\n }\n // Suggested follow-up replies from the terminal event, when present.\n const suggestions = extractSuggestions(inner?.response);\n if (suggestions.length > 0) {\n assistant.suggestions = suggestions;\n }\n // Only keep blocks for turns that actually invoked a tool — a prose-only\n // turn drops back to the normal markdown text path (with the final text).\n if (assistant.blocks && !assistant.blocks.some((b) => b.kind === 'tool')) {\n assistant.blocks = undefined;\n }\n assistant.streaming = false;\n this.emitMessages();\n } catch (err) {\n assistant.streaming = false;\n const message =\n err instanceof ProtocolError\n ? `Error: ${err.message}`\n : (this.config.connectionErrorMessage ?? \"We couldn't reach the chat.\");\n assistant.text = assistant.text ? `${assistant.text}\\n\\n${message}` : message;\n this.emitMessages();\n this.setStatus('error', err instanceof Error ? err.message : String(err));\n } finally {\n this.activeRequestId = null;\n this.setInterrupt(null);\n }\n }\n\n /** Map a non-token turn event (OTP / tool-confirmation lifecycle) to interrupt state. */\n private handleTurnEvent(event: ServerEvent): void {\n const inner = ((event as { data?: { data?: Record<string, unknown> } }).data?.data ?? {}) as Record<string, unknown>;\n const str = (v: unknown): string | undefined => (typeof v === 'string' ? v : undefined);\n const num = (v: unknown): number | undefined => (typeof v === 'number' ? v : undefined);\n switch (event.type) {\n case 'otp_verification_required': {\n const channels: ('email' | 'sms')[] = Array.isArray(inner.availableChannels)\n ? inner.availableChannels.filter((c): c is 'email' | 'sms' => c === 'email' || c === 'sms')\n : ['email'];\n this.setInterrupt({\n kind: 'otp',\n toolId: str(inner.toolId),\n actionDescription: str(inner.actionDescription),\n availableChannels: channels.length > 0 ? channels : ['email'],\n });\n break;\n }\n case 'otp_sent':\n if (this.interrupt?.kind === 'otp') {\n this.setInterrupt({ ...this.interrupt, sent: { channel: str(inner.channel), maskedDestination: str(inner.maskedDestination) }, error: undefined });\n }\n break;\n case 'otp_verified':\n if (this.interrupt?.kind === 'otp') this.setInterrupt(null);\n break;\n case 'otp_invalid':\n if (this.interrupt?.kind === 'otp') {\n this.setInterrupt({ ...this.interrupt, error: str(inner.message) ?? 'That code was incorrect.', attemptsRemaining: num(inner.attemptsRemaining) });\n }\n break;\n case 'write_confirmation_required':\n this.setInterrupt({ kind: 'confirm', toolId: str(inner.toolId), actionDescription: str(inner.actionDescription) });\n break;\n case 'interaction_required': {\n const interactionId = str(inner.interactionId);\n const kind = str(inner.kind);\n const spec = inner.spec && typeof inner.spec === 'object' ? (inner.spec as Record<string, unknown>) : {};\n if (!interactionId || !kind) break; // not renderable — ignore\n this.pendingInteractionValues = null;\n this.setInterrupt({\n kind: 'interaction',\n interactionId,\n interactionKind: kind,\n spec,\n reason: str(inner.reason),\n });\n break;\n }\n case 'interaction_invalid':\n if (this.interrupt?.kind === 'interaction' && this.interrupt.interactionId === str(inner.interactionId)) {\n const errors: { field: string; message: string }[] = [];\n if (Array.isArray(inner.errors)) {\n for (const e of inner.errors) {\n if (!e || typeof e !== 'object') continue;\n const o = e as Record<string, unknown>;\n const field = str(o.field);\n if (field) errors.push({ field, message: str(o.message) ?? 'Invalid value' });\n }\n }\n this.pendingInteractionValues = null;\n this.setInterrupt({ ...this.interrupt, errors });\n }\n break;\n case 'immediate_response':\n // Mid-turn immediate_response while an interaction card is showing\n // is the submit/decline ack: the park resolved — clear the card\n // and, for accepted identity values, persist them.\n if (this.interrupt?.kind === 'interaction') {\n const pending = this.pendingInteractionValues;\n if (pending && pending.kind === 'identity_intake') {\n const v = pending.values as { name?: string; email?: string; phone?: string };\n this.store.getState().mergeIdentity({ name: v.name, email: v.email, phone: v.phone });\n }\n this.pendingInteractionValues = null;\n this.setInterrupt(null);\n }\n break;\n default:\n break;\n }\n }\n\n // ─────────────────── Cross-device \"restore my chats\" (§c) ───────────────────\n //\n // Three HTTP POST routes on the chat-ws wrapper (the engine `/ws` dispatch\n // rejects unknown verbs): request-otp → verify-otp → resolve. ALL THREE are\n // session-scoped — they require a live `sessionId` (a uuid). request-otp\n // establishes the session itself (idempotent connect) before sending, so the\n // whole flow shares one session and verify-otp can't hit \"No active session\"\n // even if the email was submitted before the initial connect() resolved.\n\n /**\n * Begin the cross-device restore: POST `/internal/identity/request-otp` for\n * `email` over `channel`. The view collects the email via an explicit affordance.\n */\n async requestIdentityOtp(email: string, channel: 'email' | 'sms' = 'email'): Promise<void> {\n const trimmed = email.trim();\n if (!trimmed) return;\n this.setIdentityRestore({ phase: 'requesting', email: trimmed, channel });\n // request-otp must be SESSION-CONSISTENT with verify-otp (which hard-requires\n // a sessionId). If the restore affordance fired request-otp before connect()\n // resolved, there'd be no sessionId here and verify-otp would later error\n // \"No active session.\" Establish a session first (idempotent connect), then\n // require it — so the whole request → verify flow shares one live session.\n if (!this.sessionId) {\n try {\n await this.connect();\n } catch {\n /* fall through: handled by the sessionId check below */\n }\n }\n if (!this.sessionId) {\n this.setIdentityRestore({ phase: 'error', message: 'No active session to verify against.' });\n return;\n }\n try {\n const json = await this.postInternal('/internal/identity/request-otp', {\n sessionId: this.sessionId,\n email: trimmed,\n channel,\n });\n const masked = typeof json.maskedDestination === 'string' ? json.maskedDestination : undefined;\n this.setIdentityRestore({ phase: 'awaiting_code', email: trimmed, channel, maskedDestination: masked });\n } catch (err) {\n this.setIdentityRestore({ phase: 'error', message: err instanceof Error ? err.message : 'Could not send a verification code.' });\n }\n }\n\n /** Submit the code: POST `/internal/identity/verify-otp`, then resolve on success. */\n async verifyIdentityOtp(code: string): Promise<void> {\n const state = this.identityRestore;\n const trimmed = code.trim();\n if (!trimmed || state.phase !== 'awaiting_code') return;\n const { email, channel } = state;\n if (!this.sessionId) {\n this.setIdentityRestore({ phase: 'error', message: 'No active session to verify against.' });\n return;\n }\n this.setIdentityRestore({ phase: 'verifying', email, channel });\n try {\n const json = await this.postInternal('/internal/identity/verify-otp', { sessionId: this.sessionId, email, code: trimmed });\n if (json.event === 'otp_verified') {\n // Bind the OTP proof to the session it was verified against, so it\n // can't leak onto a different visitor's session on a shared browser.\n this.store.getState().setVerifiedEmail(email, this.sessionId);\n await this.resolveIdentity(email);\n } else if (json.event === 'otp_invalid') {\n const remaining = typeof json.attemptsRemaining === 'number' ? json.attemptsRemaining : undefined;\n this.setIdentityRestore({ phase: 'awaiting_code', email, channel, error: 'That code was incorrect.', attemptsRemaining: remaining });\n } else {\n this.setIdentityRestore({ phase: 'error', message: 'Verification failed.' });\n }\n } catch (err) {\n this.setIdentityRestore({ phase: 'error', message: err instanceof Error ? err.message : 'Verification failed.' });\n }\n }\n\n /** Resolve the verified identity → restorable conversations via POST `/internal/identity/resolve`. */\n private async resolveIdentity(email: string): Promise<void> {\n if (!this.sessionId) return;\n this.setIdentityRestore({ phase: 'resolving', email });\n try {\n const json = await this.postInternal('/internal/identity/resolve', { sessionId: this.sessionId, email });\n if (json.resolved !== true) {\n this.setIdentityRestore({ phase: 'resolved', email, conversations: [] });\n return;\n }\n const raw = json.conversations;\n const conversations: RestorableConversation[] = Array.isArray(raw)\n ? raw\n .map((c): RestorableConversation | null => {\n if (!c || typeof c !== 'object') return null;\n const o = c as Record<string, unknown>;\n const conversationId = typeof o.conversationId === 'string' ? o.conversationId : '';\n const sessionId = typeof o.sessionId === 'string' ? o.sessionId : '';\n if (!sessionId) return null;\n return {\n conversationId,\n sessionId,\n lastActivityAt: typeof o.lastActivityAt === 'string' ? o.lastActivityAt : undefined,\n preview: typeof o.preview === 'string' ? o.preview : undefined,\n };\n })\n .filter((c): c is RestorableConversation => c !== null)\n : [];\n this.setIdentityRestore({ phase: 'resolved', email, conversations });\n } catch (err) {\n this.setIdentityRestore({ phase: 'error', message: err instanceof Error ? err.message : 'Could not load your chats.' });\n }\n }\n\n /**\n * Replay a chosen restorable conversation: point the live session at its\n * sessionId, hydrate its transcript (get_session + get_messages), and persist\n * the new pointer so the next `sendMessage` continues it.\n */\n async restoreConversation(sessionId: string): Promise<void> {\n if (!this.client) await this.ensureClient();\n // Capture the OTP proof bound to the CURRENT live session BEFORE tryResume\n // repoints this.sessionId to the restored one. The visitor proved ownership\n // of this email in this very flow, so the proof legitimately follows the\n // conversation they chose to restore.\n const proven = this.sessionId ? this.verifiedEmailForSession(this.sessionId) : null;\n const resumed = await this.tryResume(sessionId);\n if (resumed) {\n this.store.getState().setSessionId(sessionId);\n // Rebind the proof to the restored session (keeps verifiedEmail\n // session-scoped, just now to the session it's actually used on). Only a\n // proof from the just-verified session follows — never an unrelated stale one.\n if (proven) this.store.getState().setVerifiedEmail(proven, sessionId);\n this.setIdentityRestore({ phase: 'idle' });\n this.setStatus('ready');\n } else {\n this.setIdentityRestore({ phase: 'error', message: 'That conversation is no longer available.' });\n }\n }\n\n /** Dismiss the cross-device restore panel. */\n cancelIdentityRestore(): void {\n this.setIdentityRestore({ phase: 'idle' });\n }\n\n /** Tear down the underlying client. */\n disconnect(): void {\n this.client?.disconnect('widget closed');\n this.client = null;\n this.sessionId = null;\n this.activeRequestId = null;\n // A full teardown ends the controller lifecycle: a subsequent connect() is a\n // genuine re-open and may resume again, so re-arm the resume probe.\n this.resumeAttempted = false;\n this.setInterrupt(null);\n this.setStatus('closed');\n }\n}\n","/**\n * The Smooth logo + icon, inlined as SVG strings so the full-page header can\n * render them without a separate network fetch (the IIFE bundle is\n * self-contained).\n *\n * GENERATED from `assets/smooth-logo.svg` / `assets/smooth-icon.svg` — do not\n * edit by hand. Regenerate with:\n * node -e 'const fs=require(\"fs\");process.stdout.write(JSON.stringify(fs.readFileSync(\"assets/smooth-icon.svg\",\"utf8\")))'\n */\n/* eslint-disable */\nexport const SMOOTH_LOGO_SVG = \"<?xml version=\\\"1.0\\\" encoding=\\\"UTF-8\\\"?>\\n<svg id=\\\"Layer_1\\\" data-name=\\\"Layer 1\\\" xmlns=\\\"http://www.w3.org/2000/svg\\\" xmlns:xlink=\\\"http://www.w3.org/1999/xlink\\\" viewBox=\\\"0 0 550 135\\\">\\n <defs>\\n <style>\\n .cls-1 {\\n fill: url(#linear-gradient-3);\\n }\\n\\n .cls-2 {\\n fill: url(#linear-gradient-2);\\n }\\n\\n .cls-3 {\\n fill: url(#linear-gradient);\\n fill-rule: evenodd;\\n }\\n </style>\\n <linearGradient id=\\\"linear-gradient\\\" x1=\\\"115.59\\\" y1=\\\"112.81\\\" x2=\\\"25.08\\\" y2=\\\"22.3\\\" gradientUnits=\\\"userSpaceOnUse\\\">\\n <stop offset=\\\".3\\\" stop-color=\\\"#f49f0a\\\"/>\\n <stop offset=\\\".79\\\" stop-color=\\\"#fb7a4d\\\"/>\\n <stop offset=\\\"1\\\" stop-color=\\\"#ff6b6c\\\"/>\\n </linearGradient>\\n <linearGradient id=\\\"linear-gradient-2\\\" x1=\\\"360.91\\\" y1=\\\"152.01\\\" x2=\\\"202.32\\\" y2=\\\"-6.59\\\" xlink:href=\\\"#linear-gradient\\\"/>\\n <linearGradient id=\\\"linear-gradient-3\\\" x1=\\\"443.91\\\" y1=\\\"30.15\\\" x2=\\\"531.36\\\" y2=\\\"117.59\\\" gradientUnits=\\\"userSpaceOnUse\\\">\\n <stop offset=\\\".43\\\" stop-color=\\\"#00a6a6\\\"/>\\n <stop offset=\\\"1\\\" stop-color=\\\"#1238dd\\\"/>\\n </linearGradient>\\n </defs>\\n <path class=\\\"cls-3\\\" d=\\\"M48.28,14.96c-12.39,5.21-22.54,14.64-28.65,26.61-6.12,11.97-7.8,25.72-4.77,38.81,3.04,13.09,10.6,24.69,21.36,32.75,10.76,8.06,24.02,12.05,37.44,11.28,13.42-.77,26.13-6.26,35.9-15.5,9.76-9.24,15.95-21.63,17.46-34.99,1.51-13.36-1.74-26.82-9.19-38.01-1.07-1.61-.64-3.78.97-4.85,1.61-1.07,3.78-.64,4.85.97,8.36,12.56,12.02,27.68,10.32,42.67-1.7,15-8.64,28.91-19.61,39.28-10.96,10.37-25.24,16.54-40.31,17.4-15.07.87-29.96-3.62-42.04-12.66-12.08-9.05-20.58-22.07-23.99-36.77-3.41-14.7-1.51-30.14,5.35-43.58,6.87-13.44,18.26-24.02,32.17-29.87,13.91-5.85,29.44-6.6,43.85-2.11,1.85.57,2.88,2.54,2.3,4.38-.57,1.85-2.54,2.88-4.38,2.3-12.83-4-26.67-3.33-39.06,1.88ZM111.39,19.75c0,2.07-1.68,3.75-3.75,3.75s-3.75-1.68-3.75-3.75,1.68-3.75,3.75-3.75,3.75,1.68,3.75,3.75ZM64.64,59.93c0,1.91,2.39,2.56,7.69,3.88,3.89.97,6.6,2.18,8.15,3.63,1.53,1.45,2.29,3.53,2.29,6.25,0,3.57-1.03,6.26-3.11,8.08-2.07,1.82-5.09,2.73-9.09,2.73h-9.6c-1.97,0-3.57-1.6-3.59-3.57-.01-1.99,1.6-3.61,3.59-3.61h9.41c3.15-.12,4.79-.95,4.91-2.47,0-1.3-1.03-2.21-3.07-2.73-6.91-1.72-11.11-3.44-12.6-5.15-1.48-1.71-2.23-3.77-2.23-6.19,0-6.59,3.2-9.85,9.59-9.8h10.77c1.99,0,3.6,1.61,3.6,3.59s-1.61,3.59-3.6,3.59h-9.69c-1.83,0-3.43.06-3.43,1.77Z\\\"/>\\n <path class=\\\"cls-2\\\" d=\\\"M205.52,48.44h-8.86c-.44-3.75-2.23-6.65-5.38-8.72-3.16-2.07-7.03-3.1-11.6-3.1h0c-3.35,0-6.27.54-8.78,1.62-2.49,1.09-4.44,2.59-5.84,4.48-1.39,1.89-2.08,4.05-2.08,6.46h0c0,2.01.49,3.75,1.46,5.2.97,1.44,2.22,2.63,3.74,3.58,1.53.95,3.13,1.72,4.8,2.32,1.68.6,3.22,1.09,4.62,1.46h0l7.68,2.06c1.97.52,4.17,1.23,6.6,2.14,2.43.92,4.75,2.16,6.98,3.72,2.23,1.56,4.07,3.56,5.52,6,1.45,2.44,2.18,5.43,2.18,8.98h0c0,4.08-1.07,7.77-3.2,11.08-2.12,3.29-5.22,5.91-9.3,7.86-4.08,1.95-9.02,2.92-14.82,2.92h0c-5.43,0-10.11-.87-14.06-2.62-3.95-1.75-7.05-4.19-9.3-7.32-2.25-3.12-3.53-6.75-3.84-10.88h9.46c.25,2.85,1.22,5.21,2.9,7.06,1.69,1.87,3.83,3.25,6.42,4.14,2.6.89,5.41,1.34,8.42,1.34h0c3.49,0,6.63-.57,9.4-1.72,2.79-1.13,4.99-2.73,6.62-4.8,1.63-2.05,2.44-4.46,2.44-7.22h0c0-2.51-.7-4.55-2.1-6.12-1.41-1.57-3.26-2.85-5.54-3.84-2.29-.99-4.77-1.85-7.44-2.58h0l-9.3-2.66c-5.91-1.71-10.59-4.13-14.04-7.28-3.44-3.16-5.16-7.29-5.16-12.38h0c0-4.23,1.15-7.93,3.46-11.1,2.29-3.16,5.39-5.62,9.3-7.38,3.91-1.76,8.27-2.64,13.08-2.64h0c4.88,0,9.21.87,13,2.6,3.8,1.73,6.81,4.11,9.04,7.12,2.23,3,3.4,6.41,3.52,10.22h0ZM229.16,105.18h-8.72v-56.74h8.42v8.86h.74c1.19-3.03,3.1-5.38,5.74-7.06,2.63-1.69,5.79-2.54,9.48-2.54h0c3.75,0,6.87.85,9.36,2.54,2.51,1.68,4.46,4.03,5.86,7.06h.58c1.45-2.92,3.63-5.25,6.54-7,2.91-1.73,6.39-2.6,10.46-2.6h0c5.07,0,9.21,1.58,12.44,4.74,3.23,3.17,4.84,8.09,4.84,14.76h0v37.98h-8.72v-37.98c0-4.19-1.14-7.18-3.42-8.98-2.29-1.79-4.99-2.68-8.1-2.68h0c-3.99,0-7.07,1.2-9.26,3.6-2.2,2.4-3.3,5.43-3.3,9.1h0v36.94h-8.86v-38.86c0-3.23-1.05-5.83-3.14-7.82-2.09-1.97-4.79-2.96-8.08-2.96h0c-2.27,0-4.38.6-6.34,1.8-1.96,1.21-3.53,2.88-4.72,5-1.2,2.13-1.8,4.59-1.8,7.38h0v35.46ZM333.9,106.36h0c-5.12,0-9.61-1.22-13.46-3.66-3.85-2.44-6.86-5.85-9.02-10.24-2.15-4.37-3.22-9.49-3.22-15.36h0c0-5.91,1.07-11.07,3.22-15.48,2.16-4.4,5.17-7.82,9.02-10.26,3.85-2.44,8.34-3.66,13.46-3.66h0c5.12,0,9.61,1.22,13.46,3.66,3.85,2.44,6.86,5.86,9.02,10.26,2.15,4.41,3.22,9.57,3.22,15.48h0c0,5.87-1.07,10.99-3.22,15.36-2.16,4.39-5.17,7.8-9.02,10.24-3.85,2.44-8.34,3.66-13.46,3.66ZM333.9,98.52h0c3.89,0,7.09-.99,9.6-2.98,2.52-2,4.38-4.63,5.58-7.88,1.21-3.25,1.82-6.77,1.82-10.56h0c0-3.79-.61-7.32-1.82-10.6-1.2-3.27-3.06-5.91-5.58-7.94-2.51-2.01-5.71-3.02-9.6-3.02h0c-3.89,0-7.09,1.01-9.6,3.02-2.51,2.03-4.37,4.67-5.58,7.94-1.2,3.28-1.8,6.81-1.8,10.6h0c0,3.79.6,7.31,1.8,10.56,1.21,3.25,3.07,5.88,5.58,7.88,2.51,1.99,5.71,2.98,9.6,2.98ZM395.94,106.36h0c-5.12,0-9.61-1.22-13.46-3.66-3.85-2.44-6.85-5.85-9-10.24-2.16-4.37-3.24-9.49-3.24-15.36h0c0-5.91,1.08-11.07,3.24-15.48,2.15-4.4,5.15-7.82,9-10.26,3.85-2.44,8.34-3.66,13.46-3.66h0c5.12,0,9.61,1.22,13.46,3.66,3.85,2.44,6.86,5.86,9.02,10.26,2.16,4.41,3.24,9.57,3.24,15.48h0c0,5.87-1.08,10.99-3.24,15.36-2.16,4.39-5.17,7.8-9.02,10.24-3.85,2.44-8.34,3.66-13.46,3.66ZM395.94,98.52h0c3.89,0,7.09-.99,9.6-2.98,2.52-2,4.38-4.63,5.58-7.88,1.21-3.25,1.82-6.77,1.82-10.56h0c0-3.79-.61-7.32-1.82-10.6-1.2-3.27-3.06-5.91-5.58-7.94-2.51-2.01-5.71-3.02-9.6-3.02h0c-3.88,0-7.08,1.01-9.6,3.02-2.51,2.03-4.37,4.67-5.58,7.94-1.2,3.28-1.8,6.81-1.8,10.6h0c0,3.79.6,7.31,1.8,10.56,1.21,3.25,3.07,5.88,5.58,7.88,2.52,1.99,5.72,2.98,9.6,2.98Z\\\"/>\\n <path class=\\\"cls-1\\\" d=\\\"M467.88,48.02v13.28h-35.79v-13.28h35.79ZM439.68,34.38h17.89v53.42c0,1.5.36,2.62,1.08,3.36.72.74,1.88,1.1,3.49,1.1.62,0,1.48-.07,2.59-.21,1.11-.14,1.91-.27,2.38-.41l2.31,13.02c-2.02.58-3.97.97-5.84,1.18-1.88.21-3.66.31-5.33.31-6.08,0-10.7-1.43-13.84-4.28-3.15-2.85-4.72-7.01-4.72-12.48v-55.01ZM506.59,72.63v32.71h-17.89V28.95h17.53v33.53h-1.13c1.4-4.55,3.6-8.21,6.59-11,2.99-2.79,7.01-4.18,12.07-4.18,4,0,7.48.89,10.46,2.67,2.97,1.78,5.28,4.29,6.92,7.54,1.64,3.25,2.46,7.02,2.46,11.33v36.5h-17.89v-33.02c0-3.21-.82-5.73-2.46-7.56-1.64-1.83-3.93-2.74-6.87-2.74-1.92,0-3.62.42-5.1,1.26-1.49.84-2.64,2.04-3.46,3.61-.82,1.57-1.23,3.49-1.23,5.74Z\\\"/>\\n</svg>\";\n\n/** The square Smooth icon (the stylized `th` glyph) — used as the default full-page header avatar. */\nexport const SMOOTH_ICON_SVG = \"<?xml version=\\\"1.0\\\" encoding=\\\"UTF-8\\\"?>\\n<svg id=\\\"Layer_1\\\" data-name=\\\"Layer 1\\\" xmlns=\\\"http://www.w3.org/2000/svg\\\" xmlns:xlink=\\\"http://www.w3.org/1999/xlink\\\" viewBox=\\\"0 0 150 150\\\">\\n <defs>\\n <style>\\n .cls-1 {\\n fill: url(#linear-gradient);\\n }\\n </style>\\n <linearGradient id=\\\"linear-gradient\\\" x1=\\\"31.06\\\" y1=\\\"37.6\\\" x2=\\\"118.5\\\" y2=\\\"125.04\\\" gradientUnits=\\\"userSpaceOnUse\\\">\\n <stop offset=\\\".43\\\" stop-color=\\\"#00a6a6\\\"/>\\n <stop offset=\\\"1\\\" stop-color=\\\"#1238dd\\\"/>\\n </linearGradient>\\n </defs>\\n <path class=\\\"cls-1\\\" d=\\\"M55.03,55.47v13.28H19.24v-13.28h35.79ZM26.83,41.83h17.89v53.42c0,1.5.36,2.62,1.08,3.36.72.74,1.88,1.1,3.49,1.1.62,0,1.48-.07,2.59-.21,1.11-.14,1.91-.27,2.38-.41l2.31,13.02c-2.02.58-3.97.97-5.84,1.18-1.88.21-3.66.31-5.33.31-6.08,0-10.7-1.43-13.84-4.28-3.15-2.85-4.72-7.01-4.72-12.48v-55.01ZM93.74,80.08v32.71h-17.89V36.39h17.53v33.53h-1.13c1.4-4.55,3.6-8.21,6.59-11,2.99-2.79,7.01-4.18,12.07-4.18,4,0,7.48.89,10.46,2.67,2.97,1.78,5.28,4.29,6.92,7.54,1.64,3.25,2.46,7.02,2.46,11.33v36.5h-17.89v-33.02c0-3.21-.82-5.73-2.46-7.56-1.64-1.83-3.93-2.74-6.87-2.74-1.92,0-3.62.42-5.1,1.26-1.49.84-2.64,2.04-3.46,3.61-.82,1.57-1.23,3.49-1.23,5.74Z\\\"/>\\n</svg>\";\n","import type { ChatWidgetMode, ResolvedTheme } from './config.js';\n\n/**\n * Render the widget's scoped stylesheet — the \"Aurora Glass\" design system.\n *\n * Every brand value is injected as a CSS custom property on `:host` so a host\n * page can override colors per-instance and the rules below stay static. Two\n * extra tokens are *derived in CSS* from the brand vars so they adapt to any\n * theme (light or dark) without the caller supplying them:\n *\n * --sac-primary-2 a darker shade of `primary`, used as the second stop of the\n * launcher / send / user-bubble gradients (depth without a\n * second brand input).\n * --sac-surface-2 a faint wash derived from `text`, used for inset chrome\n * (composer field, close button, source cards). On a dark\n * panel it reads as a light overlay; on a light panel, dark.\n *\n * Deliberately framework-light: no Tailwind, no runtime CSS-in-JS — just a string\n * the web component drops into its shadow root. Modern color features\n * (`color-mix`) are used intentionally; the widget targets evergreen browsers.\n *\n * `mode` switches host positioning + panel sizing between the floating popover\n * (default) and the full-page layout (fills its container/viewport).\n */\nexport function buildStyles(theme: ResolvedTheme, mode: ChatWidgetMode = 'popover'): string {\n return `\n:host {\n --sac-text: ${theme.text};\n --sac-bg: ${theme.background};\n --sac-primary: ${theme.primary};\n --sac-primary-text: ${theme.primaryText};\n --sac-secondary: ${theme.secondary};\n --sac-assistant-bubble: ${theme.assistantBubble};\n --sac-assistant-bubble-text: ${theme.assistantBubbleText};\n --sac-user-bubble: ${theme.userBubble};\n --sac-user-bubble-text: ${theme.userBubbleText};\n --sac-border: ${theme.border};\n\n /* Derived tokens — adapt to any brand color without a second input. */\n --sac-primary-2: color-mix(in srgb, var(--sac-primary) 78%, #000 22%);\n --sac-surface-2: color-mix(in srgb, var(--sac-text) 5%, transparent);\n --sac-radius: 22px;\n --sac-ease: cubic-bezier(.16, 1, .3, 1);\n\n ${\n mode === 'fullpage'\n ? `/* Full-page: fill the host's box (sized by its container, else the viewport). */\n display: flex;\n flex-direction: column;\n position: relative;\n width: 100%;\n height: 100%;`\n : `/* Popover: float in the bottom-right corner. */\n position: fixed;\n bottom: 24px;\n right: 24px;\n z-index: 2147483000;`\n }\n font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Helvetica, Arial, sans-serif;\n -webkit-font-smoothing: antialiased;\n}\n${\n mode === 'fullpage'\n ? `\n/* Viewport fallback — the element sets this attribute only when the host's\n container gives it no resolved height (e.g. mounted straight into an\n auto-height <body>). A sized container always wins, so an embed inside a\n fixed-height box never overflows it (composer stays visible). */\n:host([data-viewport-fallback]) { min-height: 100dvh; }\n/* The render wrapper passes the host's box down to the panel via flex. */\n.wrap {\n flex: 1;\n display: flex;\n flex-direction: column;\n min-height: 0;\n}\n`\n : ''\n}\n* { box-sizing: border-box; }\n\n/* ───────────────────────────── Launcher ───────────────────────────── */\n.launcher {\n position: relative;\n width: 62px;\n height: 62px;\n border-radius: 50%;\n border: none;\n cursor: pointer;\n padding: 0;\n background: radial-gradient(120% 120% at 30% 20%,\n color-mix(in srgb, var(--sac-primary) 78%, #fff 22%) 0%,\n var(--sac-primary) 42%,\n var(--sac-primary-2) 130%);\n color: var(--sac-primary-text);\n display: flex;\n align-items: center;\n justify-content: center;\n box-shadow:\n 0 1px 0 rgba(255, 255, 255, .25) inset,\n 0 10px 24px -6px color-mix(in srgb, var(--sac-primary) 55%, transparent),\n 0 18px 50px -12px rgba(0, 0, 0, .6);\n transition: transform .45s var(--sac-ease), box-shadow .45s var(--sac-ease), opacity .3s ease;\n isolation: isolate;\n}\n/* Breathing presence ring. */\n.launcher::before {\n content: '';\n position: absolute;\n inset: -6px;\n border-radius: 50%;\n z-index: -1;\n background: radial-gradient(closest-side, color-mix(in srgb, var(--sac-primary) 45%, transparent), transparent 75%);\n animation: sac-breathe 3.4s ease-in-out infinite;\n}\n@keyframes sac-breathe { 0%, 100% { transform: scale(1); opacity: .55 } 50% { transform: scale(1.28); opacity: 0 } }\n.launcher:hover {\n transform: translateY(-3px) scale(1.06);\n box-shadow:\n 0 1px 0 rgba(255, 255, 255, .3) inset,\n 0 16px 30px -6px color-mix(in srgb, var(--sac-primary) 60%, transparent),\n 0 26px 60px -14px rgba(0, 0, 0, .7);\n}\n.launcher:active { transform: translateY(-1px) scale(.98); }\n.launcher .ico { width: 27px; height: 27px; display: block; transition: transform .4s var(--sac-ease); }\n.launcher:hover .ico { transform: rotate(-6deg) scale(1.04); }\n.launcher.hidden { opacity: 0; transform: scale(.4) translateY(10px); pointer-events: none; }\n\n/* ─────────────────────────────── Panel ────────────────────────────── */\n.panel {\n width: 390px;\n max-width: calc(100vw - 40px);\n height: 600px;\n max-height: calc(100vh - 56px);\n display: flex;\n flex-direction: column;\n overflow: hidden;\n border-radius: var(--sac-radius);\n background: linear-gradient(180deg, color-mix(in srgb, var(--sac-bg) 92%, #fff 8%) 0%, var(--sac-bg) 22%);\n color: var(--sac-text);\n border: 1px solid color-mix(in srgb, var(--sac-border) 80%, transparent);\n box-shadow:\n 0 0 0 1px rgba(255, 255, 255, .03) inset,\n 0 40px 80px -24px rgba(0, 0, 0, .65),\n 0 16px 40px -20px rgba(0, 0, 0, .5);\n transform-origin: bottom right;\n animation: sac-panel-in .5s var(--sac-ease) both;\n position: relative;\n}\n@keyframes sac-panel-in { from { opacity: 0; transform: translateY(16px) scale(.92) } to { opacity: 1; transform: none } }\n.panel.hidden { display: none; }\n/* Ambient brand glow bleeding from the top of the panel. */\n.panel::before {\n content: '';\n position: absolute;\n left: 0; right: 0; top: 0;\n height: 140px;\n pointer-events: none;\n background: radial-gradient(120% 100% at 50% 0%, color-mix(in srgb, var(--sac-primary) 22%, transparent), transparent 70%);\n}\n/* Full-page: the panel becomes the whole surface — it follows the host's box\n (via the .wrap flex chain), never a hardcoded viewport unit. */\n.panel.fullpage {\n width: 100%;\n flex: 1;\n height: auto;\n min-height: 0;\n max-width: none;\n max-height: none;\n border: none;\n border-radius: 0;\n box-shadow: none;\n animation: none;\n}\n\n/* ─────────────────────────────── Header ───────────────────────────── */\n.header {\n position: relative;\n display: flex;\n align-items: center;\n gap: 12px;\n padding: 16px 16px 14px;\n}\n.avatar {\n width: 40px;\n height: 40px;\n border-radius: 13px;\n flex: none;\n background: linear-gradient(140deg, var(--sac-primary), var(--sac-primary-2));\n display: flex;\n align-items: center;\n justify-content: center;\n color: var(--sac-primary-text);\n box-shadow:\n 0 6px 16px -6px color-mix(in srgb, var(--sac-primary) 60%, transparent),\n 0 1px 0 rgba(255, 255, 255, .25) inset;\n}\n.avatar svg { width: 22px; height: 22px; }\n.avatar .logo-wrap { display: flex; align-items: center; justify-content: center; width: 100%; height: 100%; }\n.avatar .logo { height: 22px; width: auto; display: block; }\n.avatar .logo-img { max-width: 100%; max-height: 100%; width: auto; height: auto; object-fit: contain; display: block; border-radius: 9px; }\n.meta { min-width: 0; flex: 1; display: flex; flex-direction: column; gap: 2px; }\n.title { font-weight: 650; font-size: 15.5px; letter-spacing: -.01em; line-height: 1.1; }\n.status {\n display: flex;\n align-items: center;\n gap: 6px;\n font-size: 12px;\n color: color-mix(in srgb, var(--sac-text) 62%, transparent);\n}\n.dot {\n width: 7px; height: 7px;\n border-radius: 50%;\n flex: none;\n background: #34d399;\n color: #34d399;\n box-shadow: 0 0 0 0 rgba(52, 211, 153, .6);\n animation: sac-pulse 2.4s ease-out infinite;\n}\n.dot.connecting { background: #fbbf24; color: #fbbf24; animation: sac-pulse 1.1s ease-out infinite; }\n.dot.error { background: #f87171; color: #f87171; animation: none; }\n.dot.off { background: #94a3b8; color: #94a3b8; animation: none; }\n@keyframes sac-pulse {\n 0% { box-shadow: 0 0 0 0 color-mix(in srgb, currentColor 55%, transparent) }\n 70% { box-shadow: 0 0 0 6px transparent }\n 100% { box-shadow: 0 0 0 0 transparent }\n}\n.close {\n margin-left: auto;\n width: 32px; height: 32px;\n border-radius: 10px;\n border: none;\n cursor: pointer;\n background: var(--sac-surface-2);\n color: inherit;\n display: flex;\n align-items: center;\n justify-content: center;\n transition: background .2s ease, transform .2s ease;\n}\n.close:hover { background: color-mix(in srgb, var(--sac-text) 12%, transparent); transform: translateY(1px); }\n.close svg { width: 16px; height: 16px; opacity: .8; }\n.powered { margin-left: auto; font-size: 10.5px; letter-spacing: .02em; opacity: .6; color: inherit; text-decoration: none; }\n.powered:hover { opacity: .85; text-decoration: underline; }\n.header-sep { height: 1px; margin: 0 16px; background: linear-gradient(90deg, transparent, var(--sac-border), transparent); }\n\n/* Full-page header: taller, logo-led, no close. */\n.panel.fullpage .header { padding: 18px 22px; }\n.panel.fullpage .avatar { width: 44px; height: 44px; }\n.panel.fullpage .avatar .logo { height: 26px; }\n.panel.fullpage .avatar svg { width: 28px; height: 28px; }\n\n/* ────────────────────────────── Messages ──────────────────────────── */\n.messages {\n flex: 1;\n overflow-y: auto;\n padding: 18px 16px 8px;\n display: flex;\n flex-direction: column;\n gap: 12px;\n scroll-behavior: smooth;\n}\n.messages::-webkit-scrollbar { width: 8px; }\n.messages::-webkit-scrollbar-thumb {\n background: color-mix(in srgb, var(--sac-text) 14%, transparent);\n border-radius: 99px;\n border: 2px solid transparent;\n background-clip: padding-box;\n}\n.messages::-webkit-scrollbar-thumb:hover {\n background: color-mix(in srgb, var(--sac-text) 24%, transparent);\n background-clip: padding-box;\n}\n\n.row {\n display: flex;\n gap: 9px;\n max-width: 88%;\n animation: sac-msg-in .42s var(--sac-ease) both;\n}\n@keyframes sac-msg-in { from { opacity: 0; transform: translateY(8px) } to { opacity: 1; transform: none } }\n.row.user { align-self: flex-end; flex-direction: row-reverse; }\n.row.assistant { align-self: flex-start; }\n.mini {\n width: 26px; height: 26px;\n border-radius: 9px;\n flex: none;\n align-self: flex-end;\n background: linear-gradient(140deg, var(--sac-primary), var(--sac-primary-2));\n display: flex;\n align-items: center;\n justify-content: center;\n color: var(--sac-primary-text);\n}\n.mini svg { width: 15px; height: 15px; }\n\n.bubble {\n padding: 11px 14px;\n border-radius: 16px;\n font-size: 14px;\n line-height: 1.5;\n white-space: pre-wrap;\n word-break: break-word;\n position: relative;\n}\n.bubble.assistant {\n background: linear-gradient(180deg, color-mix(in srgb, var(--sac-assistant-bubble) 86%, #fff 5%), var(--sac-assistant-bubble));\n color: var(--sac-assistant-bubble-text);\n border: 1px solid color-mix(in srgb, var(--sac-text) 8%, transparent);\n border-bottom-left-radius: 5px;\n box-shadow: 0 2px 8px -4px rgba(0, 0, 0, .4);\n}\n.bubble.user {\n background: linear-gradient(165deg,\n color-mix(in srgb, var(--sac-user-bubble) 88%, #fff 12%),\n var(--sac-user-bubble) 60%,\n color-mix(in srgb, var(--sac-user-bubble) 80%, var(--sac-primary-2) 20%));\n color: var(--sac-user-bubble-text);\n border-bottom-right-radius: 5px;\n box-shadow: 0 6px 16px -8px color-mix(in srgb, var(--sac-primary) 50%, transparent);\n}\n.bubble.greeting {\n background: transparent;\n border: 1px dashed color-mix(in srgb, var(--sac-text) 14%, transparent);\n color: color-mix(in srgb, var(--sac-text) 80%, transparent);\n box-shadow: none;\n}\n\n/* Typing indicator (assistant bubble with no text yet). */\n.bubble.typing { display: flex; gap: 4px; padding: 14px 15px; }\n.bubble.typing i {\n width: 7px; height: 7px;\n border-radius: 50%;\n background: color-mix(in srgb, var(--sac-assistant-bubble-text) 55%, transparent);\n animation: sac-typing 1.3s ease-in-out infinite;\n}\n.bubble.typing i:nth-child(2) { animation-delay: .18s; }\n.bubble.typing i:nth-child(3) { animation-delay: .36s; }\n@keyframes sac-typing { 0%, 60%, 100% { transform: translateY(0); opacity: .4 } 30% { transform: translateY(-5px); opacity: 1 } }\n\n.cursor::after {\n content: '';\n display: inline-block;\n width: 2px; height: 1.05em;\n margin-left: 2px;\n vertical-align: -2px;\n border-radius: 2px;\n background: currentColor;\n animation: sac-blink 1s steps(2, start) infinite;\n}\n@keyframes sac-blink { to { opacity: 0 } }\n\n/* Interleaved tool-activity strip (gated by showToolActivity): prose bubbles\n and inline tool chips stacked in the order the model produced them. */\n.blocks { display: flex; flex-direction: column; align-items: flex-start; gap: 7px; }\n.blocks .bubble { align-self: flex-start; }\n.toolchip {\n display: inline-flex;\n align-items: center;\n gap: 6px;\n max-width: 100%;\n padding: 5px 10px;\n border-radius: 99px;\n font-size: 12px;\n line-height: 1.3;\n color: color-mix(in srgb, var(--sac-text) 78%, transparent);\n background: color-mix(in srgb, var(--sac-text) 6%, transparent);\n border: 1px solid color-mix(in srgb, var(--sac-text) 12%, transparent);\n animation: sac-msg-in .3s var(--sac-ease) both;\n}\n.toolchip .ti { display: inline-flex; flex: none; opacity: .8; }\n.toolchip .ti svg { width: 13px; height: 13px; }\n.toolchip .tn { font-weight: 600; letter-spacing: .01em; }\n.toolchip .ts { opacity: .7; }\n.toolchip .ta {\n font-family: ui-monospace, SFMono-Regular, Menlo, monospace;\n font-size: 11px;\n opacity: .6;\n overflow: hidden;\n text-overflow: ellipsis;\n white-space: nowrap;\n min-width: 0;\n}\n.toolchip.running { border-color: color-mix(in srgb, var(--sac-primary) 45%, transparent); }\n.toolchip.running .ts { color: var(--sac-primary); opacity: 1; animation: sac-typing 1.3s ease-in-out infinite; }\n.toolchip.done .ts::before { content: '✓ '; }\n.toolchip.error {\n color: var(--sac-secondary);\n border-color: color-mix(in srgb, var(--sac-secondary) 50%, transparent);\n background: color-mix(in srgb, var(--sac-secondary) 10%, transparent);\n}\n.toolchip.error .ts::before { content: '! '; }\n\n/* ─────────────── Rendered markdown (assistant bubbles / snippets) ─────────── */\n/* The renderer (markdown.ts) emits a small allowlisted set of tags; these rules\n keep them legible inside the tight Aurora-Glass bubble + citation card. */\n/* Block-level markdown drives its own spacing/wrapping, so opt out of the\n bubble's pre-wrap (which would otherwise add stray blank lines). */\n.bubble.md { white-space: normal; }\n.md > :first-child { margin-top: 0; }\n.md > :last-child { margin-bottom: 0; }\n.md p { margin: 0 0 8px; }\n.md ul, .md ol { margin: 6px 0 8px; padding-left: 20px; }\n.md li { margin: 2px 0; }\n.md li::marker { color: color-mix(in srgb, var(--sac-primary) 75%, transparent); }\n.md a {\n color: color-mix(in srgb, var(--sac-primary) 92%, #fff);\n text-decoration: underline;\n text-underline-offset: 2px;\n word-break: break-word;\n}\n.md a:hover { text-decoration: none; }\n.md strong { font-weight: 700; }\n.md em { font-style: italic; }\n.md code {\n font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;\n font-size: .9em;\n padding: 1px 5px;\n border-radius: 5px;\n background: color-mix(in srgb, var(--sac-text) 10%, transparent);\n}\n.md pre {\n margin: 6px 0 8px;\n padding: 9px 11px;\n border-radius: 9px;\n overflow-x: auto;\n background: color-mix(in srgb, var(--sac-text) 9%, transparent);\n border: 1px solid color-mix(in srgb, var(--sac-text) 8%, transparent);\n}\n.md pre code { padding: 0; background: none; font-size: 12px; line-height: 1.45; }\n.md blockquote {\n margin: 6px 0;\n padding: 2px 0 2px 11px;\n border-left: 2px solid color-mix(in srgb, var(--sac-primary) 55%, transparent);\n color: color-mix(in srgb, var(--sac-text) 78%, transparent);\n}\n\n/* Full-page: center the conversation in a readable column. */\n.panel.fullpage .messages { padding: 26px 20px; }\n.panel.fullpage .row { max-width: 760px; width: 100%; margin-left: auto; margin-right: auto; }\n.panel.fullpage .row.user { max-width: 80%; margin-right: 0; }\n\n/* ───────────────── Sources (grounding citations) ──────────────────── */\n.sources {\n align-self: flex-start;\n max-width: 88%;\n margin: -4px 0 0 35px;\n}\n.panel.fullpage .sources { max-width: 760px; width: 100%; margin-left: auto; margin-right: auto; }\n.sources summary {\n cursor: pointer;\n list-style: none;\n display: inline-flex;\n align-items: center;\n gap: 7px;\n font-size: 12px;\n font-weight: 600;\n color: color-mix(in srgb, var(--sac-text) 70%, transparent);\n padding: 5px 0;\n user-select: none;\n}\n.sources summary::-webkit-details-marker { display: none; }\n.sources .chev { transition: transform .2s var(--sac-ease); flex: none; }\n.sources details[open] .chev { transform: rotate(90deg); }\n.sources .count {\n background: color-mix(in srgb, var(--sac-primary) 18%, transparent);\n color: color-mix(in srgb, var(--sac-primary) 92%, #fff);\n font-size: 10.5px;\n font-weight: 700;\n padding: 1px 7px;\n border-radius: 99px;\n}\n.sources ol { list-style: none; margin: 6px 0 2px; padding: 0; display: flex; flex-direction: column; gap: 7px; }\n.sources li {\n background: var(--sac-surface-2);\n border: 1px solid color-mix(in srgb, var(--sac-border) 70%, transparent);\n border-left: 2px solid var(--sac-primary);\n border-radius: 9px;\n padding: 8px 10px;\n}\n.sources .src-title {\n color: color-mix(in srgb, var(--sac-primary) 92%, #fff);\n font-weight: 600;\n font-size: 12.5px;\n text-decoration: none;\n word-break: break-word;\n}\n.sources a.src-title:hover { text-decoration: underline; }\n.sources span.src-title { color: var(--sac-text); opacity: .95; }\n.sources .src-snippet {\n display: block;\n margin-top: 3px;\n font-size: 11.5px;\n line-height: 1.45;\n color: color-mix(in srgb, var(--sac-text) 55%, transparent);\n white-space: normal;\n}\n\n/* ────────────────────────────── Composer ──────────────────────────── */\n.composer-wrap { padding: 12px 14px calc(12px + env(safe-area-inset-bottom)); }\n.composer {\n display: flex;\n align-items: flex-end;\n gap: 8px;\n padding: 7px 7px 7px 14px;\n border-radius: 18px;\n background: var(--sac-surface-2);\n border: 1px solid color-mix(in srgb, var(--sac-border) 80%, transparent);\n transition: border-color .25s ease, box-shadow .25s ease, background .25s ease;\n}\n.composer:focus-within {\n border-color: color-mix(in srgb, var(--sac-primary) 60%, transparent);\n box-shadow: 0 0 0 4px color-mix(in srgb, var(--sac-primary) 14%, transparent);\n}\n.composer textarea {\n flex: 1;\n resize: none;\n border: none;\n background: transparent;\n color: var(--sac-text);\n font-family: inherit;\n font-size: 14px;\n line-height: 1.45;\n max-height: 120px;\n padding: 6px 0;\n outline: none;\n}\n.composer textarea::placeholder { color: color-mix(in srgb, var(--sac-text) 42%, transparent); }\n.send {\n width: 38px; height: 38px;\n flex: none;\n border: none;\n border-radius: 13px;\n cursor: pointer;\n display: flex;\n align-items: center;\n justify-content: center;\n background: linear-gradient(150deg, var(--sac-primary), var(--sac-primary-2));\n color: var(--sac-primary-text);\n box-shadow:\n 0 6px 14px -6px color-mix(in srgb, var(--sac-primary) 65%, transparent),\n 0 1px 0 rgba(255, 255, 255, .25) inset;\n transition: transform .2s var(--sac-ease), box-shadow .2s var(--sac-ease), opacity .2s ease;\n}\n.send svg { width: 18px; height: 18px; }\n.send:hover { transform: translateY(-1px) scale(1.05); }\n.send:active { transform: scale(.94); }\n.send:disabled { opacity: .4; cursor: default; transform: none; box-shadow: none; }\n.footer {\n text-align: center;\n margin-top: 9px;\n font-size: 10.5px;\n letter-spacing: .04em;\n color: color-mix(in srgb, var(--sac-text) 38%, transparent);\n}\n.footer b { font-weight: 600; color: color-mix(in srgb, var(--sac-text) 55%, transparent); }\n.footer a { color: inherit; text-decoration: none; }\n.footer a:hover { text-decoration: underline; }\n\n/* ─────────────────── Pre-chat identity form ───────────────────────── */\n.prechat { flex: 1; display: flex; flex-direction: column; justify-content: center; gap: 18px; padding: 22px 20px; }\n.pc-head { text-align: center; }\n.pc-title { font-size: 17px; font-weight: 650; letter-spacing: -.01em; }\n.pc-sub { margin-top: 4px; font-size: 13px; color: color-mix(in srgb, var(--sac-text) 60%, transparent); }\n.pc-form { display: flex; flex-direction: column; gap: 12px; }\n.pc-field { display: flex; flex-direction: column; gap: 5px; }\n.pc-field span { font-size: 12px; font-weight: 600; color: color-mix(in srgb, var(--sac-text) 70%, transparent); }\n.pc-field input {\n border: 1px solid color-mix(in srgb, var(--sac-border) 80%, transparent);\n background: var(--sac-surface-2);\n color: var(--sac-text);\n border-radius: 12px;\n padding: 11px 13px;\n font-family: inherit;\n font-size: 14px;\n outline: none;\n transition: border-color .2s ease, box-shadow .2s ease;\n}\n.pc-field input::placeholder { color: color-mix(in srgb, var(--sac-text) 42%, transparent); }\n.pc-field input:focus {\n border-color: color-mix(in srgb, var(--sac-primary) 60%, transparent);\n box-shadow: 0 0 0 4px color-mix(in srgb, var(--sac-primary) 14%, transparent);\n}\n/* Inline phone validity — subtle, themed. Empty stays neutral (optional field). */\n.pc-field.valid input {\n border-color: color-mix(in srgb, var(--sac-primary) 55%, #2faa6a 45%);\n}\n.pc-field.invalid input {\n border-color: color-mix(in srgb, #e2566b 62%, var(--sac-border) 38%);\n}\n.pc-field.invalid input:focus {\n box-shadow: 0 0 0 4px color-mix(in srgb, #e2566b 16%, transparent);\n}\n.pc-field .pc-hint {\n min-height: 13px;\n margin-top: 1px;\n font-size: 11.5px;\n font-weight: 500;\n line-height: 1.2;\n color: color-mix(in srgb, #e2566b 78%, var(--sac-text) 22%);\n}\n.pc-submit {\n margin-top: 4px;\n border: none;\n border-radius: 13px;\n padding: 12px;\n cursor: pointer;\n background: linear-gradient(150deg, var(--sac-primary), var(--sac-primary-2));\n color: var(--sac-primary-text);\n font-weight: 650;\n font-size: 14px;\n box-shadow: 0 6px 14px -6px color-mix(in srgb, var(--sac-primary) 65%, transparent), 0 1px 0 rgba(255, 255, 255, .25) inset;\n transition: transform .2s var(--sac-ease);\n}\n.pc-submit:hover { transform: translateY(-1px); }\n.pc-submit:active { transform: scale(.98); }\n.pc-consents { display: flex; flex-direction: column; gap: 9px; margin-top: 2px; }\n.pc-consent { display: flex; align-items: flex-start; gap: 9px; cursor: pointer; }\n.pc-consent input {\n margin-top: 2px;\n width: 16px;\n height: 16px;\n flex: 0 0 auto;\n accent-color: var(--sac-primary);\n cursor: pointer;\n}\n.pc-consent span { font-size: 12px; line-height: 1.4; color: color-mix(in srgb, var(--sac-text) 72%, transparent); }\n\n/* ─────────────────── Starter-prompt chips ─────────────────────────── */\n.prompts { display: flex; flex-wrap: wrap; gap: 8px; margin: 2px 0 2px 35px; }\n.panel.fullpage .prompts { margin-left: auto; margin-right: auto; max-width: 760px; width: 100%; }\n.chip {\n border: 1px solid color-mix(in srgb, var(--sac-border) 80%, transparent);\n background: var(--sac-surface-2);\n color: var(--sac-text);\n border-radius: 999px;\n padding: 8px 13px;\n font-family: inherit;\n font-size: 12.5px;\n cursor: pointer;\n text-align: left;\n transition: border-color .2s ease, background .2s ease, transform .2s ease;\n}\n.chip:hover {\n border-color: color-mix(in srgb, var(--sac-primary) 50%, transparent);\n background: color-mix(in srgb, var(--sac-primary) 10%, var(--sac-surface-2));\n transform: translateY(-1px);\n}\n\n/* ───────────── Mid-conversation suggested-reply chips ─────────────── */\n.reply-suggestions { padding: 0 14px 4px; }\n.reply-suggestions:empty { display: none; }\n\n/* ─────────────── OTP / tool-confirmation interrupt ────────────────── */\n.interrupt { padding: 0 14px; }\n.int-card {\n border: 1px solid color-mix(in srgb, var(--sac-primary) 35%, var(--sac-border));\n background: color-mix(in srgb, var(--sac-primary) 8%, var(--sac-surface-2));\n border-radius: 14px;\n padding: 12px 13px;\n animation: sac-msg-in .3s var(--sac-ease) both;\n}\n.int-head { display: flex; align-items: center; gap: 8px; }\n.int-ico { display: flex; color: var(--sac-primary); }\n.int-ico svg { width: 17px; height: 17px; }\n.int-title { font-size: 13.5px; font-weight: 650; }\n.int-desc { margin-top: 5px; font-size: 12.5px; line-height: 1.45; color: color-mix(in srgb, var(--sac-text) 80%, transparent); }\n.int-sent { margin-top: 6px; font-size: 11.5px; color: color-mix(in srgb, var(--sac-text) 60%, transparent); }\n.int-row { display: flex; gap: 8px; margin-top: 10px; }\n.int-input {\n flex: 1;\n min-width: 0;\n border: 1px solid color-mix(in srgb, var(--sac-border) 80%, transparent);\n background: var(--sac-bg);\n color: var(--sac-text);\n border-radius: 10px;\n padding: 9px 11px;\n font-family: inherit;\n font-size: 14px;\n letter-spacing: .14em;\n outline: none;\n transition: border-color .2s ease, box-shadow .2s ease;\n}\n.int-input:focus {\n border-color: color-mix(in srgb, var(--sac-primary) 60%, transparent);\n box-shadow: 0 0 0 4px color-mix(in srgb, var(--sac-primary) 14%, transparent);\n}\n.int-form { display: flex; flex-direction: column; gap: 10px; margin-top: 10px; }\n.int-form .pc-field input { width: 100%; box-sizing: border-box; }\n.int-form .int-error { margin-top: 2px; }\n.int-btn {\n border: 1px solid color-mix(in srgb, var(--sac-border) 80%, transparent);\n background: var(--sac-surface-2);\n color: var(--sac-text);\n border-radius: 10px;\n padding: 9px 14px;\n font-family: inherit;\n font-size: 13px;\n font-weight: 600;\n cursor: pointer;\n transition: transform .2s var(--sac-ease), background .2s ease, border-color .2s ease;\n}\n.int-btn:hover { transform: translateY(-1px); }\n.int-btn.primary {\n border: none;\n background: linear-gradient(150deg, var(--sac-primary), var(--sac-primary-2));\n color: var(--sac-primary-text);\n box-shadow: 0 6px 14px -6px color-mix(in srgb, var(--sac-primary) 65%, transparent);\n}\n.int-row .int-form { display: flex; flex-direction: column; gap: 10px; margin-top: 10px; }\n.int-form .pc-field input { width: 100%; box-sizing: border-box; }\n.int-form .int-error { margin-top: 2px; }\n.int-btn { flex: 1; }\n.int-row .int-input + .int-form { display: flex; flex-direction: column; gap: 10px; margin-top: 10px; }\n.int-form .pc-field input { width: 100%; box-sizing: border-box; }\n.int-form .int-error { margin-top: 2px; }\n.int-btn { flex: 0 0 auto; }\n.int-error { margin-top: 8px; font-size: 12px; color: #f87171; }\n.int-card { position: relative; }\n.int-close {\n position: absolute;\n top: 8px;\n right: 9px;\n border: none;\n background: transparent;\n color: color-mix(in srgb, var(--sac-text) 55%, transparent);\n font-size: 18px;\n line-height: 1;\n cursor: pointer;\n padding: 2px 4px;\n border-radius: 6px;\n transition: color .2s ease, background .2s ease;\n}\n.int-close:hover { color: var(--sac-text); background: color-mix(in srgb, var(--sac-text) 8%, transparent); }\n\n/* ─────────────── Cross-device \"Restore my chats\" ──────────────────── */\n.restore-link {\n border: none;\n background: none;\n padding: 0;\n font: inherit;\n font-size: 10.5px;\n letter-spacing: .04em;\n color: color-mix(in srgb, var(--sac-primary) 80%, var(--sac-text));\n cursor: pointer;\n text-decoration: underline;\n text-underline-offset: 2px;\n}\n.restore-link:hover { color: var(--sac-primary); }\n.restore-list { display: flex; flex-direction: column; gap: 7px; margin-top: 9px; }\n.restore-item {\n display: flex;\n align-items: center;\n justify-content: space-between;\n gap: 10px;\n text-align: left;\n border: 1px solid color-mix(in srgb, var(--sac-border) 80%, transparent);\n background: var(--sac-bg);\n color: var(--sac-text);\n border-radius: 10px;\n padding: 9px 11px;\n font-family: inherit;\n font-size: 12.5px;\n cursor: pointer;\n transition: border-color .2s ease, background .2s ease, transform .2s ease;\n}\n.restore-item:hover {\n border-color: color-mix(in srgb, var(--sac-primary) 50%, transparent);\n background: color-mix(in srgb, var(--sac-primary) 8%, var(--sac-bg));\n transform: translateY(-1px);\n}\n.restore-preview { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }\n.restore-when { flex: 0 0 auto; font-size: 11px; color: color-mix(in srgb, var(--sac-text) 55%, transparent); }\n\n.hidden { display: none !important; }\n\n@media (prefers-reduced-motion: reduce) {\n .launcher::before, .dot, .bubble.typing i { animation: none !important; }\n .panel, .row, .launcher, .send, .close { animation: none !important; transition: none !important; }\n}\n`;\n}\n","/**\n * `<smooth-agent-chat>` — a framework-light embeddable chat web component.\n *\n * A clean, dependency-light web component that preserves a familiar embedding\n * model — a launcher + popover panel, declarative HTML attributes, and a\n * programmatic API — while talking to the `@smooai/smooth-operator` protocol\n * client. The visual layer is the \"Aurora Glass\" design system (see\n * {@link buildStyles}): a spring launcher with a live presence pulse, a\n * glass-depth panel, a gradient brand avatar + status dot, an animated typing\n * indicator, message rise-in, refined source cards, and an icon composer. Every\n * color is driven by `--sac-*` custom properties so a host's brand flows through.\n *\n * Embedding model:\n * <smooth-agent-chat endpoint=\"ws://localhost:8787/ws\" agent-id=\"…\"></smooth-agent-chat>\n * or programmatically via {@link mountChatWidget}.\n */\nimport { AsYouType, isValidPhoneNumber, parsePhoneNumber } from 'libphonenumber-js/min';\nimport type { ChatWidgetConfig, ChatWidgetMode, ChatWidgetTheme } from './config.js';\nimport { needsUserInfo, resolveConfig } from './config.js';\nimport {\n type ChatMessage,\n type Citation,\n type ConnectionStatus,\n ConversationController,\n type IdentityRestore,\n type Interrupt,\n SUPPORTED_INTERACTION_CAPABILITIES,\n type ToolCall,\n} from './conversation.js';\nimport { SMOOTH_ICON_SVG } from './logo.js';\nimport { cleanCitationSnippet, escapeHtml, renderMarkdown, safeHttpUrl } from './markdown.js';\nimport { buildStyles } from './styles.js';\n\nexport const ELEMENT_TAG = 'smooth-agent-chat';\n\n/**\n * Default region for phone parsing/formatting on the pre-chat form. The widget\n * is US-first; the backend does the authoritative E.164 normalization (SMOODEV-2153),\n * so this only governs the as-you-type display + the inline validity hint and the\n * best-effort E.164 we send when the number already parses as valid.\n */\nconst PHONE_DEFAULT_REGION = 'US' as const;\n\n/**\n * Best-effort E.164 for an as-typed phone number. Returns the canonical\n * `+1…` form when the value parses to a valid number in {@link PHONE_DEFAULT_REGION},\n * otherwise `null` (caller falls back to sending the raw value — the backend\n * re-parses and normalizes/nulls authoritatively).\n */\nfunction phoneToE164(value: string): string | null {\n const v = value.trim();\n if (!v) return null;\n try {\n if (!isValidPhoneNumber(v, PHONE_DEFAULT_REGION)) return null;\n return parsePhoneNumber(v, PHONE_DEFAULT_REGION).number;\n } catch {\n return null;\n }\n}\n\n/** Public smooth-operator repo — the \"powered by\" header tag + footer link here. */\nconst SMOOTH_OPERATOR_URL = 'https://github.com/SmooAI/smooth-operator';\n\nconst OBSERVED = ['endpoint', 'agent-id', 'agent-name', 'logo-url', 'placeholder', 'greeting', 'start-open', 'mode', 'hide-branding', 'show-tool-activity'] as const;\n\n/**\n * Inline SVG icons (static, trusted strings — never interpolated with user data).\n * Kept here so the IIFE bundle is self-contained: no icon-font or network fetch.\n */\nconst ICON = {\n /** Launcher — a speech bubble carrying a spark (chat + AI). */\n spark: `<svg class=\"ico\" viewBox=\"0 0 24 24\" fill=\"none\" xmlns=\"http://www.w3.org/2000/svg\"><path d=\"M12 3.5c-4.7 0-8.5 3.2-8.5 7.2 0 2.2 1.2 4.2 3 5.5v3.3l3.2-1.7c.7.1 1.5.2 2.3.2 4.7 0 8.5-3.2 8.5-7.3S16.7 3.5 12 3.5Z\" fill=\"currentColor\" opacity=\".22\"/><path d=\"M13.4 7.2 9 12.6h2.6l-1 4.2 4.4-5.4h-2.6l1-4.2Z\" fill=\"currentColor\"/></svg>`,\n /** Small assistant avatar used beside each assistant message. */\n bot: `<svg viewBox=\"0 0 24 24\" fill=\"none\" xmlns=\"http://www.w3.org/2000/svg\"><rect x=\"4.5\" y=\"7.5\" width=\"15\" height=\"11\" rx=\"3.5\" stroke=\"currentColor\" stroke-width=\"1.6\"/><path d=\"M12 4.5v3M8.5 12.2h.01M15.5 12.2h.01\" stroke=\"currentColor\" stroke-width=\"1.8\" stroke-linecap=\"round\"/><path d=\"M9.5 15.4c.7.6 1.5.9 2.5.9s1.8-.3 2.5-.9\" stroke=\"currentColor\" stroke-width=\"1.5\" stroke-linecap=\"round\"/></svg>`,\n /** Close (collapse panel) — a downward chevron. */\n close: `<svg viewBox=\"0 0 24 24\" fill=\"none\" xmlns=\"http://www.w3.org/2000/svg\"><path d=\"m7 10 5 5 5-5\" stroke=\"currentColor\" stroke-width=\"1.8\" stroke-linecap=\"round\" stroke-linejoin=\"round\"/></svg>`,\n /** Send — an upward arrow. */\n send: `<svg viewBox=\"0 0 24 24\" fill=\"none\" xmlns=\"http://www.w3.org/2000/svg\"><path d=\"M12 19V6M12 6l-5.5 5.5M12 6l5.5 5.5\" stroke=\"currentColor\" stroke-width=\"1.9\" stroke-linecap=\"round\" stroke-linejoin=\"round\"/></svg>`,\n /** Sources disclosure caret. */\n chev: `<svg width=\"11\" height=\"11\" viewBox=\"0 0 24 24\" fill=\"none\"><path d=\"m9 6 6 6-6 6\" stroke=\"currentColor\" stroke-width=\"2.2\" stroke-linecap=\"round\" stroke-linejoin=\"round\"/></svg>`,\n /** OTP interrupt — a padlock. */\n lock: `<svg viewBox=\"0 0 24 24\" fill=\"none\" xmlns=\"http://www.w3.org/2000/svg\"><rect x=\"5\" y=\"10.5\" width=\"14\" height=\"9.5\" rx=\"2.2\" stroke=\"currentColor\" stroke-width=\"1.7\"/><path d=\"M8 10.5V8a4 4 0 0 1 8 0v2.5\" stroke=\"currentColor\" stroke-width=\"1.7\"/></svg>`,\n /** Identity-intake interrupt — a person. */\n user: `<svg viewBox=\"0 0 24 24\" fill=\"none\" xmlns=\"http://www.w3.org/2000/svg\"><circle cx=\"12\" cy=\"8.2\" r=\"3.4\" stroke=\"currentColor\" stroke-width=\"1.7\"/><path d=\"M5.5 19.5c.8-3.1 3.4-4.8 6.5-4.8s5.7 1.7 6.5 4.8\" stroke=\"currentColor\" stroke-width=\"1.7\" stroke-linecap=\"round\"/></svg>`,\n /** Tool-confirmation interrupt — a shield. */\n shield: `<svg viewBox=\"0 0 24 24\" fill=\"none\" xmlns=\"http://www.w3.org/2000/svg\"><path d=\"M12 3 5 6v5c0 4.4 3 7.2 7 8.5 4-1.3 7-4.1 7-8.5V6l-7-3Z\" stroke=\"currentColor\" stroke-width=\"1.7\" stroke-linejoin=\"round\"/><path d=\"m9 11.5 2 2 4-4\" stroke=\"currentColor\" stroke-width=\"1.7\" stroke-linecap=\"round\" stroke-linejoin=\"round\"/></svg>`,\n /** Tool-activity chip — a wrench. */\n tool: `<svg viewBox=\"0 0 24 24\" fill=\"none\" xmlns=\"http://www.w3.org/2000/svg\"><path d=\"M14.7 6.3a3.5 3.5 0 0 0-4.6 4.3l-5 5a1.6 1.6 0 0 0 2.3 2.3l5-5a3.5 3.5 0 0 0 4.3-4.6l-2 2-1.7-.3-.3-1.7 2-2Z\" stroke=\"currentColor\" stroke-width=\"1.5\" stroke-linejoin=\"round\"/></svg>`,\n} as const;\n\n/**\n * The Rich Interactions **card registry**: interaction kind → overlay card.\n * `interaction_required { kind }` looks its card up here; registering a card IS\n * declaring the widget's render capability for that kind (see\n * `SUPPORTED_INTERACTION_CAPABILITIES` in conversation.ts — a test keeps the\n * two aligned). Adding a kind = one card builder + one entry.\n *\n * The existing OTP and tool-approval overlays are prior instances of this same\n * shape and should retrofit onto this registry later (their wire events predate\n * the pattern).\n */\nexport interface InteractionCardContext {\n /** Submit kind-shaped values (resumes the parked turn; server validates). */\n submit: (values: Record<string, unknown>) => void;\n /** Decline the interaction (the agent continues without it). */\n decline: () => void;\n /** Persisted visitor identity, for pre-filling known fields. */\n prefill: { name?: string; email?: string; phone?: string };\n /** Wire live phone formatting + validity hint onto a form's phone input. */\n wirePhoneField: (form: HTMLFormElement) => void;\n}\n\nexport interface InteractionCard {\n /** The render capability this card provides (goes into `supports`). */\n capability: string;\n /** Card header title. */\n title: string;\n /** Static, trusted header icon SVG. */\n icon: string;\n /** Build the card body for an `interaction` interrupt. */\n build: (it: Extract<Interrupt, { kind: 'interaction' }>, ctx: InteractionCardContext) => HTMLElement;\n}\n\n/**\n * The identity_intake card: the fields the agent requested (pre-chat form field\n * pattern — same classes, same phone formatting), per-field server errors, a\n * submit and a decline affordance. Server-supplied text (reason, labels, error\n * messages) is set via `textContent` — never innerHTML.\n */\nfunction buildIdentityIntakeCard(it: Extract<Interrupt, { kind: 'interaction' }>, ctx: InteractionCardContext): HTMLElement {\n const form = document.createElement('form');\n form.className = 'int-form';\n form.noValidate = true;\n\n if (it.reason) {\n const desc = document.createElement('div');\n desc.className = 'int-desc';\n desc.textContent = it.reason;\n form.appendChild(desc);\n }\n\n const DEFAULTS: Record<string, { label: string; type: string; autocomplete: string }> = {\n name: { label: 'Name', type: 'text', autocomplete: 'name' },\n email: { label: 'Email', type: 'email', autocomplete: 'email' },\n phone: { label: 'Phone', type: 'tel', autocomplete: 'tel' },\n };\n\n // Parse the kind's spec defensively: `{ fields: [{ key, required, label? }] }`.\n const rawFields = Array.isArray(it.spec.fields) ? it.spec.fields : [];\n const fields: { key: 'name' | 'email' | 'phone'; required: boolean; label?: string }[] = [];\n for (const f of rawFields) {\n if (!f || typeof f !== 'object') continue;\n const o = f as Record<string, unknown>;\n const key = typeof o.key === 'string' ? o.key : '';\n if (key !== 'name' && key !== 'email' && key !== 'phone') continue;\n fields.push({ key, required: o.required === true, label: typeof o.label === 'string' ? o.label : undefined });\n }\n if (fields.length === 0) fields.push({ key: 'email', required: true });\n\n for (const f of fields) {\n const d = DEFAULTS[f.key]!;\n const label = document.createElement('label');\n label.className = 'pc-field';\n const caption = document.createElement('span');\n caption.textContent = f.label ?? d.label;\n const input = document.createElement('input');\n input.name = f.key;\n input.type = d.type;\n input.setAttribute('autocomplete', d.autocomplete);\n input.required = f.required;\n const prefill = ctx.prefill[f.key];\n if (prefill) input.value = prefill;\n label.append(caption, input);\n if (f.key === 'phone') {\n const hint = document.createElement('span');\n hint.className = 'pc-hint';\n hint.setAttribute('aria-live', 'polite');\n label.appendChild(hint);\n }\n // Per-field server-side validation error (interaction_invalid).\n const serverError = it.errors?.find((e) => e.field === f.key);\n if (serverError) {\n label.classList.add('invalid');\n const err = document.createElement('span');\n err.className = 'int-error';\n err.textContent = serverError.message;\n label.appendChild(err);\n }\n form.appendChild(label);\n }\n\n const row = document.createElement('div');\n row.className = 'int-row';\n const decline = document.createElement('button');\n decline.className = 'int-btn';\n decline.type = 'button';\n decline.textContent = 'No thanks';\n decline.addEventListener('click', () => ctx.decline());\n const share = document.createElement('button');\n share.className = 'int-btn primary';\n share.type = 'submit';\n share.textContent = 'Share details';\n row.append(decline, share);\n form.appendChild(row);\n\n form.addEventListener('submit', (ev) => {\n ev.preventDefault();\n if (!form.reportValidity()) return;\n const data = new FormData(form);\n const val = (k: string) => ((data.get(k) as string | null)?.trim() || undefined);\n\n // Phone: mirror the pre-chat rules — block a required-but-invalid number,\n // prefer canonical E.164 when it parses (the server re-validates anyway).\n const rawPhone = val('phone');\n const phoneInput = form.querySelector('input[name=\"phone\"]') as HTMLInputElement | null;\n if (rawPhone && phoneInput && !isValidPhoneNumber(rawPhone, PHONE_DEFAULT_REGION)) {\n const field = phoneInput.closest('.pc-field');\n field?.classList.add('invalid');\n const hint = field?.querySelector('.pc-hint');\n if (hint) hint.textContent = 'Enter a valid phone number';\n if (phoneInput.hasAttribute('required')) {\n phoneInput.focus();\n return;\n }\n }\n const phone = rawPhone ? (phoneToE164(rawPhone) ?? rawPhone) : undefined;\n ctx.submit({ name: val('name'), email: val('email'), phone });\n });\n // Same live phone formatting + validity hint as the pre-chat form.\n ctx.wirePhoneField(form);\n queueMicrotask(() => (form.querySelector('input') as HTMLInputElement | null)?.focus());\n return form;\n}\n\n/** Kind → card. See the registry doc above. */\nexport const INTERACTION_CARDS: Record<string, InteractionCard> = {\n identity_intake: {\n capability: 'identity_form',\n title: 'Share your details',\n icon: ICON.user,\n build: buildIdentityIntakeCard,\n },\n};\n\n// `safeHttpUrl` / `escapeHtml` live in `./markdown.js` (the markdown renderer\n// needs them too); re-exported here for back-compat with existing importers.\nexport { escapeHtml, safeHttpUrl } from './markdown.js';\n\nexport class SmoothAgentChatElement extends HTMLElement {\n static get observedAttributes(): readonly string[] {\n return OBSERVED;\n }\n\n private readonly root: ShadowRoot;\n private controller: ConversationController | null = null;\n private overrides: Partial<ChatWidgetConfig> = {};\n private open = false;\n private messages: ChatMessage[] = [];\n private status: ConnectionStatus = 'idle';\n private mounted = false;\n /** True once the visitor has cleared the pre-chat identity gate (or it's not needed). */\n private userInfoSatisfied = false;\n /** True after the visitor has sent their first message (hides starter chips). */\n private hasSent = false;\n /** Starter prompts shown as chips in the empty state. */\n private examplePrompts: string[] = [];\n /** Whether mid-conversation suggested-reply chips are shown (config). */\n private showSuggestedReplies = true;\n /** Resolved greeting text, cached so async (rAF) renders can reuse it. */\n private greeting = '';\n /** Current mid-turn interrupt (OTP / tool-confirmation), or null. */\n private interrupt: Interrupt | null = null;\n private interruptEl: HTMLElement | null = null;\n /** Cross-device \"restore my chats\" flow state (ADR-048 §c). */\n private identityRestore: IdentityRestore = { phase: 'idle' };\n /** Whether the cross-device restore affordance is offered (config). */\n private allowChatRestore = true;\n /** True while the pre-chat identity gate is showing (blocks premature connect). */\n private gating = false;\n\n // Cached DOM refs (populated in render()).\n private panelEl: HTMLElement | null = null;\n private launcherEl: HTMLElement | null = null;\n private messagesEl: HTMLElement | null = null;\n private statusEl: HTMLElement | null = null;\n private dotEl: HTMLElement | null = null;\n private inputEl: HTMLTextAreaElement | null = null;\n private sendBtn: HTMLButtonElement | null = null;\n private suggestionsEl: HTMLElement | null = null;\n\n // ── Smooth streaming reveal ──\n // Tokens arrive in variable-size bursts at uneven rates, so revealing text in\n // lockstep with arrival looks jerky. Instead we buffer the full target text\n // and reveal it via a requestAnimationFrame \"typewriter\" at an adaptive rate\n // (chars/frame scales with the pending backlog so it never falls behind the\n // network). State below tracks the single in-flight streaming bubble.\n /** The live streaming assistant bubble whose textContent the rAF loop drives. */\n private streamBubbleEl: HTMLElement | null = null;\n /** Message id the reveal is bound to (guards against stale frames after rebuilds). */\n private streamMsgId: string | null = null;\n /** Full buffered target text for the streaming message (grows as tokens arrive). */\n private streamTarget = '';\n /** How many chars of {@link streamTarget} are currently shown. */\n private displayedLength = 0;\n private rafId = 0;\n /** Block structure signature of the last-rendered streaming message (tool chips\n * only — text growth doesn't change it), so a chip add/resolve forces a rebuild\n * while plain trailing-text growth stays on the fast reveal path. */\n private prevBlockSig = '';\n\n constructor() {\n super();\n this.root = this.attachShadow({ mode: 'open' });\n }\n\n connectedCallback(): void {\n this.mounted = true;\n this.render();\n }\n\n disconnectedCallback(): void {\n this.mounted = false;\n this.resetReveal();\n this.controller?.disconnect();\n this.controller = null;\n }\n\n attributeChangedCallback(): void {\n if (this.mounted) this.render();\n }\n\n /**\n * Programmatically merge config overrides (endpoint, agentId, theme, …). Values\n * set here take precedence over HTML attributes. Re-renders the widget.\n */\n configure(config: Partial<ChatWidgetConfig>): void {\n this.overrides = { ...this.overrides, ...config };\n if (config.theme) {\n this.overrides.theme = { ...(this.overrides.theme ?? {}), ...config.theme };\n }\n if (this.mounted) this.render();\n }\n\n /** Open the chat panel. */\n openChat(): void {\n this.open = true;\n this.syncOpenState();\n // Don't connect while the pre-chat identity gate is unsatisfied — connecting\n // here would create a session BEFORE the visitor submits their name/email/\n // consent, sending an empty identity. The form's submit handler connects.\n if (!this.gating) void this.controller?.connect().catch(() => {});\n }\n\n /** Collapse the chat panel back to the launcher. */\n closeChat(): void {\n this.open = false;\n this.syncOpenState();\n }\n\n // ─────────────────────────── Config resolution ─────────────────────────────\n\n private readConfig(): ChatWidgetConfig | null {\n const endpoint = this.overrides.endpoint ?? this.getAttribute('endpoint') ?? '';\n const agentId = this.overrides.agentId ?? this.getAttribute('agent-id') ?? '';\n if (!endpoint || !agentId) return null;\n\n const theme: ChatWidgetTheme | undefined = this.overrides.theme;\n const modeAttr = this.getAttribute('mode');\n const mode: ChatWidgetMode = this.overrides.mode ?? (modeAttr === 'fullpage' ? 'fullpage' : modeAttr === 'popover' ? 'popover' : undefined) ?? 'popover';\n return {\n endpoint,\n mode,\n agentId,\n agentName: this.overrides.agentName ?? this.getAttribute('agent-name') ?? undefined,\n logoUrl: this.overrides.logoUrl ?? this.getAttribute('logo-url') ?? undefined,\n userName: this.overrides.userName,\n userEmail: this.overrides.userEmail,\n userPhone: this.overrides.userPhone,\n authContext: this.overrides.authContext,\n placeholder: this.overrides.placeholder ?? this.getAttribute('placeholder') ?? undefined,\n greeting: this.overrides.greeting ?? this.getAttribute('greeting') ?? undefined,\n connectionErrorMessage: this.overrides.connectionErrorMessage,\n startOpen: this.overrides.startOpen ?? this.hasAttribute('start-open'),\n hideBranding: this.overrides.hideBranding ?? this.hasAttribute('hide-branding'),\n examplePrompts: this.overrides.examplePrompts,\n showSuggestedReplies: this.overrides.showSuggestedReplies,\n requireName: this.overrides.requireName,\n requireEmail: this.overrides.requireEmail,\n requirePhone: this.overrides.requirePhone,\n collectPhone: this.overrides.collectPhone,\n collectConsent: this.overrides.collectConsent,\n allowChatRestore: this.overrides.allowChatRestore,\n allowAnonymous: this.overrides.allowAnonymous,\n showToolActivity: this.overrides.showToolActivity ?? this.hasAttribute('show-tool-activity'),\n theme,\n };\n }\n\n // ───────────────────────────────── Render ──────────────────────────────────\n\n private render(): void {\n const config = this.readConfig();\n if (!config) {\n this.root.innerHTML = '';\n return;\n }\n const resolved = resolveConfig(config);\n\n this.allowChatRestore = resolved.allowChatRestore;\n\n // (Re)create the controller only when there isn't one yet. Attribute churn\n // (e.g. theme tweaks) re-renders the view without dropping the session.\n if (!this.controller) {\n this.controller = new ConversationController(config, {\n onMessages: (messages) => {\n this.handleMessages(messages, resolved.greeting);\n },\n onStatus: (status) => {\n this.status = status;\n this.renderStatus();\n this.renderComposerState();\n },\n onInterrupt: (interrupt) => {\n this.interrupt = interrupt;\n this.renderInterrupt();\n // Suggestion chips are hidden while an interrupt overlay is up.\n this.renderSuggestions();\n },\n onIdentityRestore: (state) => {\n this.identityRestore = state;\n this.renderInterrupt();\n // The restore overlay reuses the interrupt slot — hide chips too.\n this.renderSuggestions();\n },\n });\n if (resolved.startOpen) this.open = true;\n // Returning visitor: a persisted session or identity lets us skip the\n // pre-chat gate and resume straight into the conversation (ADR-048 §b).\n if (this.controller.hasPersistedSession() || this.controller.hasPersistedIdentity()) {\n this.userInfoSatisfied = true;\n }\n }\n\n const fullpage = resolved.mode === 'fullpage';\n // Full-page mode is always \"open\" — it fills its container and has no\n // launcher to toggle.\n if (fullpage) this.open = true;\n\n const style = document.createElement('style');\n style.textContent = buildStyles(resolved.theme, resolved.mode);\n\n // Header: in full-page mode lead with the brand logo in the avatar tile\n // and a subtle \"powered by\" tag; in popover mode show a brand-colored\n // monogram avatar + a compact close (collapse) button. The logo defaults\n // to the square Smooth icon, but a host page can override it with\n // `logoUrl` (already sanitized to http(s)-only by resolveConfig; escaped\n // here so it can't break out of the src attribute).\n const monogram = escapeHtml((resolved.agentName.trim().charAt(0) || 'A').toUpperCase());\n const headerLogo = resolved.logoUrl\n ? `<img src=\"${escapeHtml(resolved.logoUrl)}\" alt=\"\" class=\"logo-img\" />`\n : SMOOTH_ICON_SVG;\n const header = fullpage\n ? `<div class=\"header\">\n <div class=\"avatar\"><span class=\"logo-wrap\">${headerLogo}</span></div>\n <div class=\"meta\">\n <span class=\"title\">${escapeHtml(resolved.agentName)}</span>\n <span class=\"status\"><span class=\"dot off\"></span><span class=\"status-text\"></span></span>\n </div>\n ${\n resolved.hideBranding\n ? ''\n : `<a class=\"powered\" href=\"${SMOOTH_OPERATOR_URL}\" target=\"_blank\" rel=\"noopener noreferrer\">powered by smooth-operator</a>`\n }\n </div>`\n : `<div class=\"header\">\n <div class=\"avatar\">${monogram}</div>\n <div class=\"meta\">\n <span class=\"title\">${escapeHtml(resolved.agentName)}</span>\n <span class=\"status\"><span class=\"dot off\"></span><span class=\"status-text\"></span></span>\n </div>\n <button class=\"close\" aria-label=\"Close chat\">${ICON.close}</button>\n </div>`;\n\n // Remember starter prompts + greeting for the empty-state chips / async renders.\n this.examplePrompts = resolved.examplePrompts;\n this.showSuggestedReplies = resolved.showSuggestedReplies;\n this.greeting = resolved.greeting;\n\n // Gate the conversation behind a pre-chat identity form when required.\n const gating = needsUserInfo(resolved) && !this.userInfoSatisfied;\n this.gating = gating;\n // Phone is collected by default (optional unless requirePhone). Consent\n // checkboxes default to shown, explicit + unchecked (ADR-048 §a/§3).\n const showPhone = resolved.requirePhone || resolved.collectPhone;\n const field = (name: string, type: string, label: string, autocomplete: string, required: boolean, hint = false) =>\n `<label class=\"pc-field\"><span>${escapeHtml(label)}</span><input name=\"${name}\" type=\"${type}\" autocomplete=\"${autocomplete}\"${required ? ' required' : ''} />${\n hint ? '<span class=\"pc-hint\" aria-live=\"polite\"></span>' : ''\n }</label>`;\n const consentBox = (name: string, label: string) =>\n `<label class=\"pc-consent\"><input name=\"${name}\" type=\"checkbox\" /><span>${escapeHtml(label)}</span></label>`;\n const consentHtml = resolved.collectConsent\n ? `<div class=\"pc-consents\">\n ${consentBox('emailOptIn', 'Email me product news and offers.')}\n ${consentBox('smsOptIn', 'Text me updates by SMS. Message/data rates may apply.')}\n </div>`\n : '';\n const prechatHtml = `\n <div class=\"prechat\">\n <div class=\"pc-head\">\n <div class=\"pc-title\">Before we chat</div>\n <div class=\"pc-sub\">A couple details so ${escapeHtml(resolved.agentName)} can help.</div>\n </div>\n <form class=\"pc-form\" novalidate>\n ${resolved.requireName ? field('name', 'text', 'Name', 'name', true) : ''}\n ${resolved.requireEmail ? field('email', 'email', 'Email', 'email', true) : ''}\n ${showPhone ? field('phone', 'tel', 'Phone', 'tel', resolved.requirePhone, true) : ''}\n ${consentHtml}\n <button type=\"submit\" class=\"pc-submit\">Start chat</button>\n </form>\n </div>`;\n // Footer: optional \"powered by\" branding (hidden by hide-branding) and an\n // optional \"Restore my chats\" affordance. The \" · \" separator only appears\n // when both are present, and the footer is omitted entirely when neither is.\n const brandingHtml = resolved.hideBranding\n ? ''\n : `<a href=\"${SMOOTH_OPERATOR_URL}\" target=\"_blank\" rel=\"noopener noreferrer\">powered by <b>smooth‑operator</b></a>`;\n const restoreBtn = this.allowChatRestore ? `<button type=\"button\" class=\"restore-link\">Restore my chats</button>` : '';\n const footerInner = [brandingHtml, restoreBtn].filter(Boolean).join(' · ');\n const footerHtml = footerInner ? `<div class=\"footer\">${footerInner}</div>` : '';\n const chatHtml = `\n <div class=\"messages\"></div>\n <div class=\"reply-suggestions\"></div>\n <div class=\"interrupt hidden\"></div>\n <div class=\"composer-wrap\">\n <div class=\"composer\">\n <textarea rows=\"1\" placeholder=\"${escapeHtml(resolved.placeholder)}\"></textarea>\n <button class=\"send\" type=\"button\" aria-label=\"Send message\">${ICON.send}</button>\n </div>\n ${footerHtml}\n </div>`;\n\n const container = document.createElement('div');\n container.className = 'wrap';\n container.innerHTML = `\n ${fullpage ? '' : `<button class=\"launcher\" part=\"launcher\" aria-label=\"Open chat\">${ICON.spark}</button>`}\n <div class=\"panel${fullpage ? ' fullpage' : ' hidden'}\" part=\"panel\" role=\"${fullpage ? 'region' : 'dialog'}\" aria-label=\"${escapeHtml(resolved.agentName)} chat\">\n ${header}\n <div class=\"header-sep\"></div>\n ${gating ? prechatHtml : chatHtml}\n </div>\n `;\n\n // Tag the logo <svg> so styles can size it (the inlined SVG has its own id).\n const logoSvg = container.querySelector('.logo-wrap svg');\n if (logoSvg) logoSvg.setAttribute('class', 'logo');\n\n // A full DOM rebuild invalidates any cached streaming-bubble ref; cancel\n // the in-flight reveal loop so renderMessages can re-bind cleanly.\n this.resetReveal();\n this.root.replaceChildren(style, container);\n\n this.launcherEl = container.querySelector('.launcher');\n this.panelEl = container.querySelector('.panel');\n this.messagesEl = container.querySelector('.messages');\n this.statusEl = container.querySelector('.status-text');\n this.dotEl = container.querySelector('.dot');\n this.inputEl = container.querySelector('textarea');\n this.sendBtn = container.querySelector('.send');\n this.interruptEl = container.querySelector('.interrupt');\n this.suggestionsEl = container.querySelector('.reply-suggestions');\n\n this.launcherEl?.addEventListener('click', () => this.openChat());\n container.querySelector('.close')?.addEventListener('click', () => this.closeChat());\n this.sendBtn?.addEventListener('click', () => this.submit());\n this.inputEl?.addEventListener('input', () => this.autosize());\n this.inputEl?.addEventListener('keydown', (ev) => {\n if (ev.key === 'Enter' && !ev.shiftKey) {\n ev.preventDefault();\n this.submit();\n }\n });\n\n const pcForm = container.querySelector('.pc-form');\n pcForm?.addEventListener('submit', (ev) => {\n ev.preventDefault();\n this.handlePrechatSubmit(pcForm as HTMLFormElement);\n });\n\n // Live phone formatting + validity hint (libphonenumber-js, US default).\n // The implicit <label>, type=\"tel\", and autocomplete=\"tel\" from field()\n // are preserved — autofill keeps working — and we also reformat on\n // `change` so a browser-autofilled value gets formatted/validated too.\n this.wirePhoneField(pcForm as HTMLFormElement | null);\n\n // Cross-device \"Restore my chats\": open the panel + start the email entry.\n // AWAIT connect() before showing the email step so a `sessionId` exists by\n // the time the visitor submits — otherwise request-otp could go out with no\n // session and verify-otp would then hard-error \"No active session.\" The\n // request-otp/verify-otp paths in the controller also require a session, so\n // gating here keeps the affordance race-free.\n container.querySelector('.restore-link')?.addEventListener('click', () => {\n void (async () => {\n this.identityRestore = { phase: 'awaiting_email' };\n this.renderInterrupt();\n // Establish a live session before the email entry can fire request-otp.\n await this.controller?.connect().catch(() => {});\n })();\n });\n\n // Full-page mode sizes to the host's box; fall back to the viewport only\n // when the container gives the host no height.\n if (fullpage) this.syncViewportFallback();\n\n // Full-page mode connects eagerly (there's no launcher click to trigger it) —\n // but only once any identity gate is cleared.\n if (fullpage && !gating) void this.controller?.connect().catch(() => {});\n\n this.syncOpenState();\n if (!gating) this.renderMessages();\n this.renderStatus();\n this.renderComposerState();\n this.renderInterrupt();\n }\n\n /**\n * Render (or clear) the mid-turn interrupt overlay above the composer:\n * an OTP code prompt or a tool-write confirmation. Server-supplied text is\n * set via `textContent` (never innerHTML); only static icons use innerHTML.\n */\n private renderInterrupt(): void {\n const el = this.interruptEl;\n if (!el) return;\n el.replaceChildren();\n const it = this.interrupt;\n if (!it) {\n // No mid-turn interrupt — but the cross-device restore flow may be\n // active, which reuses this same overlay slot.\n if (this.identityRestore.phase !== 'idle') {\n el.classList.remove('hidden');\n el.appendChild(this.buildRestoreCard());\n return;\n }\n el.classList.add('hidden');\n return;\n }\n el.classList.remove('hidden');\n\n const card = document.createElement('div');\n card.className = 'int-card';\n\n const head = document.createElement('div');\n head.className = 'int-head';\n const ico = document.createElement('span');\n ico.className = 'int-ico';\n const card_meta = it.kind === 'interaction' ? INTERACTION_CARDS[it.interactionKind] : undefined;\n if (it.kind === 'interaction' && !card_meta) {\n // A kind we have no card for (shouldn't happen — we only declare\n // capabilities for registered cards). Decline so the turn never hangs.\n this.controller?.declineInteraction();\n el.classList.add('hidden');\n return;\n }\n ico.innerHTML = it.kind === 'otp' ? ICON.lock : it.kind === 'interaction' ? (card_meta?.icon ?? ICON.user) : ICON.shield; // static, trusted\n const title = document.createElement('span');\n title.className = 'int-title';\n title.textContent = it.kind === 'otp' ? 'Verification required' : it.kind === 'interaction' ? (card_meta?.title ?? 'One more thing') : 'Confirm this action';\n head.append(ico, title);\n card.appendChild(head);\n\n if (it.kind !== 'interaction' && it.actionDescription) {\n const desc = document.createElement('div');\n desc.className = 'int-desc';\n desc.textContent = it.actionDescription;\n card.appendChild(desc);\n }\n\n if (it.kind === 'interaction') {\n card.appendChild(\n card_meta!.build(it, {\n submit: (values) => this.controller?.submitInteraction(values),\n decline: () => this.controller?.declineInteraction(),\n prefill: this.controller?.getStore().getState().identity ?? {},\n wirePhoneField: (form) => this.wirePhoneField(form),\n }),\n );\n } else if (it.kind === 'otp') {\n if (it.sent?.maskedDestination) {\n const sent = document.createElement('div');\n sent.className = 'int-sent';\n sent.textContent = `Code sent to ${it.sent.maskedDestination}${it.sent.channel ? ` via ${it.sent.channel}` : ''}.`;\n card.appendChild(sent);\n }\n const row = document.createElement('div');\n row.className = 'int-row';\n const input = document.createElement('input');\n input.className = 'int-input';\n input.type = 'text';\n input.inputMode = 'numeric';\n input.autocomplete = 'one-time-code';\n input.placeholder = 'Enter code';\n const submit = () => {\n const code = input.value.trim();\n if (code) this.controller?.verifyOtp(code);\n };\n input.addEventListener('keydown', (ev) => {\n if (ev.key === 'Enter') {\n ev.preventDefault();\n submit();\n }\n });\n const verify = document.createElement('button');\n verify.className = 'int-btn primary';\n verify.type = 'button';\n verify.textContent = 'Verify';\n verify.addEventListener('click', submit);\n row.append(input, verify);\n card.appendChild(row);\n if (it.error) {\n const err = document.createElement('div');\n err.className = 'int-error';\n err.textContent = it.attemptsRemaining != null ? `${it.error} (${it.attemptsRemaining} left)` : it.error;\n card.appendChild(err);\n }\n queueMicrotask(() => input.focus());\n } else {\n const row = document.createElement('div');\n row.className = 'int-row';\n const decline = document.createElement('button');\n decline.className = 'int-btn';\n decline.type = 'button';\n decline.textContent = 'Decline';\n decline.addEventListener('click', () => this.controller?.confirmTool(false));\n const approve = document.createElement('button');\n approve.className = 'int-btn primary';\n approve.type = 'button';\n approve.textContent = 'Approve';\n approve.addEventListener('click', () => this.controller?.confirmTool(true));\n row.append(decline, approve);\n card.appendChild(row);\n }\n\n el.appendChild(card);\n }\n\n /**\n * Build the cross-device \"Restore my chats\" card (ADR-048 §c). Reuses the\n * same overlay slot + visual language as the OTP interrupt. All server-supplied\n * strings (masked destination, conversation previews) are set via `textContent`\n * — never innerHTML — so they can't inject markup; only the static lock icon\n * uses innerHTML.\n */\n private buildRestoreCard(): HTMLElement {\n const state = this.identityRestore;\n const card = document.createElement('div');\n card.className = 'int-card';\n\n const head = document.createElement('div');\n head.className = 'int-head';\n const ico = document.createElement('span');\n ico.className = 'int-ico';\n ico.innerHTML = ICON.lock; // static, trusted\n const title = document.createElement('span');\n title.className = 'int-title';\n title.textContent = 'Restore your chats';\n head.append(ico, title);\n card.appendChild(head);\n\n const close = document.createElement('button');\n close.className = 'int-close';\n close.type = 'button';\n close.setAttribute('aria-label', 'Cancel');\n close.textContent = '×';\n close.addEventListener('click', () => {\n this.controller?.cancelIdentityRestore();\n this.identityRestore = { phase: 'idle' };\n this.renderInterrupt();\n });\n card.appendChild(close);\n\n if (state.phase === 'awaiting_email') {\n const desc = document.createElement('div');\n desc.className = 'int-desc';\n desc.textContent = \"Enter your email and we'll send a code to find your previous chats.\";\n card.appendChild(desc);\n\n const row = document.createElement('div');\n row.className = 'int-row';\n const input = document.createElement('input');\n input.className = 'int-input';\n input.type = 'email';\n input.autocomplete = 'email';\n input.placeholder = 'you@example.com';\n const go = () => {\n const email = input.value.trim();\n if (email) void this.controller?.requestIdentityOtp(email, 'email');\n };\n input.addEventListener('keydown', (ev) => {\n if (ev.key === 'Enter') {\n ev.preventDefault();\n go();\n }\n });\n const send = document.createElement('button');\n send.className = 'int-btn primary';\n send.type = 'button';\n send.textContent = 'Send code';\n send.addEventListener('click', go);\n row.append(input, send);\n card.appendChild(row);\n if (state.error) {\n const err = document.createElement('div');\n err.className = 'int-error';\n err.textContent = state.error;\n card.appendChild(err);\n }\n queueMicrotask(() => input.focus());\n } else if (state.phase === 'requesting' || state.phase === 'verifying' || state.phase === 'resolving') {\n const msg = document.createElement('div');\n msg.className = 'int-sent';\n msg.textContent = state.phase === 'requesting' ? 'Sending a code…' : state.phase === 'verifying' ? 'Verifying…' : 'Finding your chats…';\n card.appendChild(msg);\n } else if (state.phase === 'awaiting_code') {\n if (state.maskedDestination) {\n const sent = document.createElement('div');\n sent.className = 'int-sent';\n sent.textContent = `Code sent to ${state.maskedDestination}.`;\n card.appendChild(sent);\n }\n const row = document.createElement('div');\n row.className = 'int-row';\n const input = document.createElement('input');\n input.className = 'int-input';\n input.type = 'text';\n input.inputMode = 'numeric';\n input.autocomplete = 'one-time-code';\n input.placeholder = 'Enter code';\n const submit = () => {\n const code = input.value.trim();\n if (code) void this.controller?.verifyIdentityOtp(code);\n };\n input.addEventListener('keydown', (ev) => {\n if (ev.key === 'Enter') {\n ev.preventDefault();\n submit();\n }\n });\n const verify = document.createElement('button');\n verify.className = 'int-btn primary';\n verify.type = 'button';\n verify.textContent = 'Verify';\n verify.addEventListener('click', submit);\n row.append(input, verify);\n card.appendChild(row);\n if (state.error) {\n const err = document.createElement('div');\n err.className = 'int-error';\n err.textContent = state.attemptsRemaining != null ? `${state.error} (${state.attemptsRemaining} left)` : state.error;\n card.appendChild(err);\n }\n queueMicrotask(() => input.focus());\n } else if (state.phase === 'resolved') {\n if (state.conversations.length === 0) {\n const none = document.createElement('div');\n none.className = 'int-desc';\n none.textContent = 'No previous chats found for that email.';\n card.appendChild(none);\n } else {\n const pick = document.createElement('div');\n pick.className = 'int-desc';\n pick.textContent = 'Pick a conversation to continue:';\n card.appendChild(pick);\n const list = document.createElement('div');\n list.className = 'restore-list';\n for (const conv of state.conversations) {\n const btn = document.createElement('button');\n btn.type = 'button';\n btn.className = 'restore-item';\n const preview = document.createElement('span');\n preview.className = 'restore-preview';\n preview.textContent = conv.preview || 'Conversation';\n btn.appendChild(preview);\n if (conv.lastActivityAt) {\n const when = document.createElement('span');\n when.className = 'restore-when';\n when.textContent = this.formatWhen(conv.lastActivityAt);\n btn.appendChild(when);\n }\n btn.addEventListener('click', () => {\n void this.controller?.restoreConversation(conv.sessionId);\n });\n list.appendChild(btn);\n }\n card.appendChild(list);\n }\n } else if (state.phase === 'error') {\n const err = document.createElement('div');\n err.className = 'int-error';\n err.textContent = state.message;\n card.appendChild(err);\n }\n\n return card;\n }\n\n /** Format an ISO timestamp as a short, locale-aware label (best-effort). */\n private formatWhen(iso: string): string {\n const d = new Date(iso);\n if (Number.isNaN(d.getTime())) return '';\n try {\n return d.toLocaleDateString(undefined, { month: 'short', day: 'numeric' });\n } catch {\n return '';\n }\n }\n\n /**\n * Wire as-you-type formatting + an inline validity hint onto the pre-chat\n * phone input (libphonenumber-js, US default region). Autofill is preserved:\n * the input keeps its `type=\"tel\"` + `autocomplete=\"tel\"` + implicit <label>,\n * and we also reformat on `change` so a browser-autofilled value gets\n * formatted/validated too.\n *\n * As-you-type caret note: `AsYouType` reformats the entire string, which\n * moves the caret to the end on a mid-string edit. To avoid fighting the\n * user, we only rewrite the value when the caret is at the end (the typical\n * append-a-digit case) and never on a deletion — so backspacing the\n * formatting characters works naturally.\n */\n private wirePhoneField(form: HTMLFormElement | null): void {\n const input = form?.querySelector('input[name=\"phone\"]') as HTMLInputElement | null;\n if (!input) return;\n const hint = input.parentElement?.querySelector('.pc-hint') as HTMLElement | null;\n\n const updateHint = () => {\n const v = input.value.trim();\n const field = input.closest('.pc-field');\n if (!v) {\n // Empty is neutral — the field is optional unless requirePhone.\n field?.classList.remove('valid', 'invalid');\n if (hint) hint.textContent = '';\n return;\n }\n const ok = isValidPhoneNumber(v, PHONE_DEFAULT_REGION);\n field?.classList.toggle('valid', ok);\n field?.classList.toggle('invalid', !ok);\n if (hint) hint.textContent = ok ? '' : 'Enter a valid phone number';\n };\n\n const reformat = () => {\n const atEnd = input.selectionStart === input.value.length && input.selectionEnd === input.value.length;\n // Only reformat when appending at the end; never fight a mid-string\n // edit or a deletion (see the caret note above).\n if (atEnd) {\n const formatted = new AsYouType(PHONE_DEFAULT_REGION).input(input.value);\n // Avoid clobbering when the user is deleting: only grow/normalize,\n // not when the formatter would re-add a character they just removed.\n if (formatted.length >= input.value.length) {\n input.value = formatted;\n }\n }\n updateHint();\n };\n\n input.addEventListener('input', (ev) => {\n const ie = ev as InputEvent;\n // Don't reformat while deleting — let the user clear characters freely.\n if (typeof ie.inputType === 'string' && ie.inputType.startsWith('delete')) {\n updateHint();\n return;\n }\n reformat();\n });\n // Browser autofill / paste-then-blur lands here; format + validate it too.\n input.addEventListener('change', reformat);\n }\n\n /** Collect identity + consent from the pre-chat form, then drop into the chat view. */\n private handlePrechatSubmit(form: HTMLFormElement): void {\n if (!form.reportValidity()) return;\n const data = new FormData(form);\n const val = (k: string) => ((data.get(k) as string | null)?.trim() || undefined);\n const checked = (k: string) => data.get(k) === 'on';\n\n // Phone: when required, block on an invalid number and surface the hint.\n // When optional, allow submit — the backend normalizes/nulls authoritatively.\n const rawPhone = val('phone');\n const phoneInput = form.querySelector('input[name=\"phone\"]') as HTMLInputElement | null;\n if (rawPhone && phoneInput && !isValidPhoneNumber(rawPhone, PHONE_DEFAULT_REGION)) {\n const required = phoneInput.hasAttribute('required');\n const field = phoneInput.closest('.pc-field');\n field?.classList.add('invalid');\n const hint = field?.querySelector('.pc-hint');\n if (hint) hint.textContent = 'Enter a valid phone number';\n if (required) {\n phoneInput.focus();\n return;\n }\n }\n // Prefer canonical E.164 when it parses; fall back to the raw value\n // otherwise (the backend re-parses + normalizes either way).\n const phone = rawPhone ? (phoneToE164(rawPhone) ?? rawPhone) : undefined;\n\n this.controller?.setUserInfo({\n name: val('name'),\n email: val('email'),\n phone,\n consent: { emailOptIn: checked('emailOptIn'), smsOptIn: checked('smsOptIn') },\n });\n this.userInfoSatisfied = true;\n this.render();\n void this.controller?.connect().catch(() => {});\n }\n\n /** Send a starter prompt (from a chip click). */\n private submitPrompt(text: string): void {\n if (!this.inputEl) return;\n this.inputEl.value = text;\n this.submit();\n }\n\n private syncOpenState(): void {\n // In full-page mode the panel always fills the host; nothing to toggle.\n if (this.panelEl?.classList.contains('fullpage')) {\n this.inputEl?.focus();\n return;\n }\n this.panelEl?.classList.toggle('hidden', !this.open);\n this.launcherEl?.classList.toggle('hidden', this.open);\n if (this.open) this.inputEl?.focus();\n }\n\n /** Grow the textarea with its content, up to the CSS max-height. */\n private autosize(): void {\n const ta = this.inputEl;\n if (!ta) return;\n ta.style.height = 'auto';\n ta.style.height = `${ta.scrollHeight}px`;\n }\n\n /**\n * Receive a new message snapshot from the controller and update the view.\n *\n * `onMessages` fires on *every* `stream_token` delta. Rebuilding the whole\n * list each frame is wasteful and fights the smooth reveal, so we take the\n * cheap path when the only change is the trailing streaming assistant message\n * growing: just bump the reveal *target* (the rAF loop drains it). Any\n * structural change (new message, finalize, citations) triggers a full\n * rebuild via {@link renderMessages}.\n */\n private handleMessages(messages: ChatMessage[], greeting: string): void {\n this.greeting = greeting;\n const prev = this.messages;\n const last = messages[messages.length - 1];\n const prevLast = prev[prev.length - 1];\n\n const structural =\n messages.length !== prev.length ||\n !last ||\n !prevLast ||\n last.id !== prevLast.id ||\n last.role !== prevLast.role ||\n // finalize transition (streaming → done) needs the markdown render + sources\n last.streaming !== prevLast.streaming ||\n // first token after the typing indicator needs the bubble swapped in\n (!!last.streaming && !prevLast.text && !!last.text) ||\n // a tool chip was added or resolved (text growth alone doesn't change this)\n this.blockSig(last) !== this.prevBlockSig;\n\n this.messages = messages;\n this.prevBlockSig = this.blockSig(last);\n\n if (!structural && last && last.streaming && this.tailKey(last) === this.streamMsgId) {\n // Fast path: the streaming (trailing) text just grew. Bump the reveal\n // target and let the rAF loop catch up — no DOM rebuild, no per-token\n // reflow. `tailText` is the live trailing text block for a tool turn, or\n // the whole message for a plain-prose turn.\n this.streamTarget = this.tailText(last);\n this.ensureRevealLoop();\n return;\n }\n\n this.renderMessages();\n }\n\n /** True when an assistant message's turn invoked at least one tool. */\n private hasToolBlocks(m?: ChatMessage): boolean {\n return !!m?.blocks?.some((b) => b.kind === 'tool');\n }\n\n /** Signature that changes only when a tool chip is added or resolved (text growth is 'x'). */\n private blockSig(m?: ChatMessage): string {\n if (!m?.blocks) return '';\n return m.blocks.map((b) => (b.kind === 'tool' ? `t:${b.tool.id}:${b.tool.done ? 1 : 0}` : 'x')).join('|');\n }\n\n /** The live (last) text block for a tool turn, else the whole message text. */\n private tailText(m: ChatMessage): string {\n if (this.hasToolBlocks(m) && m.blocks) {\n const last = m.blocks[m.blocks.length - 1];\n return last?.kind === 'text' ? last.text : '';\n }\n return m.text;\n }\n\n /** Reveal-binding key — composite for a tool-turn tail (so a new trailing block rebinds), else msg id. */\n private tailKey(m: ChatMessage): string {\n if (this.hasToolBlocks(m) && m.blocks) return `${m.id}#${m.blocks.length - 1}`;\n return m.id;\n }\n\n private renderMessages(): void {\n if (!this.messagesEl) return;\n this.resetReveal();\n this.messagesEl.replaceChildren();\n\n const greeting = this.greeting;\n if (this.messages.length === 0 && greeting) {\n this.messagesEl.appendChild(this.buildRow('assistant', this.greetingBubble(greeting)));\n }\n\n // Starter-prompt chips: shown until the visitor sends their first message.\n if (!this.hasSent && this.messages.length === 0 && this.examplePrompts.length > 0) {\n const chips = document.createElement('div');\n chips.className = 'prompts';\n for (const prompt of this.examplePrompts) {\n const chip = document.createElement('button');\n chip.type = 'button';\n chip.className = 'chip';\n chip.textContent = prompt;\n chip.addEventListener('click', () => this.submitPrompt(prompt));\n chips.appendChild(chip);\n }\n this.messagesEl.appendChild(chips);\n }\n\n for (const msg of this.messages) {\n // Tool-activity turns (gated by `showToolActivity`) render as an ordered\n // strip of prose bubbles + inline tool chips instead of one bubble.\n if (msg.role === 'assistant' && this.hasToolBlocks(msg)) {\n this.messagesEl.appendChild(this.buildRow('assistant', this.renderAssistantBlocks(msg)));\n if (!msg.streaming && msg.citations && msg.citations.length > 0) {\n this.messagesEl.appendChild(this.renderSources(msg.citations));\n }\n continue;\n }\n\n const bubble = document.createElement('div');\n bubble.className = `bubble ${msg.role}`;\n if (msg.role === 'assistant' && msg.streaming && !msg.text) {\n // No text yet → animated typing indicator.\n bubble.classList.add('typing');\n bubble.append(this.typingDot(), this.typingDot(), this.typingDot());\n } else if (msg.streaming) {\n // Mid-stream: partial/unclosed markdown renders ugly (half-open\n // `**`, dangling `[`), so keep plain text + the blinking cursor.\n // The text is revealed gradually by the rAF typewriter; seed the\n // bubble with whatever is already displayed and bind the reveal.\n bubble.classList.add('cursor');\n this.bindReveal(msg, bubble);\n } else if (msg.role === 'assistant') {\n // Final assistant turn → render the sanitized markdown subset.\n // `renderMarkdown` escapes all text, drops images, gates links to\n // http(s), and only emits an allowlisted set of tags, so this\n // `innerHTML` cannot inject markup (see markdown.ts).\n bubble.classList.add('md');\n bubble.innerHTML = renderMarkdown(msg.text);\n } else {\n // User bubbles stay plain text.\n bubble.textContent = msg.text;\n }\n this.messagesEl.appendChild(this.buildRow(msg.role, bubble));\n\n // Render a \"Sources (N)\" section under any assistant message whose\n // terminal eventual_response carried citations.\n if (msg.role === 'assistant' && !msg.streaming && msg.citations && msg.citations.length > 0) {\n this.messagesEl.appendChild(this.renderSources(msg.citations));\n }\n }\n this.scrollToBottom(true);\n this.renderSuggestions();\n }\n\n /**\n * Render (or clear) the mid-conversation suggested-reply chips under the\n * composer. Shown ONLY when: the feature is enabled, no interrupt / restore\n * overlay is active (those reuse the slot above the composer), and the LATEST\n * message is a finalized assistant turn that carried suggestions. A new turn\n * (agent or the visitor typing) appends messages, so the latest is no longer\n * that assistant message and the chips clear on the next render. Chips reuse\n * the empty-state `.prompts`/`.chip` styling and send via the same path.\n */\n private renderSuggestions(): void {\n const el = this.suggestionsEl;\n if (!el) return;\n el.replaceChildren();\n if (!this.showSuggestedReplies) return;\n // Hidden while an OTP / tool-confirmation / restore overlay is active.\n if (this.interrupt || this.identityRestore.phase !== 'idle') return;\n const last = this.messages[this.messages.length - 1];\n if (!last || last.role !== 'assistant' || last.streaming || !last.suggestions || last.suggestions.length === 0) return;\n\n const chips = document.createElement('div');\n chips.className = 'prompts';\n for (const suggestion of last.suggestions) {\n const chip = document.createElement('button');\n chip.type = 'button';\n chip.className = 'chip';\n chip.textContent = suggestion;\n chip.addEventListener('click', () => this.submitPrompt(suggestion));\n chips.appendChild(chip);\n }\n el.appendChild(chips);\n }\n\n // ─────────────────────── Smooth streaming reveal ───────────────────────────\n\n /** True when the host/user prefers reduced motion (snap, no typewriter). */\n private prefersReducedMotion(): boolean {\n return typeof matchMedia === 'function' && matchMedia('(prefers-reduced-motion: reduce)').matches;\n }\n\n /**\n * Bind the rAF typewriter to a freshly built streaming bubble. Preserves the\n * already-revealed prefix across rebuilds (so a structural rebuild mid-stream\n * doesn't restart the reveal from zero), then resumes the loop.\n */\n private bindReveal(msg: ChatMessage, bubble: HTMLElement): void {\n // `tailKey`/`tailText` collapse to the message id + full text for a plain\n // prose turn, and to the live trailing text block for a tool turn — so both\n // the single streaming bubble and a tool turn's trailing prose share this path.\n const key = this.tailKey(msg);\n const target = this.tailText(msg);\n const carryOver = key === this.streamMsgId ? Math.min(this.displayedLength, target.length) : 0;\n this.streamBubbleEl = bubble;\n this.streamMsgId = key;\n this.streamTarget = target;\n this.displayedLength = carryOver;\n\n if (this.prefersReducedMotion()) {\n // No animation: show everything immediately.\n this.displayedLength = target.length;\n bubble.textContent = target;\n return;\n }\n bubble.textContent = target.slice(0, this.displayedLength);\n this.ensureRevealLoop();\n }\n\n /**\n * Render a tool-activity assistant turn as an ordered strip: prose bubbles and\n * inline tool chips in the order the model produced them (mirrors the daemon\n * SPA's `blocks`). The live trailing text block (while streaming) binds to the\n * rAF reveal; earlier/finalized text blocks render as sanitized markdown.\n */\n private renderAssistantBlocks(msg: ChatMessage): HTMLElement {\n const wrap = document.createElement('div');\n wrap.className = 'blocks';\n const blocks = msg.blocks ?? [];\n const lastIdx = blocks.length - 1;\n blocks.forEach((block, i) => {\n if (block.kind === 'tool') {\n wrap.appendChild(this.buildToolChip(block.tool));\n return;\n }\n const bubble = document.createElement('div');\n bubble.className = 'bubble assistant';\n if (msg.streaming && i === lastIdx) {\n // Live trailing prose → plain text + cursor, driven by the reveal loop.\n bubble.classList.add('cursor');\n this.bindReveal(msg, bubble);\n } else {\n // Settled prose → sanitized markdown (same allowlisted renderer as bubbles).\n bubble.classList.add('md');\n bubble.innerHTML = renderMarkdown(block.text);\n }\n wrap.appendChild(bubble);\n });\n return wrap;\n }\n\n /**\n * A single tool-activity chip: icon + tool name + status (running… / done / error),\n * with a truncated args preview. Tool name/args are set via `textContent` so a\n * tool payload can never inject markup.\n */\n private buildToolChip(tool: ToolCall): HTMLElement {\n const chip = document.createElement('div');\n chip.className = `toolchip ${tool.done ? (tool.isError ? 'error' : 'done') : 'running'}`;\n chip.setAttribute('part', 'tool-chip');\n\n const icon = document.createElement('span');\n icon.className = 'ti';\n icon.innerHTML = ICON.tool; // static, trusted\n const name = document.createElement('span');\n name.className = 'tn';\n name.textContent = tool.name || 'tool';\n const status = document.createElement('span');\n status.className = 'ts';\n status.textContent = tool.done ? (tool.isError ? 'error' : 'done') : 'running…';\n chip.append(icon, name, status);\n\n if (tool.args && tool.args !== '{}' && tool.args !== '\"\"') {\n const args = document.createElement('span');\n args.className = 'ta';\n args.textContent = tool.args.length > 80 ? `${tool.args.slice(0, 80)}…` : tool.args;\n chip.appendChild(args);\n }\n return chip;\n }\n\n /** Start the rAF loop if it isn't already running. */\n private ensureRevealLoop(): void {\n if (this.prefersReducedMotion() || typeof requestAnimationFrame !== 'function') {\n // No animation (reduced-motion or no rAF): snap to the full buffer.\n this.snapReveal();\n return;\n }\n if (this.rafId) return; // already running\n this.rafId = requestAnimationFrame(() => this.tickReveal());\n }\n\n /**\n * One animation frame of the reveal. Advances `displayedLength` toward the\n * buffered target at an ADAPTIVE rate — the deeper the backlog, the more\n * chars per frame — so the reveal stays smooth yet never falls behind the\n * network. Updates ONLY the bound bubble's textContent (no list rebuild).\n */\n private tickReveal(): void {\n this.rafId = 0;\n const bubble = this.streamBubbleEl;\n if (!bubble) return;\n\n const target = this.streamTarget;\n const remaining = target.length - this.displayedLength;\n\n if (remaining <= 0) {\n // Caught up to everything buffered so far → idle. A later token bump\n // (handleMessages → ensureRevealLoop) restarts the loop; the finalize\n // structural rebuild snaps to the full markdown render.\n return;\n }\n\n // Adaptive speed: ~1/8 of the backlog per frame (≈ catch up over a few\n // frames), clamped to a readable floor so short bursts still animate and\n // an aggressive ceiling so a deep buffer drains fast. At ~60fps this\n // comfortably outruns the wire — the reveal is steady, never bursty.\n const step = Math.max(2, Math.min(remaining, Math.ceil(remaining / 8)));\n this.displayedLength = Math.min(target.length, this.displayedLength + step);\n bubble.textContent = target.slice(0, this.displayedLength);\n this.scrollToBottom(false);\n\n this.rafId = requestAnimationFrame(() => this.tickReveal());\n }\n\n /** Snap the bound bubble to the full buffered text immediately (reduced-motion / no-rAF). */\n private snapReveal(): void {\n if (this.streamBubbleEl) {\n this.displayedLength = this.streamTarget.length;\n this.streamBubbleEl.textContent = this.streamTarget;\n }\n }\n\n /**\n * Full-page sizing probe: decide whether the host's container gives it a\n * real box. With the `.wrap` flex chain hidden, `height: 100%` of a SIZED\n * container still resolves (clientHeight > 0), while an auto-height parent\n * (e.g. mounted straight into `<body>`) collapses to ~0. Only the latter\n * gets `data-viewport-fallback`, whose CSS applies `min-height: 100dvh` —\n * so an embed inside a fixed-height box never overflows it (the composer\n * stays visible), and a bare full-page route still fills the viewport.\n */\n private syncViewportFallback(): void {\n const wrap = this.shadowRoot?.querySelector<HTMLElement>('.wrap');\n if (!wrap) return;\n const prev = wrap.style.display;\n wrap.style.display = 'none';\n const heightless = this.clientHeight < 8;\n wrap.style.display = prev;\n this.toggleAttribute('data-viewport-fallback', heightless);\n }\n\n /** Cancel any in-flight reveal loop and clear its state (called on full rebuild). */\n private resetReveal(): void {\n if (this.rafId && typeof cancelAnimationFrame === 'function') cancelAnimationFrame(this.rafId);\n this.rafId = 0;\n this.streamBubbleEl = null;\n // streamMsgId/displayedLength are intentionally kept so bindReveal can\n // carry the revealed prefix across a structural rebuild of the same msg;\n // they're reset when a different message binds.\n }\n\n /**\n * Auto-scroll the message list to the bottom — but don't fight a visitor who\n * has scrolled up to read history. When `force` (a structural rebuild) we\n * always pin to bottom; during the streaming reveal we only follow if the\n * viewport is already near the bottom.\n */\n private scrollToBottom(force: boolean): void {\n const el = this.messagesEl;\n if (!el) return;\n if (force) {\n el.scrollTop = el.scrollHeight;\n return;\n }\n const nearBottom = el.scrollHeight - el.scrollTop - el.clientHeight < 80;\n if (nearBottom) el.scrollTop = el.scrollHeight;\n }\n\n /** Wrap a bubble in a `.row`, prefixing assistant rows with a mini avatar. */\n private buildRow(role: 'user' | 'assistant', bubble: HTMLElement): HTMLElement {\n const row = document.createElement('div');\n row.className = `row ${role}`;\n if (role === 'assistant') {\n const mini = document.createElement('div');\n mini.className = 'mini';\n mini.innerHTML = ICON.bot; // static, trusted\n row.appendChild(mini);\n }\n row.appendChild(bubble);\n return row;\n }\n\n private greetingBubble(greeting: string): HTMLElement {\n const b = document.createElement('div');\n b.className = 'bubble assistant greeting';\n b.textContent = greeting;\n return b;\n }\n\n private typingDot(): HTMLElement {\n return document.createElement('i');\n }\n\n /**\n * Build the collapsible \"Sources (N)\" block for an assistant message's\n * citations. Title/snippet are set via `textContent` (never innerHTML) so\n * citation text can't inject markup; only the static chevron + numeric count\n * use innerHTML.\n */\n private renderSources(citations: Citation[]): HTMLElement {\n const wrap = document.createElement('div');\n wrap.className = 'sources';\n wrap.setAttribute('part', 'sources');\n\n const details = document.createElement('details');\n details.open = true;\n\n const summary = document.createElement('summary');\n const chev = document.createElement('span');\n chev.className = 'chev';\n chev.innerHTML = ICON.chev; // static, trusted\n const label = document.createElement('span');\n label.textContent = 'Sources';\n const count = document.createElement('span');\n count.className = 'count';\n count.textContent = String(citations.length);\n summary.append(chev, label, count);\n details.appendChild(summary);\n\n const list = document.createElement('ol');\n for (const c of citations) {\n const li = document.createElement('li');\n\n let titleEl: HTMLElement;\n // SECURITY: only absolute http(s) URLs may become a link href. A\n // citation URL comes from indexed content (web/GitHub connectors), so\n // an attacker-influenceable doc could carry `javascript:`/`data:`/\n // `vbscript:` — assigning those to `a.href` is a one-click XSS. Anything\n // that isn't a valid absolute http(s) URL renders as plain text.\n const safeUrl = safeHttpUrl(c.url);\n if (safeUrl) {\n const a = document.createElement('a');\n a.className = 'src-title';\n a.href = safeUrl;\n a.target = '_blank';\n a.rel = 'noopener noreferrer nofollow';\n titleEl = a;\n } else {\n titleEl = document.createElement('span');\n titleEl.className = 'src-title';\n }\n titleEl.textContent = c.title || c.id || 'Source';\n li.appendChild(titleEl);\n\n if (c.snippet) {\n // The snippet is the raw scraped chunk — often led by page\n // boilerplate (logo link, nav, whitespace). Trim it to a clean\n // excerpt, then render the sanitized markdown subset. Both steps\n // escape text + drop images/unsafe links (see markdown.ts), so\n // this `innerHTML` is safe.\n const cleaned = cleanCitationSnippet(c.snippet);\n if (cleaned) {\n const snip = document.createElement('span');\n snip.className = 'src-snippet md';\n snip.innerHTML = renderMarkdown(cleaned);\n li.appendChild(snip);\n }\n }\n list.appendChild(li);\n }\n details.appendChild(list);\n wrap.appendChild(details);\n return wrap;\n }\n\n private renderStatus(): void {\n const label: Record<ConnectionStatus, string> = {\n idle: '',\n connecting: 'Connecting…',\n ready: 'Online',\n error: 'Connection issue',\n closed: 'Disconnected',\n };\n if (this.statusEl) this.statusEl.textContent = label[this.status];\n if (this.dotEl) {\n // ready → green (no modifier); connecting → amber; error → red; else grey.\n const mod = this.status === 'ready' ? '' : this.status === 'connecting' ? ' connecting' : this.status === 'error' ? ' error' : ' off';\n this.dotEl.className = `dot${mod}`;\n }\n }\n\n private renderComposerState(): void {\n const busy = this.status === 'connecting';\n if (this.sendBtn) this.sendBtn.disabled = busy;\n if (this.inputEl) this.inputEl.disabled = busy;\n }\n\n private submit(): void {\n if (!this.inputEl || !this.controller) return;\n const text = this.inputEl.value;\n if (!text.trim()) return;\n this.inputEl.value = '';\n this.hasSent = true;\n this.autosize();\n void this.controller.send(text);\n }\n}\n\n/** Register the custom element once. Safe to call multiple times. */\nexport function defineChatWidget(): void {\n if (typeof customElements !== 'undefined' && !customElements.get(ELEMENT_TAG)) {\n customElements.define(ELEMENT_TAG, SmoothAgentChatElement);\n }\n}\n\n/**\n * Programmatically create, configure, and append a widget to the page.\n * Returns the element so the host can drive `openChat()` / `closeChat()`.\n */\nexport function mountChatWidget(config: ChatWidgetConfig, target: HTMLElement = document.body): SmoothAgentChatElement {\n defineChatWidget();\n const el = document.createElement(ELEMENT_TAG) as SmoothAgentChatElement;\n el.configure(config);\n target.appendChild(el);\n return el;\n}\n\n/**\n * Ergonomic helper for the full-page layout: mounts a `<smooth-agent-chat>` in\n * `mode: \"fullpage\"` (no launcher — the chat fills its container/viewport with a\n * Smooth-branded header, a scrollable message list, and an input bar) and\n * returns the element.\n *\n * `target` defaults to `document.body`; pass a sized container to embed the\n * full-page chat inside a layout region (e.g. a `/chat` route shell or an\n * iframe). The `mode` is forced to `\"fullpage\"` regardless of the passed config.\n *\n * ```ts\n * mountFullPageChat({ endpoint: 'wss://…/ws', agentId: '…', agentName: 'Support' });\n * ```\n */\nexport function mountFullPageChat(config: Omit<ChatWidgetConfig, 'mode'>, target: HTMLElement = document.body): SmoothAgentChatElement {\n return mountChatWidget({ ...config, mode: 'fullpage' }, target);\n}\n","/**\n * Standalone IIFE entry. Bundled (with the protocol client inlined) into\n * `dist/chat-widget.global.js` for a plain `<script src=\"…\">` embed.\n *\n * On load it:\n * - registers the `<smooth-agent-chat>` custom element, and\n * - exposes the programmatic API on the IIFE global `SmoothAgentChat`\n * (`window.SmoothAgentChat.mount({ endpoint, agentId })`).\n *\n * A host page can then either drop the element in markup:\n * <smooth-agent-chat endpoint=\"wss://…/ws\" agent-id=\"…\"></smooth-agent-chat>\n * or mount it programmatically:\n * SmoothAgentChat.mount({ endpoint: 'wss://…/ws', agentId: '…' });\n */\nimport type { ChatWidgetConfig } from './config.js';\nimport { defineChatWidget, mountChatWidget, mountFullPageChat, SmoothAgentChatElement } from './element.js';\n\ndefineChatWidget();\n\nexport { defineChatWidget, mountChatWidget, mountFullPageChat, SmoothAgentChatElement };\n\n/** Convenience alias matching the global API surface (`SmoothAgentChat.mount`). */\nexport function mount(config: ChatWidgetConfig, target?: HTMLElement): SmoothAgentChatElement {\n return mountChatWidget(config, target);\n}\n\n/**\n * Full-page convenience alias (`SmoothAgentChat.mountFullPage`): mounts the chat\n * in `mode: \"fullpage\"` so it fills its container/viewport with no launcher.\n */\nexport function mountFullPage(config: Omit<ChatWidgetConfig, 'mode'>, target?: HTMLElement): SmoothAgentChatElement {\n return mountFullPageChat(config, target);\n}\n"],"x_google_ignoreList":[0,1,2,3,4,5,6,7,8,9,10,11,12,13,14,15,16,17,18,19,20,21,22,23,24,25,26,27,28,29,30,31,32,33,34,35,36,37,38,39,40,41,42,43,44,45,46,47,48,49,50,51,52,53,56,57,58,60,61],"mappings":";;;CAGA,IAAA,4BAAe;EAAC,WAAU;EAAE,yBAAwB;GAAC,KAAI;IAAC;IAAK;IAAK;IAAK;IAAK;IAAK;IAAK;IAAK;IAAK;IAAK;IAAK;IAAK;IAAK;IAAK;IAAK;IAAK;IAAK;IAAK;IAAK;IAAK;IAAK;IAAK;IAAK;IAAK;IAAK;GAAI;GAAE,KAAI,CAAC,MAAK,IAAI;GAAE,MAAK,CAAC,IAAI;GAAE,MAAK,CAAC,IAAI;GAAE,MAAK,CAAC,IAAI;GAAE,MAAK,CAAC,IAAI;GAAE,MAAK,CAAC,IAAI;GAAE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